Statistics
| Branch: | Tag: | Revision:

root / lib @ 7a9dbd61

# Date Author Comment
7a9dbd61 10/04/2013 05:10 pm Klaus Aehlig

Provide path to ensure-dirs in pathutils

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Jose Lopes <>

b9db7d45 10/04/2013 05:10 pm Klaus Aehlig

Provide the canonical path to cfgupgrade in pathutils

This is the version-independent path for cfgupgrade, that will
always refer to the cfgupgrade of the currently installed version.

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Jose Lopes <>

790fc19d 10/04/2013 05:10 pm Klaus Aehlig

Expose the list of online nodes at ssconf

Ganeti's ssconf contains the list of nodes currently considered
online. Expose this data at the ssconf interface.

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Jose Lopes <>

750b7090 10/04/2013 05:10 pm Klaus Aehlig

Also export PKGLIBDIR in pathutils

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Jose Lopes <>

78521495 10/04/2013 05:10 pm Klaus Aehlig

Add predicate whether to call cfgupgrade --downgrade

Provide a predicate that, given the current version and the
version to go to, tells whether it is appropriate to call
cfgupgrade --downgrade.

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Jose Lopes <>

0890e0d1 10/04/2013 05:10 pm Klaus Aehlig

Add utility function to recognize upgrade ranges

Upgrading is possible within the same major version to any equal
or higher minor version. Downgrading is possible within the same
major version to the previous minor version. Moreover, automatic
upgrades are only supported from version 2.10 onwards. Add a utility...

8c44d5b3 10/04/2013 05:10 pm Klaus Aehlig

Also provide the program version

Conceptionally, the versions of the program, the protocols, and the
configuration are three different things, even though, currently there
is a tight coupling. So export the version as well, as the upgrades
are designed to make decisions based on the version....

1eda3dd3 10/04/2013 05:09 pm Klaus Aehlig

Add utility function to parse version strings

The new 'gnt-cluster upgrade' command will get a Ganeti version as
argument. So provide a function able to parse it.

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Jose Lopes <>

294254b1 10/02/2013 05:55 pm Raffa Santi

Check validity of the access protocol parameter

  • Prevent incompatible hypervisor/disk template/access type
    combinations from being reached through the command line.
  • Prevent the access config from taking illegal values such as "pink
    bunny" through the command line....
117a85a0 10/02/2013 05:55 pm Raffa Santi

Add Userspace RBD support in KVM

  • Add device class object in block_device tuple
  • Update hv_xen.py for new block_devices format
  • Fix tests broken by the change

Signed-off-by: Santi Raffa <>
Reviewed-by: Thomas Thrainer <>

f83057ad 10/02/2013 05:55 pm Raffa Santi

New method GetUserspaceAccessURI in storage class

Returns a hypervisor specific URI for RBD template when userspace
access is requested.

Signed-off-by: Santi Raffa <>
Signed-off-by: Thomas Thrainer <>
Reviewed-by: Thomas Thrainer <>

9b9e088c 10/02/2013 05:55 pm Raffa Santi

Define 'access' disk-parameter type

Add the "access" parameter to the RBD configuration. Fix test broken
by this change.

Signed-off-by: Santi Raffa <>
Reviewed-by: Thomas Thrainer <>

d067f40b 10/02/2013 03:50 pm Jose A. Lopes

Merge 'EvacNode' and 'NodeEvacMode'

Merge 'EvacMode' and 'NodeEvacMode' which are associated with the
duplicated constants 'IALLOCATOR_NEVAC_*' and 'NODE_EVAC_*'. This
merge moves the type 'EvacMode' to 'Ganeti.Types' in order to avoid a
circular dependency between 'Ganeti.HsConstants' and...

6dc364f9 10/02/2013 03:50 pm Jose A. Lopes

Remove duplicate 'IALLOCATOR_NEVAC_*' constants

Constants 'IALLOCATOR_NEVAC_*' are duplicates of 'NODE_EVAC_*' and are
no longer being used so they can be removed. Fixes issue 583.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

d4d424fb 10/02/2013 03:50 pm Jose A. Lopes

Replace 'IALLOCATOR_NEVAC_*' with 'NODE_EVAC_*'

