Statistics
| Branch: | Tag: | Revision:

root @ daa79414

# Date Author Comment
daa79414 12/17/2012 01:38 pm Iustin Pop

Introduce NFData instances for JSON types

The JSValue/JSObject types don't come with a NFData instance, so let's
add one ourselves, so that we can force evaluation of JSValues (either
when building or when reading them).

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

77d43564 12/17/2012 01:38 pm Iustin Pop

Fix parsing of absolute job dependencies

It seems that Python code generates (sometimes) absolute job
dependencies which are strings, instead of integers, so we should be
able to parse these as well. We simply change from explicit int-based
parsing (makeJobId) to the generic one (parseJobId)....

1496f5f3 12/17/2012 01:38 pm Iustin Pop

Make two common opcode parameters always serialised

This changes deps and comment fields to always be shown, to match the
Python behaviour for (at least) job listing/ops field.

Signed-off-by: Iustin Pop <>
Reviewed-by: Helga Velroyen <>

88127c47 12/17/2012 01:38 pm Iustin Pop

Fix disk_template OpInstSetParams parameter

This is not a required field, but rather an optional one; we add a new
parameter and use it instead.

Signed-off-by: Iustin Pop <>
Reviewed-by: Helga Velroyen <>

d2970809 12/17/2012 01:38 pm Iustin Pop

Support 'null' in Luxi QueryJobs names field

Python code sometimes sends this, so let's support it even though it's
non-standard.

Signed-off-by: Iustin Pop <>
Reviewed-by: Helga Velroyen <>

fd958a3d 12/17/2012 01:38 pm Iustin Pop

Abstract code related to job ID creation

Having makeJobIdS as a separate function will allow us to use it
outside of json encoding.

The patch also exports one more function from the Types module.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michele Tartara <>

4355b2de 12/17/2012 01:37 pm Iustin Pop

Add new Haskell library dependency for tests

The 'temporary' library add support for create temporary
directories/files beyond what is offered in the base library (which is
somewhat limited, and hard to use in tests).

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

a664325e 12/17/2012 01:37 pm Iustin Pop

Reduce logging level in tests

This allows tests to execute IO actions which have logging as a side
effect, without polluting the stderr too much.

A better solution would be that we have fine-grained control over
loggers, so that tests can run with their own logging, etc. etc.....

55438c07 12/17/2012 01:37 pm Iustin Pop

Export jstore constants as well to Constants.hs

This single constant could be as well moved to constants.py. For now I
choose to just export the module as well.

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

df8578fb 12/17/2012 01:37 pm Iustin Pop

Generalise the test helper 'genUniquesList'

Instead of always using "arbitrary", make it require a generator (that
can then use more complex rules for building the list elements), and
also convert it to use a temporary set instead of list membership.

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

1db32048 12/17/2012 01:37 pm Iustin Pop

Export more paths from Path.hs

Also adds a small helper for building the paths.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michele Tartara <>

a1d137f6 12/17/2012 01:29 pm Iustin Pop

Simplify a bit the FilterRegex JSON instance

Signed-off-by: Iustin Pop <>
Reviewed-by: Helga Velroyen <>

ad1c1e41 12/17/2012 01:29 pm Iustin Pop

Implement opcode summary support

This implements in the Haskell codebase the opcode summary. As opposed
to Python, we always use custom code for formatting, since we don't
want to use dynamic attribute lookup.

To test this properly, we need to change MetaOpCode to record-syntax,...

8bc17ebb 12/17/2012 01:29 pm Iustin Pop

Add optional formatting for OP_DSC_FIELD

For some opcodes, the output is not "stable", and depends on the exact
input values; this makes it harder to check consistency against
Haskell code.

To compensate for this, we add a way to override the formatting of the...

5cd95d46 12/17/2012 01:29 pm Iustin Pop

Add a type for the log type in job/opcode logs

Also fixes indentation for OP_STATUS.

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

60f20a41 12/17/2012 01:29 pm Iustin Pop

Fix small typo in OpTestDelay/duration definition

