Another burnin fix
This is a result of the log timestamp changes.
Reviewed-by: imsnah
Unify SetupDaemon/SetupLogging
The 'old-style' info, error, debug logs do not make much sense. Thispatch unifies the SetupLogging and SetupDaemon functions. As a result,all the commands logs to a 'commands.log' file.
The patch also changes the log setup to keep going if there's an error...
Improve cli.SubmitOpCode
Currently, the feedback_fn argument to SubmitOpCode is no longer used.We still need it in burnin, so we re-enable it by making the code callthat function with the msg argument in case feedback_fn is callable. Thepatch also modifies burnin to accept the new argument format (msg is not...
Burnin doesn't need a Processor
In 2.0 burnin submits job to the master daemon, so it doesn't need tocreate an internal Processor anymore. Even if the processor is not usedanywhere in the burnin code it was still initialized as a leftover ofhow burnin used to work. Fixing this....
cfgupgrade: Implement upgrading to Ganeti 2.0 configuration
Reviewed-by: iustinp
cfgupgrade: Add main() function
cfgupgrade: Add logging module
Use a single Makefile.am instead of many
This change allows us to use cleaner dependencies betweendirectories. The build system is basically rewritten in large partsand may contain bugs.
Burnin: Use iallocator in import/export
Currently the iallocator option is ignored by burnin at import/exporttime even if passed in. With this patch it becomes used. The log messageused by the importer is also changed to reflect this.
This patch also improves import/export on the non-iallocator case:...
Replace logging functions with calls to logging module
- Shorter code- Reorder arguments to logger.SetupLogging calls to make more sense
LURemoveInstance: fix op.ignore_failures usage
Currently: the LURemoveInstance.Exec() method uses the ignore_failuresattribute of the OpRemoveInstance opcode, but it doesn't check for itsexistence. The patch adds this attribute to _OP_REQP and to all the...
Move the 'cmd' lock from cli.py to ganeti-masterd
This patch removes the lock and the lock options from cli.py and movesthem to the master.
Later during development we can remove it completely, but for now it'sgood to protect any other tool that uses the lock directly....
Convert cli.SubmitOpCode to use the master
This patch converts the cli.py SubmitOpCode method to use the unixprotocol and thus execute the opcodes via the master.
The patch allows a partial burnin to work with the master. Currently thequery opcodes, since they are executed via the SubmitOpCode, are...
Implement replace secondary via the iallocator
This patch implements secondary replace via the iallocator. The newopcode parameter 'iallocator' behaves like this: if passed, it willalways compute and assign a new secondary, behaving in effect as if the...
Implement memory size option for burnin
This simple patch adds memory size for the burnin instances, which helpstesting allocator algorithm response based on the available node memoryand instance memory size values.
Reviewed-by: ultrotter
Fix burnin ImportExport CreateInstance opcode
This patch adds the two attributes file_storage_dir and file_driverto the CreateInstance opcode in the ImportExport method, sinceotherwise it will fail with the file storage patches.
burnin: improve instance create message
When the allocator or a non-mirrored template are used the message shown byburnin at instance creation time was wrong. Fixing it.
burnin: remove created exports
Make burnin remove exports after importing the instance back.
Add instance rename to burnin
This patch adds the possibility to execute instance renaming whendoing a cluster burnin. The optional parameter --rename takesone 'spare' instance name.Given this option it renames all given instances to the spare oneand back to their original name....
Allow burnin to use an iallocator in instance creation
This patch adds iallocator support to burnin, currently only in instancecreation. This means that, depending on the external algorithm, not allnodes might get instances.
The patch also restricts node selection and iallocator options together....
Modify burnin to support file storage backend
This patch does two things:- adjusts burnin to work with the file storage backend patches- adds the possibilty to do a burnin for file based instances
Rework the results of OpDiagnoseOS opcode
Currently, the opcode DiagnoseOS is the only opcode that return astructure of objects.OS (which is a custom class, and not a simplepython object) and furthermore all the processing of OS validity acrossnodes is left to the clients of this opcode....
Remove support for Pickle configuration files
Add more explicit help for command line
Update copyright year, imports of cfgupgrade
Remove the option to create md/drbd7 instances
This patch removes the options that allow to create local_raid1 orremote_raid1 instances. It also modifies the documentation and removesthese disk templates from burnin and from qa.
Codestyle fixes: adding a few empty lines
Revert "Include the DRBD upgrade tool in the dist archive"
This reverts commit 604 as the upgrade tool should not be in the 1.3 branch.
Reviewed-by: schreiberal
Include the DRBD upgrade tool in the dist archive
This patch adds the DRBD upgrade tool in the archive and in theinstalled tools dir, and its associated README in the doc_DATA target.
Two small improvements to burnin
This tiny patch fixes the verbose option to actually work, and also whencreating instances it logs the secondary node too (even if this doesn'tapply for plain templates, it doesn't create an error).
Change the install directory for the tools
Currently, the tools are installed under $prefix/share/ganeti. Thisprevents installing other things in a nice way under share/ganeti (likearch-independent OS definitions), therefore we want the tools to liveunder share/ganeti/tools....
Allow use of 'diskless' disk template in burnin
Even if this doesn't have any practical use for actually creatinginstances, it can be used for very fast burnin and testing just theadd/start/stop/remove functionality.
This has also revealed a bug in export/import related to diskless...
Make instance start/stop skippable at burnin time
Even though burnin was born just to do that test it now contains a lot morethings one might try, so it makes sense to make instance start/stop optionaltoo.
This creates a burnin that at the bare minimum tests instance create and...
Do instance export and import during burnin
Instances get exported to a remote node, then removed and imported back totheir original nodes. This should be an idempotent option from the instancepoint of view, and help making sure ImportExport is kept up to date....
Allow burnin to take "-t plain" as an option
The burnin code deals with "-t plain", but the command line parserdoesn't allow that as an option. This patch fixes this issue.
Support selecting the boot device order for HVM.
This patch adds support for specifying and changing the boot device order forHVM instances. The boot device order specification is ignored for non HVMinstances.
Add the new OpCreateInstance parameters to burnin
Various code style fixes for strings.
- When line wrapping is needed, move spaces to the next line.- Remove embedded line breaks from error messages.
Flush stdout after printing a message during burnin.
Replace disk template drbd8 with drbd where missing.
Code style fixes for burnin.
Simplify burnin output
Currently, the burnin output is very verbose (we log the entire outputfrom LU feedback) and duplicate in some cases (as we enable debugging).
This patch disables debugging and only logs the burnin output when anerror occurs.
Refactor burnin to improve disk replacement
This patch changes the burnin: - split the code into functions - add replace2 (replace the secondary) for remote_raid1 - add replace1/2 for drbd8
Add option to burnin only a given set of nodes
This patch adds a '-n' option to burnin that takes a comma-separatedlist of nodes to perform the burnin on.
Improve burnin with regard to drbd8
Allow burnin to use the new drbd8 template (for which case one needs todisable replacement of disks, burnin does yet support that with drbd8).
The patch also changes do-replace12 to no-replace12 as that is whatthey actually do....
Fix usage of OpReplaceDisks.
Change the signature of some methods of mcpu.Processor
This patch moves the passing of the feedback_fn argument from the(Exec|Chain)OpCode to the initialization of the Processor instance.
Change configuration storage format from Pickle to JSON.
- Add NEWS file with major changes between versions.- Bump RPC version number- No longer serialize in RPC, but just convert to dict
Old Pickle based configuration files can be converted using the cfgupgrade...
Fix tools/burnin w.r.t. OpCreateInstance.ip_check
Since we added a new, required parameter to OpCreateInstance, we need toupdate burnin to build the correct opcode.
Change OpQueryNodes nodes attribute to names
Change this to have the exact same parameters as OpQueryInstances.
Also fix burnin which is broken since r146.
Style changes for pep-8 and python-3000 compliance.
This changes the raising of exceptions from: raise Exception, valueto raise Exception(value)
as the first form will be removed in python-3000 and the second form ispreferred now.
The changes also involve a few cases of changing from raising standard...
Implement --dry-run for cfgupgrade.
Add configuration upgrade utility.
Move the cluster name from ConfigWriter to SimpleStore.
Reason: if left ConfigWriter, nodes don't know to which cluster they belong.This will bite us later when we'll revisit node join operation.
Cons: we lose the cluster name from the config file, which means a...
Implement “cd /” and “cd” to get to the root directory.
Replace tabs with spaces.
Fix burnin - when removed from cmdlib, it lost locking functionality.
Also improve the burnin by doing an optional replace-disks.
Initial commit.