Replace uses of 'IALLOCATOR_NEVAC_PRI', 'IALLOCATOR_NEVAC_SEC',
'IALLOCATOR_NEVAC_ALL', and 'IALLOCATOR_NEVAC_MODES', with
'NODE_EVAC_PRI', 'NODE_EVAC_SEC', 'NODE_EVAC_ALL', and
'NODE_EVAC_MODES', given that these constants are repeated....

b5cad580 10/02/2013 03:22 pm Raffa Santi

Add soundhw support to XEN hypervisors

This allows XEN hypervisors to enable sound support, if the host
machines has required support. This has been tested only up to the
point of making sure the xen config file has the required
configuration values as per:...

295ed29b 10/02/2013 03:22 pm Santi Raffa

Add cpuid support to XEN hypervisors

Ease instance migration between heterogeneous nodes by letting system
administrators hide CPU capabilities as needed.

Signed-off-by: Santi Raffa <>
Reviewed-by: Thomas Thrainer <>

690e509d 09/30/2013 03:20 pm Spyros Trigazis

Add MonD's latest API Version in lib/constants.py

Extract the version number from MonD's own file into the constants file, so that
is can be accessed from other parts of the system as well (e.g.: to perform
queries over the MonD protocol).

Signed-off-by: Spyros Trigazis <>...

f56ab6d1 09/27/2013 09:33 am Thomas Thrainer

Use secondary IP when moving instances

All data traffic usually goes over the secondary network, but
gnt-instance move didn't. This patch corrects this problem by using the
target nodes secondary IP as move target.

Signed-off-by: Thomas Thrainer <>...

3c260845 09/26/2013 04:02 pm Thomas Thrainer

Honor disks_active of instance when adding disks

Adding a disk to an instance used to leave the disk behind activated, no
matter how the disks_active flag of the instance was. This changes make
sure that new disks are only active if the other disks of the instance...

922a9e65 09/26/2013 04:02 pm Thomas Thrainer

Wait for disk sync when adding a disk

When creating an instance, gnt-instance waits for instance disks to
sync. Inconsistently, this was not the case for adding a disk to an
instance. This patch changes the default behavior to wait for sync when
adding a disk, but honor the --no-wait-for-sync option which...

42e85303 09/25/2013 04:49 pm Klaus Aehlig

Merge branch 'stable-2.9' into master

  • stable-2.9
    Including missing RST files in packaging
    Update supported lint tools version numbers
    Fix some wrong indentations in the code
    Disable parenthesis indentation check
    Fix an improperly escaped string...
08d58f4c 09/25/2013 03:07 pm Klaus Aehlig

Merge branch 'stable-2.8' into stable-2.9

  • stable-2.8
    Add additional tests for utils.Retry
    Make retry tests independent of actual time
    Fix corner-case in handling of remaining retry time
    Perform proper cleanup on termination of Haskell daemons

Signed-off-by: Klaus Aehlig <>...

effc1b86 09/25/2013 01:50 pm Jose A. Lopes

Move 'BuildVersion' to 'lib/utils/version.py'

Functions 'BuildVersion' and 'SplitVersion' are no longer needed by
the constants and, given that they are not constants, they should be
moved elsewhere. Since they are only used by 'cfgupgrade' and tests,
these functions are moved to 'lib/utils/version.py' and references to...

b8669a69 09/25/2013 01:49 pm Jose A. Lopes

Hs2Py constants: update Python references

Update references to constants that were previously in the generated
'lib/_autoconf.py' and since the previous patch have been included in
the Hs2Py constant generation.

Signed-off-by: Jose A. Lopes <>...

e0d672fa 09/25/2013 01:49 pm Jose A. Lopes

Hs2Py constants: update Python references to autoconf

Update Python references to all constants that used to point to the
generated 'lib/_autoconf.py', which has been superseeded by the
Haskell counterpart 'src/AutoConf.hs'.

Signed-off-by: Jose A. Lopes <>...

e0e44476 09/25/2013 10:55 am Michele Tartara

Fix some wrong indentations in the code

Fix all instances of pep8's error: "E128 continuation line under-indented for
visual indent".

Signed-off-by: Michele Tartara <>
Reviewed-by: Guido Trotter <>

