Statistics
| Branch: | Tag: | Revision:

root / lib @ 08896026

# Date Author Comment
08896026 06/19/2009 04:24 pm Iustin Pop

LUCreateInstance: the node list as return value

Currently LUCreateInstance has no result; this patch changes it so that
both the normal result and the dry-run result is the node list of the
selected instance.

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

64c65a2a 06/19/2009 04:24 pm Iustin Pop

Implement dry-run mode at cli level (partially)

This patch adds support for the dry-run mode for all command line
operations, and also makes use of this for commands using the
SubmitOrSend function. For the ones not using it, the flag has no
effect (future patches)....

20777413 06/19/2009 04:24 pm Iustin Pop

LU execution: implement dry-run framework

This patch adds a new (global) opcode flag 'dry_run' which, when True,
causes early exit from the LU workflow, returning a special value from
the LU object (initialized in the parent LogicalUnit class, and which if...

4f05fd3b 06/19/2009 04:23 pm Iustin Pop

Introduce slots deriving in opcodes.py

This simple patch adds to all opcodes extension of the base opcode
slots. This way we can add slots across all opcodes, for example
'dry-run'.

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

f2fd87d7 06/19/2009 02:14 pm Iustin Pop

Fix some small epydoc warnings

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

29921401 06/18/2009 01:49 pm Iustin Pop

Fix various pylint warnings

There were multiple issues:
- copy-paste resulted in wrong indentation
- wrong function name
- missing spaces around assignment
- overriding built-in names (type, dir) or already defines ones
(errors, hypervisor)

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

495cfdf0 06/17/2009 04:22 pm Guido Trotter

RAPI: move to nic parameters

In query we ask for nic.links, rather than nic.bridges
In create we accept both "link" and "bridge" and let the opcode deal
with it. Note that we still can create only one nic per instance.

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

5e3d3eb3 06/17/2009 04:21 pm Guido Trotter

Update a forgot docstring for nic parameters

Properly document the expected nic format.

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

0b13832c 06/17/2009 04:21 pm Guido Trotter

Fix QueryInstanceData for nic parameters

This CL updates QueryInstanceData to return NICs in the new format (mac,
ip, mode, link) and fixes gnt-instance info to properly display them.

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

638c6349 06/17/2009 04:21 pm Guido Trotter

Update instance query for NIC parameters

Compatibility with the old parameters is maintained, by allowing to
query for "bridge" "nic.bridges" and "nic.bridge/N", but None is
returned in that case for routed nics.

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

f9b10246 06/17/2009 04:21 pm Guido Trotter

Rename _PreBuildNICHooksList to _NICListToTuple

We're going to use this helper function for more than just hooks, so
we'll give it a more generic name.

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

2b1ac224 06/16/2009 06:25 pm Guido Trotter

Merge branch 'next' into branch-2.1

  • next:
    gnt-cluster(8) fix --backend-parameters opt name
    LUQueryInstances: fix querying for nic data
    Specify the object type in two docstring
39a02558 06/16/2009 06:03 pm Guido Trotter

LUQueryInstances: fix querying for nic data

Currently we support querying for "mac" "ip" or "bridge", meaning "the
one of the first nic. We are not checking that there is a first nic,
though, and thus could incur in errors. This patch fixes it by returning...

a2a24f4c 06/16/2009 06:02 pm Guido Trotter

Specify the object type in two docstring

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

7b381438 06/16/2009 03:35 pm Guido Trotter

KVMHypervisor, fix a bug in MigrateInstance

This was introduced as a typo in commit
7e66c35b5685525538dd65dd3dff75b5346d30d7 while removing duplicate code
from the KVM hypervisor.

Signed-off-by: Guido Trotter <>

541741d3 06/16/2009 03:27 pm Guido Trotter

Fix backend.{Start,Stop}Master

Commit c26a6bd21c17641f718369caed88ae16947fa774 changed GetMasterInfo
not to return a tuple anymore, but didn't update its two callers in
backend.py, which were trying to extract the values from the second
tuple element. This causes a stack trace in node-daemon.log....

af0413bb 06/16/2009 02:28 pm Guido Trotter

Merge branch 'next' into branch-2.1

  • next: (22 commits)
    Update NEWS and version for 2.0.1 release
    gnt-{instance,backup}(8) --nic is actually --net
    Fix a wrong function name in backend.DrbdAttachNet
    GNT-CLUSTER fix search-tags example
    Enable stripped LVs...
c57f169e 06/16/2009 02:25 pm Guido Trotter

Merge branch 'master' into next

  • master:
    Update NEWS and version for 2.0.1 release
    gnt-{instance,backup}(8) --nic is actually --net
    Fix a wrong function name in backend.DrbdAttachNet
    GNT-CLUSTER fix search-tags example
6f7d4e75 06/15/2009 08:13 pm Iustin Pop

Small whitespace change

Some indentation was wrong, and pylint rightfully complained.

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

4c4e4e1e 06/15/2009 08:13 pm Iustin Pop

Simplify RPC call result check in cmdlib.py

Now that all results are the same, we can even more simplify the
handling in cmdlib more. Almost all if result.RemoteFailMsg()…
constructs are similar, and we resurect the RpcResult.Raise() function
to take a message argument, which it will process and raise an...

c26a6bd2 06/15/2009 08:08 pm Iustin Pop

Simplify the RPC result framework in backend.py

Since now all functions fail via _Fail, the return True, … is redundant
as all normal return paths have it, and thus the True value can be added
in the ganeti-noded handler.

This means that all functions can now forget about the special result...

afdc3985 06/15/2009 08:08 pm Iustin Pop

Convert all backend function to exception

Instead of returning (False, msg) from rpc endpoints, we raise always
exceptions (the non-endpoint, internal functions can remain as is). This
means that the error paths are agnostic to how the failure is signalled...

5a533f8a 06/15/2009 08:08 pm Iustin Pop

Simplify usage of backend._FindDisks

Since all users of _FindDisks now return new-style results, we can
simply make it raise an exception and not deal with the status field.

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

d3c8b360 06/15/2009 08:08 pm Iustin Pop

Pre-compute error status in RpcResult

Since now all RPCs have the new style result type, we can pre-compute
the error message at RpcResult() init time and not wait until it's
requested.

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

8e70b181 06/15/2009 08:08 pm Iustin Pop

Remove old invalid-os related functionality

We no longer need OS objects to be able to represent invalid OSes. This
cleans up the code handling those cases.

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

255dcebd 06/15/2009 08:08 pm Iustin Pop

Big rewrite of the OS-related functions

Currently the OSes have a special, customized error handling: the OS
object can represent either a valid OS, or an invalid OS. The associated
function, instead of raising other exception or failing, create custom
OS objects representing failed OSes....

c8457ce7 06/15/2009 08:08 pm Iustin Pop

Convert the jobqueue rpc to new style result

This patch converts the job queue rpc calls to the new style result.
It's done in a single patch as there are helper function (in both jqueue
and backend) that are used by multiple rpcs and need synchronized
change....