The extra space results in inaccessible names; currently GHC doesn't
flag this as an error, but I've filled an upstream bug for that
(http://hackage.haskell.org/trac/ghc/ticket/7484).

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

9d3867b1 12/14/2012 04:55 pm Iustin Pop

Add constants for two values which we re-evaluate

Two constants which we use as Integer are defined as Int in
Constants.hs (coming from constants.py), so we do the conversion every
time we use it. Let's move them to top-level names, so that the
conversion is only done once....

5448799c 12/14/2012 04:55 pm Iustin Pop

Fix an small but quite nasty typo

Introduced in commit d4752785.

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

d0054203 12/14/2012 04:44 pm Guido Trotter

update gnt-instance manpage about self-rename

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

9fdc92fa 12/14/2012 04:43 pm Guido Trotter

burnin: rename instances to same name

this (a) allows us to test renaming in burnin even if we don't have an
extra instance name and (b) is a valid operation, as it allows to "fix"
an instance who went name-astray

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

57fb6fcb 12/14/2012 04:28 pm Guido Trotter

Very very very basic openvswitch support

This is a "better than nothing" support, just for kvm and just joining
the machine to the opevswitch bridge with the right command.

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

d6b5da24 12/14/2012 03:11 pm Guido Trotter

Add profiling dependencies note

As discussed on the list, these are needed to do a make hs-prof.

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

f127e585 12/14/2012 03:11 pm Guido Trotter

remove duplicate code in Graph.hs

Also update the docstring of a function.

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

cce30754 12/14/2012 03:11 pm Guido Trotter

Improve a few Graph test properties

Return type is changed from Property to Bool, and the ==? True at the
end is dropped.

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

f74b88fa 12/13/2012 07:47 pm Iustin Pop

Log only partial response in Luxi when in debug mode

Currently, we log the entire response (at debug level) in the Luxi
replies. This is not a good idea; the logging library operates on
strings, and as such it will use huge amounts of memory: without debug...

e21c2eec 12/13/2012 07:16 pm Constantinos Venetsanopoulos

Pass check_ip and not hostname.ip to _ComputeNics

This should be done because in the case of --no-name-check there
is no 'hostname.ip' attribute, causing an execution error.
'check_ip' is always set (in CheckArguments) even if --no-name-check
is passed in the command line....

924d9134 12/13/2012 05:35 pm Michael Hanselmann

Add version check for doc/design-draft.rst

This is similar to README or “doc/security.rst”. Having a comment that
needs updating for a new version is more likely going to trigger a check
of the lists of design drafts.

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

a5b0694f 12/13/2012 05:35 pm Michael Hanselmann

Makefile/check-local: List all errors before failing

Use the “error” variable in multiple places and fail only once all tests
have been completed.

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

98a83f17 12/13/2012 04:55 pm Michael Hanselmann

Move four designs from draft to 2.7

These are the ones I implemented and for which I'm certain they're
complete.

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

f1d243bd 12/13/2012 04:52 pm Michael Hanselmann

RAPI documentation fix and update

- Mention user capabilities in security.rst
- Replace “query” with “read” in RAPI documentation

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

542e3dea 12/13/2012 02:30 pm Michele Tartara

Add hpc-mon-collector to .gitignore

It is a binary file and it should never be added to the git repository.

Signed-off-by: Michele Tartara <>
Reviewed-by: Iustin Pop <>

ec5af888 12/13/2012 01:29 pm Michael Hanselmann

Read watcher pause using RPC, not directly

The master daemon should not directly read files written by the node
daemon. This patch adds a new RPC to read the watcher pause file and
changes the master code to use it.

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

7c4bd156 12/13/2012 01:29 pm Michael Hanselmann

Set watcher pause on all nodes

Instead of just setting the watcher pause file, which isn't replicated,
RPC is used to set it on all nodes (where possible). This means that
after an outage of the master node and a following master-failover, the
watcher will still be paused....

99e222b1 12/13/2012 01:29 pm Michael Hanselmann

Add RPC for setting watcher pause

The watcher pause file should be set/unset on all nodes at once, not
only the master node. For that a new RPC is needed.

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

f2bca93e 12/13/2012 01:28 pm Michael Hanselmann

Generated RPC code: Don't write whitespace after paren

There is no obvious need for this space--the line would wrap at the next
space, which comes soon after.

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

6ec28bc6 12/13/2012 01:28 pm Michael Hanselmann

Rename test for backend._CommonRestrictedCmdCheck

“TestWriteFile” was not renamed when adding the file based on
“ganeti.utils.io_unittest-runasroot.py”.

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

383477e9 12/13/2012 01:27 pm Michael Hanselmann

jqueue: Improve inotify error reporting

This addresses issue 218. When the number of inotify watches is
exhausted, for example by being set too low from the beginning or by
other programs, waiting for a job to change would just report a lost job
(e.g. “Error checking job status: Job with id 7817 lost”)....

e37f47d3 12/13/2012 01:27 pm Michael Hanselmann

Improve test for tools.ensure_dirs

- Add more checks, some of them are deliberately redundant
- Descriptive error messages
- Add comment describing order to “tools.ensure_dirs”
- Avoid copying a list in an assertion in “tools.ensure_dirs”

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

164947cc 12/12/2012 05:54 pm Dato Simó

Jobs.hs: make L.Client the last argument for all functions

Having the Luxi client be the last argument of the functions allows for
easier use with `Exception.bracket L.getClient L.closeClient ...`.

Signed-off-by: Dato Simó <>
Reviewed-by: Iustin Pop <>

5f2cdb2a 12/12/2012 05:06 pm Michele Tartara

Fix a bug in the hs-coverage rule of Makefile.am

The coverage information for mon-collector was not merged correctly.

Signed-off-by: Michele Tartara <>
Reviewed-by: Iustin Pop <>

23f1bf29 12/12/2012 03:25 pm Michael Hanselmann

uidpool: Remove roman number support

Doing so simplifies to code a bit and never had a practical use.

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

3e3ddbf0 12/12/2012 03:18 pm Constantinos Venetsanopoulos

Remove checks wrt IDISK_PARAMS from OpCode level

Change the "--disks" option validation, to just check the format
of the dict and do not check whether the keys are included in the
IDISK_PARAMS constant at OpCode level. This allows the passing of
arbitrary parameters at the CLI, which will then be logically...

cefd4a4a 12/12/2012 02:09 pm Michele Tartara

Add shelltests for the mon-collector

This commit adds shelltests for the mon-collector binary and for the DRBD
data collector.

Also, it fixes a small bug in the DRBD parser found thanks to the tests.

Signed-off-by: Michele Tartara <>...

332b1340 12/12/2012 02:09 pm Michele Tartara

Add the stand-alone data collector for DRBD

It is implemented as a single binary receiving, as its first parameter,
the name of the actual data collector to be run.
This way, its structure can be used for all the future data collectors.

Also, factored out of bdev.py into constants.py the location of the DRBD...

61e062dd 12/12/2012 02:08 pm Michele Tartara

Move the path of the DRBD status file to the Constants file

It will be needed by the DRBD data collector, that will be added shortly.

Signed-off-by: Michele Tartara <>
Reviewed-by: Iustin Pop <>

432d62a8 12/12/2012 01:43 pm Helga Velroyen

Make configure check for haskell vector library

Signed-off-by: Helga Velroyen <>
Reviewed-by: Michele Tartara <>

405656b7 12/12/2012 11:20 am Helga Velroyen

Remove usage of reserved key word 'family'

An old hlint version (1.8.28) was complaining about the
word 'family' being used in the network tests. Thanks to
an epiphany of Iustin this was due to that it is a reserved
key word.

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

fcc1977b 12/12/2012 10:43 am Helga Velroyen

Add documentation about new dependency to vector lib

Updates the INSTALL file to add the haskell library
libghc-vector-dev.

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

76a0266e 12/11/2012 05:18 pm Helga Velroyen

Network and address pool (again)

Implementation of the network objects and address pool. Functionality
as in the reverted commit b9a616e132af9bba718d2da8c94eeec7af886814, but
now using only the vector library and not the bit-vector library.
Tested with vector library version 0.9 and 0.10., which are...

9eac61f8 12/11/2012 04:53 pm Michael Hanselmann

Fix ordering of entries in tools.ensure_dirs

Commit ebd437a added two new entries to tools.ensure_dirs, but did so in
the wrong order. Patch forthcoming to improve the unittest's error
message.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>

ebd437a4 12/11/2012 04:31 pm Michael Hanselmann

Set owner on watcher pause and queue drain files

If the files were created by a user different, e.g. due to a switch from
running masterd as root to running it as a dedicated user, they couldn't
be modified/removed anymore.

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

af8f2fbf 12/11/2012 04:31 pm Michael Hanselmann

lib/tools/ensure_dirs.py: Code formatting

Wrap lines in a consistent manner (uid/gid on the second line) if
wrapping is necessary at all. “git diff --color-words” shows no
difference at all as only whitespace changed.

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

be6c403e 12/11/2012 03:37 pm Michael Hanselmann

Replicate queue drain flag across all master candidates

Until now, the flag was unset on a master failover unless the
“$localstatedir/lib/ganeti/queue/drain” file existed.

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

4a3dd52d 12/11/2012 01:01 pm Michael Hanselmann

Add utility function to create frozenset with unique values

When used instead of a plain call to “frozenset”, this would have
avoided the issue fixed in commit e2dd6ec. The new function is located
in the “compat” module as it will be used at module load time in most...

af54b7d7 12/11/2012 01:01 pm Michael Hanselmann

constants: Remove duplicate DRBD barrier option

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

d4e297b8 12/10/2012 07:02 pm Michael Hanselmann

doc/rapi.rst: Add ECODE_TEMP_NORES

The assertion was failing as ECODE_TEMP_NORES was not documented.

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

e2dd6ece 12/10/2012 06:03 pm Michael Hanselmann

Change value for ECODE_TEMP_NORES

Unfortunately there was a bug in commit 518a45e whereby ECODE_TEMP_NORES
had the same value as ECODE_NORES, leading to failures in a Haskell
test. Of course this would also have affected other users of the constant.

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

94811696 12/10/2012 05:53 pm Michael Hanselmann

Make htools/Ganeti/Constants.hs depend on errors.py

It also uses values from “lib/errors.py”.

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

78fcfd43 12/10/2012 04:47 pm Michael Hanselmann

masterd: Remove duplicate code

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>

7fb5ac7c 12/10/2012 04:23 pm Michael Hanselmann

Improve error message for when adding inotify watcher fails

Explicitely mention the fs.inotify.max_user_watches sysctl value.

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

6bee863c 12/10/2012 04:23 pm Michael Hanselmann

htools/Ganeti/Errors: Add ECodeTempNoRes

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

be505f2c 12/10/2012 03:34 pm Michael Hanselmann

Update pyinotify website

It has moved to github.com.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>

bccb8d20 12/07/2012 05:43 pm Dato Simó

htest/Types.hs: check ordering of some ADTs

In some ADT, ordering of constructors is important because a certain
meaning is attached to ordinality (e.g., "clusters with lesser AllocPolicy
are preferred").

To ensure constructor order is not accidentally changed, this commit...

c298ed02 12/07/2012 03:24 pm Michael Hanselmann

htools: Add missing parameter to OpInstanceMultiAlloc

Somehow this went missing in commit 1f1188c.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Michele Tartara <>

518a45e5 12/07/2012 02:47 pm Michael Hanselmann

Add error code for temporary lack of resources

When an instance creation uses opportunistic locks, the iallocator might
not be able to find an allocation solution if not enough node locks (or
a suboptimal subset thereof) were acquired. As per the design document...

bc826292 12/07/2012 02:47 pm Michael Hanselmann

Export error codes from RAPI client module

Until now the error codes were not available from the RAPI client
module. A newly added unit test ensures all error codes are contained in
“ECODE_ALL”, as well as ensuring consistency between the RAPI client and...

78bfb560 12/07/2012 02:45 pm Michael Hanselmann

cmdlib: Use locked nodes as node whitelist

Also actually start using opportunistic locks (if requested).

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

1f1188c3 12/07/2012 02:36 pm Michael Hanselmann

cmdlib: Opportunistic locking on instance creation

Adds a new parameter to “OpInstanceCreate” and “OpInstanceMultiAlloc” to
use opportunistic locks.

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

b3c728dc 12/07/2012 02:36 pm Michael Hanselmann

cmdlib: Node whitelist support for allocation request

Forward the node whitelist to the iallocator plugin.

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

e9a81214 12/07/2012 02:35 pm Michael Hanselmann

mcpu: Verify node allocation lock mode

Add verification code to mcpu to check an LU's locks. Two whitelists are
provided to exclude LUs from the two tests.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Bernardo Dal Seno <>

ba6eda59 12/07/2012 02:35 pm Michael Hanselmann

_ExportQuery: Use node allocation lock

Block instance allocations when all node locks will be acquired.

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

38446261 12/07/2012 02:35 pm Michael Hanselmann

LUBackupExport: Use node allocation lock

Block instance allocations when all node locks will be acquired.

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

dc7d923e 12/07/2012 02:35 pm Michael Hanselmann

LUBackupRemove: Use node allocation lock

Block instance allocations when all node locks will be acquired.

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

5df1c9aa 12/07/2012 02:32 pm Michael Hanselmann

LUInstanceMultiAlloc: Use node allocation lock

Avoid conflicts between instance allocations.

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

32bea623 12/07/2012 02:32 pm Michael Hanselmann

LUInstanceRecreateDisks: Use node allocation lock

Block instance allocations when all node locks will be acquired.

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

48126102 12/07/2012 02:32 pm Michael Hanselmann

LUNodeSetParams: Use node allocation lock

Block instance allocations when all node locks will be acquired.

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

7254c0a9 12/07/2012 02:32 pm Michael Hanselmann

LUNodeQueryvols: Use node allocation lock

Block instance allocations when all node locks will be acquired.

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

cfae7671 12/07/2012 02:32 pm Michael Hanselmann

LUOobCommand: Use node allocation lock

If no node names are given, all node locks are acquired.

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

63e166a5 12/07/2012 12:40 pm Michele Tartara

Fix typo in comment

There was a typo in the docstring of the parseMessage function of the
confd server.

Signed-off-by: Michele Tartara <>
Reviewed-by: Michael Hanselmann <>

fa23de0b 12/07/2012 11:45 am Helga Velroyen

Revert "Network and address pool"

This reverts commit b9a616e132af9bba718d2da8c94eeec7af886814, which
depends on the "bitvec" library. We need to investigate a bit further that
dependency, as it in turns depends on "vector" 0.9.1 or below, since
0.10.* removed support for Data.Vector.Unboxed.Safe which it uses....

b9a616e1 12/06/2012 07:13 pm Helga Velroyen

Network and address pool

Implementation of the network and address pool class in
Haskell. Not complete yet. Includes unit tests that cover
all functionality that is so far implemented.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Iustin Pop <>

e712e5b8 12/06/2012 06:19 pm Michael Hanselmann

Fix node-daemon-setup test with older pyOpenSSL

Older versions use “-----BEGIN RSA PRIVATE KEY-----” instead of
“-----BEGIN PRIVATE KEY-----”.

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

d5fe5fa9 12/06/2012 05:07 pm Michael Hanselmann

Add tool to clean up node

Sometimes a node is not removed properly from a cluster (especially
during development). This new tool stops all daemons and removes (after
making copies) the most critical files.

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

69e5fefc 12/06/2012 04:07 pm Michael Hanselmann

Add tool to configure node daemon

The design for this is in “doc/design-node-add.rst”. The tool receives a
JSON data structure on stdin and configures the node's daemon after
verifying the received values.

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

7b8ba235 12/06/2012 04:07 pm Michael Hanselmann

Switch from scp/ssh to node daemon setup utility

This patch does away with many calls to scp and by means of using
“tools/node-daemon-setup”, verifies most of the values before writing
them to files.

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

4c49b965 12/06/2012 02:29 pm Guido Trotter

make genMaybe more Just

There is a common conception that Just something is more worth than
Nothing. So we're biasing our tests towards that. As such let's generate
Nothing fewer times, and Just subgen more times. The values were copied
from the "official" maybe generator....

f22433c0 12/06/2012 01:37 pm Dimitris Aragiorgis

Locking related fixes for networks

Use GetNetwork() only when having already aquired the lock,
i.e. in CheckPrereq().

In LUNetworkConnect/Disconnect do not include Network info in Hooks
environment, so that network locking can be avoided if conflicts
are not checked....

3516b09a 12/06/2012 11:15 am Iustin Pop

Fix build breakage in Jobs.hs test code

Commit 3bdbe4b3 (“Jobs.hs: move OpStatus and JobStatus ADTs to
Types.hs”) removed the TemplateHaskell language pragma from
htest/Test/Ganeti/Jobs.hs due to a hlint warning, but that is bad: it
means the testSuite call is no longer interpreted as a splice, so it results in:...

7b22f99c 12/05/2012 09:04 pm Dato Simó

configure.ac: fix reading of HLINT environment variable

configure.ac advertised that the HLINT environment variable could be set to
specify the path to the 'hlint' tool. However, HLINT was being initialized
to "no" inside configure.ac, which broke this usage....

369671f4 12/05/2012 09:04 pm Dato Simó

Hbal.hs: move job execution functions to Jobs.hs

Ganeti.Jobs now holds functions that can be used to submit and monitor the
status of jobs. In particular, execJobsWait and waitForJobs are factored
out of Hbal.hs.

Signed-off-by: Dato Simó <>...

42afc235 12/05/2012 09:04 pm Dato Simó

Hbal.hs: use Result (), not Bool, as return value for exec*

Previously, functions in Hbal.hs related to execution of jobsets were
returning only IO Bool, and printing any errors they found directly to
stderr on their own.

I'm going to be moving some of these functions to a library module in...

3b23f238 12/05/2012 09:04 pm Dato Simó

Hbal.hs: rename functions that deal with early termination

In Hbal.hs, it's easy to get lost in the flow of exec* functions
because their names are similar and don't convey their different
purposes (e.g. runJobSet, execJobSet, execWrapper).

This patch renames 'runJobSet' to 'execWithCancel', and 'execWrapper'...

9cd4288e 12/05/2012 09:03 pm Dato Simó

Hbal.hs: fix typo in signal handler names (hangle -> handle)

'hangleSigInt' and 'hangleSigTerm' are renamed to 'handleSigInt' and
'handleSigTerm', respectively.

Signed-off-by: Dato Simó <>
Reviewed-by: Michele Tartara <>

3bdbe4b3 12/05/2012 09:03 pm Dato Simó

Jobs.hs: move OpStatus and JobStatus ADTs to Types.hs

This leaves Ganeti/Jobs.hs and Test/Ganeti/Jobs.hs empty, but they're the
target of a future move of some functions, so we leave them around, and
don't delete them, to avoid unnecessary delete/create diffs....

de645b5b 12/05/2012 07:05 pm Michael Hanselmann

Makefile: Reset environment for epydoc

epydoc allows overriding configuration values via environment variables.
While this might be useful in certain use cases, but as no prefix
whatsoever is used, conflicts are easily created. Some people have the
environment variable “NAME” set, effectively overriding the project name...

3c631ea2 12/05/2012 05:35 pm Michael Hanselmann

jqueue: Don't modify input opcode when changing priority

Commit 4679547 implemented the ability to change job's priority after it
was submitted. The code contained a bug whereby it would modify the
input data for an opcode, something the job queue shouldn't do (logical...

ca519248 12/05/2012 05:04 pm Dimitris Aragiorgis

Use new util function for mac_prefix validation

Use new NormalizeAndValidateThreeOctetMacPrefix() util function in
LUNetworkAdd/LUNetworkSetParams to validate network's MAC prefix.
Additionally, move the check in CheckArguments() in the case of
LUNetworkAdd....

26e88cde 12/05/2012 01:00 pm Michael Hanselmann

LUClusterRedistConf: Use node allocation lock

All node locks are acquired.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>

9cbfc69a 12/05/2012 01:00 pm Michael Hanselmann

LUClusterRepairDiskSizes: Use node allocation lock

This opcode acquires all node resource locks, which conflicts with
instance allocations.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>

51305499 12/05/2012 01:00 pm Michael Hanselmann

LUGroupVerifyDisks: Use node allocation lock

See comment in code.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Helga Velroyen <>