5e34123e 09/25/2013 10:51 am Michele Tartara

Make QmpMessage a proper container

Newer pylint versions complain that QmpMessage is not a proper container because
it does not implement the len() and delitem() methods. This commit
implements them.

Also, tests are added.

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

f5bfed26 09/24/2013 02:36 pm Jose A. Lopes

Hs2Py constants: update Python references

Update references of Python constants in the previous patch to fetch
their values from the generated Haskell to Python constants.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

8d04ac5e 09/24/2013 02:36 pm Jose A. Lopes

Hs2Py constants: update Python references

Update references of the Python constants that were introduced in the
previous patch.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

d66acf3d 09/24/2013 10:37 am Thomas Thrainer

Fix RPC call to blockdev_getdimensions

The parameter format for call_blockdev_getdimensions has changed in a
previous patch. Here, the correct parameter format is used for the RPC
call.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Jose A. Lopes <>

76b920e6 09/24/2013 09:17 am Thomas Thrainer

Display node names instead of node UUIDs

Display resolved node names instead of node UUIDs in a couple of
warnings and log messages.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Jose A. Lopes <>

a0d2a91e 09/24/2013 09:17 am Thomas Thrainer

Only serialize dynamic_params on demand

To make sure that the dynamic_params field is not serialized by accident
to the configuration file only include it in the serialization when
explicitly asked for.

Signed-off-by: Thomas Thrainer <>...

a57e502a 09/24/2013 09:17 am Thomas Thrainer

Remove physical_id field from disk object

The 'physical_id' field of disk objects is no longer used, so remove it.
Also, all references are removed together with the code which made sure
that the physical_id is up to date when transmitted over RPC.

Signed-off-by: Thomas Thrainer <>...

0c3d9c7c 09/24/2013 09:17 am Thomas Thrainer

Replace physical_id with dynamic_params

The disk field 'physical_id' has to be kept up to date whenever a disk
object is sent to a node via RPC. This is done with the SetDiskID method
manually, which is a source of bugs.

This patch replaces the use of 'physical_id' with a new field names...

5bd52dab 09/24/2013 09:17 am Thomas Thrainer

Fix typo

Fix typo in comment.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Jose A. Lopes <>

cd824bde 09/20/2013 04:03 pm Jose A. Lopes

Hs2Py constants: update 'SF_*' references

Update references to storage field Python constants to fetch their
values from 'lib/_constants.py'.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

34098a73 09/20/2013 03:21 pm Klaus Aehlig

Fix corner-case in handling of remaining retry time

Consider a remaining time of 0 as already timed out. Otherwise,
there is no guarantee that calling utils.Retry with timeout 0
will call the function precisely once; it might run in time
shorter than the resolution of timer....

2ff95a6b 09/19/2013 06:15 pm Jose A. Lopes

Hs2Py constants: update Python references

Update references to the Python constants generated in the previous
patch.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

3311e336 09/19/2013 04:42 pm Jose A. Lopes

Fix conflicting path values from 'configure'

Because the Hs2Py constant generation infrastructure is transitional,
there are two generated 'autoconf' modules, namely, 'src/AutoConf.hs'
and 'lib/_autoconf.py'. However, conflicting values were being
generated for Haskell and Python concerning the variables...

230bc94a 09/19/2013 03:49 pm Klaus Aehlig

Merge branch 'stable-2.9' into master

  • stable-2.9
    Fix incorrect conflict resolution in lib/cmdlib/instance.py
  • stable-2.8
    Version bump for 2.8 rc3
    Add a default to file-driver when unspecified over RAPI
    Remove typo from RAPI documentation
    Describe the files in doc/users in NEWS...
8a7a197a 09/19/2013 11:52 am Jose A. Lopes

Hs2Py constants: update Python references

Update Python references to all constants added in the previous patch,
which are the constants associated with the Haskell types declared in
'Ganeti.Types'.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

06fd57e5 09/19/2013 11:52 am Jose A. Lopes

Fetch 'randomUuidFile' from 'ConstantUtils'

In 'Ganeti.Utils', update the reference to 'randomUuidFile' to fetch
the value from 'Ganeti.ConstantUtils' instead of the Python to Haskell
generated constant. This allows breaking the dependency of
'Ganeti.Utils' on the constants module, which in turn will allow...