b2b8bcce 06/15/2009 08:08 pm Iustin Pop

Convert the file storage rpcs to new style result

This patch converts all three file-storage rpc (create, delete, rename)
to new style result. This is done in a single patch as they all use a
helper function which itself needs to/can be converted.

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

38ea42a1 06/15/2009 08:08 pm Iustin Pop

Convert test_delay rpc to new style result

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

87f5c298 06/15/2009 08:08 pm Iustin Pop

Convert iallocator_runner rpc to new result style

This patch converts this rpc into the new style. Since the function
already had some error handling, we remove this custom error reporting
and replace it with our (new-style) result type. This allows significant...

3fb4f740 06/15/2009 08:08 pm Iustin Pop

Convert hooks_runner rpc to new style result

This also converts (and fixes) unittests and mock objects to deal with
this change, and the custom hook verifier in cmdlib.LUClusterVerify.

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

83d92ad8 06/15/2009 08:08 pm Iustin Pop

Convert os_diagnose rpc to new style result

This also removes custom post-processing from rpc.py; since this call
has only one user, it was simple to move it back to the caller.

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

90b54c26 06/15/2009 08:08 pm Iustin Pop

Convert call_version rpc to new style result

This also cleans up its single use in cmdlib.py.

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

e1e75d00 06/15/2009 08:08 pm Iustin Pop

Convert write_ssconf_files to new style

