ganeti-local
11 years agoAdd constants for storage types to constants.py
Helga Velroyen [Wed, 13 Mar 2013 12:21:41 +0000 (13:21 +0100)]
Add constants for storage types to constants.py

This patch adds the currently known and used storage methods to the
constants.py file. Note that storage types are different from disk
templates. For example both disk templates, drbd and plain, use lvm
storage types.

The rapi documentation asserts that valid storage types are limited
to lvm and file. With the extension of storage types, this is not true
anymore, but the implementation of listing storage units is not
implemented for the new types. We disable the assert for now, adding
a fixme to extend it once the listing of storage units is extended
for the new types as well.

'gnt-node list-storage' currently does not support any other storage
type than 'lvm' and 'file'. We limit the QA to storage types that are
currently implemented for this operation.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix Mond man page
Michele Tartara [Thu, 21 Mar 2013 11:18:26 +0000 (12:18 +0100)]
Fix Mond man page

Remove some erroneous formatting from the Mond man page.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoAdd monitoring HTTP API structure
Michele Tartara [Thu, 7 Mar 2013 15:36:48 +0000 (15:36 +0000)]
Add monitoring HTTP API structure

Add all the supported commands to the API.
The actual response is still to be implemented.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAdd basic HTTP server functionalities to Mond
Michele Tartara [Fri, 8 Mar 2013 18:27:06 +0000 (18:27 +0000)]
Add basic HTTP server functionalities to Mond

Add a stub implementation of the Mond HTTP server to Mond using the Haskell
snap-server library.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoUpdate documentation for monitoring daemon
Michele Tartara [Fri, 8 Mar 2013 18:35:41 +0000 (19:35 +0100)]
Update documentation for monitoring daemon

This commit updates the installation instructions and the user guide.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoMerge branch 'devel-2.7'
Bernardo Dal Seno [Thu, 21 Mar 2013 09:42:16 +0000 (10:42 +0100)]
Merge branch 'devel-2.7'

* devel-2.7
  cfgupgrade: Fix error messages
  Update "FIXME" string in RAPI
  rapi client: add target_node to migrate instance
  Make diskless instances externally mirrored
  Fix migrate/failover -n for ext mirror storage

Trivial merge: no conflicts

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoAdd the core of the monitoring daemon
Michele Tartara [Wed, 20 Feb 2013 10:39:17 +0000 (11:39 +0100)]
Add the core of the monitoring daemon

This commit adds the core infrastructure of the monitoring daemon,
and integrates it in the build and test systems.

The actual functionality of the monitoring daemon is still completely
missing.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agocfgupgrade: Fix error messages
Bernardo Dal Seno [Wed, 20 Mar 2013 13:24:49 +0000 (14:24 +0100)]
cfgupgrade: Fix error messages

Messages were inconsistent. You could get both an error and a message
saying that everything was fine.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoUpdate "FIXME" string in RAPI
Michele Tartara [Wed, 20 Mar 2013 11:16:47 +0000 (12:16 +0100)]
Update "FIXME" string in RAPI

We are not ready for this change yet. Let's push it to 2.8.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoTypo 'repot' in Server.hs
Helga Velroyen [Wed, 20 Mar 2013 10:42:48 +0000 (11:42 +0100)]
Typo 'repot' in Server.hs

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoFix typo 'VolumeN' in bdev.py
Helga Velroyen [Wed, 20 Mar 2013 10:22:57 +0000 (11:22 +0100)]
Fix typo 'VolumeN' in bdev.py

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoAdd design document for the "reason trail"
Michele Tartara [Mon, 11 Mar 2013 14:43:57 +0000 (15:43 +0100)]
Add design document for the "reason trail"

This commit adds the design document for introducing "reason trails",
tracing the reason why opcodes are executed, step by step.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAdd Mond to the list of possible daemons
Michele Tartara [Fri, 8 Mar 2013 17:28:10 +0000 (17:28 +0000)]
Add Mond to the list of possible daemons

Also, add its logfiles and extra log files.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoAdd infrastructure for allowing additional logfiles
Michele Tartara [Fri, 8 Mar 2013 14:41:38 +0000 (14:41 +0000)]
Add infrastructure for allowing additional logfiles

Some daemons will need more than the single logfile that is currently
allowed. This patch introduces the infrastructure to allow this.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoAdd user and group for the monitoring agent
Michele Tartara [Thu, 21 Feb 2013 16:25:36 +0000 (16:25 +0000)]
Add user and group for the monitoring agent

This commit adds the user and group variables for the monitoring agent in all
the configuration files where they are required.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agorapi client: add target_node to migrate instance
Daniel Krambrock [Tue, 12 Mar 2013 17:17:24 +0000 (18:17 +0100)]
rapi client: add target_node to migrate instance

This allows migrating to any node, as it is already possible for
failover, when instances are externally mirrored.

