Statistics
| Branch: | Tag: | Revision:

root / lib / cmdlib @ 4869595d

# Date Author Comment
4869595d 12/17/2013 10:11 pm Petr Pudlak

Add a Python directory for RPC code to keep it at one place

Move rpc.py to rpc/node.py and modify imports in existing code.

Signed-off-by: Petr Pudlak <>
Reviewed-by: Helga Velroyen <>

5a904197 12/17/2013 06:12 pm Santi Raffa

Gluster: add the Shared File storage type

The shared file and gluster disk templates should not report their disk
space information like file does, because they do not behave the same.

If a cluster pulls from the same, shared source of storage then it is...

6488e5bc 12/17/2013 06:12 pm Santi Raffa

Gluster: add userspace access support

Add support for the QEMU gluster: protocol. Also change the access
mode routines so they check the access parameter for all templates.

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

845b7ed1 12/17/2013 06:12 pm Santi Raffa

Gluster: mount automatically

Add parameters to the Gluster disk template so Gluster can manage the
mount point point autonomously.

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

ac156ecd 12/17/2013 06:12 pm Santi Raffa

Gluster: use ssconf value for mountpoint directory

Gluster still does not mount anything autonomously, but this commit
changes where Gluster expects its mountpoint to be.

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

8106dd64 12/17/2013 06:12 pm Santi Raffa

Gluster: minimal implementation

Add Gluster to Ganeti by essentially cloning the shared file behaviour
everywhere in the code base.

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

b0e8ed3f 12/17/2013 04:59 pm Santi Raffa

gnt-cluster verify: demote orphan volume error to warning

Ganeti checks for orphan volume by making sure that it knows about all
volumes on disk; any additional orphan volume, even if created by the
administrator, causes a failure in gnt-cluster verify. Given that...

0359e5d0 11/29/2013 12:10 pm Spyros Trigazis

Add default_iallocator_params cluster parameter

Add a cluster parameter to hold the iallocator parameters used
by the default instance allocator. Implement the option to
modify config.data, query config.data and upgrade man pages,
tests and cfgupgrade tool. The new default_iallocator_params is...

5c98b73e 11/26/2013 11:14 am Helga Velroyen

Instance queries: remove opcodes and LU

Removes the remains of the instance queries.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Hrvoje Ribicic <>

64981f25 11/26/2013 11:14 am Helga Velroyen

Export and network queries: remove opcodes and LUs

Removes the remains of the export (aka backup) and network
queries.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Hrvoje Ribicic <>

081dc516 11/26/2013 11:14 am Helga Velroyen

Group queries: remove opcodes and LUs

Removes the remains of the group query code.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Hrvoje Ribicic <>

dde771ba 11/26/2013 11:14 am Helga Velroyen

Node queries: remove opcodes and LUs

Removes the remains of the node query code.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Hrvoje Ribicic <>

2a02d6fe 11/26/2013 11:14 am Helga Velroyen

Remove instance query python code

This patch removes the python code for the instance
queries. So far, it replaces it by 'NotImplemented'
exceptions. In a later patch of this series, the
remaining part is remove completely.

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

96431562 11/26/2013 11:14 am Helga Velroyen

Switch to Haskell for group queries

This patch removes the group query implementation
in python in order to use the new Haskell implementation.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Hrvoje Ribicic <>

fbeb41e6 11/26/2013 11:13 am Helga Velroyen

Switch to haskell for export (aka backup) queries

This patch removes the python implementation of export
(aka backup) queries. So far, it is replaced by
'NotImplemented' exceptions, but later in this series
it will be replaced completely.

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

44ffd981 11/26/2013 11:13 am Helga Velroyen

Switch to Haskell for network queries

This patch removes the python implementation of network
queries and replaces it with 'NotImplemented' exceptions.
It will be removed completely once all queries are
switched to Haskell.

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

862beeab 11/26/2013 11:13 am Helga Velroyen

Disable node query code

This patch removes the python query implementation for
nodes. So far, the code is replaced by 'NotImplemented'
exceptions, because the overall structure of query classes
can be removed more easily at once when all query
implementations are ready to be removed....

a9532fb0 11/26/2013 11:13 am Helga Velroyen

masterd: implement query via luxi