The patch also adds logging of errors from the ConfigWriter in case the
RPC fails (although today we don't have failure modes).

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

2a52a064 06/15/2009 08:08 pm Iustin Pop

Convert master_info rpc to new style result

This was more tricky as the backend function is used by other function
in backend.py. As such, it must be handled specially - it must raise
always an exception and not simply return False, err.

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

10bfe6cb 06/15/2009 08:08 pm Iustin Pop

Convert node_volumes rpc to new style result

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

0623d351 06/15/2009 08:08 pm Iustin Pop

Conver node_leave_cluster rpc to new style result

This patch converts this rpc call to the new style result, and also
changes in the process the meaning of the QuitGanetiException's
arguments and the node daemon rpc call exception handler.

The problem with the exception handler is that we used a two-stage one,...

6c00d19a 06/15/2009 08:08 pm Iustin Pop

Convert node_stop_master rpc to new style result

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

b726aff0 06/15/2009 08:08 pm Iustin Pop

Convert node_start_master to new style result

This is used in multiple places outside cmdlib.py, so it's a more
interesting patch.

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

6f68a739 06/15/2009 08:08 pm Iustin Pop

Convert node_verify rpc to new result style

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

31e22135 06/15/2009 08:08 pm Iustin Pop

Remove utils.CheckDict since it's no longer used

Only the custom handling in rpc.py for call_node_info used this, so now
it can be removed.

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

070e998b 06/15/2009 08:08 pm Iustin Pop

Convert node_info rpc to new style result

This patch also does some cleanup and enforces valid results (with
proper type, i.e. int for memory/disk values) from remote node,
otherwise we handle the result as failure.

We do this so that we can remove custom processing in rpc.py which is...

c2fc8250 06/15/2009 08:08 pm Iustin Pop

Convert node_has_ip_address rpc to new style

This should actually have a function in backend, but it's fine for now.

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

aca13712 06/15/2009 08:08 pm Iustin Pop

Convert instance_list rpc to new style result

Since backend.GetInstanceList() is used both as RPC endpoint and as
internal function, it can't return (status, value). Instead it returns
only valid instance info, and failures are denoted by exceptions; and...

2fa74ef4 06/15/2009 08:08 pm Iustin Pop

Convert all_instances_info rpc to new result style

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

7ad1af4a 06/15/2009 08:08 pm Iustin Pop

Convert instance_info rpc to new style result

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

944bf548 06/15/2009 08:08 pm Iustin Pop

Convert instance_os_import rpc to new style result

This changes from a list of booleans to «status, error messages». This
means that instead knowing which disk has failed (position based), we
get a list of all failures (with details how they failed).

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

35c0c8da 06/15/2009 08:08 pm Iustin Pop

Convert bridges_exist to new style result

This was a very simple (boolean) RPC, so converting it to actually have
more value with the new style results was more difficult.

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

e480923b 06/15/2009 07:37 pm Iustin Pop

Convert vg_list rpc to new style result

This doesn't have known failure modes but converting will help later.

We also now call directly utils.ListVolumeGroups() instead of the
backend.ListVolumeGroups() so that we don't have to undo the (status,
value) result type....

29d376ec 06/15/2009 07:37 pm Iustin Pop

Convert volume_list rpc to new style result

This is a big change, because we need to cleanup its users too.

The call and thus LUVerifyDisks LU used to differentiate between failure
at node level and failure at LV level, by returning different types in
the RPC result. This is way too complicated for our needs....

35fbcd11 06/15/2009 07:37 pm Iustin Pop

Convert export_remove rpc to new style

This converts the export_remove rpc to new style result and also fixes
and old TODO by adding exception handling (and conversion to failure).

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

1b7bfbb7 06/15/2009 07:37 pm Iustin Pop

Convert export_list rpc to new style result

This is used in multiple places, so it has a little more changes than
the previous ones.

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

3eccac06 06/15/2009 07:37 pm Iustin Pop

Convert export_info rpc to new style result

This also removes some code from ganeti-noded and rpc.py, which should
not do such processing of data (and be simply glue code). (Or
alternatively they could, if we had better infrastructure).

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

9b201a0d 06/15/2009 07:37 pm Iustin Pop

Convert finalize_export rpc to new style results

This rpc doesn't have explicit failure modes, but once all RPCs are
converted and we can catch and convert expceptions to failure in noded,
we will have meaningfull error messages.

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

ba55d062 06/15/2009 07:37 pm Iustin Pop

Convert snapshot_export rpc to new style

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

87812fd3 06/15/2009 07:37 pm Iustin Pop

Convert blockdev_snapshot rpc to new result style

This also slightly changes the code in cmdlib that uses it for more
clarity.

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

3efa9051 06/15/2009 07:36 pm Iustin Pop

Convert blockdev_getmirrorstatus rpc to new style

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

c738375b 06/15/2009 02:10 pm Iustin Pop

Fix a wrong function name in backend.DrbdAttachNet

Commit cf8df3f30c2dcd0ab398d835fa9f64d61578a4f7 "bdev: forward-port
ReAttachNet/DisconnectNet" forward-ported 1.2's bdev.DRBD8.ReAttachNet()
to 2.0 while renaming it to AttachNet(), but commit
6b93ec9d798ed53089a06bc0ced58ef1d8a9e4b0 "Forward-port DrbdNetReconfig"...

