Statistics
| Branch: | Tag: | Revision:

root @ 0dda8696

# Date Author Comment
0dda8696 01/04/2010 11:17 am Iustin Pop

pylint: disable the similarities checker

This is a very slow checker, estimated to be O(n²) by its author; so
using it all the time is not good. It can be re-enabled on the command
line via “--disable-checker=”.

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

857121ad 01/04/2010 11:16 am Iustin Pop

LUDiagnoseOS._DiagnoseByOS: remove unused arg

The node_list argument to _DiagnoseByOS is not used, and is obsoleted by
the fact that the rlist argument already has the valid nodes as keys
(assuming RPC behaviour didn't change). Thus, we remove it and silence...

f93427cd 01/04/2010 11:16 am Iustin Pop

daemons: handle arguments correctly and uniformly

Of all daemons, only rapi did abort when given argument. None of our
daemons use any arguments, but they accepted them blindly. This is a
very bad experience for the user.

This patch adds checking and exiting in all daemons, in a uniform way....

7ed85ffe 01/04/2010 11:16 am Iustin Pop

hv_xen/_GetConfigFileDiskData: remove unused arg

The disk template is not needed, all that's used is the disk data. As
such, remove this parameter from the function.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

45e0d704 01/04/2010 11:16 am Iustin Pop

jqueue/_CheckRpcResult: log the whole operation

Currently only the rpc call, but not its description (which also shows
the argument) is logged. We change this to log failmsg too, and this
also silences a warning.

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

8929d28c 01/04/2010 11:16 am Iustin Pop

Optparse extenders have to obey a given API

So we just silence the warning.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

c19f9810 01/04/2010 11:16 am Iustin Pop

backend._OSOndiskAPIVersion: remove obsolete arg

The 'name' argument is not used anymore, probably since before 2.0.
Since this is an internal function, we can just remove it (from its
caller too).

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

e11ddf13 01/04/2010 11:16 am Iustin Pop

pylint cleanups: dangerous initializers

Plus a silence for a wrong "uninitialized var".

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

7e950d31 01/04/2010 11:16 am Iustin Pop

Convert to static methods (where appropriate)

Many methods are simple pure functions, and not depending on the object
state. We convert these to staticmethods.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

f4ad2ef0 01/04/2010 11:15 am Iustin Pop

Remove more unused variables

This removes unused variables in the rest of the code (outside lib/).

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

7260cfbe 01/04/2010 11:15 am Iustin Pop

Add targeted pylint disables

This patch should have only:

- pylint disables
- docstring changes
- whitespace changes

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

e7beaa02 01/04/2010 11:15 am Iustin Pop

burnin: move decorators out of classes

Similar to commit c881c5, we move the decorators out of classes, such
that they become simple functions instead of methods. This more clean,
since only the wrapped functions need to be methods/have access to
‘self’....

e2e10467 01/04/2010 11:15 am Iustin Pop

Rename an ConfdInotifyEventHandler init argument

'file' is a builtin keyword/type. Like many others, it should not be
used as a variable/argument name.

No code is actually passing in this argument so renaming it is simple.

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

e0098923 01/04/2010 11:15 am Iustin Pop

Introduce a makefile lint rule

This runs pylint over all the python files. Yes, it takes a long while,
but it's the only way to properly analyze the source codes as only in
this way pylint can see all uses of the various modules/classes/etc.

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

94fed7da 01/04/2010 11:15 am Iustin Pop

Implement all hv functions in hv_chroot/hv_fake

The chroot and fake hypervisors were missing:

- the powercycle node functionality
- proper handling of migration requests

The powercycle was just used as in the other hypervisors (use the
standard linux powercycle). The migration for chroot was disabled...

0a4e7f24 01/04/2010 11:12 am Iustin Pop

Update the _autoconf.py make rule for pylint

This adds targeted pylint disables, but since _autoconf.py is
autogenerated we need to do this in Makefile.am (hence the separate
patch).

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

dfe879ce 01/04/2010 11:12 am Iustin Pop

Disable TODO warnings in pylint

We don't get any useful out of this - a git grep is as effective, and
these only pollute the pylint output.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

bbe4cc16 01/04/2010 11:12 am Iustin Pop

Add some stubs to bdev.FileStorage

This patch adds explicit errors (instead of notimplemented) in
FileStorage (and the associated TODOs).

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

6af8a903 01/04/2010 11:11 am Iustin Pop

Fix indentation issues

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

be0fc05d 01/04/2010 11:11 am Iustin Pop

Fix two bugs in ConfigWriter._EnsureUUID

Wrong argument name and wrong number of arguments in string formatting.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

5905901c 01/04/2010 11:11 am Iustin Pop

KVM: Abstract/rework instance up checks

This patch abstract the check "is instance stopped" into a separate
function, and thus simplifies a couple of higher-level functions. It
also moves from manual read of the pidfile to use the (correct
abstraction of) _InstancePidAlive....

98ec75d6 01/04/2010 11:10 am Iustin Pop

KVM: Split out the pidfile computation

In some cases we only need the pidfile, but not the pid or the alive
status.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

d1b83918 01/04/2010 11:10 am Iustin Pop

Fix an error message

Detected by an 'Unused variable' warning.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

1122eb25 01/04/2010 11:10 am Iustin Pop

Remove many 'Unused variable' warnings

Note there are some cases left which need extra cleanup.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

07b8a2b5 01/04/2010 10:42 am Iustin Pop

Fix use of the logging functions

The logging functions expand the arguments themselves, thus it's safer
to let them do it rather than manual string formatting.

Also re-wraps one comment.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

d984846d 12/28/2009 02:05 pm Iustin Pop

Merge branch 'devel-2.0' into devel-2.1

  • devel-2.0:
    Fix indentation in hv_kvm
    Implement BuildHooksEnv for NoHooksLU
    Clarifiy some more wide pylint disables
    Fix two bugs in seldom-used codepaths
    Update pylintrc
    Add targetted pylint disables
    Partial cherry-pick of 6c881c5 from the 2.1 branch...
fe267188 12/28/2009 12:43 pm Iustin Pop

Add targetted pylint disables

This patch adds targeted pylint disables, where it makes sense (either
due to limitations in pylint or due to historical usage), and also a few
blanket ones in rapi where all the names are… “different”.

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

80f3f415 12/28/2009 12:43 pm Iustin Pop

Update pylintrc

Since the current pylintrc is in now way good for our style, we update
it:

- remove docstring checks, since we have too many cases where a
docstring doesn't make sense
- relax naming rules to cover more alternatives (but not break the
naming rules)...

4c4b5058 12/28/2009 12:43 pm Iustin Pop

Fix two bugs in seldom-used codepaths

New version of pylint, new bugs found!

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

c70d2d9b 12/28/2009 12:43 pm Iustin Pop

Clarifiy some more wide pylint disables

This removes/updates some module-wide pylint disables.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

fc8a6b8f 12/28/2009 12:43 pm Iustin Pop

Implement BuildHooksEnv for NoHooksLU

This just adds a stub function that raises an assertion error; this
accomplishes two things:

- silences many pylint warnings
- if we ever stumble upon this, a specific assertion error is
(hopefully) clearer than just a not implemented error...

146afafb 12/28/2009 12:43 pm Iustin Pop

Fix indentation in hv_kvm

Per pylint warnings.

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

caeffaa0 12/28/2009 12:43 pm Iustin Pop

Partial cherry-pick of 6c881c5 from the 2.1 branch

This cherry-picks the utils.FieldSet.Matches changes and the significant
jqueue.py change. These are stable in the 2.1 branch and therefore make
sense to backport to 2.0 (are basically cleanups).

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

2b32e20c 12/18/2009 05:56 pm Iustin Pop

Add a release script

Currently releases are done via the manual procedure on
http://code.google.com/p/ganeti/wiki/ReleaseProcess, but that is not
very reliable, and breaks for rc releases. The 1.2.9/2.0.5/2.1.0~rc2
releases were done with this new script that eases the process....

1e57442a 12/18/2009 03:01 pm René Nussbaumer

Fix a typo in the doc string

MaybeRaise in lib/errors.py had a typo in the doc string

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

fa05c92d 12/16/2009 04:10 pm Iustin Pop

Merge branch 'stable-2.1' into devel-2.1

  • stable-2.1:
    Bump version to 2.1.0~rc2
    Update NEWS file and release Ganeti 2.0.5
    Security issue: add validation of script names
    Move the hooks file mask into constants.py
    Improve LUQueryNodes for lockless case...
1a44f8cd 12/16/2009 04:07 pm Iustin Pop

Bump version to 2.1.0~rc2

5c0433d6 12/16/2009 04:06 pm Iustin Pop

Merge branch 'stable-2.0' into stable-2.1

  • stable-2.0:
    Update NEWS file and release Ganeti 2.0.5
    Security issue: add validation of script names
    Move the hooks file mask into constants.py
    Improve LUQueryNodes for lockless case
    Ship rapi.rst/rapi.html in the dist archive...
e5823b7e 12/16/2009 03:42 pm Iustin Pop

Update NEWS file and release Ganeti 2.0.5

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

1d65264b 12/16/2009 11:54 am Iustin Pop

Doc updates for --no-name-check

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

544ca43b 12/16/2009 11:54 am Iustin Pop

burnin: add --no-name-check support

This patch modifies burnin to accept the --no-name-check option and also
adds --no-ip-check (which was always set to True before).

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

18c8f361 12/16/2009 11:54 am Iustin Pop

CreateInstance: allow no ip check with start mode

Since gnt-instance start doesn't do any checks on the IP, it doesn't
make much sense to do so in instance create (with start) if the user
expressly passes in ‘--no-ip-check’. Removing this requirement eases the...

460d22be 12/16/2009 11:54 am Iustin Pop

Command line/RAPI support for --no-name-check

This patch adds --no-name-check to gnt-instance add and gnt-backup
import. This is opposite to the opcode parameter (name_check) as it is
similar to ip_check and start.

It also adds it to RAPI and gnt-instance batch-create as a parameter in...

5f23e043 12/16/2009 11:54 am Iustin Pop

Op/LUCreateInstance support for (no) name checks

This adds a new opcode parameter ‘name_check’ (similar to ip_check) that
is not required to be present (to easy backwards compatibility for
tools).

It also adds a CheckArguments to LUCreateInstance and changes the...

8b2df5f6 12/16/2009 11:47 am Iustin Pop

Pass --fqdn to ssh hostname checks

The cluster verify checks for fqdn are done via address lookups, and
there we actually use the FQDN. However, for the ssh hostname check
which is done at node add time, we rely on the default of the “hostname”
command. And Debian for example recently changed the default to return...

4fe80ef2 12/14/2009 05:36 pm Iustin Pop

Move the hooks file mask into constants.py

This will allow reuse of the same mask for multiple validations.

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

f95c81bf 12/14/2009 05:36 pm Iustin Pop

Security issue: add validation of script names

This patch unifies the search for external script to always go through
utils.FindFile and implements in that function a restriction on valid
chars in file names and (additionally) that the passed name is the...

4dfd6266 12/14/2009 05:34 pm Iustin Pop

Improve LUQueryNodes for lockless case

In most uses of LUQueryNodes, we don't take a lock. This means that the
instance data is not protected across GetInstanceList and
GetInstanceInfo, and this can lead to instances not existing anymore.

Switching to GetAllInstanceInfo means that we get a single,...

19572932 12/10/2009 04:45 pm Iustin Pop

Add disk cache control parameter for KVM

This patch adds the 'cache' parameter for KVM; currently this is only
customisable at the hypervisor level, so it's the same for all drives
(except any CDROM image, which gets the default).

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

ad54f3d2 12/10/2009 03:53 pm Guido Trotter

Change pyinotify import for broader compatibility

On some distributions pyinotify is installed in a different way, and the
actual module just contains an internal pyinotify entry, which is the
actual library. On others the main pyinotify module contains the library...

77220dd2 12/05/2009 06:18 pm Iustin Pop

Ship rapi.rst/rapi.html in the dist archive

Patch 4352bf6 changed RAPI docs to RST from the previous SGML format
(the last file to be converted to RST).

However, it didn't add rapi.rst to the docrst Makefile variable, and as
such rapi.html was neither build nor shipped in the archive. We fix this...

43dc8496 12/02/2009 04:01 pm Guido Trotter

ClusterMasterQuery: add primary ip field

By allowing also the primary ip field to be fetched directly, we avoid
one more confd lookup, or dns request, to find out which address the
master node lives at.

Signed-off-by: Guido Trotter <>

250554a9 12/02/2009 03:08 pm Guido Trotter

confd ClusterMasterQuery: allow fields request

Change the ClusterMasterQuery to allow a query, and if present accept a
list of fields to be returned. Currently only name and ip are accepted.

This feature will be used by NLD to route the cluster ip over the nbma....

310fbb64 12/01/2009 12:49 pm Iustin Pop

DRBD: ignore unreadable meta devices

The DRBD driver can ignore dead disks but not dead meta devices (for
which it refuses to configure the minor). To handle this case, we check
that the meta device is readable and if not we ignore it (the same as
when backend._RecursiveAssembleBD didn't find it)....

016308cb 12/01/2009 12:49 pm Iustin Pop

Simplify utils.ReadFile

The documentation for file objects' read method states that if the size
is "negative or ommitted", all data is read; thus we can simplify it to
have size=-1 by default and not have the if test.

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

313b2dd4 11/30/2009 04:34 pm Michael Hanselmann

gnt-cluster verify: Warn if node time diverges too far

The warning will be generated if the clocks diverge by more
than 150 seconds. Due to the way the RPC system works, we
cannot get exact time differences, e.g. if one of the
queried nodes is broken. The comparision is done using a...

94c2ed34 11/26/2009 07:28 pm Guido Trotter

KVM: fail when a routed nic has no ip

This shouldn't happen, but if it does it's better to fail at this level,
rather than create a broken NIC script, which is hard to debug.

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

b30e35c6 11/26/2009 06:25 pm Iustin Pop

Enable batch mode for devel/upload

Since the rsync/ssh calls are done in parallel, they can't read properly a
password or confirmation about keys from stdin. As such, it's better to enable
batch mode so that they fail right away instead of prompting and then timing...

5bc556dd 11/26/2009 05:29 pm Michael Hanselmann

cmdlib: Work around race condition in DRBD before version 8.0.13

DRBD goes into sync mode for a short amount of time after
executing the "resize" command. DRBD 8.x below version
8.0.13 contains a bug whereby calling "resize" in sync
mode fails.

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

43473573 11/25/2009 06:39 pm Michael Hanselmann

Bump version to 2.1.0~rc1

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

a33690c2 11/25/2009 04:40 pm Michael Hanselmann

Remove testJsonIndent unittest

It can't work on older distributions where simplejson
doesn't have indentation support.

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

8e671b7c 11/25/2009 04:36 pm Iustin Pop

QA: improve usability with cluster-init: False

When not initialising the cluster, consider all nodes are added, so that
multi-node tests (e.g. export, replace) work correctly (if there are
nodes, of course).

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

1f864b60 11/25/2009 04:30 pm Iustin Pop

Remove quotes from CommaJoin and convert to it

This patch removes the quotes from CommaJoin and converts most of the
callers (that I could find) to it. Since CommaJoin does str(i) for i in
param, we can remove these, thus simplifying slightly a few calls....

82e186f8 11/25/2009 02:08 pm Michael Hanselmann

Re-add “nic.bridges” field to RAPI bulk instance list

Commit 495cfdf0 removed “nic.bridges” from the default
list for bulk instance list RAPI requests.

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

8adfb141 11/25/2009 02:08 pm Michael Hanselmann

build-bash-completion: Check for None before comparing

Comparing a number with None is not a good idea:

>>> (0 < None, 0 > None)
(False, True)

This patch also adds build-bash-completion to the list
of checked Python scripts and wraps one line of more...

ab3e6da8 11/25/2009 01:45 pm Iustin Pop

Revert "Get rid of utils.CommaJoin"

This reverts commit 6915bc28fe053e92aa16cf2d974d205f1140219c based on thread on
ganeti-devel.

Conflicts:

lib/cmdlib.py (due to the error code classification, trivial)

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

8d0a4f99 11/25/2009 01:08 pm Michael Hanselmann

Add check for OpenSSL entropy status

By checking for this explicitly, the errors (SSLEAY_RAND_BYTES, “PRNG
not seeded”) will happen in the start-up phase of the daemon and not
only when executing remote procedure calls.

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

20b1bd80 11/25/2009 12:33 pm Iustin Pop

A couple of doc updates

Clarify the fact that temporary HV/BE params in instance start override
and do not extend the configured parameters; and change the instance
list headers from HVM_* to * since many of the parameters apply to KVM
too. Also fix a typo in the rapi documention for '/2/nodes'....

a426508d 11/20/2009 01:44 pm Michael Hanselmann

Handle EEXIST in utils.RenameFile

This should fix an issue I've seen exactly once during testing. It might have
been caused by parallel RPC calls to archive jobs.

[…] ganeti-noded:112 ERROR Error in RPC call […]
File "/usr/lib/python2.4/site-packages/ganeti/backend.py", line 2365, in JobQueueRename...

b6c07b79 11/20/2009 01:43 pm Michael Hanselmann

Remove unused parameter “unlock” from cmdlib._WaitForSync

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

21bcb9aa 11/16/2009 06:52 pm Michael Hanselmann

Fix off-by-one error when modifying instance NIC

For an instance with exactly one NIC:

$ gnt-instance modify --net 1:ip=1.2.3.4 inst1
Failure: prerequisites not met for this operation:
error type: wrong_input, error details:
Invalid NIC index 1, valid values are 0 to 1...

b8716596 11/16/2009 03:58 pm Michael Hanselmann

Re-add check for duplicate instance IP

This was originally implemented in 0ce8f948 and partially
rolled back in 9b65e0d4. Apart from re-adding the check,
this patch does some housekeeping by renaming the “_helper”
function to “_AddIpAddress”.

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

8619a3bd 11/16/2009 01:47 pm Guido Trotter

Fix gnt-instance list documentation

(1) Both the man page and the online help report the link and mode
fields, which are in the code called nic_link and nic_mode.
(2) Add missing fields to the online help.

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

8d9c3bef 11/13/2009 06:00 pm Michael Hanselmann

config: Style fixes

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

94338f0a 11/13/2009 05:59 pm Michael Hanselmann

Add packaging notes to documentation

This includes a few paragraphs about daemon-util.

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

9044275a 11/13/2009 05:59 pm Michael Hanselmann

Fix epydoc error

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

e7f6524c 11/13/2009 05:59 pm Michael Hanselmann

sphinx: Treat warnings as errors

This makes it easier to catch warnings.

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

cbf3d64b 11/13/2009 05:59 pm Michael Hanselmann

Include INSTALL in documentation

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

c27ba1cc 11/13/2009 05:59 pm Michael Hanselmann

Convert INSTALL to RST

This is in preparation to including it into the large
documentation.

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

90b704a1 11/13/2009 02:07 pm Guido Trotter

Fix change of cluster nic parameters

To stay on the safe side, we check for errors in all instances, and
refuse to act, reporting on the errors we found, if there are any
problems.

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

beabf067 11/12/2009 07:29 pm Guido Trotter

Fix mispopulation of nic parameters at nic modify

There's a bug in Ganeti 2.1 rc0 that makes nic parameters be populated
from the "filled in" dict, even if we're not changing any values in
them. This patch fixes the problem, by populating them from the correct...

0c9d32c1 11/12/2009 07:29 pm Guido Trotter

NIC.CheckParameterSyntax: fix bridged check

We should match for the strings to be the same "==" not to point to the
same memory location with is, or we skip the actual check.

Signed-off-by: Guido Trotter <>

3e5af833 11/11/2009 07:18 pm Michael Hanselmann

Bump version to 2.1.0~rc0

Also add one item to NEWS.

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

e91cfc2a 11/11/2009 04:00 pm Iustin Pop

Update RAPI documentation on job results

This documents the new error classifier added for OpPrereqError.

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

3d547d87 11/11/2009 03:30 pm Michael Hanselmann

Revert "Backport AC_PATH_PROGS_FEATURE_CHECK"

This reverts commit 52b699ecaa688a2aaac00fa64558e249d0bc9a26.

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

fe5b0c42 11/11/2009 03:30 pm Michael Hanselmann

Fix and simplify socat escape detection

- Program paths should not be --with-… options (see
Autoconf docs)
- Simplify checks for escape functionality
- Make SOCAT_USE_ESCAPE variable a bool

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

7e1fac25 11/11/2009 03:30 pm Michael Hanselmann

Use “daemon-util” to reload SSH keys

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

88df4f39 11/10/2009 04:59 pm Guido Trotter

KVMHypervisor: fix broken error format string

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

4fae38c5 11/06/2009 05:36 pm Guido Trotter

ConfigWriter: move _temporary_ids to reservation

In order to do this we need to pass a job id when reserving a resource.
We have one during _EnsureUUIDs because we passed it in from AddNode and
AddInstance. During config upgrade we use a fake job ID which we then...

36b66e6e 11/06/2009 05:36 pm Guido Trotter

ConfigWriter: move _temporary_macs to reservation

This solves the race conditions in mac reservation, as macs are actually
reserved, under the current ec id.

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

afa1386e 11/06/2009 05:36 pm Guido Trotter

ConfigWriter: simplify GenerateDRBDSecret

We can do this by adding a new TemporaryReservationManager

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

013da361 11/06/2009 05:36 pm Guido Trotter

TemporaryReservationManager

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

2c8a5690 11/06/2009 04:08 pm Guido Trotter

Add errors.ReservationError

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

664fbc9d 11/06/2009 04:08 pm Guido Trotter

Remove exceptions list from GenerateUniqueID

It's not used anywhere, so it's dead code.

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

adfa97e3 11/06/2009 04:08 pm Guido Trotter

Processor: support a unique execution id

When the processor is executing a job, it can export the execution id to
its callers. This is not supported for Queries, as they're not executed
in a job.

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

73064714 11/06/2009 04:08 pm Guido Trotter

Add config.DropECReservations

For now this function does nothing, but it gets called by mcpu when the
execution of an LU is done, making sure any pending reservations are
dropped.

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

0debfb35 11/06/2009 04:08 pm Guido Trotter

config.Add{Node,Instance}: get the ec id

This is ok because adding a node or instance cannot happen in a query.

We get the ec id from the LU and pass it to _EnsureUUID, which will
then for now not use it.

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

6c881c52 11/06/2009 03:48 pm Iustin Pop

Fix pylint 'E' (error) codes

This patch adds some silences and tweaks the code slightly so that
“pylint --rcfile pylintrc -e ganeti” doesn't give any errors.

The biggest change is in jqueue.py, the move of _RequireOpenQueue out of
the JobQueue class. Since that is actually a function and not a method...

bfe61b0b 11/06/2009 03:33 pm Iustin Pop

A few more small documentation updates

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

5ba3e84f 11/06/2009 03:32 pm Iustin Pop

Remove obsolete statement in autogen.sh

Nowadays we have actual files (tracket by VCS) in autotools/, so we know
the directory exists.

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