7236533e 09/18/2013 02:33 pm Jose A. Lopes

Hs2Py constants: add xen related constants

Add xen related constants, such as, 'xenBootloader' and 'xenCmdXm' to
the Haskell to Python constant generation.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

df726590 09/18/2013 02:33 pm Jose A. Lopes

Hs2Py constants: add 'devConsole' and syslog related

Add 'devConsole' and syslog related constants to the Haskell to Python
constant generation.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

edada04b 09/18/2013 01:29 pm Michele Tartara

Fix strings invalid with newer lint versions

Generating ASCII characters via a supported but not official escape sequence
leads to a "Anomalous backslash in string" error in newer pylint versions. This
patch fixes the issue.

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

216bfc8f 09/18/2013 11:55 am Jose A. Lopes

Update Python references to exit code constants

Update Python references to exit code constants to take their values
from the generated 'lib/_constants.py'.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

1a79791d 09/18/2013 11:55 am Jose A. Lopes

Update Python reference to 'DAEMONS_LOGBASE'

Update Python reference of 'DAEMONS_LOGBASE' to fetch its value from
the generated 'lib/_constants.py' module.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

1c31b263 09/18/2013 11:55 am Jose A. Lopes

Flip dependency between Haskell types and constants

Before this patch, Haskell types, such as, 'GanetiDaemon' and
'GanetiGroup', and related functions were taking their values from
Haskell constants. However, given that the role of Haskell to Python
constants is to leverage Haskell and its typesystem, it makes sense to...

5be00b4b 09/17/2013 05:54 pm Klaus Aehlig

Fix incorrect conflict resolution in lib/cmdlib/instance.py

Between the last two merges, nothing happened on stable-2.9. The
only change on stable-2.8 that touched lib/cmdlib/instance.py is
ff34fb97. So make sure, the net change since the last merge to
this file is that of the said commit. This also fixes the doclint...

52469de0 09/17/2013 02:12 pm Klaus Aehlig

Merge branch 'stable-2.8' into stable-2.9

  • stable-2.8
    Add a default to file-driver when unspecified over RAPI
    Remove typo from RAPI documentation
    Describe the files in doc/users in NEWS
    Update the upgrade procedure
  • stable-2.7
    Fix incorrect manpage reference to htools...
ff34fb97 09/16/2013 02:25 pm Michele Tartara

Add a default to file-driver when unspecified over RAPI

The file-driver value, used by file-based instances, had a default value when
an instance was being created over the CLI, but not when the instance was
created through the RAPI.

This patch introduces a default value for the remote API and, while doing so,...

355d1f32 09/13/2013 02:55 pm Sebastian Gebhard

Fix lint errors in fix keyerrors patch

This patch fixes one lint error introduced by my recent patch to
fix keyerrors in lib/cmdlib/node.py.

Signed-off-by: Sebastian Gebhard <>
Signed-off-by: Klaus Aehlig <>
Reviewed-by: Klaus Aehlig <>

0d8ce33e 09/13/2013 01:50 pm Sebastian Gebhard

Fix keyerrors in cmdlib node

This patch fixes potential key errors in the OpenvSwitch implementation
in cmdlib/node.py. The checks in that file expected to have a ndparams dict
with certain keys to be present. This should not be the case as it will
result in KeyErrors when those keys are not present....

aefc2f89 09/12/2013 03:56 pm Thomas Thrainer

Use RpcResult.Warn where appropriate

Those two occurrences of warnings can be replaced the RpcResult.Warn
method, which is done in this patch.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Klaus Aehlig <>

34956ece 09/12/2013 03:56 pm Thomas Thrainer

Remove unneeded except block

The validation of the opcodes already checks the size parameter for the
right type, so this except block is not required.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Klaus Aehlig <>

f667baab 09/12/2013 03:56 pm Thomas Thrainer

Rename variable to reflect its content

Rename the "node" variable to "node_uuid" as that's the content it
actually receives.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Klaus Aehlig <>

0c5f1b13 09/12/2013 03:23 pm Thomas Thrainer