a9fe7e8f 06/15/2009 01:54 pm Guido Trotter

Iallocator: NIC parameters

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

503b97a9 06/15/2009 01:54 pm Guido Trotter

Xen: NIC parameters

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

bef9c750 06/15/2009 01:54 pm Guido Trotter

KVM: NIC parameters

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

1ba9227f 06/15/2009 01:52 pm Guido Trotter

OSEnvironment: convert to NIC parameters

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

b848ce79 06/15/2009 01:52 pm Guido Trotter

rpc: fill in NIC parameters in instances

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

9b31ca85 06/15/2009 01:52 pm Guido Trotter

Remove bridge and default_bridge from objects

These values are deprecated, and not used in 2.1 anymore.
The slots are still there to allow auto-upgrading from 2.0.

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

62f0dd02 06/15/2009 01:52 pm Guido Trotter

NIC Parameters: fix hooks environment generation

In order to do that we change the way nics are espected to be passed to
the _BuildInstanceHookEnv function, from (ip, bridge, mac) to (ip, mac,
mode, link).

To translate new nics, which have the ip, mac and nicparams fields to...

8fcc0cb1 06/15/2009 01:52 pm Guido Trotter

Remove config.GetDefBridge

Default bridge is now handled with nic parameters, and this function is
unused.

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

9ebe9556 06/15/2009 01:52 pm Guido Trotter

QueryClusterInfo: don't show default_bridge

Since default_bridge is deprecated, avoid displaying it when querying
for cluster information.

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

ec0652ad 06/15/2009 01:52 pm Guido Trotter

InitCluster: don't set default_bridge

And remove the -b option, as default nic parameters can be used instead.
We could support the option, but that would add more code, and since
cluster init is not a frequent operation, it's better to keep the code
clean....

b165e77e 06/15/2009 01:52 pm Guido Trotter

_CheckInstanceBridgesExist: move to NIC parameters

Rather than checking all bridges, we check all links for bridged nics,
if any. Since this function is now slightly more complex than before,
it's been split into an auxiliary function, and more parameters are...

cd098c41 06/15/2009 01:51 pm Guido Trotter

LUSetInstanceParams: nic parameters

Hooks are dealt with in a later patch in the series.

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

0329617a 06/12/2009 10:43 am Guido Trotter

LUSetInstanceParams: abstract _GetUpdatedParams

There is some duplicated code between hv and be parameters to create the
updated parameters dict. This will need to be done also for nic
parameters, so we abstract this functionality in a function.

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

2ee88aeb 06/12/2009 10:43 am Guido Trotter

LUSetInstanceParams: save cluster

Rather than querying for the cluster multiple times, save it.

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

9dce4771 06/12/2009 10:42 am Guido Trotter

LUCreateInstance: NIC parameters

Instance creation is changed to support the new nic parameters.

Hooks are dealt with in a later patch in the series.

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

13f1af63 06/12/2009 10:41 am Guido Trotter

Add nicparams to the NIC object

Also populate nicparams with a sensible default for imported instances.
Unfortunately we don't know if the bridge set up in old nics is the
default one or not, and we don't have access to the config cluster
object here to verify, so we'll just copy it without questions....

dd7db360 06/10/2009 03:46 pm Iustin Pop

Fix ConfigWriter._DistributeConfig error handling

Commit 1b54fc6c2fd92b614c029cc5312d02f9f1526253 added a typo (due to
copy-paste) in the error handling path of this function.

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

035566e3 06/10/2009 12:57 pm Iustin Pop

Fix node add and RedistributeAncillaryFiles

Commit 28eddce5249f35c2c330a04da07b74950877dcf5 added the
RedistributeAncillaryFiles, but it calls it with a wrong parameter and thus
makes node add fail.

This one-liner fixes it.

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

2cc6781a 06/09/2009 12:07 pm Iustin Pop

rpc: Add a simple failure reporting framework

This patch adds a simple failure reporting tool, similar to bdev's
_ThrowError. In backend, we move towards the new-style RPC results (of
type (status, payload)) and thus functions which use this style can very...

1094acda 06/08/2009 07:58 pm Guido Trotter

Show nic parameters in cluster info

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

5af3da74 06/08/2009 07:58 pm Guido Trotter

Allow modifying of default nic parameters

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

b6a30b0d 06/08/2009 07:58 pm Guido Trotter

Allow setting NIC parameters at gnt-cluster init

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

c8fcde47 06/08/2009 07:58 pm Guido Trotter

Cluster: add nicparams, and update them on upgrade

This also migrates the default bridge from the cluster object to the nic
params, at load time. Since we don't support changing the default bridge
after cluster init, this is ok for now. In the future we'll make...

