Statistics
| Branch: | Tag: | Revision:

root / lib / cmdlib @ 88acff3f

# Date Author Comment
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 <>

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

bbe0f264 08/13/2013 03:33 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 <>...

9fdb10be 08/13/2013 12:02 pm Thomas Thrainer

Extend unit tests for LUClusterVerifyGroup

- Add tests for additional Verify* methods
- Converted test for VerifyFiles to the new test framework
- Added possibility to prepare the LU in a test class before actually
executing the test method with it

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

18397489 08/13/2013 11:59 am Thomas Thrainer

Revert "Display node name instead of UUID in error message"

This reverts commit fbff213691328562cc4029f3babaa2e72e2012c4.
When running hooks, the node name is used to identify nodes, not (as
wrongly assumed in the patch) the node UUID.

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

fbff2136 08/13/2013 08:54 am Thomas Thrainer

Display node name instead of UUID in error message

The hooks callback in LUClusterGroupVerify misinterpreted the key in the
node result as name instead of node UUID. This patch fixes this, which
leads to more user friendly error messages.

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

c214896c 08/12/2013 04:06 pm Thomas Thrainer

Use node name in error message

CheckNodeNotDrained displayed only the node UUID if the node is drained.
In order to provide a more helpful error message, use the node name
instead.

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

c89eb67d 08/08/2013 06:48 pm Helga Velroyen

ClusterSetParams: move vg-name checks from to CheckPrereq

This fixes a bug in the logic of 'gnt-cluster modify'.
Some checks that should better be done in 'CheckPrereq'
were actually done in 'Exec'. This lead to a strange
behavior in case the execution failed, because an...

702243ec 08/08/2013 06:48 pm Helga Velroyen

gnt-group add/modify: ipolicy vs disk templates

This patch adds a consistency check between the ipolicy's
list of allowed disk templates with the cluster-wide
enable disk templates when a new node group is added
or a group is modified.

It also fixes a bug in gnt-group where the list of allowed...

4e771a95 08/08/2013 06:48 pm Helga Velroyen

Move Ipolicy utility function to cmdlib/common.py

Since the check of consistency between an ipolicy and
the list of enabled disk templates will not only be
needed on cluster modification, but also on group
modification, we move the respective function and its...

33a6464e 08/08/2013 06:48 pm Helga Velroyen

gnt-cluster modify: ipolicy vs enabled disk templates

This patch adds a check to LUClusterSetParams which
ensures that the list of allowed disk templates is a
subset of the list of cluster-wide enabled disk
templates. Unit tests are included.

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

1532b078 08/08/2013 06:48 pm Helga Velroyen

gnt-cluster modify: factor out ipolicy check

This refactors the LUClusterSetParams to do all ipolicy
sanity / validity checks in a separate function
in order to increase testability. No function changes
otherwise.

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

5cbf7832 08/08/2013 10:31 am Jose A. Lopes

Fix opcodes and parameters

  • fix some return types in opcodes and some types and documentation in
    parameters.
  • fix serialization of the default value of the 'name' parameter in
    the opcodes related to tags when tag kind is 'cluster'
  • revert changes to 'pShutdownTimeout'' and its references because the...
a794b8d7 08/07/2013 06:52 pm Thomas Thrainer

Add unit test for LUClusterSetParams

Some changes to the test framework were performed while writing this
test:
- Extended builder for disks
- Introduced builder for NICs
- Fixed bugs in RpcResultsBuilder

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

6bb43023 08/07/2013 06:52 pm Thomas Thrainer

Use ConfigWriter.GetMasterNodeInfo() consistently

This shortcut method to get the node object of the master node directly
makes the code more readable and concise. Therefore, use it everywhere
where appropriate.

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

e969a81f 08/07/2013 06:48 pm Thomas Thrainer

Add unit test for LUTestAllocator

Additionally to adding unit tests for LUTestAllocator, the test
framework was adapted for its requirements.

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

ef725c86 08/07/2013 06:48 pm Thomas Thrainer

Remove unneeded checks

