Statistics
| Branch: | Tag: | Revision:

root @ cdb08f44

# Date Author Comment
cdb08f44 03/04/2008 04:46 pm Michael Hanselmann

Codestyle updates for locking code

Reviewed-by: ultrotter

3b7ed473 03/04/2008 03:18 pm Guido Trotter

LockSet: make acquire() able to get the whole set

This new functionality makes it possible to acquire a whole set, by passing
"None" to the acquire() function as the list of elements. This will avoid new
additions to the set, and then acquire all the current elements. The list of...

806e20fd 03/04/2008 03:18 pm Guido Trotter

LockSet: encapsulate acquire() in try-except

This patch adds a try/except area around most of the acquire() code (everything
after the intial condition checks). Since the except: clause contains just a
'raise' nothing really changes except the indentation of the code....

0cf257c5 03/04/2008 03:17 pm Guido Trotter

Make LockSet.__names() return a list, not a set

Previously the private version of the __names function returned directly a set.
We'll keep this in the public interface but change the private version to a
list in order to be able to sort() its result and then loop on it, even though...

3f404fc5 03/04/2008 03:17 pm Guido Trotter

LockSet: improve remove() api

Lockset's remove() function used to return a list of locks we failed to remove.
Rather than doing this we'll return a list of removed locks, so it's more
similar to how acquire() behaves. This patch also fixes the relevant unit tests....

0cc00929 03/04/2008 03:17 pm Guido Trotter

LockSet: make acquire() return the set of names