255e19d4 06/08/2009 07:58 pm Guido Trotter

Add NIC.CheckParameterSyntax

This function will be used to check the NIC parameters for validity.
Unittests are included.

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

ac061be9 06/08/2009 07:58 pm Guido Trotter

nic parameters: constants

Introducing the constants used for implementing nic parameters in
Ganeti, according to the 2.1 design.

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

6e34b628 06/08/2009 07:58 pm Guido Trotter

Abstract Param upgrade from cluster.UpgradeConfig

A new UpgradeGroupedParams is used to upgrade all the profiles for one
parameter filling in the default values, or creating the whole dict
anew, should it be missing. This is used only for beparams, currently,...

4ef7f423 06/08/2009 07:58 pm Guido Trotter

Change BEGR_DEFAULT to PP_DEFAULT

This way the same constant can represent the default profile also for
nic, disk and OS parameters.

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

abe609b2 06/08/2009 07:58 pm Guido Trotter

Move FillDict at module level

This way it can be also used by scripts and other object types.

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

022c3a0b 06/08/2009 07:58 pm Guido Trotter

Fix a typo in InitCluster

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

9205a895 06/08/2009 07:44 pm Iustin Pop

Convert call_blockdev_removechildren to new result

This patch converts blockdev_removechildren to new result type and
slightly changes a message in addchildren to match this (paired)
function.

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

2cc1da8b 06/08/2009 07:44 pm Iustin Pop

Convert call_blockdev_addchildren to new result

This patch converts the blockdev_addchildren rpc call to the new result
format.

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

6b5e3f70 06/08/2009 07:43 pm Iustin Pop

Convert rpc call_blockdev_rename to (status, data)

This small patch converts the call_blockdev_rename to the new result
type.

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

fecbe9d5 06/08/2009 06:00 pm Iustin Pop

Enable stripped LVs

This patch enables stripped LVs, falling back to non-stripped if the
stripped creation fails. If the configure-time lvm-stripecount is 1,
this patch becomes a noop (with an insignificant python-level overhead,
but no extra lvm calls)....

3736cb6b 06/08/2009 06:00 pm Iustin Pop

Add a lvm stripecount configure parameter

This patch adds a configure-time customizable parameter that will be
used to enable stripped LVs. The default of the parameter is 3.

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

3c003d9d 06/08/2009 06:00 pm Iustin Pop

Add more constants for DRBD and change sync tests

This patch adds constants for the connection status, peer roles and disk
status, and it changes the rules for when the disk is considered as
“resyncing” - previously it was only for syncsource/synctarget, but...

5ce92cd3 06/08/2009 12:53 pm Iustin Pop

Merge branch 'master' into next

  • master:
    Wait for a while in failed resyncs
    Fix two issues with exports and snapshot errors
fbafd7a8 06/04/2009 01:06 pm Iustin Pop

Wait for a while in failed resyncs

This patch is an attempt at fixing some very rare occurrences of messages like:
- "There are some degraded disks for this instance", or:
- "Cannot resync disks on node node3.example.com: [True, 100]"

What I believe happens is that drbd has finished syncing, but not all...

f069addf 06/03/2009 07:09 pm Iustin Pop

Assemble DRBD using the known size

This patch changes DRBD disk attachment to force the wanted size, as opposed to
letting the device auto-discover its size.

This should make the disks more resilient with regard to small differences in
size (e.g. due to LVM rounding). This still works with regard to disk...

a97da6b7 06/03/2009 03:17 pm Iustin Pop

Fix two issues with exports and snapshot errors

This patch fixes two issues related to failed snapshots during exports:
- first, the error messages used disk.logical_id1, which is a node
name for DRBD, and it resulted in strange error messages like...

8a6c7011 05/28/2009 08:55 pm Iustin Pop

Set the size on new DRBDs in replace secondary

Currently the code in cmdlib doesn't set the device size to new DRBD
devices in replace secondary, but we need to do it otherwise it gets
initialized to None.

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

464f8daf 05/28/2009 05:05 pm Iustin Pop

Change the bdev init signatures

This patch changes all the bdev.BlockDev constructors to take an
additional ‘size’ parameter, all the backend functions that call those
functions to pass it and also changes backend.BlocdevCreate() to not use
the size passed via the rpc call but instead directly disk.size (this is...

c1b42c18 05/28/2009 03:18 pm Guido Trotter

Upgrade be/hv params with default values

From time to time we're adding new be or hv parameters. With this patch
missing parameters get set to the default value when loading the cluster
object. This patch version also considers the case when hv/be params...