Statistics
| Branch: | Tag: | Revision:

root / lib @ 332a83ca

# Date Author Comment
332a83ca 02/18/2013 05:34 pm Michele Tartara

Add request type to Confd server for getting instance list

Add to Confd server a new request type (and its implementation) to ask for
the list of instances in a node.

Signed-off-by: Michele Tartara <>
Reviewed-by: Iustin Pop <>

fe502d25 02/15/2013 03:04 pm Iustin Pop

Merge branch 'devel-2.7'

  • devel-2.7:
    Rename lib/objectutils to outils.py
    Fix typo in gnt-group manpage
    Fix wrong type in a docstring of the RAPI subsystem
    Finish the remote→restricted commands rename
    Enable use of the priority option in hbal
    Add CLI-level option to override the priority...
d9a22528 02/15/2013 12:23 pm Iustin Pop

Revert "Disable live-RPC queries under split query"

This reverts commit fb251c2c4c582ec0d6c00a6f6c5e134ed5196e03. On the
master branch we want to continue to have them enabled.

Signed-off-by: Iustin Pop <>
Reviewed-by: Helga Velroyen <>

473d87a3 02/15/2013 12:14 pm Iustin Pop

Rename lib/objectutils to outils.py

Back when this was introduced, I mentioned that it breaks heavily tab
completion (ob<TAB> doesn't work anymore), but at that moment I didn't
have a suggestion what to name it. I think outils is good and short
enough, and doesn't conflict with anything else, so here it goes....

20ba96f5 02/13/2013 12:34 pm Michele Tartara

Fix wrong type in a docstring of the RAPI subsystem

Signed-off-by: Michele Tartara <>
Reviewed-by: Michael Hanselmann <>

45bc4635 02/12/2013 03:47 pm Iustin Pop

Finish the remote→restricted commands rename

The documentation still points to /etc/ganeti/remote-commands,
although the code is already using restricted-command. Update the
documentation and a few docstrings accordingly.

Signed-off-by: Iustin Pop <>...

37a978e7 02/12/2013 03:39 pm Helga Velroyen

Force conflicts check in LUNetworkDisconnect

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....

1b68f268 02/12/2013 03:39 pm Helga Velroyen

If _UnlockedLookupNetwork() fails raise error

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 1cce2c4....

ae8de7e3 02/12/2013 03:39 pm Guido Trotter

Change default xen root path to /dev/xvda1

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 <>...

bdecfea2 02/12/2013 03:39 pm Stratos Psomadakis

Fix rbd showmapped output parsing

'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...

3c296f56 02/12/2013 03:25 pm Michael Hanselmann

Merge branch 'devel-2.7'

  • devel-2.7: (23 commits)
    QA: Support additional arguments for initialization
    qa_utils: Fix order of arguments passed to _AssertRetCode
    Improve reporting on errors.AddressPoolError exceptions
    Add note about lv-tags rename...
74e642cd 02/12/2013 01:30 pm Michael Hanselmann

Improve reporting on errors.AddressPoolError exceptions

This patch improves the error messages given when a
“errors.AddressPoolError” exception is caught. Includes some small style
fixes.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

5cfa6c37 02/11/2013 05:31 pm Dimitris Aragiorgis

Remove network_type slot (Issue 363)

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...

48616625 02/11/2013 05:31 pm Dimitris Aragiorgis

Remove family and size from network objects

This info is not used by Ganeti and therefore is removed.

Signed-off-by: Dimitris Aragiorgis <>
Reviewed-by: Guido Trotter <>

7e8f03e3 02/11/2013 05:31 pm Dimitris Aragiorgis

Make use of HooksDict() for networks

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 <>
Reviewed-by: Guido Trotter <>

3697def0 02/11/2013 04:21 pm Bernardo Dal Seno

Moved uniformity check for exclusive_storage flag

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...

250a9404 02/11/2013 04:21 pm Bernardo Dal Seno

"exclusive_storage" cannot be changed on single nodes

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....

45f62156 02/11/2013 04:20 pm Bernardo Dal Seno

Upgrades made on loading the configuration are always saved

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 <>...

7f5edc60 02/11/2013 12:28 pm Iustin Pop

Show correct daemon name on Luxi connect errors

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....

ee9516c8 02/08/2013 01:40 pm Guido Trotter

ConfigData: run UpgradeConfig on network objects

Although this does nothing for now, running it is safe, and consistent
with how other objects behave.

Signed-off-by: Guido Trotter <>
Reviewed-by: Iustin Pop <>

d89168ff 02/08/2013 01:40 pm Guido Trotter

OS environment: add network information

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....

58bc8fbc 02/08/2013 12:04 pm Iustin Pop

Make gnt-os list work with no OSes

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....

11eb5cd0 02/08/2013 11:59 am Michael Hanselmann

baserlib: Fix two mistakes in docstring

The method names were wrong due to copy & paste.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

595149d5 02/08/2013 11:48 am Michael Hanselmann

vcluster: Make _MakeNodeRoot public

The QA code will also have to generate virtual paths and this function
comes in handy.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Michele Tartara <>

afa9bb2e 02/07/2013 01:29 pm Michael Hanselmann

hv_kvm: Error messages, punctuation, other style fixes

- Capitalize acronyms such as “QMP” or “SPICE”
- Remove punctuation from error messages
- Improve error reporting when sending a monitor command failed
- Put “or” at end of line
- Fix indentation for a concatenated string...

eace6157 02/07/2013 12:50 pm Michael Hanselmann

hv_kvm: Add TODO regarding monitor commands

Monitor calls should be replaced with QMP once KVM >= 0.14 is required.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

83251115 02/05/2013 06:55 pm Michael Hanselmann

Merge branch 'devel-2.7'

  • devel-2.7:
    Redirect output for gnt-* list/list-fields commands
    Add function to execute QA commands with redirected output
    Implement option to skip logging of QA commands
    Fix typo in a comment
    Add some more Haskell/Python equivalence tests...
9411474b 02/05/2013 10:36 am Iustin Pop

Fix Haskell log file naming after virtual cluster changes

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...

473ab806 02/04/2013 04:52 pm Michael Hanselmann

Extract container converters

“objects.ConfigObject” contains two useful functions for working with
containers of serialized objects, “_ContainerToDicts” and
“_ContainerFromDicts”. This patch separates those functions and moves
them into “objectutils” as they'll be useful for converting parts of the...

81124130 02/04/2013 04:52 pm Michael Hanselmann

hv_xen: Fix epydoc error

“utils.RunCmd” is re-exported from “utils.process.RunCmd”. Epydoc
doesn't fully understand this, so we have to refer to the original.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

4d36fbf4 02/04/2013 04:22 pm Michael Hanselmann

objects: Improve handling of TCP/UDP port pool

- Handle de-serialization correctly when pool is not defined
- Serialize to empty list when the attribute is None (this should never
happen in reality as the attribute is always set when de-serializing)
- Add tests...

1f4b9d39 02/04/2013 03:06 pm Iustin Pop

Switch KVM to multi-error verify results

This uses the new _FormatVerifyResults helper function to return
multiple errors.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

0628a50a 02/04/2013 03:06 pm Iustin Pop

Make LXC fail verification if cgroup is not mounted

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 <>...

53fde1ac 02/04/2013 03:06 pm Iustin Pop

Add a helper function for hypervisor verification

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 <>
Reviewed-by: Michael Hanselmann <>

e4157912 02/04/2013 09:48 am Guido Trotter

hv_lxc: fix whitespace errors

The latest lxc patches included a few whitespace style errors, that make
lint fail. This patch fixes those.

Signed-off-by: Guido Trotter <>
Reviewed-by: Helga Velroyen <>

f078c799 02/02/2013 12:52 pm Faidon Liambotis

LXC: add support for the memory controller

Add support for the memory resource controller, useful to actually place
memory limits on instances.

Support is still optional, in case the kernel doesn't have it compiled
in, or in the case of Debian has it dependent on a kernel command-line...

35e18c38 02/01/2013 06:21 pm Michael Hanselmann

Merge branch 'devel-2.7'

  • devel-2.7: (24 commits)
    Fix typo in ganeti-noded man page
    QA: Run instance tests with different cluster configurations
    QA: Run cluster-verify after instance tests
    QA: Refactored launching of the various instance tests
    QA: Use lists of nodes as argument to instance tests...
2e5a6203 02/01/2013 05:53 pm Faidon Liambotis

LXC: adapt hv for newer lxc userspace tools

Currently hv_lxc depends on the behavior and output of older LXC tools,
which have since changed, making it unable to function in current
distributions (e.g. Debian wheezy).

Adapt the tools and expectation for the output and make it into a...

cfc24646 02/01/2013 12:01 pm Iustin Pop

Fix logging arguments formatting

This fixes: “ganeti/hypervisor/hv_kvm.py:93: [W1201, _GetTunFeatures]
Specify string format arguments as logging function parameters”, and
also updates the copyright years.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michele Tartara <>

fb251c2c 01/31/2013 01:10 pm Iustin Pop

Disable live-RPC queries under split query

Currently, the node listing RPC is very slow due to missing
parallelisation. For the 2.7 release, we reset these back to masterd,
hoping to revert them by the time 2.8 is ready.

There are a number of queries that I've left pointing to confd, as...

aeb6ba44 01/30/2013 07:39 pm Dato Simó

Document that OpTestDelay/TestDelay take duration in seconds

Also, fix @rtype and @return elements of utils.TestDelay(), which now
returns a tuple but this wasn't being indicated.

Signed-off-by: Dato Simó <>
Reviewed-by: Helga Velroyen <>

6bb939a2 01/30/2013 07:26 pm Helga Velroyen

Force conflicts check in LUNetworkDisconnect

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....

1cce2c47 01/30/2013 07:26 pm Helga Velroyen

If _UnlockedLookupNetwork() fails raise error

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...

Signed-off-by: Dimitris Aragiorgis <>...

ea2bcb82 01/30/2013 07:12 pm Michael Hanselmann

hv_kvm: Refactor getting TAP features, add tests

Split retrieving supported features into a dedicated function which can
be mocked. Tests are added for both “_ProbeTapVnetHdr” and
“_GetTunFeatures”.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

b76d4aaf 01/30/2013 06:13 pm Michael Hanselmann

Merge branch 'devel-2.7'

  • devel-2.7:
    hv_kvm: Original error message, keyword parameter
    CLI.hs: fix double spaces in option help strings
    Add new NIC parameter to man page of 'gnt-instance'
    Fix spelling issue in hroller.rst

Signed-off-by: Michael Hanselmann <>...

6f1e1921 01/30/2013 06:05 pm Michael Hanselmann

hv_kvm: Original error message, keyword parameter

- Include original error message when creating TAP interface failed
- Pass keyword parameter as such

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

f601723c 01/25/2013 04:28 pm Michael Hanselmann

Merge branch 'devel-2.7'

  • devel-2.7:
    kvm: fix bug while fetching -device list

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

d8784f7d 01/25/2013 04:07 pm Michael Hanselmann

hv_xen: Fix issues with migration, add tests

Commit 3d942d8 broke instance migration (“self._cmd” was set to None).
This patch fixes that issue, refactors “MigrateInstance” for testing and
adds those tests.

Signed-off-by: Michael Hanselmann <>...

bc0fed4b 01/25/2013 03:25 pm Guido Trotter

kvm: fix bug while fetching -device list

_GetKVMOutput expects the command to succeed, but unfortunately on some
versions of kvm "-device ?" will output a correct list of devices, while
exiting with an error code.

To fix this we accept failure in that case (note that this doesn't...

31da5ab5 01/25/2013 12:58 pm Michael Hanselmann

hv_xen: Split StopInstance

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>

3d942d8b 01/25/2013 12:58 pm Michael Hanselmann

hv_xen: Abstract running Xen commands

Instead of using the “XEN_CMD” constant in multiple places, that is now
all in a single place and can easily be changed for unit tests (through
a parameter given to the constructor).

Signed-off-by: Michael Hanselmann <>...

89c4e365 01/25/2013 12:57 pm Michael Hanselmann

Merge branch 'devel-2.7'

  • devel-2.7:
    hv_xen: Remove config after shutdown was successful

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Bernardo Dal Seno <>

effc9cad 01/24/2013 08:30 pm Helga Velroyen

List networks: call client explicitely

This way, it is easier to make it call the haskell
implementation of the network queries.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Michael Hanselmann <>

4b8b172d 01/24/2013 03:35 pm Michael Hanselmann

hv_xen: Remove config after shutdown was successful

If stopping an instance failed, the configuration would already be gone
and other operations depending on it (e.g. migration) would no longer
work. With this patch the configuration file is only removed once the...

c3d839f5 01/24/2013 02:29 pm Michael Hanselmann

hv_xen: Simplify writing configuration

Instead of calling _WriteConfigFileStatic from both derived classes,
those now only return the content (minus the “do not edit” header). The
configuration is then written by the base class, XenHypervisor.

Signed-off-by: Michael Hanselmann <>...

0a903309 01/24/2013 02:29 pm Michael Hanselmann

hv_xen: Prepare for unit tests, remove {static,class}method

Unit tests will have to specify a custom Xen configuration directory (a
temporary directory). To this end “hv_xen.XenHypervisor” and its two
derived classes are modified to have fewer static and class methods. A...

d0bb3f24 01/24/2013 02:27 pm Michael Hanselmann

hv_xen: Factorize and test disk configuration

The “_GetConfigFileDiskData” function is moved to module level and
cleaned up (module-level constants for letters and file I/O drivers).

Until now only 24 disks would be supported (e.g. “sda” to “sdx”), when...

06c9a520 01/24/2013 01:58 pm Michael Hanselmann

hv_xen: Refactor getting node information, add tests

Refactor and add tests for getting node (Domain-0) information.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Bernardo Dal Seno <>

b255379d 01/24/2013 01:57 pm Michael Hanselmann

hv_xen: Refactor running & parsing "xm list", add tests

This patch refactors “_RunXmList” and adds some tests.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Bernardo Dal Seno <>

d82dec68 01/24/2013 01:46 pm Michael Hanselmann

Merge branch 'devel-2.7'

  • devel-2.7:
    hv_*: Always return from Verify, style fixes
    _VerifyErrors()._Error() and _ErrorIf() are now consistent
    Handle the result of QueryGroups() correctly

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Bernardo Dal Seno <>

cd04dfd2 01/24/2013 12:46 pm Michael Hanselmann

hv_*: Always return from Verify, style fixes

Change all “Verify” methods in hypervisor abstractions to explicitely
return None if no problem was detected. Remove punctuation from error
messages. Update docstrings with “@return” and some small mistakes.

Signed-off-by: Michael Hanselmann <>...

9842f020 01/24/2013 10:50 am Helga Velroyen

Check minimum size of networks on creation

When creating a network, so far no size constraints were checked.
We now limit the size of a network to a /30 or bigger, although
tecnically, the ipaddr library supports even /32 networks.

Signed-off-by: Helga Velroyen <>...

0c348b86 01/23/2013 07:49 pm Michael Hanselmann

constants: Add list of known Xen commands

These will be used in unittests.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

8bb2df7d 01/23/2013 06:34 pm Bernardo Dal Seno

_VerifyErrors()._Error() and _ErrorIf() are now consistent

_Error() didn't contain the logic for demoting errors to warnings and for
marking an operation as failed. Now _ErrorIf() is just a minimal wrapper
for _Error().

Unit tests included.

Signed-off-by: Bernardo Dal Seno <>...

286d0218 01/23/2013 03:25 pm Dimitris Aragiorgis

Handle the result of QueryGroups() correctly

If no group is given for the “gnt-network connect“/“… disconnect”
commands, the client uses the result of “QueryGroups()” which is a list
of lists. Use “itertools.chain()” to handle the return value correctly....

af3aea48 01/23/2013 03:24 pm Dimitris Aragiorgis

Handle the result of QueryGroups() correctly

If no group is given for the “gnt-network connect“/“… disconnect”
commands, the client uses the result of “QueryGroups()” which is a list
of lists. Use “itertools.chain()” to handle the return value correctly....

76c364d9 01/23/2013 01:41 pm Michael Hanselmann

hv_xen: Compose file name outside error handling

In _ReadConfigFile, the filename should be prepared outside the
try/except block. Fixes bad code formatting, too.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>

0d07a850 01/22/2013 04:05 pm Michael Hanselmann

hv_base: Remove empty constructor

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Bernardo Dal Seno <>

3b721842 01/22/2013 04:05 pm Michael Hanselmann

Add test for backend._GetBlockDevSymlinkPath

Add a unit test for the trivial “_GetBlockDevSymlinkPath” function in
backend (small changes in the function were required).

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Bernardo Dal Seno <>

af89fa76 01/21/2013 05:31 pm Helga Velroyen

Fix format string of KVM output

This fixes a missing 's' in the format string and
the wrong quotes. Those bugs were introduced in
commit 6e043e60.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Iustin Pop <>

7e7fa841 01/21/2013 01:57 pm Iustin Pop

First part of confd timer changes

This patch changes the resolution of the timers: the watcher timer
goes from 60s to 17s, and the polling-mode timer goes from 2 seconds
to 250ms. The code changes a bit more due to the changes in the units
of the various constants....

525f0f98 01/18/2013 05:12 pm Christos Stavrakakis

Fix type of 'node_whitelist' request parameter

If opportunistic_locking is used, then 'node_whitelist' parameter passed
to the allocator is set to the LU's owned node locks. However, LU owned_locks
has type of 'set' while IReqInstanceAlloc expects type of...

347fa0f1 01/18/2013 05:12 pm Michael Hanselmann

hv_xen: Add test for CPU pinning configuration

Add a unittest for a function formatting CPU pinning information for
Xen's configuration.

Signed-off-by: Michael Hanselmann <>
Signed-off-by: Guido Trotter <>
Reviewed-by: Guido Trotter <>

6e043e60 01/18/2013 05:12 pm Guido Trotter

kvm: deduplicate 'get output' code

We had the same code twice, and were about to add a third time. Better
to collapse it into just one function.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

6f4070cd 01/18/2013 05:12 pm Guido Trotter

kvm: extract a regexp matching out of a for loop

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

f0db563d 01/18/2013 05:12 pm Guido Trotter

kvm: remove last version-based feature detection

This was left behind because it required a different kvm invocation.
Now that we can add new ones cheaply (two constants) it's easy to get
rid of it. Differently than in other cases we support old version which...

a8e8c0c6 01/18/2013 04:30 pm Michael Hanselmann

Make Xen config path a build-time option

Stop hardcoding the path in “hv_xen.py”.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

94d5cee9 01/18/2013 03:39 pm Michael Hanselmann

burnin: Don't keep hypervisor class around

Just determine whether it can migrate and keep that value instead of the
full hypervisor class.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

d38bef8e 01/18/2013 12:13 pm Constantinos Venetsanopoulos

Run pre-migrate hooks on primary node too

Signed-off-by: Constantinos Venetsanopoulos <>
Reviewed-by: Guido Trotter <>

82e3bf85 01/16/2013 08:57 pm Dimitris Aragiorgis

Check if KVM machine version is supported

If machine version is passed as an hv param, a check is made
in target node whether this version is included in the supported
ones derived from kvm -M ? command.

Signed-off-by: Dimitris Aragiorgis <>...

e32e1fb9 01/16/2013 07:09 pm Bernardo Dal Seno

Verify that templates are compatible with exclusive storage

cluster-verify reports instances with disk templates not compatible with
exclusive storage but that are running on nodes with the exclusive storage
flag set.

Signed-off-by: Bernardo Dal Seno <>...

525939d9 01/16/2013 07:09 pm Bernardo Dal Seno

cluster-verify checks uniformity of PV sizes

When exclusive_storage is set, cluster-verify complains if the size of PVs
is not uniform across a node group.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

14fe92c7 01/16/2013 07:09 pm Bernardo Dal Seno

New RPC call for node verify in dns-only RPC client

This will be used in node-add.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

58bc6241 01/16/2013 07:09 pm Bernardo Dal Seno

add-node checks PVs

add-node now performs a few checks on LVM before adding a node to the
cluster.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

39eb39dc 01/16/2013 07:09 pm Bernardo Dal Seno

Moved checks within LUClusterVerifyGroup

Almost all instance-specific checks have been moved from the Exec method to
the _VerifyInstance method. This cleans up Exec, which was becoming too big
even for pylint…

Signed-off-by: Bernardo Dal Seno <>...

b496abdb 01/16/2013 07:09 pm Bernardo Dal Seno

bdev.GetPVInfo() returns list of LVs

This will be used for checks related to exclusive storage.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

d5a690cb 01/16/2013 07:09 pm Bernardo Dal Seno

cluster-verify checks that PVs are not shared

When exclusive_storage is set, cluster-verify complains if PVs are shared
among unrelated LVs.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

8c3d6797 01/16/2013 07:09 pm Bernardo Dal Seno

Small cleanup in constants.py

- compat.UniqueFrozenset used in one more place, for consistency.
- The order of NV_XXX constants is fixed so that all values are now sorted
by name.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

22d9752a 01/16/2013 07:09 pm Bernardo Dal Seno

cluster-verify checks uniformity of exclusive_storage flag

The value of the flag should be the same for nodes within the same group.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

11064155 01/16/2013 07:09 pm Bernardo Dal Seno

utils.LvmExclusiveCheckNodePvs() returns more info

utils.LvmExclusiveCheckNodePvs() now returns the size of the smallest and
biggest PVs of a node. They will be used for cross-node consistency checks.

Signed-off-by: Bernardo Dal Seno <>...

13d3acab 01/16/2013 03:56 pm Michele Tartara

Add reporting infrastructure for data collectors

This commit adds the part of the JSON report generation code that will be
common to all the data collectors, according to the format specified in the
design document.

Signed-off-by: Michele Tartara <>...

4b9638dc 01/16/2013 01:10 pm Guido Trotter

kvm: make kvm path configurable as an hv parameter

This fixes Issue 225.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

b73f1c59 01/16/2013 01:07 pm Guido Trotter

make _{Generate,Execute}KVMRuntime accept kvm help

Currently kvm --help is called twice at instance startup, this makes
sure it's called only once.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

3b59ec02 01/16/2013 01:07 pm Guido Trotter

kvm: make auxiliary functions accept a kvm path

This will be used to be able to customize the path in an hv parameter.

Also fix two comments that still mentioned version-based checking.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

4ab75599 01/16/2013 01:06 pm Dimitris Aragiorgis

Add KVM machine version as hv param

This is needed in case an instance must be booted with an exact type of
machine version (due to e.g. outdated drivers). If this hv param
explicitly defined (during instance creation/modification) then the kvm
process will be started having this version for the -M option. Otherwise...

8e55e20f 01/16/2013 12:19 pm Michael Hanselmann

Move burnin to ganeti.tools.burnin

Similar to other scripts, “tools/burnin” just becomes a wrapper script.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

5ce58234 01/15/2013 04:43 pm Michael Hanselmann

Link man pages in documentation

This patch depends on “Option to include man pages in documentation”. In
the documentation build including man pages, all “:manpage:`…`”
references are converted to links. For man pages not provided by Ganeti,
Sphinx' standard formatting is used....

3e77a36c 01/14/2013 05:52 pm Dato Simó

Add initial constants and Haskell ADTs for auto repair

In this commit, the AutoRepairType and AutoRepairResult types are defined,
with the possible values specified in doc/design-autorepair.rst.

Signed-off-by: Dato Simó <>
Reviewed-by: Iustin Pop <>

e6f24d89 01/14/2013 04:36 pm Guido Trotter

kvm: Add kvm_extra parameter

As requested in Issue 261 and many other times.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

7589346f 01/14/2013 04:36 pm Guido Trotter

kvm: Add -vga option

As requested in Issue 69.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>