In a LockSet acquire() returned True on success. This code changes that to
return a set containing the names of the elements acquired. This is still a
true value if we acquired any lock but is slightly more useful (because if...

8b68f394 03/04/2008 03:16 pm Guido Trotter

LockSet: invert try/for nesting in acquire()

This patch changes nothing to the functionality of a LockSet. Rather than
trying to do the whole for loop we try each of its steps. This opens the way to
handle differently a single failure.

Reviewed-by: imsnah

7ee7c0c7 03/04/2008 12:09 pm Guido Trotter

Initial GanetiLockManager implementation

Includes some locking-related constants and explanations on how the
LockManager should be used, the class itself and its test cases.

The class includes:
- a basic constructor
- functions to acquire and release lists of locks at the same level...

c9064964 02/29/2008 06:32 pm Iustin Pop

Fix master role stop on cluster destroy

Currently the cluster destroy doesn't remove the master role, which
means that the IP address of the cluster remains assigned to the master
node.

This patch fixes this and also a docstring in backend.StopMaster()....

caea3b32 02/29/2008 05:33 pm Iustin Pop

Implement QA tests for gnt-cluster rename

Reviewed-by: imsnah

488b540d 02/29/2008 02:32 pm Iustin Pop

Fix cluster rename operation

This one-liner fixes the cluster rename operation. As a side note, we
should have a QA test for this too.

Reviewed-by: imsnah

e6c200d6 02/28/2008 08:53 pm Guido Trotter

LockSet: make acquire() fail faster on wrong locks

This patch makes acquire() first look up all the locks in the dict and then try
to acquire them later. The advantage is that if a lockname is already wrong
since the beginning we won't need to first queue and acquire other locks to...

aaae9bc0 02/28/2008 05:06 pm Guido Trotter

LockSet implementation and unit tests

A LockSet represents locking for a set of resources of the same type. A thread
can acquire multiple resources at the same time, and release some or all of
them, but cannot acquire more resources incrementally at different times...

f3b100e1 02/28/2008 01:20 pm Guido Trotter

Fix the gnt-cluster init man page

Some options were missing in the gnt-cluster init man page. This patch adds
them, removes an empty line, and clarifies a bit more some requirements.

Reviewed-by: schreiberal

7bde3275 02/28/2008 01:20 pm Guido Trotter

Don't allow renaming to an existing instance

Even if the target instance is down or we are not checking for IP conflicts
changing an instance name to a new one which is already in the cluster is
doomed to fail, because in a lot of places (among which figures the mind of...

5336d63d 02/28/2008 12:33 pm Alexander Schreiber

Clarify online help for xc-instance reinstall.

Reviewed-by: imsnah

107711b0 02/27/2008 03:05 pm Michael Hanselmann

Use constants.ETC_HOSTS instead of string for /etc/hosts

Reviewed-by: iustinp

7324ad4c 02/27/2008 02:22 pm Michael Hanselmann

Distribute lib/locking.py

Reviewed-by: ultrotter

c9c4f19e 02/26/2008 10:15 pm Michael Hanselmann

Split GanetiUnitTest into testutils.py

Reviewed-by: iustinp

bcfbed6b 02/26/2008 04:14 pm Michael Hanselmann

Update svn:ignore properties

Reviewed-by: iustin

29df1f02 02/25/2008 03:54 pm Michael Hanselmann

Some changes on disk failure tests

Change comments to printed information, some cleanup. These changes
are from November 2007. The test is not perfect yet.

Reviewed-by: iustinp

3517d9b9 02/25/2008 11:17 am Manuel Franceschini

This patch replaces some hardcoded strings with their corresponding constant in `_GenerateDiskTemplate()`.

Reviewed-by: iustinp

0d349b3a 02/23/2008 12:48 pm Guido Trotter

Improve ganeti example cron file

The cron file in ganeti's example directory is now static, and executes
ganeti-watcher in /usr/local/sbin no matter where it's really installed. With
this patch we generate it at build time substituting the right value of...

6c8af3d0 02/22/2008 06:12 pm Manuel Franceschini

Small comment fix.

c99a3cc0 02/22/2008 06:12 pm Manuel Franceschini

Fixes small spell mistakes and comments

81010134 02/22/2008 02:39 pm Iustin Pop

Break trunk by removing twisted

This patch switches from the twisted usage for inter-node protocol to
simple BaseHTTPServer/httplib. The patch has more deletions because we
use no authentication, no encryption at all.

As such, this is just for trunk, and only for testing. What it brings is...

84152b96 02/21/2008 03:45 pm Guido Trotter

Add a few SharedLock delete() tests

- Check that even a shared acquire() fails on a deleted lock
- Check that delete() fails on a lock you share (must own it or nothing)

These are assumptions I build on in future code, so better check for them.
Currently no code change is necessary for them to be valid....

4354ab03 02/20/2008 03:47 pm Guido Trotter

SharedLock: fix a wrong unit-test helper code

The _doItDelete helper code was supposed to be used to dispatch threads that
deleted the SharedLock. It actually just acquired it exclusively. This remained
unnoticed as the helper thread is just used to test interaction, not the delete...

00ce8b29 02/20/2008 01:17 pm Guido Trotter

Add another 1.1->1.2 compatibility alias

gnt-instance replace-disks used to be called replace_disks.

Reviewed-by: iustinp

a95fd5d7 02/19/2008 03:50 pm Guido Trotter

Add the delete() operation to SharedLock

This new operation lets a lock be cleanly deleted. The lock will be exclusively
held before deletion, and after it pending and future acquires will raise an
exception. Other SharedLock operations are modify to deal with delete() and to...

d6646186 02/18/2008 06:58 pm Guido Trotter

Fix a couple of SharedLock docstrings

Use the actual class name rather than a spaced version of it.

Reviewed-by: iustinp

bae27f68 02/18/2008 03:36 pm Iustin Pop

Update version numbers for the 1.2.3 release

Note: we don't update for now the install.sgml file with the new version
number, as there are no other changes. We'll update the web site to
indicate that the current install.html document is valid for 1.2.3 too....

c05bcecf 02/18/2008 12:59 pm Iustin Pop

Revert "Include the DRBD upgrade tool in the dist archive"

This reverts commit 604 as the upgrade tool should not be in the 1.3 branch.

Reviewed-by: schreiberal

9b603bff 02/18/2008 12:44 pm Alexander Schreiber

Update online help and manpage to include drbd disk type.

Reviewed-by: imsnah

8b084a1a 02/18/2008 12:42 pm Iustin Pop

Include the DRBD upgrade tool in the dist archive

This patch adds the DRBD upgrade tool in the archive and in the
installed tools dir, and its associated README in the doc_DATA target.

Reviewed-by: ultrotter

515207af 02/16/2008 03:06 pm Guido Trotter

Fix gnt-instance info i1 i2 ...

Due to an indentation error only the last instance queried got returned by
LUQueryInstanceData. Moving the append() call inside the for cycle to fix this
issue.

This is a one-liner targeted at 1.2.3

Reviewed-by: iustinp

e30c295e 02/15/2008 02:41 pm Michael Hanselmann

Replace version number in install.sgml during build time

Reviewed-by: iustinp

ef756965 02/15/2008 11:53 am Iustin Pop

Further fixes for the 'export MAC in hooks' change

QA suite which tests gnt-instance modify has uncovered another issue related to
mac export.

Reviewed-by: imsnah

40a03283 02/14/2008 05:54 pm Iustin Pop

Alter the device activation code

This tiny patch fixes the breakage that the previous patch about
activation did by removing the Close() call after activation.

The initial reason for that call was that if the device is already
active and open, but we need it closed, we close it automatically....

d7b47a77 02/14/2008 05:53 pm Iustin Pop

Two small improvements to burnin

This tiny patch fixes the verbose option to actually work, and also when
creating instances it logs the secondary node too (even if this doesn't
apply for plain templates, it doesn't create an error).

Reviewed-by: imsnah

d8052456 02/14/2008 05:53 pm Iustin Pop

Modify the default output of gnt-instance list

This patch adds a new field available for selection in gnt-instance list
names "status" which represents the combined value of "admin_state" and
"oper_state". Since this is much easier to parse (e.g. gnt-instance list...

c68d1f43 02/14/2008 05:39 pm Michael Hanselmann

Code style updates for QA code.

Reviewed-by: iustinp

c3f9340c 02/12/2008 07:06 pm Guido Trotter

Parse double protocol version in drbd8.2

DRBD 8.2 uses a double integer field ad protocol version, rather than a single
one. This patch fixes the ganeti parsing code, allowing both the old and the
new version type. In order to do so the internal _GetVersion function is...

eeb3a5f9 02/10/2008 02:10 pm Iustin Pop

Fix a wrong OP_ID added in r261

Reviewed-by: ultrotter

162c1c1f 02/08/2008 01:23 pm Guido Trotter

Shared Lock implementation and unit tests.

Adding a locking.py file for the ganeti locking library. Its first component is
the implementation of a non-recursive blocking shared lock complete with a
testing library.

Reviewed-by: imsnah, iustinp

e2618bc7 02/06/2008 01:29 pm Iustin Pop

Document the client API protocol, first version

This patch adds some documentation about the proposed client API. It's
not yet complete, but should be a usable draft for the initial
implementation.

Reviewed-by: ultrotter

06009e27 02/05/2008 04:12 pm Iustin Pop

Add a test opcode that sleeps for a given duration

This can be used for testing purposes.

Reviewed-by: ultrotter,imsnah

fdbd668d 02/05/2008 03:33 pm Iustin Pop

Reduce the chance of DRBD errors with stale primaries

This patch is a first step in reducing the chance of causing DRBD
activation failures when the primary node has not-perfect data.

This issue is more seen with DRBD8, which has an 'outdate' state (in
which it can get more often). But it can (and before this patch, usually...

b08d5a87 02/04/2008 04:33 pm Iustin Pop

Fix some indendation issues

Reviewed-by: imsnah

c7b27e9e 02/04/2008 04:28 pm Iustin Pop

Fix incomplete mac address export to hooks

This patch completes the change introduced in r566 (trunk) and r568
(branch-1.2).

Reviewed-by: imsnah

53e4e875 01/31/2008 03:22 pm Guido Trotter

Give mac information to instance hooks

Currently just the bridge and ip address are passed. Add an environment
variable for the mac address.

Reviewed-by: iustinp

cdeef2ca 01/31/2008 02:38 pm Alexander Schreiber

Make the mouse more usable in VNC for HVM.

Reviewed-by: imsnah

1cafd236 01/30/2008 01:14 pm Guido Trotter

Export bridge information too

gnt-backup export used to export the ip and mac of each nic, but not which
bridge it was connected to. Adding this information.

Reviewed-by: iustinp

1fb101fe 01/30/2008 01:14 pm Guido Trotter

Fix online help for gnt-backup import

The help string missed drbd as a disk template option. Adding it.

Reviewed-by: iustinp

e709baee 01/30/2008 12:54 pm Iustin Pop

Bump version numbers for the 1.2.2 release

Reviewed-by: ultrotter

f2e9e0e8 01/28/2008 06:22 pm Alexander Schreiber

tiny typo fix

Reviewed-by: iustinp

d8a4b51d 01/28/2008 04:32 pm Iustin Pop

Improve the documentation of query output fields

The gnt-node and gnt-instance list commands have a customizable list of
output fields, but the list is not up to date (in the man page) and not
easily understandable from the ‘--help’ output.

This patch updates the man pages and adds the available fields and...

4a160927 01/28/2008 03:35 pm Guido Trotter

Fix a typo in a devel/upload comment

Files are uploaded to $prefix/sbin, not $prefix/bin

Reviewed-by: iustinp

c0f74c55 01/28/2008 03:33 pm Iustin Pop

Add QA tests for gnt-instance modify

This patch adds QA tests for most of the possible parameters in the
instance modify operation (exception being the MAC), and modifies the
sample QA file to run this test.

It also tests the no-modification test, but that is a weak one: we only...

d6d415e8 01/28/2008 01:51 pm Iustin Pop

Add option for the number of VCPUs in instance listing

Reviewed-by: ultrotter

b32f9859 01/28/2008 12:43 pm Iustin Pop

Allow selection of hypervisor type in QA

This patch allows the selection of the hypervisor type for the QA
process; this is useful when testing hypervisor-independent changes that
don't require a Xen setup.

The patch also fixes the OS name in the sample QA config file provided....

2bc22872 01/28/2008 11:03 am Iustin Pop

Fix "gnt-instance modify --initrd"

The new QA tests for instance modify uncovered a bug in the modify
initrd operation when setting the initrd to none.

Reviewed-by: imsnah

40cece88 01/27/2008 07:08 pm Iustin Pop

Fix gnt-instance modify breakage due to hvm_boot_order

As reported by , this is missing a check on None. As we don't
care about uppercase, we keep the check simple by removing the lower() call.

Reviewed-by: ultrotter

70a35b6f 01/25/2008 05:36 pm Guido Trotter

Add a missing parenthesis

It was wrongly deleted when converting

if a in dict.keys():
to
if a in dict:

Reviewed-by: imsnah

909a0e4d 01/22/2008 09:12 am Iustin Pop

Change the install directory for the tools

Currently, the tools are installed under $prefix/share/ganeti. This
prevents installing other things in a nice way under share/ganeti (like
arch-independent OS definitions), therefore we want the tools to live
under share/ganeti/tools....

e0b62a26 01/21/2008 06:57 pm Guido Trotter

Remove qa tests for gnt-instance start/stop

Those tests were added in the wrong place. This patch removes them. One day
we'll implement proper command line regression testing and they should go in
there.

Reviewed-by: iustinp

ce9fb89d 01/21/2008 06:29 pm Guido Trotter

Test start/stop aliases in qa

This tests both that those two aliases have not been removed and also that
aliases handling hasn't been broken.

Reviewed-by: iustinp

536fda25 01/21/2008 06:29 pm Guido Trotter

Add a few aliases for startup/shutdown

These aliases are widely used to think of these operations and save some typing
too. Even though there is some thought to make start/stop the default operation
name I don't think this should happen for 1.2, for now adding it as an alias is...

dbfd89dd 01/21/2008 06:28 pm Guido Trotter

Add the first command alias

Alias activate_block_devs to activate-disks, for ganeti 1.1 compatibility.

Reviewed-by: iustinp

de47cf8f 01/21/2008 06:28 pm Guido Trotter

Add support for command aliases

Passing a new aliases dict to generic main we can easily support aliases for
compatibility reasons or simply useability.

Reviewed-by: iustinp

6e5e91a1 01/21/2008 06:18 pm Guido Trotter

Add tool to ease testing of unsubmitted patches

The upload tool can be used to submit the current code to an arbitrary list of
nodes. This helps developers in easily testing their changes before submitting
them.

Reviewed-by: iustinp

461f0538 01/21/2008 06:17 pm Guido Trotter

Check that we have a valid export list

Before iterating over the list of exports present on a node, check that what
ganeti returned is actually a list. This solves the case when one of the nodes
is down, and an error value is returned.

This fixes issue 21...

d87ae7d2 01/21/2008 04:33 pm Iustin Pop

Fix VG listing broken by r510

LVM code sometimes adds an extra separator at the end of the field list.
Make the code strip it if exists.

Reviewed-by: imsnah

f4d377e7 01/21/2008 12:13 am Iustin Pop

Make backend._GetVGInfo check the validity of 'vgs'

Currently, the function backend._GetVGInfo only checks for errors via
the exit code of the 'vgs' command. However, there are other ways of
failure so we need to also check for valid output before parsing....

8d75db10 01/21/2008 12:12 am Iustin Pop

Fix checking of node free disk in CreateInstance

This patch does two things:
- checks that the result values from call_node_info are valid integer
values and aborts otherwise
- skips disk space computation for the DT_DISKLESS case

The most important point of the patch is the verification of results...

d4f16fd9 01/21/2008 12:12 am Iustin Pop

Abstract node memory checking into a separate function

The checking of a node's free memory (via rpc.call_node_info) is done in
both start instance an failover. This patch abstracts this call,
together with the appropriate error handling, into a separate function...

97628462 01/21/2008 12:09 am Iustin Pop

Change a hardcoded path into its proper constant

The function backend.UploadFile still uses "/etc/hosts" directly instead
of the existing constant; this patch fixes this.

Reviewed-by: ultrotter

bd249e2f 01/21/2008 12:07 am Iustin Pop

Allow use of 'diskless' disk template in burnin

Even if this doesn't have any practical use for actually creating
instances, it can be used for very fast burnin and testing just the
add/start/stop/remove functionality.

This has also revealed a bug in export/import related to diskless...

1ed70996 01/21/2008 12:02 am Iustin Pop

Fix run directory for the fake hypervisor

Currently the fake hypervisor has hardcoded ‘/var/run’ as a base
directory for its store. This patch adds a constant RUN_DIR that is used
for both the fake hypervisor and for BDEV_CACHE_DIR.

Reviewed-by: ultrotter

e71d6323 01/20/2008 03:55 pm Iustin Pop

Fix the init.d script

The script (which is geared towards Debian) is actually not fully
compliant, as lintian generates a warning on it - the S runlevel is not
a valid one in the "Stop" stanza. This patch removes "S" from the stop
list.

Reviewed-by: imsnah

b6f2e47f 01/18/2008 06:07 pm Iustin Pop

Fix the make dist rule

In revision 459 I added a bug in the make dist rule in the sense that
the archive will include all of test/data directory, including the
.svn directory if it exists.

This patch fixes that problem and adds a distcheck hook that tests for...

31b9055c 01/18/2008 05:19 pm Iustin Pop

Bump version numbers for the 1.2.1 release

This a merge to trunk of revision 494.

Reviewed-by: imsnah

8ae6bb54 01/16/2008 06:01 pm Iustin Pop

Show the HVM boot order in instance info

This is a merge from the 1.2 branch

Reviewed-by: imsnah

147af04d 01/16/2008 06:01 pm Iustin Pop

Two small style fixes

This is a merge from the 1.2 branch

Reviewed-by: imsnah

d4844f0f 01/14/2008 06:03 pm Guido Trotter

Make instance start/stop skippable at burnin time

Even though burnin was born just to do that test it now contains a lot more
things one might try, so it makes sense to make instance start/stop optional
too.

This creates a burnin that at the bare minimum tests instance create and...

bd5e77f9 01/14/2008 06:01 pm Guido Trotter

Do instance export and import during burnin

Instances get exported to a remote node, then removed and imported back to
their original nodes. This should be an idempotent option from the instance
point of view, and help making sure ImportExport is kept up to date....

4aa036ab 01/14/2008 05:11 pm Iustin Pop

Allow burnin to take "-t plain" as an option

The burnin code deals with "-t plain", but the command line parser
doesn't allow that as an option. This patch fixes this issue.

Reviewed-by: ultrotter

ba4b62cf 01/14/2008 05:10 pm Iustin Pop

Fix some misspellings

This patch fixes two name typos and a style issue (which makes pylint
complain).

Reviewed-by: ultrotter

40ed12dd 01/14/2008 04:19 pm Guido Trotter

Fix CreateInstance new optional parameters

Some new paramenters of the CreateInstance opcode are optional (namely
kernel_path, initrd_path and hvm_boot_order) but their absence makes the code
crash. Fix this by initializing them to a default value if they're not present....

c19dfc03 01/14/2008 02:22 pm Guido Trotter

Add mac="auto" at import time

Mac is now a mandatory option for OpCreateInstance. Add it when we call this
opcode at import time too. This is a quick fix for the code, but probably more
work needs to be done to integrate mac addresses with the import/export...

25c5878d 01/11/2008 02:13 pm Alexander Schreiber

Support selecting the boot device order for HVM.

This patch adds support for specifying and changing the boot device order for
HVM instances. The boot device order specification is ignored for non HVM
instances.

Reviewed-by: iustinp

c234fe4c 01/10/2008 01:42 pm Guido Trotter

Complete --node description for gnt-backup(8)

The second paramenter of --node was not described in gnt-backup. Add
information about it.

Reviewed-by: imsnah

88269100 01/10/2008 01:42 pm Guido Trotter

Update gnt-backup(8) -m option explanation

Copy it from gnt-instance(8) for uniformity

Reviewed-by: imsnah

1e808cbf 01/10/2008 01:41 pm Guido Trotter

Add the --swap-size option gnt-backup(8)

Reviewed-by: imsnah

7dccfd68 01/10/2008 01:41 pm Guido Trotter

gnt-backup import doesn't allow to chose the os

Since it's an import the os is implied to be the one which performed the
export. No -o option is accepted. Reflect this in the manpage.

Reviewed-by: imsnah

d5687e89 01/10/2008 01:41 pm Guido Trotter

Fix gnt-backup import -s option

Update gnt-backup import to be in line with gnt-instance add about the os disk
size option. Thanks to Gunnar Wagenknecht for spotting the issue.

Reviewed-by: imsnah

0d9c53bc 01/09/2008 03:02 pm Alexander Schreiber

Add boot_order entry to Instance object.

First step to support custom boot device order for HVM instances, add a
location to actually store that information for the instance.

Reviewed-by: iustinp

4501af56 01/08/2008 06:16 pm Iustin Pop

Add the new OpCreateInstance parameters to burnin

Reviewed-by: schreiberal

8cafeb26 01/08/2008 06:16 pm Iustin Pop

Fix gnt-instance modify breakage introduced in r462

Reviewed-by: schreiberal

00f98619 01/08/2008 01:04 pm Iustin Pop

Update manpages with the kernel/initrd options

This patch modifes the ‘gnt-instance’ instance manpage with the new
‘--kernel’ and ‘--initrd’ options.

Reviewed-by: imsnah