Merge branch 'stable-2.9' into master

  • stable-2.9
    Fix bridging in net-common
    Sync build_chroot with buildbot slack role
    Auto-upgrade of disks' config wrt LD-renaming
    Fix tests regarding DISK_LD_DEFAULTS
    Fixing renaming of DISK_LD_DEFAULTS
    Replace LD_* constants with DT_* constants...
191e5c19 09/12/2013 02:01 pm Jose A. Lopes

Update reference to Python constants

Update reference to 'DAEMONS_PORTS' and related constants that are
used on the Haskell side to construct the 'daemonsPorts' constant.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

f2cf4da2 09/12/2013 02:01 pm Jose A. Lopes

Update references to Python constants

Update references to the Python constants introduced by the previous
patch.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

6970c28b 09/11/2013 11:16 am Jose A. Lopes

Inconsistent auto repair related constant

In 'lib/constants.py', fix inconsistency in the value of
'AUTO_REPAIR_TAG_SUSPENDED'. Fixes issue 569.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

d5b17094 09/11/2013 11:02 am Jose A. Lopes

Update constant references

Update Python user separation constants to reference the generated
module 'lib/_constants.py' instead of 'lib/_autoconf.py'.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

2b1c5a63 09/10/2013 11:58 am Jose A. Lopes

Haskell to Python constants: Update 'ADMINST_ALL' reference

Update constant 'ADMINST_ALL' to take its value from the generated
'lib/_constants.py' module.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

88284d52 09/10/2013 11:58 am Jose A. Lopes

Fix module documentation

Fix 'lib/_constants.py.in' documentation to be consistent with other
modules.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Klaus Aehlig <>

b2fbea47 09/09/2013 07:47 pm Jose A. Lopes

Replace literals with constants

In "lib/cmdlib/node.py", in lines 1315-1316, 1354, and 1359-1370,
replace string literals with constants. Fixes issue 558.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Michele Tartara <>

73d6b4a7 08/29/2013 04:13 pm Helga Velroyen

Auto-upgrade of disks' config wrt LD-renaming

This patch adds auto-upgrade functionality to the disk
objects with respected to the switch from LD constants
to DT constants. Unit tests are provided.

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

acf9af53 08/29/2013 01:17 pm Jose A. Lopes

Update Python constants references to '_constants.py'

Update Python constants 'ADMINST_{DOWN,UP,OFFLINE}' to take their
values from the Haskell generated module 'lib/_constants.py'.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Guido Trotter <>

1b2adaa6 08/29/2013 01:17 pm Jose A. Lopes

Setup constant generation infrastructure

Setup a transitional Haskell to Python constant generation
infrastructure. This infrastructure is transitional and Python
constants will not be migrated to Haskell all at once. Instead, some
constants will be incrementally pulled from Python and moved to...

6da90c0a 08/28/2013 10:13 pm Helga Velroyen

Fixing renaming of DISK_LD_DEFAULTS

This fixes the somewhat over-eager renaming of
DISK_LD_DEFAULTS to DISK_DT_DEFAULTS, which clashes
with another occurence of DISK_DT_DEFAULTS. This
patch just undoes the renaming and additionally fixes
a test regarding shared file storage....

cd3b4ff4 08/28/2013 06:19 pm Helga Velroyen

Replace LD_* constants with DT_* constants

LD_* constants are basically like DT_* constants, except
for that both file and shared file were mapped to file.
In order to not having to maintain three slightly different
sets of disk-related constants (DT, LD and ST), we merge...

2c88200b 08/27/2013 04:50 pm Helga Velroyen

CLI: actually remove the --no-drbd-storage option

This removes the '--no-drbd-storage' option completely
from the command line interface. The hugepages design
doc still had a left-over reference to --no-lvm-storage,
which is removed in this patch as well....

38969795 08/27/2013 04:50 pm Helga Velroyen

cluster init/modify: set helper without DRBD being enabled

The logic around the DRBD usermode helper so far was that
setting it was only possible when DRDB was not explicitely
disabled. This patches changes it in a way that it is
consistent to how Ganeti handles the volume group name....

25e5e785 08/27/2013 04:50 pm Helga Velroyen

objects.py: upgrade config

