Statistics
| Branch: | Tag: | Revision:

root / lib / mcpu.py @ 60452edf

History | View | Annotate | Download (18.2 kB)

# Date Author Comment
eb279644 05/19/2011 02:01 pm Michael Hanselmann

mcpu: Add missing docstring to _ProcessResult

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

0d5a0b96 05/10/2011 02:03 pm Michael Hanselmann

cmdlib: Remove acquired_locks attribute from LUs

The “acquired_locks” attribute in LUs is used to keep a list of acquired
locks at each lock level. This information is already known in the lock
manager, which also happens to be the authoritative source. Removing the...

af7b6689 04/07/2011 01:24 pm Michael Hanselmann

Merge branch 'devel-2.4'

  • devel-2.4:
    LUInstanceQueryData: Don't acquire locks unless requested
    Increase the lock timeouts before we block-acquire
    daemon.py: move startup log message before prep_fn
    Display the actual memory values in N+1 failures...
d385a174 04/06/2011 03:49 pm Iustin Pop

Increase the lock timeouts before we block-acquire

This has been observed to cause problems on real clusters via the
following mechanism:

- a long job (e.g. a replace-disks) is keeping an exclusive lock on an
instance
- the watcher starts and submits its query instances opcode which...

6a373640 03/25/2011 03:53 pm Michael Hanselmann

Implement submitting jobs from logical units

The design details can be seen in the design document
(doc/design-lu-generated-jobs.rst).

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

07e0896f 03/18/2011 04:53 pm Michael Hanselmann

Split BuildHooksEnv of LUs

Commit dd7f677623 added another call to BuildHooksEnv to provide
post-phase status variables. Since BuildHooksEnv also built the node
lists, that meant they have to be built twice. First a rather strict
check was used, but it turned out to be more tricky. Commit b423c51336...

b423c513 03/17/2011 06:43 pm Michael Hanselmann

Remove restrictive hook node list check

Commit dd7f67762 added a restrictive check for the node lists returned
by BuildHooksEnv, leading to errors with some LUs, one of which was
fixed in commit 0dfa2c227. As it turns out, other LUs have similar
issues, some not easy to fix. This patch disables the restrictive check...

ebc75510 03/16/2011 07:58 pm Michael Hanselmann

HooksMaster: Add more assertions for variable names

Also replace explicit loop with dict.update.

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

dd7f6776 03/16/2011 07:58 pm Michael Hanselmann

hooks: Provide variables with post-opcode values

When a hook is called, it is provided with a number of variables
describing the status of the instance/node/etc. before the operation.
Some opcodes provide extra variables to see modified values from hooks,...

0306ff62 03/16/2011 07:58 pm Michael Hanselmann

mcpu: Tidy HooksMaster a bit

- Dictionary indentation
- Add empty lines for readability
- Simplify conditional code

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

3ae70d76 02/28/2011 08:40 pm Michael Hanselmann

Fix LU processor's GetECId

The exception was never actually raised.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Adeodato Simo <>

a1a7bc78 01/10/2011 02:42 pm Iustin Pop

mcpu: Automatically build the DISPATCH_TABLE

While reviewing dato's interdiff for the OpAssignGroupNodes, I
realised that we can do better. This patch replaces the hand-built
DISPATCH_TABLE with one built from the opcode.OP_MAPPING dict.

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

792af3ad 12/15/2010 05:35 pm René Nussbaumer

Rename (Op|LU)OutOfBand to (Op|LU)OobCommand

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

4da7909a 12/13/2010 06:33 pm Adeodato Simo

Add modification of node groups (OpCode/LU/CLI)

With this commit, only modification of the "ndparams" attribute is
supported.

Signed-off-by: Adeodato Simo <>
Reviewed-by: Guido Trotter <>

4fe5cf90 12/08/2010 02:27 pm Adeodato Simo

Group operations: OpCode and LU for renaming a group

Signed-off-by: Adeodato Simo <>
Reviewed-by: Michael Hanselmann <>

94bd652a 12/08/2010 02:27 pm Adeodato Simo

Group operations: OpCode and LU for removing a group

Signed-off-by: Adeodato Simo <>
Reviewed-by: Michael Hanselmann <>

b1ee5610 12/08/2010 02:27 pm Adeodato Simo

Group operations: OpCode and LU for adding a group

Signed-off-by: Adeodato Simo <>
Reviewed-by: Michael Hanselmann <>

