Statistics
| Branch: | Tag: | Revision:

root / lib / cmdlib.py @ 748e4b5a

History | View | Annotate | Download (358.9 kB)

# Date Author Comment
926feaf1 07/12/2010 06:59 pm Manuel Franceschini

Use reserved documentation IPs and domains

Use RFC 5737 IP addresses and RFC 2606 domain names in all
unittests, docs, qa and docstrings.

Signed-off-by: Manuel Franceschini <>
Reviewed-by: Iustin Pop <>

7b4c1cb9 07/12/2010 05:32 pm Michael Hanselmann

Provide feedback function for all LU methods

By exposing mcpu's _Feedback function (now renamed to “Log”) to LU's,
methods like ExpandNames can also write to the job execution log.

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

a744b676 07/09/2010 04:37 pm Manuel Franceschini

Introduce lib/netutils.py

This patch moves network utility functions to a dedicated module.

Signed-off-by: Manuel Franceschini <>
Reviewed-by: Iustin Pop <>

4ea3de4e 07/08/2010 06:57 pm Balazs Lecz

Add oper_vcpus instance status field

This introduces a new instance status field, named "oper_vcpus".
It contains the actual number of VCPUs an instance is using as
seen by the hypervisor.

Signed-off-by: Balazs Lecz <>
Reviewed-by: Iustin Pop <>

1c1b3cab 07/08/2010 04:45 pm Apollon Oikonomopoulos

LUCreateInstance: use cluster-wide iallocator

LUCreateInstance uses the cluster-wide default iallocator if no iallocator or
primary node is specified manually.

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

63ac47cc 07/08/2010 04:45 pm Apollon Oikonomopoulos

LUNodeEvacuationStrategy: Use default iallocator

Signed-off-by: Apollon Oikonomopoulos <>
Signed-off-by: Iustin Pop <>
Reviewed-by: Iustin Pop <>

bf4af505 07/08/2010 04:45 pm Apollon Oikonomopoulos

Add default_iallocator cluster parameter

Add a cluster parameter to hold the iallocator that will be used by default
when required and no alternative (manually-specified iallocator or
manually-specified node(s)) is given.

Signed-off-by: Apollon Oikonomopoulos <>...

b6dd40f5 07/08/2010 04:45 pm Apollon Oikonomopoulos

Add _CheckIAllocatorOrNode for common iallocator/node checks

_CheckIAllocatorOrNode will be called by LUs wishing to use an instance
allocator or a target node. It performs sanity checks and will modify the LU's
opcode's iallocator slot to use the cluster-wide allocator if...

44247302 07/06/2010 07:05 pm Iustin Pop

Rework the export failure handling

Currently, the way to signal export failures is by the return value.
This means that if a client doesn't check the values (e.g. burnin), any
failure is being ignore. And this is what we've been doing forever in
burning (not actually testing that the export is successful)....

d1871275 07/06/2010 12:25 pm Luca Bigliardi

Report drbd helper in query info LU

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

7b2cd2b4 07/06/2010 12:25 pm Luca Bigliardi

Check and set drbd helper in set params LU

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

15cf9cbb 07/06/2010 12:24 pm Luca Bigliardi

Check drbd usermode helper in cluster verify

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

51cb1581 07/06/2010 12:24 pm Luca Bigliardi

Generalize a recursive check on logical disks

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

d3ce528b 07/05/2010 02:59 pm Iustin Pop

OpCreateInstance: do not require hv/be/os params

It is perfectly legal to create an instance using only defaults
(although beparams will be most times passed in), so let's relax the
requirement for these three parameters.

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

3d16a983 07/02/2010 06:01 pm Iustin Pop

A few more type definitions

This is to simplify the type declarations in the actual LUs.

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

e7736336 07/02/2010 06:01 pm Iustin Pop

Make _CheckDiskTemplate a valid type checker

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

b8812691 07/02/2010 06:01 pm Iustin Pop

Rework the "type" system

This patch merges the _OP_REQP and _OP_DEFS class attributes into a
_OP_PARAMS list, which holds both. The associated unittest checks that
all opcode attributes are declared and checked, and that no LU uses the
old fields (could be removed later)....

7486d752 07/02/2010 06:01 pm Iustin Pop

Remove _CheckBooleanOpField

This is no longer used, and we can remove it.

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