Upgrading the config with respect to the DRBD usermode
helper was so far based on a guess whether or not DRBD
is enabled by checking if there are any DRBD instances
running. This check can now be replaced to look at the
list of enabled disk templates in the cluster's...

31ccfc0e 08/27/2013 04:50 pm Helga Velroyen

cluster modify: deprecate --no-drbd-storage

As in the previous patch, the option '--no-drbd-storage'
is deprectated, because it is subsumed by the non-inclusion
of 'drbd' in the list of enabled disk templates.

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

7796e1f8 08/27/2013 04:50 pm Helga Velroyen

cluster init: deprecate --no-drbd-storage

Whether or not a particular type of storage is enabled
or not is determined by the list of enabled disk templates
in the cluster's configuration. This makes the option
'--no-drbd-storage' obsolete, because it is subsumed by...

9af7ece3 08/27/2013 04:50 pm Helga Velroyen

cluster verify: check drbd helper only when drbd enabled

This change makes sure that 'gnt-cluster verify' only
checks for the DRBD usermode helper, if DRBD is actually
enabled.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Thomas Thrainer <>

7c577910 08/27/2013 04:50 pm Helga Velroyen

cmdlib/cluster.py: unit tests for usermode helper

This patch factors out the functions that deal with setting
and modifying the DRBD usermode helper in cluster.py in
order to make them more unittestable. The unit tests are
provided as well. No functional changes otherwise....

c121d42f 08/27/2013 04:50 pm Helga Velroyen

gnt_cluster.py: unit test for usermode helper

This patch factors out the functions in gnt_cluster
(related to cluster init and cluster modify) which
deal with setting / determining the drbd usermode helper
to make them more testable. Unit tests for the extracted...

af95196c 08/27/2013 04:50 pm Helga Velroyen

bootstrap.py: unit tests for setting the usermode helper

This patch factors out the function that checks the DRBD
usermode helper in bootstrap (cluster init) in order to make
it more testable. It also contains the unit tests. Otherwise,
no functional changes....

f148fe23 08/27/2013 03:04 pm Klaus Aehlig

Merge branch 'stable-2.8' into stable-2.9

  • stable-2.8
    Add function to unwrap Results logging failures
    Make the DRBD collector more failure-resilient
    Prepare GetLinuxNodeInfo for testing
    Add unit test for GetLinuxNodeInfo
    NEWS update and version bump for 2.8 rc2...
6afb9fb4 08/27/2013 09:32 am Jose A. Lopes

Simplify '_CheckOutputFields'

Function '_CheckOutputFields' was receiving three field sets, two of
which were simply being merged together. This was complicated and
unnecessary. This patch simplifies '_CheckOutputFields' to take
simply two field sets.
...

dc3dcdaf 08/27/2013 09:32 am Jose A. Lopes

Add 'SF_NODE' to 'VALID_STORAGE_FIELDS'

Constant 'SF_NODE' is a storage field and, therefore, should be in
'VALID_STORAGE_FIELDS'. This patch fixes this and also reference to
these constants, namely, in 'cmdlib' and 'qa'.

Signed-off-by: Jose A. Lopes <>...

78f99abb 08/23/2013 03:12 pm Michele Tartara

Lint improvements to regexps

Fix some regular expressions so that they pass lint checks with newer versions
of pylint.

Signed-off-by: Michele Tartara <>
Reviewed-by: Helga Velroyen <>

f51e9849 08/23/2013 10:27 am Klaus Aehlig

Add name for the Parameter ND_OVS

That was forgotten when the parameter was added.

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Michele Tartara <>

23cb5697 08/22/2013 06:17 pm Michele Tartara

Prepare GetLinuxNodeInfo for testing

The names of the input files are not hardcoded anymore, but they are now default
parameters.

No changes for the callers, but it's now possible to test the function more
easily.

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

7bb0c47f 08/22/2013 03:03 pm Thomas Thrainer

Check right disk template in inst set params

While checking the parameters of the opcode for LUInstanceSetParams, the
already set disk_template was checked instead of the new one in the
opcode. This patch fixes this bug.

Signed-off-by: Thomas Thrainer <>...

c760c1aa 08/21/2013 06:26 pm Sebastian Gebhard

Add parameters for OpenvSwitch to gnt-node