eb64da59 12/07/2010 04:51 pm René Nussbaumer

Adding new OpCode for OOB

Register OpCode and Logical Unit in mcpu.py

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

70a6a926 12/01/2010 09:31 pm Adeodato Simo

Querying node groups: LU/Opcode

This adds opcodes.OpQueryGroups and cmdlib.LUQueryGroups.

Signed-off-by: Adeodato Simo <>
Signed-off-by: Iustin Pop <>
Reviewed-by: Iustin Pop <>

83f72637 11/29/2010 10:00 pm Michael Hanselmann

Add OpQuery opcode

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

557838c1 11/16/2010 05:19 pm René Nussbaumer

Move locking.RunningTimeout to utils

As we need this functionality in other places than just locking it makes
sense to move it to utils rather than keeping it in locking

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

900df6cd 10/12/2010 03:48 pm Michael Hanselmann

mcpu: Raise directly in _AcquireLocks

Removes code duplication.

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

f879a9c7 09/24/2010 06:18 pm Michael Hanselmann

mcpu: Implement priority for lock acquiring

Until now the priority for lock acquires couldn't be passed
when running opcodes.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

a7770f03 09/23/2010 04:06 pm Michael Hanselmann

mcpu: Adjust lock acquire strategy

The changes to job queue processing require some changes on this class'
interface. LockAttemptTimeoutStrategy might move to another place, but that'll
be done in a later patch.

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

831bbbc1 09/23/2010 04:06 pm Michael Hanselmann

mcpu.Processor: Raise exception on lock acquire timeout

Right now the timeout is not passed by any caller, making the code
effectively go back to blocking acquires. Since the timeout is always
None, no caller needs to be changed in this patch.

This change also means that any LUXI query handled by ganeti-masterd...

acf931b7 09/13/2010 05:46 pm Michael Hanselmann

Remove mcpu's ReportLocks callback

This is no longer needed with the new lock monitor. One callback is kept to
check for cancelled jobs.

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

e58f87a9 07/15/2010 07:27 pm Michael Hanselmann

Add test for some aspects of job queue

This new opcode and gnt-debug sub-command test some aspects of the
job queue, including the status of a job. The bug fixed in commit
2034c70d507 was identified using this test. A future patch will
run this test automatically from the QA scripts....

7b4c1cb9 07/12/2010 05:32 pm Michael Hanselmann

Provide feedback function for all LU methods

By exposing mcpu's _Feedback function (now renamed to “Log”) to LU's,
methods like ExpandNames can also write to the job execution log.

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

8de1f1ee 06/23/2010 07:23 pm Iustin Pop

Remove the obsolete EvacuateNode OpCode/LU

All code has been switched to the new-style LU… time for cleanup.

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

1410fa8d 05/18/2010 06:53 pm Michael Hanselmann

Add opcode to prepare export

To prepare a remote export, the X509 key and certificate need to be generated.
A handshake value is also returned for an easier check whether both clusters
share the same cluster domain secret.

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

f7e7689f 02/22/2010 02:50 pm Iustin Pop

Add LUNodeEvacuationStrategy

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

4776e022 01/13/2010 03:02 pm Michael Hanselmann

mcpu: Log lock status with sorted names

Reading and comparing sorted lists is easier when debugging locking problems.

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

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

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

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

debac808 11/02/2009 04:14 pm Iustin Pop

Convert the rest of the OpPrereqError users

This finishes the conversion of OpPrereqError creation to two-argument
style. Any leftovers as one-argument are not breaking anything, just
losing information about the errors.

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

a6db1af2 10/15/2009 05:47 pm Michael Hanselmann

mcpu: Use new timeout class for timeout

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

b6b87034 10/15/2009 05:47 pm Michael Hanselmann

locking, mcpu: Ensure timeout is always >= 0.0

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

6f14fc27 10/13/2009 08:08 pm Michael Hanselmann

mcpu: Make sure added locks are released on errors

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

e3200b18 10/12/2009 01:48 pm Michael Hanselmann

mcpu: Change lock attempt timeout calculation

With this patch all timeouts are pre-calculated. The interface of
the _LockTimeoutStrategy class is also changed a bit; NextAttempt
now returns a new instance.

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

69b99987 10/12/2009 01:48 pm Michael Hanselmann

Code and docstring style fixes

Found using pylint and epydoc.

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

211b6132 10/12/2009 01:47 pm Michael Hanselmann

