- Feb 12, 2013
-
-
Iustin Pop authored
Currently, hbal code always uses annotateOpCode function, which means we would have to pass the options data to all function in the call chain if we wanted to make this more flexible. By abstracting the type of the annotator and passing it as an argument to the function, we can be more flexible. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Stratos Psomadakis authored
Add unit tests for the RADOSBlockDevice JSON output parsing function, and modify the unit tests for the plain output parsing function to work with the new code. Signed-off-by:
Stratos Psomadakis <psomas@grnet.gr> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Stratos Psomadakis authored
'rbd showmapped' output formatting differs between older and newer versions of the ceph tools. Try to use json output formatting if available (currently available only in the ceph master branch). For bobtail, argonaut and older releases fallback to manually parsing the 'rbd showmapped' output, handling the differences in the output format for each rbd version correctly. Signed-off-by:
Stratos Psomadakis <psomas@grnet.gr> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Guido Trotter authored
All recent-enough versions of linux see the xen paravirtual device as /dev/xvd*. This doesn't break old installations, as the default is only used on new clusters. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Helga Velroyen authored
This removes the check for conflicts from the Haskell version of the OpCode NetworkDisconnect. This alignes the Haskell code with the patch "Force conflicts check in LUNetworkDisconnect" (which is currently under review). I will submit these patches together then. This is a cherry-pick of commit 0ae4b355. Signed-off-by:
Helga Velroyen <helgav@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Helga Velroyen authored
Make _UnlockedLookupNetwork() raise OpPrereqError (instead of returning None) in case it does not find the requested network. Remove useless and duplicate code such as: if net_uuid is None: raise... This is a cherry-pick of commit 1cce2c47. Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Helga Velroyen <helgav@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Helga Velroyen authored
Until now if one disconnects a network with --no-conflicts-check and then remove it, there is a possibility to leave instances with NICs referencing non-existing networks. This causes network queries, instance removal and modification to fail. This patch allows a network to be disconnected from a nodegroup, only if instances residing in the nodegroup do not have NICs attached to the network. Otherwise OpPrereqError is raised. The --no-conflicts-check option is removed from the gnt-network disconnect command as well. This is a cherry-pick of commit 6bb939a2. Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Helga Velroyen <helgav@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Michael Hanselmann authored
In some scenarios it can be useful to add more arguments to “gnt-cluster init”, such as “--no-drbd-storage”, if DRBD is not installed. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
This patch improves the error messages given when a “errors.AddressPoolError” exception is caught. Includes some small style fixes. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This is not included on the 2.6 branch, so update the NEWS for 2.7.0 beta1. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Feb 11, 2013
-
-
Dimitris Aragiorgis authored
This can be used in hypervisor code as well. For consistency export *NETWORK_NAME and not *NETWORK throughout the code. Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Dimitris Aragiorgis authored
This info is not used by Ganeti and therefore is removed. Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Dimitris Aragiorgis authored
This slot was not used by Ganeti so the same info can be provided via tags. In order not to break configuration data we add a FromDict() method in Network config object that removes the deprecated network_type (if found) and then invoke the parent's method (which does the validation). Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Bernardo Dal Seno authored
Cluster-verify used to check that the value of exclusive_storage is uniform within node groups. Now, it's impossible to change the flag for a single node, so that check has been removed and an equivalent one has been added in ConfigWriter.VerifyConfig(). Unit test provided. The unit test covers only the new check, not the whole VerifyConfig method. Signed-off-by:
Bernardo Dal Seno <bdalseno@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Bernardo Dal Seno authored
There's never been support for a configuration where nodes in the same node group have different values of the exclusive_storage flag. This patch disables the possibility to change the flag for individual nodes. Signed-off-by:
Bernardo Dal Seno <bdalseno@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Bernardo Dal Seno authored
Before, only some upgrades were written back to the configuration file. A little refactoring of _UpgradeConfig() has been done to write unit tests. Signed-off-by:
Bernardo Dal Seno <bdalseno@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Since now confd also serves a Luxi endpoint, the current message in cli.FormatError is misleading when actually failing to connect to it. The patch adds a somewhat hackish way to show the right daemon name. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
This should address 359, but I'm not sure if it covers all of 2.7… Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Feb 08, 2013
-
-
Guido Trotter authored
1) Move the hooks environment dict generator inside the object. This also adds missing values such as network family and uuid. 2) Use the same generator both for the os environment and for the instance hooks. 3) Update manpage and hooks documentation. Also update a forgotten docstring about a tuple's content. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Guido Trotter authored
Although this does nothing for now, running it is safe, and consistent with how other objects behave. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
This was applied to "master" along with extra changes affecting the master branch only. Cherry-picking just the Objects.hs change. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Iustin Pop authored
When absolutely no OSes are present on the cluster, the result of OpOsDiagnose is an empty list. This is currently handled in gnt-os as an error condition, probably due to how OpOsDiagnose used to return errors in the past. However, with the query backend, an empty list is a reasonable answer, so I see no reason why gnt-os should treat that as an error, especially as it doesn't give any hint of what is "wrong". Simply removing that code block allows it to proceed normally, and list no OSes. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
LIBDIR was not defined, so the files ended up directly under /, not good. Now they're properly installed under /usr/lib/ocf, as per http://linux-ha.org/wiki/OCF_Resource_Agents . Also add "set -u" to prevent future occurrences of this kind of bug. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
The method names were wrong due to copy & paste. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Feb 07, 2013
-
-
Iustin Pop authored
When hlint sees a perfectly nice code tree, it will skip generating the reports (both stdout and html). This means that usually the old report will remain in place, so it makes development harder, as the html file is out of sync with the tree. To workaround this, we generate an empty/minimal file in this case. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Since 'head' is unsafe to use in most cases, this patch removes its use from most of the code, adds a lint warning for it (and for tail as well), and adds override annotations in the few cases where it's actually OK to use it (mainly when using head over the result of functions which guarantee to return a non-empty list by documentation, not type). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
- Feb 06, 2013
-
-
Guido Trotter authored
Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Guido Trotter authored
Also update the documentation target versions and the cfgupgrade tool to recognize 2.6 and upgrade to 2.7 Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Guido Trotter authored
- The migrate instance hook now also executes on the primary node in the "pre" phase. - Instance hooks now get full network information on each nic, if a nic's network is set. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Feb 05, 2013
-
-
Iustin Pop authored
This enabled the redirection; QA output after this patch should become much much smaller (on a 'quick' QA, we are left with ~0.5MB output on stdout and 64MB redirected output). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Some QA commands generate non-trivial output: for a full QA, the gnt-* list commands generate more than 300MB of data. To make the QA logs more parseable by humans, we need support for redirecting output of commands to a different place. This patch adds a 'AssertRedirectedCommand' that does this, redirecting the output to a (fixed) log file in the Ganeti log directory. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
This patch adds an optional kwarg that allows skipping the "Command: …" line in QA output. This is helpful if we only need to run some maintenance actions, that are QA-related and not Ganeti-related. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Iustin Pop authored
This would have caught the log file problem fixed in the previous patch (9411474b), for example. Also we test user/group equivalence, name only. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Commit 3329f4de changed the Haskell log file from constants to functions, but introduced a bug: it uses now the daemon name instead of the correct log file, which means "ganeti-confd.log" instead of "conf-daemon.log". In order to fix this, we need to abstract the log file base (in constants.py) into a separate set of constants, so that we can reuse it in the Haskell code. This fixes issue 343. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Feb 04, 2013
-
-
Bernardo Dal Seno authored
This test used to leave a node with orphan logical volumes and unused DRBD minors. Now, the expected leftovers are cleaned up after the test, and cluster-verify is run. Signed-off-by:
Bernardo Dal Seno <bdalseno@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
This uses the new _FormatVerifyResults helper function to return multiple errors. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Since LXC now relies on cgroup memory limits to enforce memory, let's make hypervisor verification (and thus cluster-verify) return errors when the cgroup filesystem is not mounted. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
This will allow easier multi-error results from hypervisors; right now, we only report the first error, which is not nice. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-