Signed-off-by: Daniel Krambrock <danielk_lists@z9d.de>
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoMake diskless instances externally mirrored
Guido Trotter [Tue, 12 Mar 2013 15:07:04 +0000 (16:07 +0100)]
Make diskless instances externally mirrored

This addresses Issue 237.

Mirroring no disk is a no-op. As such we can treat them like mirrored
instances, since the data they need (none) will be present on all nodes.

This is definitely enough to failover or migrate instances with a manual
target node. Further work might be needed for support in hail.

Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoFix migrate/failover -n for ext mirror storage
Guido Trotter [Tue, 12 Mar 2013 15:24:44 +0000 (16:24 +0100)]
Fix migrate/failover -n for ext mirror storage

This fixes issue 396.

- Fix a wrong comment that mentions drbd8 when actually the code acts
  only on externally mirrored instances.
- Fix a wrong assert that requires failover/migrate to acquire the NAL
  on externally mirrored instances: this is the case only when a
  iallocator is used, not if a node is manually specified.

Extra qa should be added, but this can only be done if an externally
mirrored instance or a diskless instance is tested. It is easier to add
it on the master branch, where we have diskless instances support.

Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoAdd a simple tool for checking split-query equivalence
Iustin Pop [Mon, 11 Mar 2013 14:44:17 +0000 (15:44 +0100)]
Add a simple tool for checking split-query equivalence

This is not run automatically (although it could/should), but is very
useful during development.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoEnable split queries for the network
Iustin Pop [Mon, 11 Mar 2013 11:53:36 +0000 (12:53 +0100)]
Enable split queries for the network

Now that all fields are implemented, and (I think) behave equivalent
to the Python implementation, we can switch on the split queries for
networks.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoAdd missing external_reservations query field in confd
Iustin Pop [Mon, 11 Mar 2013 11:52:16 +0000 (12:52 +0100)]
Add missing external_reservations query field in confd

Based on the implemented Ip4Network/Address types, we can now compute
the (external) reservations.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoAdd simple Ip4Address/Ip4Network types
Iustin Pop [Mon, 11 Mar 2013 11:50:38 +0000 (12:50 +0100)]
Add simple Ip4Address/Ip4Network types

This patch adds some very simple IPv4 address/network types, and uses
them in the 'Network' config object.

We need these in order to properly compute the reserved IP addresses,
without depending on an external library (which I haven't found, by
the way). Currently the only operation supported is 'get next IP
address', which is enough for us.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoChange to CamelCase format in Test/Ganeti/Objects.hs
Iustin Pop [Mon, 11 Mar 2013 14:37:15 +0000 (15:37 +0100)]
Change to CamelCase format in Test/Ganeti/Objects.hs

This is in preparation for using OverloadedString extensions in this
file, which conflicts with hlint 1.8.28's handling of annotations.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoExpand TestHelper to allow non-underscore prefixes
Iustin Pop [Mon, 11 Mar 2013 14:34:59 +0000 (15:34 +0100)]
Expand TestHelper to allow non-underscore prefixes

HLint 1.8.28 requires us to always add "ignore CamelCase", which can
be problematic sometimes (e.g. when using OverloadedStrings). Let's
expand TestHelper to also support less-standard 'caseFooBar' names, so
that we can remove the annotations.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoA few style fixes in Ganeti.Network
Iustin Pop [Mon, 11 Mar 2013 11:43:00 +0000 (12:43 +0100)]
A few style fixes in Ganeti.Network

Side-effects of working on some other network-related stuff…

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoChange node disk/hv_state query in confd
Iustin Pop [Mon, 11 Mar 2013 10:26:32 +0000 (11:26 +0100)]
Change node disk/hv_state query in confd

Currently, the Python code returns either FS_UNAVAIL (if these
attributes are None) or the proper dicts. As we don't allow editing of
these attributes, in most cases they will therefore be FS_UNAVAIL on
the client.

The Haskell code however returns missingRuntime, which is FS_NODATA,
so a mismatch (that also incurs a RPC call). Fixing it is easy, and
makes the output consistent.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoSort instance list in gnt-group list -opinst_list
Iustin Pop [Mon, 11 Mar 2013 10:20:29 +0000 (11:20 +0100)]
Sort instance list in gnt-group list -opinst_list

The Python code currently sorts this, but the Haskell code not.

This should maybe have a test, but I'm not sure how far we want to
encode such properties in tests… (and the real reason I'm not adding
one is that we don't have a way to generate a random cluster _with_
instances).

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoMake gnt-node list -o(p|s)inst_list output stable
Iustin Pop [Mon, 11 Mar 2013 10:17:46 +0000 (11:17 +0100)]
Make gnt-node list -o(p|s)inst_list output stable