801b6a33 07/01/2010 05:31 pm Guido Trotter

Merge branch 'stable-2.1'

  • stable-2.1:
    Bump up version for 2.1.5 release
    RapiClient: fix multi-authentication in Python 2.6
    Remove rapi-user and rapi-pass from qa-sample.json
    qa: fix gnt-instance modify -t drbd
    qa: shutdown instance before trying disk convert...
1a1296c8 07/01/2010 01:20 pm Guido Trotter

Fix check in gnt-instance modify -t

Currently when changing the instance disks the instance status (which
must be down) is only checked if the target status is among the mirrored
ones. This is incorrect: the instance must be down either way, even if
the desired final status is non-mirrored....

9c5885e2 07/01/2010 12:28 pm René Nussbaumer

Adding check_name option to the opcode and luxi call for instance rename

This will allow instance rename without dns check as it does for instance
add.

Signed-off-by: René Nussbaumer <>
Reviewed-by: Iustin Pop <>

c0c3fa27 06/30/2010 02:32 pm Manuel Franceschini

Introduce utils.IsValidIP{4,6}()

This patch introduces functions to check for valid IPv4 and IPv6
addresses and converts IsValidIP() to return True if it is either a IPv4
or a IPv6 address.

For now we do not change the functional behavior and replace IsValidIP...

0fbd4b02 06/30/2010 01:55 pm Manuel Franceschini

Fix osparams bug when gnt-cluster modify'ing

Commit 625ac1135834c27a2e78fd61bf2df2ce29ad2966 introduced 'osparams'
slot in OPSetClusterParams which was not passed when invoked via
gnt-cluster modify.

Signed-off-by: Manuel Franceschini <>...

d12f5c66 06/28/2010 04:25 pm Iustin Pop

Fix a type declaration error in LUTestAllocator

Also, improve logging of type errors, to ease debugging.

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

403f5172 06/28/2010 02:04 pm Guido Trotter

Remove pred from compat.any/all