Extend gnt-node by parameters for OpenvSwitch. --ovs Flag to enable
OpenvSwitch, --ovs-name for the name of the OpenvSwitch and --ovs-link
for the interface to connect to.

Signed-off-by: Sebastian Gebhard <>...

90d8d4d1 08/21/2013 06:26 pm Sebastian Gebhard

Add RPC functionality for creating OpenvSwitches

This patches adds the needed RPC functions in order to create the
OpenvSwitches on the nodes.

Signed-off-by: Sebastian Gebhard <>
Signed-off-by: Klaus Aehlig <>
Reviewed-by: Klaus Aehlig <>

8baa9ca7 08/21/2013 06:26 pm Sebastian Gebhard

Add OpenvSwitch functionality to LUNodeAdd

This patch adds functionality to LUNodeAdd to
- check the arguments given. It will warn if no physical link is given
and fail if OpenvSwitch is not enabled, but parameters are given
- call the RPC to configure OpenvSwitch on the node...

4daa5eb9 08/21/2013 06:26 pm Sebastian Gebhard

Backend: Create openvswitches on the nodes

This is the functionality to create the OpenvSwitches on the nodes.
Parameters are given via opcode and checked as well as extended with
the defaults.

Signed-off-by: Sebastian Gebhard <>
Signed-off-by: Klaus Aehlig <>...

807d8853 08/21/2013 06:21 pm Sebastian Gebhard

Add params for OpenvSwitch to ndparams

This patch introduces the needed fields for OpenvSwitch parameters
into ndparams and also provides the default values.

The parameters are:
ND_OVS: boolean, to show whether OpenvSwitch is enabled or not
ND_OVS_NAME: the name of the OpenvSwitch to create...

b01d9504 08/21/2013 04:30 pm Michele Tartara

Fix bug in NodeD and RapiD usage strings

The strings did not comply with the style guide, and were not diplayed
correctly either.

Signed-off-by: Michele Tartara <>
Reviewed-by: Klaus Aehlig <>

66222813 08/21/2013 10:27 am Thomas Thrainer

Add unit tests for LUInstanceCreate and move tests

- Move instance related tests to instance_unittest.py
- Adapt moved tests to the new test framework where appropriate
- Add unit test coverage for LUInstanceCreate
- Only instance creation is covered yet, no imports...

d2429198 08/21/2013 10:25 am Thomas Thrainer

Merge branch 'stable-2.9' into master

  • stable-2.9
    Allow instance mods if only osparams are given
    Use node UUIDs for locking instead of node names
    Allow instance mods if only osparams are given
    Fix a node name vs. UUID bug in instance import
    Typo in hroller man page...
125e1230 08/20/2013 03:18 pm Thomas Thrainer

Allow instance mods if only osparams are given

osparams are now recognized as changes, so changing only those without
other changes works too now.

(cherry picked from commit 5eae613c2e1e65101c5d5f7d2e8ffd7cc6edc7d5)

Signed-off-by: Thomas Thrainer <>...

6869f673 08/20/2013 02:46 pm Thomas Thrainer

Use node UUIDs for locking instead of node names

LUInstanceMultiAlloc used node names instead of node UUIDs to lock
required nodes. This patch fixes this bug.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Guido Trotter <>

5eae613c 08/20/2013 01:53 pm Thomas Thrainer

Allow instance mods if only osparams are given

osparams are now recognized as changes, so changing only those without
other changes works too now.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Helga Velroyen <>

a61a0813 08/19/2013 04:23 pm Thomas Thrainer

Fix a node name vs. UUID bug in instance import

This patch fixes a bug where node names were incorrectly used as node
UUID's.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Helga Velroyen <>

b9aae98b 08/19/2013 11:09 am Thomas Thrainer

Use node UUID for locking in LUInstanceMove

This LU (incorrectly) used the node name for locking. This patch
corrects this error.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Michele Tartara <>

6e755f9e 08/14/2013 03:19 pm Thomas Thrainer

Fix IPolicy violation check in LUGroupSetParams

cfg.GetMultiInstanceInfoByName returns a list of tuples, not a list of
instance objects which is required by ComputeNewInstanceViolations.
This patch fixes this type error.

Signed-off-by: Thomas Thrainer <>...