mcpu: Improve lock reporting with timeouts

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

407339d0 10/12/2009 01:47 pm Michael Hanselmann

mcpu: Implement lock timeouts

The timeout is always between ~0.1 and ~10.0 seconds. A small
variation of ±5% is added to prevent different jobs from
fighting each other. After 10 attempts to acquire the locks with
a timeout, a blocking acquire is made.

Lock status reporting will be improved in a separate patch....

6b95b76d 10/12/2009 01:47 pm Michael Hanselmann

mcpu: Remove unused exclusive_BGL attribute

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

3cebe102 09/17/2009 06:53 pm Michael Hanselmann

Remove RpcResult.RemoteFailMsg completely

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

ef2df7d3 09/15/2009 02:19 pm Michael Hanselmann

Keep lock status with every job

This can be useful for debugging locking problems.

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

031a3e57 09/15/2009 02:19 pm Michael Hanselmann

Move OpCode processor callbacks into separate class

There are two major arguments for this:
- There will be more callbacks (e.g. for lock debugging) and extending the
parameter list is a lot of work.
- In the jqueue module this allows us to keep per-job or per-opcode variables in...

640b961e 09/09/2009 12:46 pm Luca Bigliardi

mcpu: formatting/indenting fix

Small fix for a mistake done by bad editor settings.

Signed-off-by: Luca Bigliardi <>

d763bed0 08/25/2009 06:17 pm Luca Bigliardi

HooksMaster: fix RunPhase logging

In case of complete failure results is empty, return immediately
(tnx unittests).

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

8c4b9364 08/25/2009 05:39 pm Luca Bigliardi

HooksMaster: logging hooks in RunPhase

Extend RunPhase so it will log hooks results in POST phase.

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

cd46f3b4 08/25/2009 02:40 pm Luca Bigliardi

node-remove post on removed node

Run post phase of node-remove on the removed node as well.

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

6ef2dc74 08/25/2009 01:38 pm Luca Bigliardi

HooksMaster: document raised exception

HooksAbort is raised, but not documented.

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

17e82923 08/24/2009 08:32 pm Luca Bigliardi

HooksMaster: list of nodes override

Allow the caller of HooksMaster.RunPhase() to specify an alternative list of
nodes.

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

313bcead 08/24/2009 03:13 pm Iustin Pop

Add OPMoveInstance and LUMoveInstance

This patch adds a basic version of LUMoveInstance. It doesn't yet
support iallocator-mode and it's implemented in old-style (non-TL) mode.

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

4b5e8271 08/24/2009 03:11 pm Iustin Pop

Remove extra argument from HooksMaster class

The mcpu.py:HooksMaster class needs to have a proc attribute/argument to
init in ordet to call its LogWarning method. However, this is available
from the 'lu' attribute, so we can remove this dependency.

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

76aef8fc 08/17/2009 02:26 pm Michael Hanselmann

Add opcode to repair storage volumes

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

bd315bfa 08/14/2009 04:00 pm Iustin Pop

Implement instance recreate-disks

This can be used for a 'plain' type instance when the underlying storage
went away, to recreate the storage (and reinstall) instead of removing
the instance and readding it.

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

b142ef15 08/13/2009 02:41 pm Iustin Pop

Merge commit 'origin/next' into branch-2.1

  • commit 'origin/next': (28 commits)
    Fix a typo in InitCluster
    Ignore results from drained nodes in iallocator
    Ship the ethers hook
    Ethers hook, compatibility with old lockfile
    Remove a few unused imports from noded/masterd...
b5f5fae9 08/10/2009 03:23 pm Luca Bigliardi

Post cluster initialization LU

Add an 'empty' logical unit to run hooks after cluster initialization.

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

8486ffc0 08/07/2009 02:22 pm Guido Trotter

Merge branch 'master' into next

  • master:
    Update NEWS and version for 2.0.3 release
    devel/upload: revert rsync -p
    export: add meaningful exit code
    Fix detecting of errors in export
    Implement gnt-cluster check-disk-sizes
    rpc: add rpc call for getting disk size...
60975797 08/04/2009 05:36 pm Iustin Pop

Implement gnt-cluster check-disk-sizes

This patch adds a new opcode and lu for checking disk sizes. Currently
it does only top-level disk verification, and also doesn't check
primary/secondary node size mismatches (these two are added as TODOs in
the Exec() function of the LU)....