Those checks are already covered by the "types" in the opcodes, so
remove them.

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

3efa7659 08/07/2013 06:48 pm Thomas Thrainer

Initial version of cmdlib test framework

The initial version of the cmdlib test framework is able to execute LU's
with the following components mocked:

  • Configuration
  • IAllocator interface
  • Lock manager
  • MCPU processor
  • RPC runner

A base test class is provided which makes it easy to execute opcodes and...

1ca326c8 08/07/2013 06:46 pm Thomas Thrainer

Merge branch 'stable-2.9'

  • stable-2.9
    Fix batch creation of instances
    Fix documentation of gnt-instance batch-create
    Support multi instance allocs without iallocator
    Support DSA SSH keys in bootstrap
    Include VCS version in `gnt-cluster version`...
804d72eb 08/07/2013 05:41 pm Thomas Thrainer

Merge branch 'stable-2.8' into stable-2.9

  • stable-2.8
    Fix batch creation of instances
    Fix documentation of gnt-instance batch-create
    Support multi instance allocs without iallocator
    Support DSA SSH keys in bootstrap
    Include VCS version in `gnt-cluster version`...
0c072225 08/07/2013 02:29 pm Thomas Thrainer

Merge branch 'stable-2.7' into stable-2.8

  • stable-2.7
    Fix documentation of gnt-instance batch-create
    Support multi instance allocs without iallocator
    Document --no-conflicts-check for gnt-network
    Check disk template in right dict when copying
    ganeti.backend_unittest: chmod restricted cmd dir...
34af39e8 08/07/2013 10:41 am Jose A. Lopes

Add Python opcode generation

  • add Python opcode generation to Template Haskell
  • fix all the opcodes and parameters, including their types and
    documentation
  • update Luxi to reflect the other changes.

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

884dc063 08/07/2013 10:41 am Jose A. Lopes

Move constants to the appropriate module

Move constants ALLOCATABLE_KEY and FAILED_KEY to the constants module.

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

72cd5493 08/07/2013 10:41 am Jose A. Lopes

Add predicates to test Python types in opcodes

Add helper functions to test Python types, which are used by opcode
parameters and return values.

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

026f444f 08/06/2013 04:32 pm Thomas Thrainer

Include VCS version in `gnt-cluster version`

Also print the VCS version in the output of `gnt-cluster version`. This
makes the VCS version also available over RAPI, etc.

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

24e96ef6 08/05/2013 11:06 am Thomas Thrainer

Fix formatting of instance names in config verify

Instance object were incorrectly treated as instance UUID's which caused
an exception to be raised. Using the names of the instance objects
directly fixes this problem.

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

d3ff2741 08/02/2013 02:01 pm Thomas Thrainer

Fix verify config if a node has no instances

Do not try to provide a fake instance UUID called "no instances", as
trying to get the name for would fail and raise an exception.

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

a5b9e2f2 08/01/2013 06:30 pm Thomas Thrainer

Check for luxid permission during verify config

confd no longer needs access to the noded certificate file, but luxid
does. Change the check to use the right user.

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

f06af3ca 08/01/2013 09:16 am Thomas Thrainer

Check disk template in right dict when copying

Due to the structure of the code this condition can't possibly be true.
We have to look in the new_diskparams dict instead, otherwise it'd be
possible to try to update a non-existing entry.

(The same patch is in stable-2.7 as 106441d already)....

aa7a5c90 07/30/2013 04:12 pm Michele Tartara

Add cleanup parameter to instance failover

Most of the code is shared with instance migrate, so we actually only need
to add the parameter and pass its value along the the common code.

Also, tests and harep are updated to support the right set of options to...

4b322a76 07/29/2013 03:27 pm Helga Velroyen

gnt-cluster verify: consider shared file storage

This patch enhances 'gnt-cluster verify' in a way that it
now validates the acceptance and existance of the shared
storage directory.

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

4e6cfd11 07/29/2013 03:27 pm Helga Velroyen

gnt-cluster modify --shared-file-storage-dir