The master daemon so far still did queries via the python
implementation. This patch implements that it uses the
haskell implementation and removes the node queries from
the list of OP-queriable entities.

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

a4417db4 11/15/2013 04:49 pm Thomas Thrainer

Merge branch 'stable-2.10' into master

Merge branch 'stable-2.10' into master

  • stable-2.10
    Don't allow optional node parameters
    Move OVS node parameters to the right place
    Make NIC VLAN queryable
    Pass VLAN parameter correctly in moves
    Use constant instead of raw string...
adef95a2 11/15/2013 03:12 pm Thomas Thrainer

Merge branch 'stable-2.9' into stable-2.10

Merge branch 'stable-2.9' into stable-2.10

  • stable-2.9
    Bump revision for 2.9.1
    Update NEWS and schedule release for 2.9.1
    Fix retrieval of xen command in class method
    Fix docstring for ganeti.storage.filestorage_unittest.py...
c42be2c0 11/14/2013 05:40 pm Petr Pudlak

Use configured SSH ports when connecting to a console

This is accomplished by passing the corresponding node group to
hv_*.py. Tests for hv_*.py that call GetInstanceConsole updated.

Signed-off-by: Petr Pudlak <>
Reviewed-by: Hrvoje Ribicic <>

a9f33339 11/14/2013 05:40 pm Petr Pudlak

Use custom SSH ports in node groups when working with nodes

Calling `gnt-instance console` with a custom SSH port doesn't work yet.

Signed-off-by: Petr Pudlak <>
Reviewed-by: Hrvoje Ribicic <>

07e68848 11/14/2013 04:30 pm Thomas Thrainer

Don't allow optional node parameters

Ganeti does not support optional fields in parameters
(hypervisor-params, disk-params, etc.). OpenVSwitch related node
parameters were the exception to this rule, which caused numerous
problems related to import/export and (de-)serialization....

0d3f52da 11/14/2013 03:10 pm Jose A. Lopes

Fix instance info

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Hrvoje Ribicic <>

9c71582f 11/14/2013 03:09 pm Jose A. Lopes

Prevent instance start when user down

Prevent starting a given instance when that instance has been shutdown
by the user, given that the instance must be first properly shutdown.

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Hrvoje Ribicic <>

270df828 11/14/2013 03:08 pm Jose A. Lopes

Fix typo in documentation

Signed-off-by: Jose A. Lopes <>
Reviewed-by: Hrvoje Ribicic <>

f92d9674 11/12/2013 04:37 pm Helga Velroyen

Fix retrieval of xen command in class method

This patch fixes issue 608. When introducing the
configurability of the xen toolstack in commit
8ef418bb92, the hypervisor api was accidentally changed
in a way that let to this error in KVM.

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

a09639d1 11/11/2013 10:29 pm Santi Raffa

Remove hardcoded references to File, SharedFile templates

DTS_FILEBASED is a constant that exists and this commit makes sure
that it is used whenever sensible, rather than resorting to hardcoding
the pair of templates in very many files.

Signed-off-by: Santi Raffa <>...

30796ad6 11/07/2013 05:05 pm Klaus Aehlig

Readd nodes as online

Patch d0d7d7cf accidentally removed the offline-flag reset
when readding a node. Readd it.

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

fb62843c 11/07/2013 05:05 pm Klaus Aehlig

When verifying BRBD version, ignore missing values

When comparing for consistency of the DRBD versions, some
versions might not be available via RPC, typically, if the
node is offline. In this case, leave these nodes out of the
test, instead of failing with an internal python error....

cba1fce1 11/05/2013 03:31 pm Klaus Aehlig

Merge branch 'stable-2.10' into master

  • stable-2.10
    Fix documentation
    Replace all constant definitions with re-exports
    Prepare constants for automatic reexport
    Hs2Py constants: 'hvsParameterTypes' and 'hvsParameters'
    Fix indentation that triggers PEP8 error...
8dd23148 11/05/2013 02:57 pm Klaus Aehlig

Merge branch 'stable-2.9' into stable-2.10

  • stable-2.9
    Revision bump for 2.9.0
    Schedule release of 2.9.0
  • stable-2.8
    Improve error message for replace-disks

Conflicts:
NEWS: trivial
configure.ac: drop suffix bump of stable-2.9

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

f9dfa8df 11/04/2013 05:52 pm Klaus Aehlig

