- Mar 10, 2010
-
-
Michael Hanselmann authored
When username and password were sent for a resource not requiring authentication, it wouldn't be accepted if the user in question had a hashed password. The reason was that the function GetAuthRealm used to return None if no authentication was necessary. However, the authentication realm is necessary to verify hashed passwords. This is fixed by requiring GetAuthRealm to always return a realm and separating the decision whether to require authentication or not to a separate function. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Mar 08, 2010
-
-
Iustin Pop authored
This passes a full burnin with lots of instances, and should be safe as we mostly to join a known root (various constants) to a run-time variable. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Feb 26, 2010
-
-
Michael Hanselmann authored
By opening the lock file early, other programs can lock the state file to prevent ganeti-watcher from restarting daemons. Using the pause feature is inherently prone to race conditions. Before a traceback was logged when the lock file couldn't be acquired. Now it'll be a more friendly message. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
This is going to be used from the nbma repository, to ensure that the nld daemon is running. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
These hooks are run on all nodes, after the "base" daemons are started. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Guido Trotter authored
We're using a separate function for this, as we're going to add some functionality to this feature. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Feb 23, 2010
-
-
Michael Hanselmann authored
If activating disks fails for some reason, the watcher didn't catch the exception. With this patch it's caught and logged. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Feb 22, 2010
-
-
Guido Trotter authored
This class doesn't need its constructor to be called. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Feb 18, 2010
-
-
Michael Hanselmann authored
This function could be useful in other places and this way we can easily unittest it. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Feb 17, 2010
-
-
Michael Hanselmann authored
snap_disks can contain boolean values. They weren't handled correctly. The error message was “Error while executing backend function: Invalid object passed to FromDict: expected dict, got <type 'bool'>”. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Feb 03, 2010
-
-
Iustin Pop authored
This doesn't implement the full functionality, we need to add the debug level to the opcodes too, but at least won't require changing the RPC calls during the 2.1 series. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Feb 02, 2010
-
-
Elmar Hoffmann authored
This is from Debian Bug#568105. ganeti-cleaner in one case erroneously calls "echo 0" instead of "exit 0". As ganeti-cleaner is called in the daily cronjob, this leads to a daily mail containing just "0" with an unconfigured default install. Signed-off-by:
Elmar Hoffmann <elho@elho.net> Reviewed-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com> Signed-off-by:
Iustin Pop <iustin@google.com>
-
- Jan 28, 2010
-
-
Guido Trotter authored
Ganeti-confd should be running on all 2.1 nodes. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jan 27, 2010
-
-
Iustin Pop authored
In case the queue dir cannot be create/initialized, currently ganeti-noded exits. This means that a read-only filesystem or a permission error breaks all node daemon functionality, including powercycle. This is not good for the usual failure case for nodes. To workaround this, we don't require successful initialization at node daemon startup; if we can't init the queue dir/lock, we retry at every RPC call requiring a job queue lock, and if we still can't acquire the lock, we raise an exception (which is catched in HandleRequest and transformed into an RPC failure). This allows the node daemon to start in face of queue issues, and the master node to power-cycle it. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
In some versions of bash, here-docs and here-strings use temporary files, which means daemon-util needs a writable temporary filesystem. Since echo is a bash builtin anyway, it's simple to switch to it and remove this dependency. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Jan 19, 2010
-
-
Michael Hanselmann authored
This patch fixes a quoting issue in daemon-util: $ EXTRA_MASTERD_ARGS=--no-voting /etc/init.d/ganeti restart […] * ganeti-masterd... /…/ganeti/daemon-util: line 65: local: `--no-voting': not a valid identifier The reason was that the generated variables were not quoted properly and the troublesome line expanded to “local args=$MASTERD_ARGS $EXTRA_MASTERD_ARGS” instead of the correct “local args="$MASTERD_ARGS $EXTRA_MASTERD_ARGS"”. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jan 13, 2010
-
-
Michael Hanselmann authored
Having a proper name instead of just a number makes debugging easier. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jan 05, 2010
-
-
Iustin Pop authored
This changes from submitting jobs to get the tags (in cli scripts) to queries, which (since the tags query is a cheap one) should be much faster. The tags queries are already done without locks (in the generic query paths for instances/nodes/cluster), so this shouldn't break tags query via gnt-* list-tags. On a small cluster, the runtime of gnt-cluster/gnt-instance list tags more than halves; on a big cluster (with many MCs) I expect it to be more than 5 times faster. The speed of the tags get is not the main gain, it is eliminating a job when a simple query is enough. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
- Jan 04, 2010
-
-
Iustin Pop authored
In some cases pylint doesn't parse the import correctly, so we add silences; but there are also many cases of unused imports, which we simply remove. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
Two variables are used in a strange way in ExecConfd. Until that is clarified, add a TODO and a silence for the unused variable warning. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
Many of our functions have to follow a given API, and thus we have to keep a given signature, but pylint doesn't understand this. Therefore, we silence this warning. The patch does a few other cleanups. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
Of all daemons, only rapi did abort when given argument. None of our daemons use any arguments, but they accepted them blindly. This is a very bad experience for the user. This patch adds checking and exiting in all daemons, in a uniform way. One other option would have been to add a flag to GenericMain (noargs=True). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
This removes unused variables in the rest of the code (outside lib/). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
This patch should have only: - pylint disables - docstring changes - whitespace changes Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
'file' is a builtin keyword/type. Like many others, it should not be used as a variable/argument name. No code is actually passing in this argument so renaming it is simple. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
The logging functions expand the arguments themselves, thus it's safer to let them do it rather than manual string formatting. Also re-wraps one comment. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
- Dec 10, 2009
-
-
Guido Trotter authored
On some distributions pyinotify is installed in a different way, and the actual module just contains an internal pyinotify entry, which is the actual library. On others the main pyinotify module contains the library itself. We'll try both, in order to be more compatible. Signed-off-by:
Guido Trotter <ultrotter@google.com>
-
- Nov 25, 2009
-
-
Iustin Pop authored
This patch removes the quotes from CommaJoin and converts most of the callers (that I could find) to it. Since CommaJoin does str(i) for i in param, we can remove these, thus simplifying slightly a few calls. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Nov 11, 2009
-
-
Michael Hanselmann authored
Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Nov 06, 2009
-
-
Guido Trotter authored
This is ok because adding a node or instance cannot happen in a query. We get the ec id from the LU and pass it to _EnsureUUID, which will then for now not use it. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
When the processor is executing a job, it can export the execution id to its callers. This is not supported for Queries, as they're not executed in a job. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Nov 05, 2009
-
-
Michael Hanselmann authored
Until now, Ganeti started and stopped its own daemons using custom functions. To start, the daemon was just executed and then sent the appropriate signals to stop it again. Init scripts would have to pay attention to the PID file and other things. With this patch, a new script is added (“daemon-util”, installed in $prefix/lib/ganeti/), centralizing the starting and stopping of daemons. The provided example init script is adjusted to use this new script. Ganeti's code no longer calls its own init script. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Nov 02, 2009
-
-
Iustin Pop authored
This finishes the conversion of OpPrereqError creation to two-argument style. Any leftovers as one-argument are not breaking anything, just losing information about the errors. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Oct 29, 2009
-
-
Michael Hanselmann authored
This enables the use of hashed passwords in rapi_users. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Oct 22, 2009
-
-
Ken Wehr authored
Allows the initialization of a cluster without the creation or distribution of SSH key pairs. Includes changes for LeaveCluster and RPC. Signed-off-by:
Ken Wehr <ksw@google.com> Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Oct 13, 2009
-
-
Guido Trotter authored
All the LUs that shut down the instance need to be able too pass the timeout parameter as well. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Oct 09, 2009
-
-
Guido Trotter authored
Using the new --timeout option: - gnt-instance shutdown is changed to accept a timeout - the opcode is changed to hold one - the LU is changed to optionally get one - the rpc is changed to carry one - the backend is changed to take it as a parameter rather than hardcoding it in the function Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Sep 29, 2009
-
-
Iustin Pop authored
This is not needed anymore - the original change was more than a year ago when masterd was in its incipient phase. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Sep 28, 2009
-
-
Guido Trotter authored
Many functionalities of confd have been moved to other classes/modules, and the main confd daemon doesn't reference these modules directly anymore. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-