You need to sign in or sign up before continuing.
- Jan 27, 2009
-
-
Iustin Pop authored
This patch changes the multi-instance gnt-* commands (gnt-instance start/stop, gnt-node evacuate/failover) such that the individual operations are submitted in parallel, ideally improving the speed of the execution. The patch does this by abstracting the job set functionality into a new class in cli.py, that takes care of the job submit, job poll and error handling. Reviewed-by: ultrotter
-
- Jan 12, 2009
-
-
Iustin Pop authored
This patch makes gnt-cluster copyfile and command skip the offline nodes. Reviwed-by: ultrotter, imsnah
-
- Dec 17, 2008
-
-
Michael Hanselmann authored
A job queue with too many jobs can increase memory usage and/or make the master daemon slow. The current limit is just an arbitrary number. A "soft" limit for automatic job archival is prepared. Reviewed-by: iustinp
-
- Dec 11, 2008
-
-
Iustin Pop authored
This patch should fix all outstanding epydoc parsing errors; as such, we switch epydoc into verbose mode so that any new errors will be visible. Reviewed-by: imsnah
-
- Nov 28, 2008
-
-
Michael Hanselmann authored
- Add new "canceling" status - Notify clients when job is canceled - Give a return value from CancelJob - Handle it in the client library Reviewed-by: iustinp
-
- Nov 27, 2008
-
-
Iustin Pop authored
Currently, job failures are done by raising OpExecError(job result). For a one-opcode job that failed, this is very non-intuitive: Failure: command execution error: [u'Disk size change not possible, use grow-disk'] This patch changes the output in two ways: - for a job which didn't have opcodes which succeeded, it changes it to: Failure: command execution error: Disk size change not possible, use grow-disk - for a job with partial completion, to: Failure: command execution error: partial failure (opcode 1): Cannot remove the last disk of an instance The actual error type is not changed. A job that doesn't have at least an error-ed opcode is shown as before. Reviewed-by: imsnah
-
- Nov 23, 2008
-
-
Iustin Pop authored
This patch enables by default the old 'human-readable' option, but in a slightly different model. The option is now called "units" and takes either: - 'h' for automatic formatting - 'm', 'g' or 't' for mebi/gibi/tebibytes If 'h' is used, we add a unit suffix, otherwise nothing is added so that parsing is easy. The default value of this unit is: - 'h' if a separator is not passed - 'm' if a separator is passed Reviewed-by: ultrotter
-
- Nov 21, 2008
-
-
Iustin Pop authored
This changes cli.py to FieldSet usage so that gnt-instance list will format nicely the disk.size/*, and the count of disks/nics. Reviewed-by: ultrotter
-
Michael Hanselmann authored
ganeti-masterd: Add initialization and shutdown of RPC pool. It needs to be shutdown before forking. ganeti.cli: Add decorator function to initialize and shutdown RPC pool. ganeti.rpc: Add functions to initialize and shutdown RPC pool. Throw exception when used without proper initialization. gnt-cluster, gnt-node: Use decorator function to initialize and shutdown RPC pool. Reviewed-by: iustinp
-
- Nov 18, 2008
-
-
Iustin Pop authored
This patch adds support for querying in gnt-instance list of: - disk.count - nic.count - disk.size/$N - nic.(ip|mac|bridge)/$N The patch also disables the exception raised when the header description is missing, that should be fixed in the future (together with better handling of variable numeric fields). Reviewed-by: imsnah
-
- Oct 23, 2008
-
-
Iustin Pop authored
Currently we don't catch the JobSubmittedException (although the code to format it nicely is there). The patch adds the exception name to the catch list and makes --submit work. Reviewed-by: imsnah
-
- Oct 20, 2008
-
-
Iustin Pop authored
Since now we use only one function from the logger module (SetupLogging), we move it to utils.py (which is already imported by all users of this function), and we remove the module. Reviewed-by: imsnah
-
Iustin Pop authored
We also add two function for printing messages, so that scripts won't have to import logger to get these. They are a simple extension over the logger ones, as they accept the call style from logging: ToStdout("Message: %s", msg) (instead of requiring formatting by the client. Reviewed-by: imsnah
-
- Oct 15, 2008
-
-
Iustin Pop authored
We add a (per-node) queue drain flag that blocks new job submission. There is not yet an interface to add/remove the flag (will come in next patches). Reviewed-by: imsnah
-
- Oct 14, 2008
-
-
Iustin Pop authored
This is used to validate the parameters in both “gnt-instance add” and “gnt-backup import”. Reviewed-by: ultrotter
-
Iustin Pop authored
This patch adds paramter removal in SplitKeyVal, by prefixing a value-less key with "-"; this is needed in resetting parameters back to cluster defaults, but care must be applied now that None can come from the parser. Reviewed-by: imsnah
-
- Oct 13, 2008
-
-
Iustin Pop authored
For the new 2.0-style command line options, we need to parse strings of the type: ident:key=val[,...] and key=val[,...] This patch adds two new option builders for these two, which return (ident, {key=val,}) and {key=val,} for the above two formats. It also handles specially constructs of type “key” (val is set to True) and “no_key” (val is set to False, and the ‘no_’ prefix is stripped). Reviewed-by: imsnah
-
- Oct 06, 2008
-
-
Iustin Pop authored
This patch adds a new luxi call that implements auto-archiving of jobs older than a certain age (or -1 for all completed jobs), and the gnt-job command that makes use of this (with 'all' for -1). Reviewed-by: imsnah
-
Iustin Pop authored
This function will be used for auto-archiving jobs via the command line. The function is pretty simple, we only support up to weeks since months and higher are not 'precise' entities, and dealing with them would require us to start using calendar functions. Reviewed-by: imsnah
-
Iustin Pop authored
In case the job object doesn't have a timestamp (which is a separate issue), the listing should not break. We fix this by changing the FormatTimstamp function itself to return '?' in case the timestamp doesn't look good (note that it still can break if non-integers are returned, but this is unlikely). Reviewed-by: imsnah
-
- Oct 01, 2008
-
-
Iustin Pop authored
Curently PollJob accepts a generic job, but will return (history artifact) only the first opcode result. This is wrong, as it doesn't allow polling of a job with multiple results. Its only caller (for now) is also changed, so no functional changes should happen. Reviewed-by: ultrotter, amishchenko
-
- Sep 30, 2008
-
-
Iustin Pop authored
Currently we format the timestamp inside the gnt-job info function. We will need this more times in the future, so move it to cli.py as a separate, exported function. Reviewed-by: imsnah
-
- Sep 10, 2008
-
-
Iustin Pop authored
The "sys.exit(0)" was not nice as you couldn't differentiate it from other exit codes. We change this to a specially defined exception for this, so that multi-opcode commands can handle this nicely. Reviewed-by: imsnah
-
- Aug 28, 2008
-
-
Michael Hanselmann authored
Reported by Iustin. Reviewed-by: iustinp
-
- Aug 27, 2008
-
-
Michael Hanselmann authored
This is a large patch, but I can't figure out how to split it without breaking stuff. The old way of getting messages by always getting the last one didn't bring all messages to the client if they were added too fast, thereby making commands like “gnt-cluster verify” less than useful. These changes now introduce some sort a serial number per log entry to keep track what message a client already received. They also remove the log lock per opcode to make reading log entries thread safe. Reviewed-by: ultrotter
-
- Aug 11, 2008
-
-
Michael Hanselmann authored
This means commands will not take at least one second anymore. Reviewed-by: ultrotter
-
Michael Hanselmann authored
See the comment in the patch. Reviewed-by: ultrotter
-
- Aug 07, 2008
-
-
Michael Hanselmann authored
feedback_fn wasn't passed to it. Reviewed-by: iustinp
-
- Aug 04, 2008
-
-
Iustin Pop authored
This patch adds the infrastructure for executing a job in background, instead of foreground, via a new “--submit” option. The behaviour is that the job ID is printed and the script will immediately exit. The patch also converts gnt-node list to this model (yes, this will be a query in the future). Reviewed-by: imsnah
-
- Jul 31, 2008
-
-
Iustin Pop authored
The current SubmitOpCode function is not flexible enough to be used for submitters that don't want to wait for the job finish. The patch splits this in two, a SendJob function and a PollJob one, and the old SubmitOpCode becomes a wrapper. Note that the new SendJob takes a list of opcodes (and not a single opcode anymore). Reviewed-by: imsnah
-
- Jul 30, 2008
-
-
Iustin Pop authored
This patch adds a check that we are on the master after failing to connect to the socket, and log nicely the master name. Reviewed-by: ultrotter
-
Iustin Pop authored
This is mostly: - whitespace fix (space at EOL in some files, not all, broken indentation, etc) - variable names overriding others (one is a real bug in there) - too-long-lines - cleanup of most unused imports (not all) Reviewed-by: ultrotter
-
Iustin Pop authored
The 'old-style' info, error, debug logs do not make much sense. This patch 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 in setting up the file logging but we're logging to stderr. Also, burnin now logs to its own file (burnin.log). Reviewed-by: ultrotter
-
- Jul 14, 2008
-
-
Iustin Pop authored
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 call that function with the msg argument in case feedback_fn is callable. The patch also modifies burnin to accept the new argument format (msg is not a triple instead of a string). The patch also removes the ‘proc’ argument as it's obsolete; instead we can accept a luxi.Client instance (noone uses this right now). Reviewed-by: ultrotter
-
Iustin Pop authored
This patch contains a raw version for fixing feedback_fn. The new mechanism works as follows: - instead of a per-Processor feedback_fn, there's one for each ExecOpCode, so that feedback for different opcodes go via possibly different functions - each _QueuedOpCode gets a message buffer, a method for adding feedback and a method for retrieving (parts of) the feedback - the _QueuedJob object gets a new attribute that is equal to the index of the currently executing opcode - job queries get an extra parameter called 'ticker' that will return the latest message on the current executing opcode - the cli.py job completion poll will show the new status if different from the old one Of course, quick messages will be lost, as currently only the latest one is available. Also changes between opcodes are not represented at all. Reviewed-by: imsnah
-
- Jul 11, 2008
-
-
Michael Hanselmann authored
"gnt-job list" was broken after my recent changes in the RPC between clients and the master. This patch makes it work again. Reviewed-by: iustinp
-
- Jul 09, 2008
-
-
Michael Hanselmann authored
- Introduce abstraction class on client side - Use constants for method names - Adopt legacy function SubmitOpCode to use it Reviewed-by: iustinp
-
- Jul 03, 2008
-
-
Iustin Pop authored
By a mistake, we don't reuse the luxi client. As such, we open and close the connection at each poll cycle and spam the server logs. Reviewed-by: ultrotter
-
- Jun 21, 2008
-
-
Iustin Pop authored
Currently the generic handling of ganeti errors in cli.py (GenericMain and FormatError) only handles the core ganeti errors, and not the client protocol errors (which live in a separate hierarchy). This patch adds handling of luxi errors too, and also adds another luxi error for the case when the master is not running. This gives us a nice: gnta1:~# gnt-node list Cannot communicate with the master daemon. Is it running and listening on '/var/run/ganeti-master.sock'? error message instead of a traceback. Reviewed-by: amishchenko
-
- Jun 13, 2008
-
-
Michael Hanselmann authored
- Shorter code - Reorder arguments to logger.SetupLogging calls to make more sense Reviewed-by: iustinp
-