efb8da02 08/04/2009 12:44 pm Michael Hanselmann

cmdlib: Add opcode to modify storage unit fields

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

9e5442ce 08/03/2009 04:42 pm Michael Hanselmann

Add new opcode to list physical volumes

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

80cb875c 07/31/2009 02:30 pm Michael Hanselmann

cmdlib: Add new opcode to migrate node

It migrates all primary instances from the node to their secondaries.

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

7ffc5a86 07/22/2009 08:52 pm Michael Hanselmann

Add new opcode to evacuate nodes

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

2f7140ba 07/08/2009 12:28 pm Guido Trotter

Merge branch 'next' into branch-2.1

  • next:
    Create a new --no-voting option for masterfailover
    ganeti-masterd: allow non-interactive --no-voting
    Fix pylint warnings
    Add custom pylintrc
    bootstrap: Don't leak file descriptor when generating SSL certificate...
7c4d6c7b 07/07/2009 03:54 pm Michael Hanselmann

Fix pylint warnings

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

5bbd3f7f 07/07/2009 03:51 pm Michael Hanselmann

Fix some typos

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

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

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

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

f5118ade 05/27/2009 01:19 pm Iustin Pop

Add a node powercycle command

This (somewhat big) patch adds support for remotely rebooting the nodes
via whatever support the hypervisor has for such a concept.

For KVM/fake (and containers in the future) this just uses sysrq plus a
‘reboot’ call if the sysrq method failed. For Xen, it first tries the...

26f15862 02/03/2009 04:45 pm Iustin Pop

An attempt at fixing some encoding issues

This patch unifies the hardcoded re-encoding attempts into a single
function in utils.py. This function is used to take either an unicode or
str object and convert it to a ASCII-only str object which can be safely...

53c776b5 01/13/2009 05:21 pm Iustin Pop

Forward port the live migration from 1.2 branch

This is forward port via copy (and not individual patches cherry-pick)
of the latest code on the 1.2 branch related to the migration.

The changes compared to 1.2 are the fact that we don't need the
IdentifyDisks step anymore (the drbd rpc calls are independent now), and...

afee0879 01/12/2009 11:14 am Iustin Pop

Introduce a very simple LU to force config updates

This LU can be used to force a push of the config in case it's needed,
for example after an upgrade to update the ssconf_release_version file.

Reviewed-by: imsnah

0a66c968 12/05/2008 01:41 pm Iustin Pop

Make cluster verify understand offline nodes

This patch changes cluster verify to not alert on offline nodes, but
instead just show a note at the end with the number of such nodes.

It also removes warnings in verify-disks and hooks about failures to
make rpc calls to such nodes....

781de953 12/02/2008 02:58 pm Iustin Pop

Convert rpc results to a custom type

For a long time we had the problem that both RPC-layer errors and
results from the remote node share the same "valuespace". This is
because we shouldn't raise an exception when only one node failed
(and lose the results from the other nodes)....

b31c8676 12/02/2008 07:05 am Iustin Pop

Add a gnt-node modify operation

This patch adds the OpCode, LogicalUnit and gnt-node command for
modifying node parameters, more specifically the master candidate flag
for a node.

Reviewed-by: imsnah

8dca23a3 11/24/2008 01:01 pm Iustin Pop

Documentation updates for mcpu.py

This is the only change needed to make mcpu epydoc-compliant.

Reviewed-by: ultrotter

c0088fb9 10/21/2008 06:45 pm Iustin Pop

Improve the mcpu.Processor logging routines

As discussed previously, many of the routinges in cmdlib.py are using
logging functions as a carry-over from 1.2 (when these also showed the
message on stderr/to the user), instead of actually warning the user....

a5eb7789 10/20/2008 03:50 pm Iustin Pop

Convert mcpu.py to use the logging module

Reviewed-by: imsnah

72737a7f 10/10/2008 12:55 pm Iustin Pop

Convert rpc module to RpcRunner