This patch introduces to 'gnt-cluster modify' the option
'--shared-file-storage-dir' to change the default directory
for instances using shared file storage at cluster runtime.

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

e8b5640e 07/29/2013 03:27 pm Helga Velroyen

Bootstrap: factor out and prepare shared-file-storage

This patch makes 'gnt-cluster init' use the
'--shared-file-storage-dir' option to set the default
shared file storage dir. Additionally, it performs the
same sanity and validity checks for the path as for...

21c2612d 07/25/2013 05:28 pm Guido Trotter

Merge branch 'stable-2.9'

  • stable-2.9:
    Update NEWS and version for Ganeti 2.7.1
    Add hvparam to disable VNET_HDR on tap devices
    daemon-util: pass --oknodo at rotate_logs
    Fix another missing renaming
    Add logrotate example
    daemon-util: provide rotate_logs and rotate_all_logs actions...
d676dbea 07/24/2013 12:55 pm Sebastian Gebhard

Extend gnt-instance show to show vlan parameter

Extensions for "gnt-instance show" to output the vlan parameter which
was introduced by my recent patch series.
This is done by extending the nic object that is used to output the
info. Every other occurrence of this object is adopted as well....

d8e55568 07/23/2013 05:15 pm Helga Velroyen

Rename VALID_STORAGE_TYPES to STORAGE_TYPES

For consistency, this patch renames 'VALID_STORAGE_TYPES'
to 'STORAGE_TYPES', because the set of valid disk
templates is also just names 'DISK_TEMPLATES'.

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

3039e2dc 07/23/2013 03:29 pm Helga Velroyen

gnt-cluster {init, modify} --file-storage-dir

This patch implements consistent usage and behavior of
the --file-storage-dir option in 'gnt-cluster init'
and 'gnt-cluster modify'. It includes a bunch of unit
tests as well.

Additionally, it enables the previously written unit...

738436bf 07/23/2013 09:31 am Thomas Thrainer

Always return tuples in Expand*Name

ExpandNodeName and ExpandInstanceName now always return a tuple. If the
node/instance was not found, (None, None) is returned. This fixes bugs
where callers blindly assign the return value of those methods to
multiple variables without checking if it was None....

5ce6fa9a 07/22/2013 02:33 pm Sebastian Gebhard

Fix KeyErrors with network mode and vlan

This patch fixes some KeyErrors that were introduced by the vlan implementation
and showed up when certain parameters were missing:
gnt-cluster init without network mode
gnt-isntance add without vlan

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

22283069 07/19/2013 04:13 pm Michele Tartara

Merge branch 'stable-2.9' into master

  • stable-2.9
    Fix parsing of drbdsetup show output for DRBD 8.4
    Revert "Disable failing QA test"
    Add unit test for drbdsetup show parsing
    GenerateDiskTemplate: Proper check for valid disk templates
    Fix iallocator unit tests...
9f7d5fe4 07/18/2013 01:52 pm Sebastian Gebhard

Support VLAN parameter during instance creation

If VLAN parameter is present, check its format:
either .<id>[:id], :id[:id...], or just id.

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

bfbffd55 07/17/2013 05:34 pm Helga Velroyen

GenerateDiskTemplate: Proper check for valid disk templates

This patch makes an FileStorageError to be risen with a
proper error message instead of just an assertion in case
the given disk template is not a valid disk template at
all.

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

32449822 07/16/2013 10:55 am Dimitris Aragiorgis

Fix conflicts check in LUNetworkDisconnect

The function _NetworkConflictCheck expects a list of instances as
last argument, not a list of pairs of instance names and instances.

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

c832f7e9 07/16/2013 10:29 am Klaus Aehlig

Merge branch 'stable-2.8' into master

  • stable-2.8
    Change method dispatch in ClientOps to enforce luxi.REQ_ALL
    Allow modify_etc_hosts to be changed
    Add --modify-etc-hosts option for CLI tools
    Add luxiReqQueryNetworks to LuxiOp
    Log received message at debug level...