Merge branch 'stable-2.8' into stable-2.9

  • stable-2.8
    Improve error message for replace-disks

Conflicts:
lib/cmdlib/instance_storage.py
Resolved by manually applying the node name to uuid
transition on the version of stable-2.9.

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

34ea8da3 11/04/2013 05:30 pm Michele Tartara

Improve error message for replace-disks

In some conditions, replace-disks will fail if the disks are not properly
activated. Improve the error message suggesting to run activate-disks before
executing replace-disks.

Fixes Issue 606.

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

b15d5bd3 10/31/2013 06:18 pm Petr Pudlak

Fix indentation that triggers PEP8 error

Signed-off-by: Petr Pudlak <>
Signed-off-by: Klaus Aehlig <>
Reviewed-by: Klaus Aehlig <>

bb133242 10/31/2013 12:46 pm Klaus Aehlig

Merge branch 'stable-2.10' into master

  • stable-2.10
    Remove FIXME + update man pages wrt iallocator
    Don't check for master netdev when using OVS
    Fix TypeError in backend/ConfigureOVS
    Create Open vSwitch on Master during Cluster init
    SimpleRetry on BlockDev.Remove()...
24711492 10/31/2013 11:28 am Dimitris Aragiorgis

Check if hotplug is supported in CheckPrereq

Introduce new RPC hotplug_supported that invokes the corresponding
hypervisor's method which checks if hotplug is generally
supported. Call this RPC early in CheckPrereq() and abort if
hotplug is not supported. Currently only KVM hypervisor with...

25ea5b98 10/30/2013 11:35 am Sebastian Gebhard

Create Open vSwitch on Master during Cluster init

Currently, Open vSwitch is only created on additional nodes, not on the master
itself.
This fixes the issue and creates and configures an Open vSwitch on the master
node during cluster init.

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

88acff3f 10/29/2013 03:56 pm Thomas Thrainer

Add possibility to compress to OpInstanceCreate

OpInstanceCreate now supports the 'compress' option. It allows to enable
compression during instance imports.

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

258de3fe 10/29/2013 03:56 pm Thomas Thrainer

Honor compress parameter in remote backups

Use the specified compression mode not only for local exports, but also
for remote ones.

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

51d7ac96 10/29/2013 03:56 pm Thomas Thrainer

Support import with compressed instance moves

Support compressing instance data while sending it to the target node on
instance imports.

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

896cc964 10/29/2013 03:56 pm Thomas Thrainer

Add local compression to OpBackupExport

OpBackupExport is extended by a compress parameter. This parameter
(either 'none' or 'gzip') controls if instance disks are compressed
before being sent over the network to the destination node.

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

f198cf91 10/29/2013 03:56 pm Thomas Thrainer

Add possibility to compress to OpInstanceMove

OpInstanceMove now supports the 'compress' option. It allows to enable
compression for intra-cluster instance moves.

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

063613aa 10/29/2013 03:56 pm Thomas Thrainer

Use import-export daemon for intra-cluster moves

This unifies the inter- and intra-cluster moves and the backup code, so
less code needs to be maintained.

Also fix failing tests for LUInstanceMove by following the code changes
in the tests.

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

d29f52a6 10/29/2013 03:56 pm Thomas Thrainer

Use cluster variable consistently

The cluster object is already retrieved from the configuration, so use
it consistently in LUInstanceMove.CheckPrereq().

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

83266db6 10/29/2013 03:56 pm Thomas Thrainer

Correct comments

Correct comments which confuse the target node with the secondary node
of an instance in LUInstanceMove.

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

9c8f7bf4 10/28/2013 12:07 pm Helga Velroyen

Fix usage of xm/xl for gnt-instance modify --new-primary

This fixes issue 519. When calling 'gnt-instance modify
--new-primary', an exception was raised, because a
RPC call was not called with the right hypervisor
parameters which caused the backend function to crash,...

e15a00dc 10/24/2013 12:27 pm Dimitris Aragiorgis

Minor changes regarding hotplug support

  • Mention restrictions in NEWS
    - RBD userspace access mode
    - In case of a downgrade instances should suffer a reboot to be migrateable
  • Bypass interactive verification in NIC modifications via --force option
    - Mention it in man page...
51951d38 10/24/2013 12:27 pm Dimitris Aragiorgis