This makes it compatible with the python builtin, and we can even use
the builtin when running under the right version of python. The all and
any functions are renamed to _all and _any, so that they can be tested,
and (non)existing unittests are updated (translation: there are no unit...

72db3fd7 06/28/2010 01:46 pm Iustin Pop

Two more fixes for OS params and opcode defaults

If the OS is not using API v20, the parameter verification should be
entirely skipped.

The second change is a simple typo.

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

40684c3a 06/25/2010 06:36 pm Iustin Pop

Fix breakage due to OS parameters

I was using wrong python installation path (thanks Guido!), so I was not
actually testing the new backend.py module. Two immediate things bugs
are fixed, and after these burnin passes again…

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

3b08cd1c 06/24/2010 01:56 pm Apollon Oikonomopoulos

Introduce constants.DTS_MAY_ADOPT

DTS_MAY_ADOPT include disk templates that may use disk adoption and will be
used in all respective checks.

Signed-off-by: Apollon Oikonomopoulos <>
Signed-off-by: Iustin Pop <>
Reviewed-by: Iustin Pop <>

f8f590c8 06/24/2010 01:46 pm Guido Trotter

Convert TestDelay repeat to the type system

Turns out with the current implementation of the type system a variable
can both be required and not required. Interesting (but perhaps worth a
further look).

Signed-off-by: Guido Trotter <>...

adb6d685 06/23/2010 07:24 pm Iustin Pop

Rename some constants and relax pylint rules

For the type system, we want a slightly relaxed rule for constant
naming, so we update the pylint rule. But the old _TPInt and _TNEString
were not clear enough, so we expand them.

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

3636400f 06/23/2010 07:24 pm Iustin Pop

Introduce a micro type system for opcodes

Currently, we have one structual validation for opcode attributes: the
_OP_REQP, which checks that a given attribute is not 'None', and the
rest of the checks are done at runtime. This means our type system has
two types: None versus Not-None....

3e512563 06/23/2010 07:24 pm Iustin Pop

LU.CheckPrereq: do not require implementation

Currently, the base class LogicalUnit's CheckPrereq will raise
NotImplementedError, which means that the child LUs have to implement
it. However, many LUs don't actually have a need for this function
(hence the many "pass" statements as the only body)....

3494b9f6 06/23/2010 07:24 pm Iustin Pop

Some more CheckPrereq/CheckArguments cleanup

For a few LUs, a few tests in, or even the whole CheckPrereq, can be
moved to CheckArguments, as they don't touch state and only do a 'type'
validation.

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

b0d85178 06/23/2010 07:23 pm Iustin Pop

Add OS verification support to cluster verify

For this, we needed to extend the NodeImage class with a few extra
variables, and we do a trick in the node verification where we pick the
first node that returned valid OS data as the reference node, and then...

a8c931c0 06/23/2010 07:23 pm Iustin Pop

Move opcode attribute defaults to data structures

LUExportInstance had two opcode fields set to default via both
_CheckBooleanOpField and getattr(…, False).

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

9ade2eda 06/23/2010 07:23 pm Iustin Pop

Cleanup LU.ExpandNames versus CheckArguments

When LogicalUnit.CheckArguments was introduced, not all code dealing
with static argument checking was moved to it; many of these checks were
left in ExpandNames. With time, most of them migrated, and this patch...

989ba0c4 06/23/2010 07:23 pm Iustin Pop

Abstract export mode validity check

The export mode is checked in two places with the exact same code…

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

8de1f1ee 06/23/2010 07:23 pm Iustin Pop

Remove the obsolete EvacuateNode OpCode/LU

All code has been switched to the new-style LU… time for cleanup.

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

dbb24ec7 06/23/2010 07:23 pm Iustin Pop

Show OS parameters in cluster/instance info

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

062a7100 06/23/2010 07:23 pm Iustin Pop

Add support for OS parameters during instance add

This is not yet complete, as it lacks proper support for instance
import.

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

21d7df5f 06/23/2010 07:23 pm Iustin Pop

_GetUpdatedParams: enhance value removal options

This patch adds controls for whether we recognize
constants.VALUE_DEFAULT or not as a default value, and also adds
dash-prefixes as another way for parameter removal.

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

625ac113 06/23/2010 07:23 pm Iustin Pop

Add support for modifying cluster OS parameters

We use _GetUpdatedParams in order to support removal too, and then
validate the OS parameters if the OS exists.

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

1052d622 06/23/2010 07:23 pm Iustin Pop

Add support for modifying instance OS parameters

We move the instance OS rename checks earlier, as we need to run the
validation against the new OS, if it has changed.

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

535b49cb 06/23/2010 07:23 pm Iustin Pop

Add support for OS parameters during import/export

Nothing special here, just copy/adjust the beparams code.

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

bad78e66 06/23/2010 07:23 pm Iustin Pop

LUDiagnoseOS: add more fields, cleanup

This patch exports all the way from backend a new field ‘api_version’
which holds the list of support API versions, and exposes the (already
computed) ‘parameters’ field.

The patch also reworks (again) the field calculation in its Exec()...

4463ae96 06/23/2010 07:23 pm Iustin Pop

Silence a pylint warning

The OS parameters code will bump the number of lines over 10K, and thus
we need to silence this (no, we don't want any other module to become
this big…, so we use a targeted silence only).

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

c7d04a6b 06/23/2010 07:23 pm Iustin Pop

Add reading of OS parameters from disk

The patch also modifies the internal methods in LUDiagnoseOS and gnt-os
to deal with the format change of call_os_diagnose.

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

acd9ff9e 06/23/2010 07:23 pm Iustin Pop

Introduce an RPC call for OS parameters validation

While we only support the 'parameters' check today, the RPC call is
generic enough that will be able to support other checks in the future.
The backend function will both validate the parameters list (so as to...

85a87e21 06/23/2010 12:38 pm Guido Trotter

Add repetition count to the TestDelay opcode

If the repetition count is not passed or is passed as 0 we sleep exactly
one time, otherwise we sleep "repeat" times and log in between.

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

706c353c 06/22/2010 04:26 pm Iustin Pop

Merge branch 'devel-2.1'

  • devel-2.1:
    Add "adopt" to the allowed disk parameters
    Improve pylintrc for pylint 0.21+
    Fix warnings with Python 2.6
    Fix a small bug introduced in cf26a87a
    Fix the type of 'valid' attribute in LUDiagnoseOS

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

035f40fc 06/22/2010 12:25 pm Iustin Pop

Fix a small bug introduced in cf26a87a

Commit cf26a87a added a tiny typo, which would break non-FQDN arguments
to modify node storage.

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

e88fc57d 06/22/2010 12:23 pm Iustin Pop

Fix the type of 'valid' attribute in LUDiagnoseOS

The update of the valid status in LUDiagnoseOS says:

valid = valid and osl and osl[0][1]

However, in Python, “True and []” (which '[]' we get for an invalid OS)
will result in “[]”, and thus the valid field for an OS will be either...

422d4619 06/14/2010 09:37 pm Iustin Pop

Rework LUSetInstanceParams._GetUpdatedParams

Currently, this function does three things:
- special handling of constants.VALUE_DEFAULT
- type enforcing of the resulting dict
- filling the dictionary with defaults

However, except for the first one, the second two do not belong in this...

73e0328b 06/14/2010 09:35 pm Iustin Pop

Add cluster.SimpleFill*() functions

Currently, the existing cluster.Fill* functions take as argument an
instance. This means that in any case where we don't have an actual
instance object, we have to resort to calling the low-level
objects.FillDict function....

31ca841c 06/14/2010 09:33 pm Iustin Pop

Merge branch 'devel-2.1' into master

Signed-off-by: Iustin Pop <>
Reviewed-by: Balazs Lecz <>

c47478f9 06/14/2010 08:47 pm Iustin Pop

Fix a bug in instance startup with custom hvparams

Since the introduction of OS-specific hvparams, we shouldn't ever use
objects.FillDict directly for instances, but instead go via the cluster
object. Otherwise the os_hvp will be ignored.

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

845da3e8 06/14/2010 08:46 pm Iustin Pop

Fix unsafe variant initializer in _TryOSFromDisk

In case an OS has inconsistent declarations, we might get into a case
where one node reports a valid variants list (with OS API >=15), and
another node has OS API < 15, in which case its supported_variants gets...

7f7b730a 06/14/2010 07:58 pm Michael Hanselmann

Start instance after creating snapshots for export

This restores functionality lost in commit 387794f8. Found during
tests using QA scripts. An instance should be started after it
has been temporarily shutdown for an export.

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

d51ae04c 06/14/2010 07:58 pm Michael Hanselmann

Use import/export magic for backup/import and inter-cluster moves

This should prevent bugs in our code from accidentally overwriting
disks.

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

acd65a16 06/14/2010 07:56 pm Michael Hanselmann

import/export: Validate remote host/port

The hostname and port received from the remote cluster should
be validated, just in case.

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

bd061c35 06/11/2010 12:50 pm Guido Trotter

Enforce consistency in disks and nics input dicts

With this change unknown disk and nic parameters will be refused, rather
than silently ignored, so that one can't pass them in by mistake and not
realize what went wrong.

Signed-off-by: Guido Trotter <>...

1b67be9b 06/11/2010 12:24 pm Guido Trotter

TLMigrateInstance: pass lu to _Check*

The various _Check* helper functions expect an lu to be passed in, but
the TL is passed instead. This works... sometimes! :)

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

e6b8d02d 06/08/2010 04:12 pm Michael Hanselmann

Show formatted ETA for disk sync and import/export

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

664ab866 06/04/2010 05:17 pm Guido Trotter

Merge branch 'devel-2.1'

  • devel-2.1:
    _ExecuteKVMRuntime: fix hv parameter fun
    Update FinalizeMigration docstring
    LUGrowDisk: fix operation on down instances
    Allow disk operation to act on a subset of disks
    NEWS: add release date for 2.1.3
    Bump up version for the 2.1.3 release...
41bbdb52 06/04/2010 04:22 pm Guido Trotter

LUGrowDisk: fix operation on down instances

Currently it's impossible to grow a disk if an instance is shutdown,
because the disk could not be assembled. Now we take care of assembling
it, and shutting it down after.

Signed-off-by: Guido Trotter <>...

ef628379 06/04/2010 04:22 pm Guido Trotter

Allow disk operation to act on a subset of disks

If the disks= parameter is passed, we can assemble/wait for
sync/shutdown only some disks belonging to an instance, rather than all.

This is useful to only activate/sync/shutdown the affected disk when
growing it....

ff89a747 06/01/2010 07:39 pm Michael Hanselmann

Distribute cluster domain secret

The cluster domain secret file was not distributed to other nodes.

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

eb630f50 05/21/2010 06:17 pm Michael Hanselmann

Put common import/export daemon options into object

The X509 key name and CA are passed from cmdlib all the way to
the backend import/export daemon. With the addition of an option
to choose the compression method, another parameter would have
to be passed all the way. By moving these options to a separate...

9bf56d77 05/18/2010 06:53 pm Michael Hanselmann

Implement opcode changes for remote-import

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

4a96f1d1 05/18/2010 06:53 pm Michael Hanselmann

Implement opcode changes for remote-export

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

1410fa8d 05/18/2010 06:53 pm Michael Hanselmann

Add opcode to prepare export

To prepare a remote export, the X509 key and certificate need to be generated.
A handshake value is also returned for an easier check whether both clusters
share the same cluster domain secret.

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

dfb34028 05/18/2010 01:30 pm Michael Hanselmann

Add function to read cluster domain secret

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

895eb320 05/18/2010 01:11 pm Michael Hanselmann

LUExportInstance: Remove instance only if export was successful

Until now, the instance was always removed (if asked for by the
user). In case of export errors however, it shouldn't.

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

31ff0247 05/17/2010 02:17 pm Michael Hanselmann

Merge branch 'devel-2.1'

  • devel-2.1:
    RAPI: /2/{nodes,instances}/$name should return 404 for unknown items
    ganeti-masterd: Improve error logging for client requests
    Return disk_template from LUQueryInstanceData
    RAPI client: Rename Get{Node,Instance}Info, add new GetInstanceInfo...
f02fbd30 05/17/2010 01:52 pm Michael Hanselmann

Return disk_template from LUQueryInstanceData

Inter-cluster instance moves need the disk template. As they run
LUQueryInstanceData to get an instance's details, the disk template
must be returned.

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

a3a5f850 05/17/2010 01:33 pm Iustin Pop

Add checks for master IP in cluster verify

This also updates a comment in the unittest for utils.py. We unittest
the new function for two things: correct reporting on real case (for
localhost), and correct reporting with a mocked-out TcpPing that returns...

5e26633b 05/11/2010 09:25 pm Michael Hanselmann

Merge branch 'devel-2.1'

  • devel-2.1: (29 commits)
    RAPI client: Improve SSL error reporting
    RAPI client: Don't check node role in client
    RAPI client: Update ReplaceInstanceDisks
    RAPI client: Fix behaviour of “allocatable” storage flag
    RAPI client: Encode boolean and None query values...
95f84636 05/11/2010 11:48 am Iustin Pop

Fix tiny typo in cluster verify

Signed-off-by: Iustin Pop <>
Reviewed-by: Balazs Lecz <>

387794f8 05/04/2010 03:38 pm Michael Hanselmann

LUExportInstance: Move exporting code to helper class

This will simplify the implementation of intra-cluster instance
exports and reduces the number of local variables in
LUExportInstance.Exec.

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

c1e7897d 05/04/2010 03:37 pm Michael Hanselmann

Merge branch 'devel-2.1'

  • devel-2.1:
    cfgupgrade: allow working with relative paths
    Cleanup /etc/hosts during node removal
    verify cluster: check /etc/hosts consistency
    Change the migration message
    qa: enable early release during parallel burnin...
58385fad 05/03/2010 06:27 pm Iustin Pop

verify cluster: check /etc/hosts consistency

If we are told to modify /etc/hosts, then verify its consistency during
cluster verify.

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

7672a621 05/03/2010 06:27 pm Iustin Pop

Cleanup /etc/hosts during node removal

It seems that commit d8470559 dropped the cleanup of /etc/hosts when a
node is removed from the cluster. I don't know for sure, but it seems
accidental. As long as we add it to /etc/hosts, we should clean it up
too....

24d70417 04/29/2010 04:30 pm Michael Hanselmann

Move cmdlib._VerifyCertificate to utils

This function will also be useful for inter-cluster instance
moves for verifying certificates.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

b60ea3ff 04/23/2010 05:50 pm Michael Hanselmann

cmdlib: Convert instance import to new style

Use instance data transfer utility to import instances.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

4fcb1b59 04/23/2010 05:50 pm Michael Hanselmann

cmdlib: Convert instance export to new style

With this change, exports of several disks will occur in parallel. Error
handling has also been improved.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

6b92f2af 04/22/2010 07:12 pm Michael Hanselmann

Merge branch 'devel-2.1'

  • devel-2.1:
    Add a basic unittest for uidpool.RequestUnusedUid
    Factorize LUExportInstance
    Use ints instead of strings to represent user-ids
    QA: fix reimporting instance with different name
    Fix broken commit 9e302a8
    ssh: make quiet configurable...
e311ed53 04/22/2010 05:55 pm Michael Hanselmann

Factorize LUExportInstance

Apart from moving parts of the code to separate functions, error handling
is also improved by making sure snapshots are always removed.

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

a91143f1 04/22/2010 12:35 pm Michael Hanselmann

Merge branch 'devel-2.1'

  • devel-2.1:
    SSH: do not check IPs
    Add separate module for backported language functionality
    Add make commit-check target
    burnin: skip migration based on hypervisor support
    Add a hypervisor constant for migration support...
96d1a0c5 04/21/2010 08:22 pm Iustin Pop

LUSetClusterParams: initialize needed parameters

… since the opcode doesn't auto-initialize to None.

Signed-off-by: Iustin Pop <>
Reviewed-by: Balazs Lecz <>

f39cd91d 04/20/2010 07:26 pm Balazs Lecz

Merge branch 'devel-2.1'

Conflicts:
doc/security.rst
trivial
lib/cli.py
trivial

Signed-off-by: Balazs Lecz <>
Reviewed-by: Michael Hanselmann <>

9f3ac970 04/20/2010 12:25 pm Iustin Pop

Fix changing the list of enabled hypervisors

When enabling a new hypervisor, we must ensure that we have its
parameters in the cluster (global) hvparams dictionary.

Furthermore, we add a verify check for this case (this should be better
replaced with an auto-fix?)....

1513e2dd 04/16/2010 05:13 pm Iustin Pop

Readd node: allow changed primary IP

The primary IP is not used for DRBD disks, only for the job queue and
internal commands. As such, it's trivial (with a quiet job queue) to
re-ip the node.

The patch just relaxes the checks in LUAddNode, and manual testing shows...

fdad8c4d 04/16/2010 04:10 pm Balazs Lecz

Add --add-uids/--remove-uids to gnt-cluster modify

Signed-off-by: Balazs Lecz <>
Reviewed-by: Guido Trotter <>

1338f2b4 04/16/2010 04:10 pm Balazs Lecz

Add --uid-pool option to gnt-cluster modify

Signed-off-by: Balazs Lecz <>
Reviewed-by: Guido Trotter <>

af2ae1c0 04/16/2010 03:06 pm Iustin Pop

Merge branch 'devel-2.1'

  • devel-2.1:
    utils: Add class to split string stream into lines
    Fix cluster behaviour with disabled file storage
    Update docstrings in tools/ and enable epydoc
    Forward-port the ganeti 2.0 cfgupgrade
    Add a new tool: sanitize-config...
0e3baaf3 04/15/2010 05:37 pm Iustin Pop

Fix cluster behaviour with disabled file storage

There are a few issues with disabled file storage:
- cluster initialization is broken by default, as it uses the 'no'
setting which is not a valid path
- some other parts of the code require the file storage dir to be a...

30198f04 04/12/2010 05:15 pm Iustin Pop

Merge remote branch 'devel-2.1'

  • devel-2.1:
    Update import documentation for the recent changes
    Add a identify-defaults options for import
    Fix create/import verification of hvparams
    objects.Cluster: add method to get hv defaults
    Reuse NIC information from export...
e588764d 04/12/2010 04:57 pm Iustin Pop

Add a identify-defaults options for import

When importing an instance, all the saved valued will be used as
explicitly specified values, overriding the cluster defaults. This means
export+import will change the status (from default to explicitly
specified) of parameters....

b6cd72b2 04/12/2010 04:57 pm Iustin Pop

Fix create/import verification of hvparams

Currently the instance creation checks the cluster hv defaults + the new
parameters for validity, ignoring the os-specific hvparams (this was an
oversight during the implementation of the os hvp). This patch uses the...

0af0f641 04/12/2010 04:57 pm Iustin Pop

Reuse NIC information from export

If the user doesn't pass any nics in import, do not use a default
one-nic, but instead read the nics from the export file as is.

Fortunately the export and the way nics are read from the command line
are compatible…

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