This big patch changes the call model used in internode-rpc from
standalong function calls in the rpc module to via a RpcRunner class,
that holds all the methods. This can be used in the future to enable
smarter processing in the RPC layer itself (some quick examples are not...

e92376d7 10/07/2008 11:03 am Iustin Pop

Implement job 'waiting' status

Background: when we have multiple jobs in the queue (more than just a
few), many of the jobs (up to the number of threads) will be in state
'running', although many of them could be actually blocked, waiting for
some locks. This is not good, as one cannot easily see what is...

0b38cf6e 10/01/2008 08:37 pm Michael Hanselmann

Don't pass sstore to LUs anymore

sstore is no longer used in LUs.

Reviewed-by: iustinp

437138c9 10/01/2008 08:34 pm Michael Hanselmann

Convert mcpu.py

Replacing ssconf with configuration.

Reviewed-by: iustinp

ae5849b5 10/01/2008 08:33 pm Michael Hanselmann

Add new query to get cluster config values

This can be used to retrieve certain cluster config values from
within clients.

OpDumpClusterConfig was not used anywhere, hence I'm just reusing
it. The way ConfigWriter.DumpConfig returned the configuration
was not thread-safe, anyway (no deepcopy)....

ca2a79e1 09/11/2008 12:44 pm Guido Trotter

Implement adding/removal of locks by declaration

With this patch LUs can declare locks to be added when they start and/or
removed after they finish. For now locks can only be added in the
acquired state, and removed if owned, and added locks default to be...

80ee04a4 09/11/2008 12:43 pm Guido Trotter

Use is_owned to determine whether to unlock

Now that is_owned is public we don't need to play games at the end of an
LU. If we're still owning anything we just release it.

Reviewed-by: imsnah

b2751b57 09/09/2008 01:41 pm Guido Trotter

Processor: remove ChainOpCode

This function was incompatible with the new locking system, and its
usage has been removed from the code. For now LUs share code by calling
common module-private functions in cmdlib.py, in the future they will
use tasklets (when those will be implemented)....

6683bba2 08/28/2008 01:29 pm Guido Trotter

Fix issue when acquiring empty lock sets

By design if an empty list of locks is acquired from a set, no locks are
acquired, and thus release() cannot be called on the set. On the other
hand if None is passed instead of the list, the whole set is acquired,...

8a2941c4 08/18/2008 03:49 pm Guido Trotter

Processor: lock all levels even if one is missing

If a locking level wasn't specified locking used to stop. This means
that if one, for example, didn't specify anything at the LEVEL_INSTANCE
level, no locks at the LEVEL_NODE level were acquired either. With this...

64381ad7 07/30/2008 06:04 pm Guido Trotter

ChainOpCode is still BGL-only

Prevent mistakes with an assert.

Reviewed-by: iustinp

38206f3c 07/30/2008 05:04 pm Iustin Pop

Fix pylint-detected issues

This is mostly:
- whitespace fix (space at EOL in some files, not all, broken
indentation, etc)
- variable names overriding others (one is a real bug in there)
- too-long-lines
- cleanup of most unused imports (not all)...

3977a4c1 07/30/2008 02:30 pm Guido Trotter

Make sharing locks possible

LUs can declare which locks they need by populating the
self.needed_locks dictionary, but those locks are always acquired as
exclusive. Make it possible to acquire shared locks as well, by
declaring a particular level as shared in the self.share_locks...

fb8dcb62 07/30/2008 02:29 pm Guido Trotter

Add LogicalUnit.DeclareLocks

This additional LogicalUnit function is optional to implement, but lets
you change your locking needs for one level just before locking it, but
after the previous levels have been already locked. It is useful for
example to calculate what nodes to lock after locking an instance....

b1b6ea87 07/30/2008 11:43 am Iustin Pop

Rework master startup/shutdown/failover

This (big) patch reworks the master startup/shutdown and the fixes the
master failover.

What does the patch do?

For master start/stop:
- remove the old ganeti-master script and its associated man page
- moves the ip start/stop directly into the backend.(Start|Stop)Master...

04e1bfaf 07/23/2008 05:23 pm Guido Trotter

Invert nodes/instances locking order

An implementation mistake from the original design caused nodes to be
locked before instances, rather than after. This patch inverts the level
numbering, changing also the relevant unittests and the recursive
locking function starting point....

f1048938 07/14/2008 04:15 pm Iustin Pop

First version of user feedback fixes

This patch contains a raw version for fixing feedback_fn.

The new mechanism works as follows:
- instead of a per-Processor feedback_fn, there's one for each
ExecOpCode, so that feedback for different opcodes go via possibly...

68adfdb2 07/08/2008 07:32 pm Guido Trotter

Processor: Acquire locks before executing an LU

If we're running in a "new style" LU we may need some locks, as required
by the ExpandNames function, to be able to run. We'll walk up the lock
levels present in the needed_locks dictionary and acquire them, then run...