Fix in RPC

Use _SingleDiskDictDP() instead of _ObjectDict() for serializing
a disk.

Signed-off-by: Dimitris Aragiorgis <>
Signed-off-by: Thomas Thrainer <>
Reviewed-by: Thomas Thrainer <>

ba924970 10/24/2013 12:27 pm Dimitris Aragiorgis

Hotplug: cmdlib support

Hotplugging is done by functions invoked by ApplyContainerMods(). In
order hotplugging to take place the --hotplug option must be passed
otherwise the modifications will take place after reboot.

NIC hotplug supports add, remove and modify. The modify is done by removing...

70b634e6 10/15/2013 02:54 pm Thomas Thrainer

Add unit tests for LUBackupExport

This patch adds unit tests for LUBackupExport.

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

fb2278aa 10/15/2013 02:53 pm Thomas Thrainer

Use node names in LUBackupQuery

The result of LUBackupQuery has to be indexed by node name rather than
by node UUID, otherwise the automatically constructed filter won't
return any results.

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

4f90370c 10/15/2013 02:13 pm Helga Velroyen

Make 'gnt-node list-storage' use default storage type

Currently, when no explicit storage type is given, the
'gnt-node list-storage' command defaults to file storage
whether or not file storage is enabled on the cluster
or not. This patch fixes it by defaulting to the default...

8b95dfdc 10/15/2013 02:13 pm Helga Velroyen

Make 'gnt-cluster modify' respect the order of templates

This fixes a bug where the order of enabled disk templates
was not respected when manipulating it with 'gnt-cluster
modify'.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Klaus Aehlig <>

6c00b2c7 10/15/2013 02:13 pm Helga Velroyen

Streamlining handling of spindles and default templates

This rather lenghy patch comprises a couple of refactorings
to achieve the following goals:
- 'gnt-node info' should only report space information about
spindles, when exclusive storage is enabled on the node...

5808df30 10/11/2013 05:32 pm Helga Velroyen

Fix typos and indentation for cluster.py

This patches fixes a typo and some indentation errors
that were accidentally introduced by premature pushing
of the patch series "Improvements on disk templates, in
particular file storage".

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

6e513917 10/11/2013 02:13 pm Helga Velroyen

Make GetDiskTemplateSets output disabled disk templates

This patch extends the 'GetDiskTemplateSets' function to
also output the list of disk templates that were enabled
before this operation, but will be disabled afterwards.
This patch also includes code to check for instances using...

87e23f2d 10/11/2013 02:13 pm Helga Velroyen

Rename GetEnabledDiskTemplates to include disabled ones

This patch solely renames the functions
_GetEnabledDiskTemplates* to _GetDiskTemplateSets, because
in later patches, we will refactor it to not only output
disk templates that are or get enabled, but also the ones...

c2e984e2 10/11/2013 02:13 pm Helga Velroyen

Check for running instances when disabling templates

This patch introduces a function to be used in
'gnt-cluster modify' when disabling a couple of disk
templates. It checks whether there are still instances
running that use these templates.

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

e8c86ab1 10/09/2013 07:39 pm Klaus Aehlig

Merge branch 'stable-2.9' into master

  • stable-2.9
    Version bump for 2.9.0 rc2
    Update NEWS for 2.9.0 rc2
    Downgrade 'vif_script'
    Downgrade 'xen_cmd'
    Add test cluster config for version 2.9
    Remove superfluous import of 'errors'
    Start NEWS entry for 2.9.0 rc2...
d48c944b 10/09/2013 01:40 pm Helga Velroyen

Use 'DTS_LVM' when possible

This patch replaces all usages of the utility function
'GetLvmDiskTemplate' by the new 'DTS_LVM' constant
to make it consistant with the usage of other DTS_*
constants.

Additionally, it provides a unit tests to ensure
consistancy between DTS_LVM and the mapping of disk...

66a37e7a 10/07/2013 04:58 pm Helga Velroyen

Rename LDS_DRBD to DTS_DRBD

This patch renames the constant 'LDS_DRBD' to 'DTS_DRBD'
to make it consistent with the renaming of LD_* constants
to DT_* constants.

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

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

b1808f46 09/27/2013 09:45 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 <>...

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

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

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

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

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

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

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

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

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

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

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