Currently, both the Python and Haskell code return the internal
instance list unsorted, which means the output can vary depending on
the phase of the moon (well, the Haskell code actually uses internally
a tree, sorted by the instance name, but it's implementation detail).

By adding an explicit sort step, we guarantee both stability of the
output and consistency between the two query paths.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoFix gnt-backup list -o node via confd
Iustin Pop [Mon, 11 Mar 2013 10:08:56 +0000 (11:08 +0100)]
Fix gnt-backup list -o node via confd

Currently, the 'node' field is declared as a simple config field, so
when only selecting this fields, the runtime gathering is no longer
run and it's presumed that all nodes have a backup. So the output is
not truthful (instead of just listing the nodes with at least one
export, all are listed).

By simply making it a runtime field, filtering works properly and we
get the same output as the masterd code.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoIntroduce better item getter helper in query.py
Iustin Pop [Mon, 11 Mar 2013 09:13:24 +0000 (10:13 +0100)]
Introduce better item getter helper in query.py

And also use it for simple network fields. Currently the Python
library returns jsnull, which is formatted as 'None' by the Python
client, which (IMHO) is not nice, since these fields are strings (some
of them) or "other". An undeclared gateway is easier to diagnose when
properly reported by the server as missing, rather than "existing but
null".

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoFix network query field types/names in the Haskell code
Iustin Pop [Fri, 8 Mar 2013 16:31:44 +0000 (17:31 +0100)]
Fix network query field types/names in the Haskell code

The headers/type/descriptions had some differences from the Python
code, when checked for exact equivalence.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoUpdate design doc about free space reporting
Helga Velroyen [Thu, 21 Feb 2013 10:21:46 +0000 (11:21 +0100)]
Update design doc about free space reporting

This patch updates the design doc "Design correct reporting of storage
free space". The modifications were chosen to not conflict with any
future changes of Ganeti regarding storage pools.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix QA: skip reinstall for diskless instances
Bernardo Dal Seno [Tue, 12 Mar 2013 13:11:32 +0000 (14:11 +0100)]
Fix QA: skip reinstall for diskless instances

Diskless instances cannot really be reinstalled, not even through RAPI.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoFix typo in the monitoring agent design doc
Michele Tartara [Tue, 12 Mar 2013 11:02:55 +0000 (12:02 +0100)]
Fix typo in the monitoring agent design doc

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoMerge branch 'devel-2.7'
Bernardo Dal Seno [Tue, 12 Mar 2013 11:07:11 +0000 (12:07 +0100)]
Merge branch 'devel-2.7'

* devel-2.7
  Add QA for instance creation with policy violation
  Add QA for policy-instance interactions
  Add QA for cluster policies
  Unit tests for objects.InstancePolicy + a fix
  Unit tests for objects.FillIPolicy() + small fix
  Fix upgrade of policy in objects.Cluster
  Fix instance policy checks for default back-end parameters
  Fix restoring default instance specs in group policies
  Unit tests for cmdlib._GetUpdatedIPolicy()
  Fix policy check for disk templates
  Fix merge 8e09e801 that resulted in duplicated code
  GanetiRapiClient: fix the no_remember option

Conflicts:
qa/qa_cluster.py
qa/qa_instance.py

Conflicts are due to QA config in master using objects instead of
dictionaries. Also updated some new QA code in devel for the same reason.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix style error in hconfd
Michele Tartara [Mon, 11 Mar 2013 17:11:48 +0000 (17:11 +0000)]
Fix style error in hconfd

The first line of a function should be blank, unless it is able to contain the
whole function.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAdd QA for instance creation with policy violation
Bernardo Dal Seno [Wed, 27 Feb 2013 10:47:02 +0000 (11:47 +0100)]
Add QA for instance creation with policy violation

When instance policy is violated, creation fails.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAdd QA for policy-instance interactions
Bernardo Dal Seno [Fri, 22 Feb 2013 18:07:33 +0000 (19:07 +0100)]
Add QA for policy-instance interactions

Violations on policy changes are checked.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAdd QA for cluster policies
Bernardo Dal Seno [Thu, 21 Feb 2013 17:58:20 +0000 (18:58 +0100)]
Add QA for cluster policies

qa_cluster.TestClusterSetISpecs() is exported as it will be used in future
tests.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoUnit tests for objects.InstancePolicy + a fix
Bernardo Dal Seno [Tue, 19 Feb 2013 21:13:27 +0000 (22:13 +0100)]
Unit tests for objects.InstancePolicy + a fix

Tests for:
  objects.InstancePolicy.CheckParameterSyntax()
  objects.InstancePolicy.CheckDiskTemplates()
  objects.InstancePolicy.CheckISpecSyntax()

Instance policies with an empty disk-template list now are reported.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoUnit tests for objects.FillIPolicy() + small fix
Bernardo Dal Seno [Tue, 19 Feb 2013 13:56:05 +0000 (14:56 +0100)]
Unit tests for objects.FillIPolicy() + small fix

IPOLICY_DEFAULTS is now a legal policy (the disk-templates entry was a set
instead of a list, before).

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix upgrade of policy in objects.Cluster
Bernardo Dal Seno [Wed, 27 Feb 2013 17:50:17 +0000 (18:50 +0100)]
Fix upgrade of policy in objects.Cluster

Unknown elements were silently removed on startup. This means that a
software upgrade could result in lost configuration information if
cfgupgrade wasn't run promptly.

Added unit test for Cluster.UpgradeConfig() to cover this case.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix instance policy checks for default back-end parameters
Bernardo Dal Seno [Thu, 7 Mar 2013 02:14:56 +0000 (03:14 +0100)]
Fix instance policy checks for default back-end parameters

Policy violations of back-end parameters that used the cluster default
value were not reported in cluster-verify.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix restoring default instance specs in group policies
Bernardo Dal Seno [Mon, 25 Feb 2013 13:16:40 +0000 (14:16 +0100)]
Fix restoring default instance specs in group policies

"default" was not accepted as a valid input value for instance specs in
group policies, due to a bug introduced in 2cc673a3e (and released with
2.6.0). Added QA for this and another similar case.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoUnit tests for cmdlib._GetUpdatedIPolicy()
Bernardo Dal Seno [Mon, 18 Feb 2013 17:02:06 +0000 (18:02 +0100)]
Unit tests for cmdlib._GetUpdatedIPolicy()

Not 100% coverage, though.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix policy check for disk templates
Bernardo Dal Seno [Thu, 7 Mar 2013 00:46:14 +0000 (01:46 +0100)]
Fix policy check for disk templates

Instance disk template is checked against the policy, and diskless
instances aren't checked for the number of disks.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix merge 8e09e801 that resulted in duplicated code
Bernardo Dal Seno [Thu, 7 Mar 2013 00:34:35 +0000 (01:34 +0100)]
Fix merge 8e09e801 that resulted in duplicated code

A fragment in LUInstanceCreate.CheckPrereq() removed in commit ba147ff8 was
reintroduced in merge 8e09e801 due to a change in df28c49b.

Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoGanetiRapiClient: fix the no_remember option
Daniel Krambrock [Mon, 11 Mar 2013 13:05:21 +0000 (14:05 +0100)]
GanetiRapiClient: fix the no_remember option

There was a typo which prevented the correct option from being passed to
RAPI

Signed-off-by: Daniel Krambrock <danielk_lists@z9d.de>
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoMerge branch 'devel-2.7'
Iustin Pop [Fri, 8 Mar 2013 15:10:42 +0000 (16:10 +0100)]
Merge branch 'devel-2.7'

* devel-2.7:
  Change hbal behaviour in case of early exit
  Fix build/sphinx_ext.py with tuple defaults for op params
  Fix bug in man build rule
  Fix hscolour style sheet building

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoChange hbal behaviour in case of early exit
Iustin Pop [Wed, 6 Mar 2013 09:58:53 +0000 (10:58 +0100)]
Change hbal behaviour in case of early exit

Currently, hbal exits with status 1 if early exit is requested, even
when all jobs are successful. This is counter-intuitive behaviour, so
let's fix it (Issue 386).

Note that the man page had conflicting information already, so it's a
good thing to clean this up.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix "reason" opcode parameter description
Michele Tartara [Wed, 6 Mar 2013 15:09:48 +0000 (15:09 +0000)]
Fix "reason" opcode parameter description

The "reason" opcode parameter can now apply to multiple opcodes, not just the
one for rebooting instances.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoFix build/sphinx_ext.py with tuple defaults for op params
Iustin Pop [Wed, 6 Mar 2013 11:04:12 +0000 (12:04 +0100)]
Fix build/sphinx_ext.py with tuple defaults for op params

When an OpCode's parameter has a tuple as default value, this code
will break:

  buf.write("defaults to ``%s``" % default)

The patch fixes this and other potential cases by always passing a
tuple to '%'.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoFix bug in man build rule
Iustin Pop [Wed, 6 Mar 2013 09:43:51 +0000 (10:43 +0100)]
Fix bug in man build rule

Currently the man page build rule is run without ‘-e’, so the actual
checks in there are just warnings (check-man-warnings,
check-man-dashes).

The patch fixes this and also fixes the man pages which made me see the
problem.

Additionally, check-man-dashes is now verbose, otherwise it's hard to
find out actually where in the page the error is.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoFix hscolour style sheet building
Iustin Pop [Tue, 5 Mar 2013 17:13:14 +0000 (18:13 +0100)]
Fix hscolour style sheet building

Currently we only symlink this into two hard-coded directories, which
breaks the source code viewing for all the others.

The patch replaces this with automatic building; as playing with
relative symlinks is non-trivial, I just generate it many times (the
file is small enough (<250) that it shouldn't matter, size-wise, and
it takes 2ms to do it).

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoMake "reason" a common opcode attribute
Michele Tartara [Wed, 27 Feb 2013 10:51:28 +0000 (11:51 +0100)]
Make "reason" a common opcode attribute

The "reason" attribute will be common to many opcodes.
This patch factors it out so that it will be possible for the next commits
to use it without code duplication.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoMerge branch 'devel-2.7'
Iustin Pop [Tue, 5 Mar 2013 16:05:11 +0000 (17:05 +0100)]
Merge branch 'devel-2.7'

* devel-2.7:
  Update required pylint version
  Constants.hs.in: improve Haddock markup in the template
  convert-constants: generate better Haddock markup
  Expand Haddock to run over test files as well

Conflicts:
        Makefile.am (curl changes and new hs directories)

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoUpdate required pylint version
Iustin Pop [Tue, 5 Mar 2013 15:00:50 +0000 (16:00 +0100)]
Update required pylint version

This should help a lot of users, since pylint 0.21.1 was quite an old
version…

The tree is "clean" w.r.t. the new pylint version.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoConstants.hs.in: improve Haddock markup in the template
Iustin Pop [Tue, 5 Mar 2013 13:12:42 +0000 (14:12 +0100)]
Constants.hs.in: improve Haddock markup in the template

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoconvert-constants: generate better Haddock markup
Iustin Pop [Tue, 5 Mar 2013 13:11:24 +0000 (14:11 +0100)]
convert-constants: generate better Haddock markup

Currently the Python source constants are used as-is, which is not
nice on the eyes (especially for unqualified names, it was hard to
separate them visually).

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoExpand Haddock to run over test files as well
Iustin Pop [Tue, 5 Mar 2013 13:07:50 +0000 (14:07 +0100)]
Expand Haddock to run over test files as well

This patch does multiple enhancements to the way we build the Haddock
docs, motivated by the fact that if we don't run Haddock over test
files as well, bad formatting can be submitted and will accumulate
over time (without any checks).

The patch does:

- replace manual built ALL_APIDOC_HS_DIRS with automatically built one
  (from HS_DIRS)
- change Haddock so that it runs from the top directory (instead of
  from src/)
- change HsColour target file to be built via bash parameter
  substitution, rather than sed (I don't know how to do it in one go,
  so I use 2 intermediate variables)
- change 'hs-apidoc' target so that it depends on the real target
  file; in case no source file has been modified, running 'make
  hs-apidoc' twice will not result in two runs
- run HsColour/Haddock under en_US.UTF-8 locale, otherwise they can't
  parse correctly the Unicode chars in the test files

Additionally, wrong formatting (oops) in a test file has been
corrected.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoMerge branch 'devel-2.7'
Iustin Pop [Tue, 5 Mar 2013 09:21:15 +0000 (10:21 +0100)]
Merge branch 'devel-2.7'

* devel-2.7: (23 commits)
  Add export lists for files which didn't have them
  Fix Haskell compatibility tests with disabled file storage
  Fix QA with disabled file storage
  Fix convert-constants handling of booleans
  Fix handling of disabled (shared) file storage
  Fix low verbosity levels in htools
  Fix improperly formatted docstring
  Allow iallocator to work without LVM storage
  Allow rpc.MakeLegacyNodeInfo to parse non-LVM results
  Fix LUTestAllocator with instance alloc
  Fix confd issue regarding --no-lvm-storage
  Fix networks in _PrepareNicModifications()
  Fix sphinx label namespace
  Clarify use of move-instance with self-signed certificates
  Remove early returns in network LUs
  Fix HooksDict() in case of no tags
  Add networks to _AllIDs()
  Fix locking in LUNetworkConnect()
  Fix networks in LUInstanceSetParams()
  Fix another docstring typo
  ...

Conflicts:
        src/Ganeti/Query/Node.hs (trivial; function rename in master
                                  and 'vgs' change in devel-2.7)
        also exported new entity from TestCommon.hs (used in master)

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

11 years agoSwitch LispConfig double comparison to relative error
Iustin Pop [Thu, 28 Feb 2013 13:34:28 +0000 (14:34 +0100)]
Switch LispConfig double comparison to relative error

This further improves the comparison for "non-trivial"
numbers. Without this patch, there are still cases where the absolute
error is too big, and we need to switch to relative error.

Concept has been taken from
<http://randomascii.wordpress.com/2012/02/25/comparing-floating-point-numbers-2012-edition/>.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoSwitch Attoparsec parser from double to rational
Iustin Pop [Thu, 28 Feb 2013 10:05:45 +0000 (11:05 +0100)]
Switch Attoparsec parser from double to rational

According to the documentation, “This function is almost ten times
faster than rational, but is slightly less accurate. For 94.2% of
numbers, this function and rational give identical results, but for
the remaining 5.8%, this function loses precision around the 15th
decimal place. For 0.001% of numbers, this function will lose
precision at the 13th or 14th decimal place.”. What happens is that
for our tests, it can happen that “Attoparsec.double (show a_double)”
is quite different from “a_double”, such that we have much more than
1e-12 absolute difference.

Since our xm lists should not be too big, I think switching to
rational is better. Next patch also changes the way we compare
doubles, so maybe this patch is not really needed…

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoMake the XmParser config test runtime more consistent
Iustin Pop [Thu, 28 Feb 2013 10:31:35 +0000 (11:31 +0100)]
Make the XmParser config test runtime more consistent

Currently, the test uses a frequency of 5 string/5 double/1 list for
generating Arbitrary instances of ListConfig. However, the list case
has simply a "choose (1, 20)" `vectorOf` arbitrary, which means it
could recurse forever.

Manually running only this test gives runtime as such:

- ~100-200ms: very often
- ~1-2s: often
- ~5s: rare
- ~20s: very rare (but I hit this when running < 30 times the test,
  so…)

On average, this makes this test one of the slowest ones, which is
annoying.

By changing to a sized generator, we can control the depth of the
recursion, ensuring that we have a consistent runtime: out of 100
runs, one is 229ms, one is 164ms, the other are 80-120ms.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoImprove output of the XmParser config test
Iustin Pop [Thu, 28 Feb 2013 10:00:52 +0000 (11:00 +0100)]
Improve output of the XmParser config test

Currently, this tests and its helper function 'isAlmostEqual' uses
plain booleans to signify failures, which means you can't really debug
a failed test. The patch changes the call chain to use annotated
properties all through, which results in messages like:

  Failing almost equal check
  Delta 3.725290298461914e-9 not smaller than 1e-12
  expected: 2.147785408767952e7
   but got: 2.1477854087679517e7

which (IMHO) it's much more readable.

The patch also replaces a 'fail' with 'failTest' in another test.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix node partial name matching in Haskell code
Iustin Pop [Wed, 27 Feb 2013 16:50:40 +0000 (17:50 +0100)]
Fix node partial name matching in Haskell code

This implements QffHostname and fixes the node listing (as well as
export listing when filtering on node name).

This bug was hidden by the fact that node listing with "gnt-node list
aa" works if you don't have live queries (as it was originally), as
the choosing of wanted nodes out of the config based on short names
works. What didn't work was later post-filtering based on such short
names (kind of duplicate, but that's how the code path is).

By implementing QffHostname, we can have custom equality checks, like
in the Python code. What I don't like is how convoluted the testing on
various left/right combinations is, but I didn't find an easier way.

The included unittest tests the partial filtering behaviour, and fails
if the node name flag is not set to QffHostname.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix bug in group queries related to node/instance fields
Iustin Pop [Mon, 25 Feb 2013 16:18:36 +0000 (17:18 +0100)]
Fix bug in group queries related to node/instance fields

Since we use the primitive string type for group UUIDs, the group
fields have a bug where we pass the group name as filter for node
tests, whereas the nodes themselves use the group UUID. This results
in zero node count, empty node list, and no instances being reported
as assigned to groups.

The patch fixes this and adds a test for the node count. It does some
test generation improvement, and also cleans up whitespace issues in
Test/G/Q/Query.hs (the functions case_queryNode_allfields,
prop_queryGroup_noUnknown and case_queryGroup_allfields are unchanged
but simply have indentation fixed).

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAbstract the individual query functions
Iustin Pop [Mon, 25 Feb 2013 12:59:01 +0000 (13:59 +0100)]
Abstract the individual query functions

After implementing a few of the query executor functions, it turns out
that we have the same general pattern:

- compile the filter
- extract the selected fields
- determine whether we need to run collectors
- do a first pass filtering
- run the collector if needed
- compute the final fields

For pure config queries, the collector/final computation is not
needed, but otherwise the code flow is the same.

We can therefore abstract all the queries that originate in the config
(i.e. except the job query) and have a single code path for all of
them, just with different parameters.

To do this, we add some stub collectors for group/network queries,
which don't have live data.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAllow confd to serve network list-fields queries
Iustin Pop [Fri, 22 Feb 2013 15:01:04 +0000 (16:01 +0100)]
Allow confd to serve network list-fields queries

The fields are not yet complete, but at least we can enable the
list-field query to see what is there already.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoRename/make uniform the other query entities
Iustin Pop [Fri, 22 Feb 2013 13:59:31 +0000 (14:59 +0100)]
Rename/make uniform the other query entities

Following the new naming style introduced in Exports.hs, this patch
renames the other resources to export non-qualified names (fieldMap as
opposed to nodeFieldMap), and to use qualified module imports.

Also fixes a haddock issue in a docstring.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAdd export lists for files which didn't have them
Iustin Pop [Mon, 4 Mar 2013 15:39:00 +0000 (16:39 +0100)]
Add export lists for files which didn't have them

Two test helper files didn't have export lists (lost during the split
of tests). This patch finally reintroduces them, to hopefully make the
export list saner and with fewer changes for purely-internal changes.

Additionally, a few missing docstrings are added as well.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoFix Haskell compatibility tests with disabled file storage
Iustin Pop [Mon, 4 Mar 2013 12:32:22 +0000 (13:32 +0100)]
Fix Haskell compatibility tests with disabled file storage

When file storage is disabled at ./configure time, we shouldn't pass
opcodes containing DTFile/DTSharedFile/StorageFile to Python for
validation, as they will fail.

This patch implements this by simply tweaking the Arbitrary instances
for DiskTemplate and StorageType (which IMHO is a nice and clean
way!), and also fixing the generation of arbitrary IPolicies to use
the correct 'allDiskTemplates' list (otherwise we'd loop forever
trying to generate a list of all templates).

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoFix QA with disabled file storage
Iustin Pop [Mon, 4 Mar 2013 12:07:25 +0000 (13:07 +0100)]
Fix QA with disabled file storage

Currently QA tries to use “gnt-node list-storage” with all storage
types, but when file storage is disabled this will fail.

The patch changes it so that if file storage is disabled, we test that
indeed fails, and otherwise we include it in the regular tests.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>

11 years agoFix convert-constants handling of booleans
Iustin Pop [Mon, 4 Mar 2013 10:54:06 +0000 (11:54 +0100)]
Fix convert-constants handling of booleans

It turns out that, in Python, booleans are also integers. So they fall
under the “isinstance(value, int)” case, resulting in all enable*
constants being integers in Haskell, which is not nice, even though
we're not using them directly today.

Patch simply adds a special casing for booleans, before integers.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix handling of disabled (shared) file storage
Iustin Pop [Mon, 4 Mar 2013 10:44:10 +0000 (11:44 +0100)]
Fix handling of disabled (shared) file storage

The vcluster changes broke the disabling of file storage; we can
workaround by (manually) skipping the virtualisation of file storage
paths if they are not enabled.

Note that tests/QA are still broken with disabled file storage; this
patch only fixes production code.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix low verbosity levels in htools
Iustin Pop [Mon, 4 Mar 2013 10:24:51 +0000 (11:24 +0100)]
Fix low verbosity levels in htools

In a few cases, we tested the verbosity level for (== 0), instead of
higher/lower than a certain value. If the user passes multiple
"--quiet" options, this can result in negative verbosity levels, which
behave like "extra verbosity".

Sigh for plain data types as opposed to proper verbosity levels…

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix improperly formatted docstring
Michele Tartara [Wed, 6 Feb 2013 09:16:01 +0000 (09:16 +0000)]
Fix improperly formatted docstring

Change the docstring of chompPrefix to prevent the error
"doc comment parse failed" that was raised by some version of
haddock while generating the documentation for this function.

Signed-off-by: Michele Tartara <mtartara@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>
(cherry picked from commit 94042ae4f2f6983a04d1ff2c99144330562b6301)

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoAllow iallocator to work without LVM storage
Iustin Pop [Fri, 1 Mar 2013 11:45:38 +0000 (12:45 +0100)]
Allow iallocator to work without LVM storage

Currently, the iallocator interface requires LVM storage, due to the
way it computes the node storage information.

By changing the code to understand that GetVGName() can return None,
and by setting the disk_total/disk_free node parameters to the value
zero, we can workaround this issue until proper multi-storage
reporting is implemented.

The hail iallocator plugin works without changes once this is
implemented, as it already handles non-LVM storage as "foreign"
storage (with unlimited capacity).

The patch also changes a bit how the parameters are retrieved and
used; hopefully this is a bit safer and more readable.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoAllow rpc.MakeLegacyNodeInfo to parse non-LVM results
Iustin Pop [Fri, 1 Mar 2013 11:23:23 +0000 (12:23 +0100)]
Allow rpc.MakeLegacyNodeInfo to parse non-LVM results

'MakeLegacyNodeInfo' is not the best place for this, but we'd have to
duplicate it if we wanted a LVM-less version, so the easiest is to add
an optional parameter that allows it to accept/skip LVM-less results.

It still requires at most one VG result, so its behaviour isn't
changed in this respect.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix LUTestAllocator with instance alloc
Iustin Pop [Fri, 1 Mar 2013 09:59:55 +0000 (10:59 +0100)]
Fix LUTestAllocator with instance alloc

This is similar to commit 8775e62a; the addition of node_whitelist
broke this LU as well.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoFix confd issue regarding --no-lvm-storage
Dimitris Aragiorgis [Thu, 28 Feb 2013 01:29:33 +0000 (03:29 +0200)]
Fix confd issue regarding --no-lvm-storage

If cluster is initialized with --no-lvm-storage then volume_group_name
does not exist in config.data. Thus we must define it as optional in
confd.

Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>
[iustin@google.com: fixed Haskell RPC definition]
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

11 years agoFix networks in _PrepareNicModifications()
Dimitris Aragiorgis [Tue, 26 Feb 2013 20:28:42 +0000 (22:28 +0200)]
Fix networks in _PrepareNicModifications()

Passing --net 0:add,ip=5.5.5.5 failed due to a reference
of a non initialized variable (new_net_obj). Reorder the checks
and add some comments to be readable.

Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>
Reviewed-by: Guido Trotter <ultrotter@google.com>

11 years agoFix sphinx label namespace
Iustin Pop [Thu, 28 Feb 2013 16:40:39 +0000 (17:40 +0100)]
Fix sphinx label namespace

Thanks Michael for pointing out the error!

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>

11 years agoClarify use of move-instance with self-signed certificates
Iustin Pop [Thu, 28 Feb 2013 15:32:11 +0000 (16:32 +0100)]
Clarify use of move-instance with self-signed certificates

The document doesn't mention which certificates need to be passed as
ca-file, so let's try to clarify that.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>

11 years agoQA: Support diskless instances
Michael Hanselmann [Wed, 27 Feb 2013 14:51:36 +0000 (15:51 +0100)]
QA: Support diskless instances

This is an initial implementation of diskless instances.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Compare ipolicy directly with None
Michael Hanselmann [Wed, 27 Feb 2013 15:18:05 +0000 (16:18 +0100)]
QA: Compare ipolicy directly with None

If a value was set to numeric 0, the parameter wouldn't be passed to the
command.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: List all ipolicy options in example configuration
Michael Hanselmann [Wed, 27 Feb 2013 15:10:08 +0000 (16:10 +0100)]
QA: List all ipolicy options in example configuration

This makes it easier to know what options are available.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Update assertion for diskless instances
Michael Hanselmann [Wed, 27 Feb 2013 16:45:04 +0000 (17:45 +0100)]
QA: Update assertion for diskless instances

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Disable reinstall test for diskless instances
Michael Hanselmann [Wed, 27 Feb 2013 15:57:44 +0000 (16:57 +0100)]
QA: Disable reinstall test for diskless instances

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Fix dictionary formatting
Michael Hanselmann [Wed, 27 Feb 2013 14:48:46 +0000 (15:48 +0100)]
QA: Fix dictionary formatting

Make it match the style guide.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Disable drbd-offline test if no DRBD instance is used
Michael Hanselmann [Wed, 27 Feb 2013 14:46:43 +0000 (15:46 +0100)]
QA: Disable drbd-offline test if no DRBD instance is used

If “instance-add-drbd-disk” is not enabled it usually also means to not
use DRBD at all.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoRemove early returns in network LUs
Dimitris Aragiorgis [Thu, 28 Feb 2013 13:55:03 +0000 (15:55 +0200)]
Remove early returns in network LUs

Remove any early returns in LUNetworkDisconnect/LUNetworkConnect
and replace them with if-else statements.

Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>
Reviewed-by: Michael Hanselmann <hansmi@google.com>

11 years agoTest AsyncStreamServer with abstract unix sockets
Guido Trotter [Tue, 19 Feb 2013 22:41:19 +0000 (14:41 -0800)]
Test AsyncStreamServer with abstract unix sockets

This was meant to be since "the beginning" but was never submitted as
somehow it failed with python 2.4. Now that the minimum python version
has been increased it can be added.

Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>

11 years agoQA: Disable RAPI tests for virtual clusters
Michael Hanselmann [Thu, 21 Feb 2013 14:32:29 +0000 (15:32 +0100)]
QA: Disable RAPI tests for virtual clusters

The QA script connects to the RAPI daemon. In virtual cluster setups the
daemon is usually listening on a local interface not reachable from the
outside.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Add virtual cluster support to queue drain test
Michael Hanselmann [Thu, 21 Feb 2013 15:27:22 +0000 (16:27 +0100)]
QA: Add virtual cluster support to queue drain test

The path to the queue drain file must use the virtual node path.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Disable copyfile test for virtual clusters
Michael Hanselmann [Thu, 21 Feb 2013 15:27:01 +0000 (16:27 +0100)]
QA: Disable copyfile test for virtual clusters

This test will need some more work for virtual clusters. Disable it in
the meantime.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Disable OOB tests for virtual clusters
Michael Hanselmann [Thu, 21 Feb 2013 15:26:31 +0000 (16:26 +0100)]
QA: Disable OOB tests for virtual clusters

They do not work properly at the moment.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Update virtual node's RAPI users file
Michael Hanselmann [Thu, 21 Feb 2013 14:33:45 +0000 (15:33 +0100)]
QA: Update virtual node's RAPI users file

The file is located below the virtual node directory.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoQA: Read virtual node's RAPI certificate
Michael Hanselmann [Thu, 21 Feb 2013 14:32:51 +0000 (15:32 +0100)]
QA: Read virtual node's RAPI certificate

The virtual node prefix must be added to the path.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>

11 years agoqa_os: Disable checks for virtual clusters
Michael Hanselmann [Thu, 21 Feb 2013 14:17:44 +0000 (15:17 +0100)]
qa_os: Disable checks for virtual clusters

The OS definitions are not virtualized. Tests configuring different OS
definitions on different nodes don't work properly.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Bernardo Dal Seno <bdalseno@google.com>