ganeti-github.git
5 years agoQA: Allow the RAPI user to be set
Hrvoje Ribicic [Tue, 22 Sep 2015 17:09:06 +0000 (19:09 +0200)]
QA: Allow the RAPI user to be set

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Lisa Velden <velden@google.com>

5 years agoQA: Do not remove nodes from cluster without destroying it
Hrvoje Ribicic [Tue, 22 Sep 2015 15:20:46 +0000 (17:20 +0200)]
QA: Do not remove nodes from cluster without destroying it

The Ganeti QA can be set up to optionally both create and destroy a
cluster during its runtime. Before this patch, the QA removed all the
nodes barring the master one at the end of a QA, regardless of whether
the cluster was supposed to be disassembled. This patch fixes this
behaviour and lets created clusters remain in place after a QA.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Lisa Velden <velden@google.com>

5 years agoQA: Refactor RAPI handling
Hrvoje Ribicic [Tue, 7 Jul 2015 00:49:23 +0000 (00:49 +0000)]
QA: Refactor RAPI handling

Since the QA RAPI code already uses the horror of global variables to
save the username and password within the qa_rapi module, the code can
be refactored to make the storage of these values outside the module
unnecessary. This encapsulates the RAPI functionality better, and will
allow for easier refactoring in later commits.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Lisa Velden <velden@google.com>

5 years agoIncrease default disk size of burnin to 1G
BSRK Aditya [Thu, 24 Sep 2015 12:14:45 +0000 (14:14 +0200)]
Increase default disk size of burnin to 1G

The previous default value causes burnin to fail at instance
creation as the disk size was too low.

Signed-off-by: BSRK Aditya <bsrk@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>

5 years agobreak line with more than 80 characters
Klaus Aehlig [Mon, 21 Sep 2015 11:41:25 +0000 (13:41 +0200)]
break line with more than 80 characters

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Lisa Velden <velden@google.com>

5 years agoOnly search for Python-2 interpreters
Klaus Aehlig [Mon, 21 Sep 2015 08:39:19 +0000 (10:39 +0200)]
Only search for Python-2 interpreters

Ganeti is not yet ready for Python 3. Therefore, at configure-time,
we effectively have two constraints for the version of Python to
use: ">=2.6" and "<3.0". As, unfortunuately, the AM_PYTHON_PATH
macro only supports minimal-version constraints, we afterwards verify
that we got an interpreter for Python 2. We also tune the search
heuristics to first check binaries that most likely are interpreters
for Python 2. To also work with older versions of the autotools, we
do the "<3.0" check manually and no rely on it already being supported
in the AM_PYTHON_CHECK_VERSION macro.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoFix faulty comments / indentation
Hrvoje Ribicic [Wed, 16 Sep 2015 13:23:59 +0000 (15:23 +0200)]
Fix faulty comments / indentation

As a part of patch 6b16d04a318d33a59, some errors were inadvertently
introduced by adding documentation. This patch fixes them.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoHandle Xen 4.3 states better
Hrvoje Ribicic [Tue, 15 Sep 2015 08:37:11 +0000 (10:37 +0200)]
Handle Xen 4.3 states better

In Xen commit e1475a6693aac8cddc4bdd456548aa05a625556b, the output from
xl list was extended to provide a reason for shutdowns. This breaks
our somewhat strict parsing of the output in certain situations where
the new states appear (e.g. the short suspension during a migration, or
an instance reboot).

This patch makes sure the new states (barring the mysterious watchdog
state) are handled correctly.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoMerge branch 'stable-2.11' into stable-2.12
Hrvoje Ribicic [Thu, 3 Sep 2015 12:39:26 +0000 (14:39 +0200)]
Merge branch 'stable-2.11' into stable-2.12

* stable-2.11
  (no changes)

* stable-2.10
  (no changes)

* stable-2.9
  Document quoting of special values in key-value parameters
  replace-disks: fix --ignore-ipolicy

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoMerge branch 'stable-2.10' into stable-2.11
Hrvoje Ribicic [Thu, 3 Sep 2015 12:10:34 +0000 (14:10 +0200)]
Merge branch 'stable-2.10' into stable-2.11

* stable-2.10
  (no changes)

* stable-2.9
  Document quoting of special values in key-value parameters
  replace-disks: fix --ignore-ipolicy

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoMerge branch 'stable-2.9' into stable-2.10
Hrvoje Ribicic [Thu, 3 Sep 2015 11:22:54 +0000 (13:22 +0200)]
Merge branch 'stable-2.9' into stable-2.10

* stable-2.9
  Document quoting of special values in key-value parameters
  replace-disks: fix --ignore-ipolicy

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoAdd forgotten IPOLICY_SPINDLE_RATIO to __all__ variable
Oleg Ponomarev [Thu, 3 Sep 2015 09:08:49 +0000 (11:08 +0200)]
Add forgotten IPOLICY_SPINDLE_RATIO to __all__ variable

Signed-off-by: Oleg Ponomarev <oponomarev@google.com>
Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoDocument quoting of special values in key-value parameters
Klaus Aehlig [Tue, 1 Sep 2015 13:23:41 +0000 (15:23 +0200)]
Document quoting of special values in key-value parameters

Since the early days of Ganeti, it is possible to pass in key-value
parameters also some special non-string values (the two boolean values
True and False and the special value None). However, the syntax for
entering them was never properly documented confusing people who had
to pass one of those values. So document it now.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoreplace-disks: fix --ignore-ipolicy
Apollon Oikonomopoulos [Mon, 31 Aug 2015 14:20:36 +0000 (17:20 +0300)]
replace-disks: fix --ignore-ipolicy

CheckTargetNodeIPolicy was expecting an LU, but got a Tasklet instead.
This caused gnt-instance replace-disks --ignore-ipolicy to fail with a
"'TLReplaceDisks' object has no attribute 'LogWarning'" message in the
presence policy-related warnings. We fix this by passing the calling LU
to CheckTargetNodeIPolicy.

Signed-off-by: Apollon Oikonomopoulos <apoikos@gmail.com>
Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoMake QA turn on user-shutdown when testing it
Hrvoje Ribicic [Wed, 19 Aug 2015 21:35:22 +0000 (23:35 +0200)]
Make QA turn on user-shutdown when testing it

Commit fe6287b4 made the --user-shutdown switch meaningful for Xen,
preventing USER_DOWN reporting if disabled. The QA turned this switch
on for KVM, where it is needed to start the specialized daemon, but
not for Xen. This patch fixes the discrepancy.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoFix disabling of user shutdown reporting
Hrvoje Ribicic [Mon, 17 Aug 2015 18:24:24 +0000 (18:24 +0000)]
Fix disabling of user shutdown reporting

Unlike the Python-side query logic still used for more detailed
queries, the Haskell queries neglected to take into account the
user-shutdown cluster-level parameter, turning USER_DOWN reporting on
by default. This is especially bad considering that this parameter was
introduced to give time to users to adapt their automation to take the
new statuses into account. This patch makes the parameter usable,
albeit possibly too late.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoMake confd answer disk requests querying by name
Hrvoje Ribicic [Tue, 18 Aug 2015 14:35:21 +0000 (14:35 +0000)]
Make confd answer disk requests querying by name

As a result of an additional bit of code introduced by patch fa3c0df5,
queries for instance disks sent to the configuration daemon required
additional information about the instance. This information was fetched
through a manual search of the list of instances, rather than the
function capable of searching by name or by uuid.

This made the burnin tool used by our tests fail when inquiring for
information and broke QA, and this patch fixes the problem.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agognt-node add: password auth is only one method
Klaus Aehlig [Tue, 11 Aug 2015 07:41:38 +0000 (09:41 +0200)]
gnt-node add: password auth is only one method

The man page for gnt-node add is slightly misleading.
In can be read to mean that we insist on password
authentication for root on the target node. However,
the only point the man page is trying to make here
is that credentials have to be provided to allow to
ssh as root to the target node; password is only of
the many options. Fix the wording accordingly.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoAccept allocation of 0 jobs
Klaus Aehlig [Fri, 7 Aug 2015 15:57:34 +0000 (17:57 +0200)]
Accept allocation of 0 jobs

However, short-cut them and return the empty list
directly, as we do not need to do any change to the
serial file.

Note that allocating 0 jobs has legitimate use cases,
like gnt-node migrate on an empty node. Doing so
without complaining in line with the behaviour of
earlier Ganeti versions.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoReturn multiple fields multiple times
Klaus Aehlig [Tue, 4 Aug 2015 16:03:03 +0000 (18:03 +0200)]
Return multiple fields multiple times

While it is not very useful, our specification still says
that we should return the values for fields requested multiple
times also multiple times. Commit 237a43b added fetching of
fields not requested but needed to evaluate the filter; to
avoid overhead the list of fields was deduplicated, thereby
breaking the said property. Restore it by only deduplicating
and filtering the additional fields.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoIn queries collect all needed data
Klaus Aehlig [Tue, 4 Aug 2015 13:19:01 +0000 (15:19 +0200)]
In queries collect all needed data

Queries are affected by two forms of fields:
- those the user wishes to see, and
- those needed to evaluate the filter provided.
For internal handling, we do have to fetch the
fields of either category to avoid wrong results,
even if we only output fields of the first category.
Ensure this fetch.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoAdd a function computing the filter arguments
Klaus Aehlig [Tue, 4 Aug 2015 13:03:31 +0000 (15:03 +0200)]
Add a function computing the filter arguments

When collecting live data for queries, we need to also
collect the fields the filter talks about, not only the
fields the user wants to see. Therefore, we need a function
computing those fields.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoUtils: Add ordNub
Niklas Hambuechen [Fri, 1 Aug 2014 15:27:11 +0000 (17:27 +0200)]
Utils: Add ordNub

For n*log(n) duplicate removal (as opposed to nub's n^2).

Signed-off-by: Niklas Hambuechen <niklash@google.com>
Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

Cherry-picked-from: 5dd8067d
Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoAccept timeout errors are luxi down
Klaus Aehlig [Mon, 3 Aug 2015 11:29:42 +0000 (13:29 +0200)]
Accept timeout errors are luxi down

With the extended retry-logic connecting to luxid, an absence
of luxid can also be perceived as a TimeoutError. Therefore,
also for this error, make the watcher try to restart the luxi
daemon.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoCorrect indendation
Lisa Velden [Mon, 3 Aug 2015 08:43:59 +0000 (10:43 +0200)]
Correct indendation

to satisfy pylint.

Signed-off-by: Lisa Velden <velden@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoMerge branch 'stable-2.11' into stable-2.12
Lisa Velden [Mon, 3 Aug 2015 07:00:43 +0000 (09:00 +0200)]
Merge branch 'stable-2.11' into stable-2.12

* stable-2.11
  (no changes)

* stable-2.10
  Add a new unit test for LUInstanceMultiAlloc
  Fix a bug in LUInstanceMultiAlloc LU

Signed-off-by: Lisa Velden <velden@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoIn confd provide proper serial number
Klaus Aehlig [Fri, 31 Jul 2015 12:46:34 +0000 (14:46 +0200)]
In confd provide proper serial number

The confd protocol heavily relies on the serial number
to filter out outdated responses. However, the current
implementation always returned 0 as serial number. Fix
this and return a serial number that is bumped with every
change that affects the answer.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoMerge branch 'stable-2.10' into stable-2.11
Lisa Velden [Fri, 31 Jul 2015 08:22:01 +0000 (10:22 +0200)]
Merge branch 'stable-2.10' into stable-2.11

* stable-2.10
  Add a new unit test for LUInstanceMultiAlloc
  Fix a bug in LUInstanceMultiAlloc LU

Signed-off-by: Lisa Velden <velden@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoAdd a new unit test for LUInstanceMultiAlloc
Dimitris Bliablias [Wed, 29 Jul 2015 11:21:12 +0000 (14:21 +0300)]
Add a new unit test for LUInstanceMultiAlloc

This patch, extends the 'cmdlib.instance_unittest.py' with a new test
for instances multi allocations, in order to test an allocation of more
than one instances.

Signed-off-by: Dimitris Bliablias <dblia@skroutz.gr>
Signed-off-by: Lisa Velden <velden@google.com>
Reviewed-by: Lisa Velden <velden@google.com>

5 years agoFix a bug in LUInstanceMultiAlloc LU
Dimitris Bliablias [Wed, 29 Jul 2015 11:21:11 +0000 (14:21 +0300)]
Fix a bug in LUInstanceMultiAlloc LU

As of commit 804d72eb, some modifications on the LUInstanceMultiAlloc LU
resulted in breaking the instances multi allocation functionality.

In details, when using an iallocator for the instances allocation, the
'jobs' list is computed for allocations using the DRBD disk template
only and not for the rest templates, due to the wrong indentation of the
relevant code line. Furthermore, for the same reason, the allocation of
more than one instances always fails since the 'missing' set is not
computed after the processing of all the allocatable instances, as it
should do, but at the end of each instance iteration.

Signed-off-by: Dimitris Bliablias <dblia@skroutz.gr>
Signed-off-by: Lisa Velden <velden@google.com>
Reviewed-by: Lisa Velden <velden@google.com>

5 years agoAlso provide default arguments for mond
Klaus Aehlig [Fri, 24 Jul 2015 10:38:41 +0000 (12:38 +0200)]
Also provide default arguments for mond

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoMerge branch 'stable-2.11' into stable-2.12
Klaus Aehlig [Fri, 24 Jul 2015 09:17:09 +0000 (11:17 +0200)]
Merge branch 'stable-2.11' into stable-2.12

* stable-2.11
  (no changes)

* stable-2.10
  Fix typo in secondary
  When hinting to do gnt-instance info, show the instance
  Update gnt-network example in admin page

Conflicts:
lib/cmdlib/instance_storage.py: trivial

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoMerge branch 'stable-2.10' into stable-2.11
Klaus Aehlig [Thu, 23 Jul 2015 17:22:39 +0000 (19:22 +0200)]
Merge branch 'stable-2.10' into stable-2.11

* stable-2.10
  Fix typo in secondary
  When hinting to do gnt-instance info, show the instance
  Update gnt-network example in admin page

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>

5 years agoFix typo in secondary
Thomas Vander Stichele [Tue, 21 Jul 2015 08:33:50 +0000 (10:33 +0200)]
Fix typo in secondary

Signed-off-by: Thomas Vander Stichele <thomasvs@google.com>
Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoWhen hinting to do gnt-instance info, show the instance
Thomas Vander Stichele [Mon, 20 Jul 2015 20:24:59 +0000 (16:24 -0400)]
When hinting to do gnt-instance info, show the instance

Signed-off-by: Thomas Vander Stichele <thomasvs@google.com>
Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoUpdate gnt-network example in admin page
Klaus Aehlig [Thu, 23 Jul 2015 10:38:14 +0000 (12:38 +0200)]
Update gnt-network example in admin page

Commit 2243b133 changed the syntax of the gnt-network command.
Mode and link are no longer passed as positional arguments, but
instead as named parameters in the --nic-parameters option.
However, the example in the admin page was not updated. Do this
now.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>

5 years agoSupport sphinx 1.3
Klaus Aehlig [Tue, 21 Jul 2015 10:46:57 +0000 (12:46 +0200)]
Support sphinx 1.3

First, enable_manpages is now required to be a bool; fortunately,
we set it via the environment in conf.py anyway, so no need to
pass it as an option as well. Also, the default template has been
renamed to classic; so branch on the sphinx version to choose the
correct name. Fixes issue #1119.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoMake documentation for -H serial_console more explicit
Lisa Velden [Tue, 21 Jul 2015 12:34:42 +0000 (14:34 +0200)]
Make documentation for -H serial_console more explicit

Mention that apart from enabling the emulation of a serial port in KVM
"console=ttyS0,<serial_speed>" is appended to the end of kernel_args.

Signed-off-by: Lisa Velden <velden@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoBugfix in checkInstanceMove function in Cluster.hs
Oleg Ponomarev [Wed, 15 Jul 2015 17:46:14 +0000 (20:46 +0300)]
Bugfix in checkInstanceMove function in Cluster.hs

checkInstanceMove function tries all possible moves of single instance
in order to found an optimal move. When option --no-disk-moves is
enabled, current implementation tries only Failover move while
FailoverToAny is a suitable move too. This patch fixes the bug.

Signed-off-by: Oleg Ponomarev <onponomarev@gmail.com>
Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRevision bump for 2.12.5 v2.12.5
Petr Pudlak [Mon, 13 Jul 2015 14:02:16 +0000 (16:02 +0200)]
Revision bump for 2.12.5

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>

5 years agoUpdate the NEWS file for 2.12.5
Petr Pudlak [Mon, 13 Jul 2015 14:00:57 +0000 (16:00 +0200)]
Update the NEWS file for 2.12.5

... mentioning all the changes.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>

5 years agoUpdate Xen documentation in install.rst
Hrvoje Ribicic [Mon, 13 Jul 2015 10:14:50 +0000 (10:14 +0000)]
Update Xen documentation in install.rst

The Xen documentation in install.rst was out of date, describing
xm-specific changes at the point where 2.12 is mostly used with xl.
This patch removes xm-specific migration steps, references the official
Xen wiki instead of replicating information from it, removes the
VNC setup settings that are outdated for xl and probably for xm, and
slightly rewrites the documentation.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoClarify need for the migration_port Xen param
Hrvoje Ribicic [Mon, 13 Jul 2015 10:14:17 +0000 (10:14 +0000)]
Clarify need for the migration_port Xen param

... depending on which toolstack is used.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoMerge branch 'stable-2.11' into stable-2.12
Klaus Aehlig [Wed, 8 Jul 2015 15:36:24 +0000 (17:36 +0200)]
Merge branch 'stable-2.11' into stable-2.12

* stable-2.11
  Fix capitalization of TestCase
  Trigger renew-crypto on downgrade to 2.11

Conflicts:
tools/post-upgrade: use 2.12 condition on when to run the hook

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoTell git to ignore tools/ssl-update
Klaus Aehlig [Wed, 8 Jul 2015 14:38:32 +0000 (16:38 +0200)]
Tell git to ignore tools/ssl-update

This tools was recently added, but not added to .gitignore. Do
so now.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoUse 'exclude_daemons' option for master only
Helga Velroyen [Thu, 2 Jul 2015 13:07:12 +0000 (15:07 +0200)]
Use 'exclude_daemons' option for master only

During 'gnt-cluster renew-crypto --new-cluster-certificate'
or '... --new-node-certficates' all daemons are shutdown,
except for wconfd and noded. So far, noded was not shutdown
on all nodes, although it is only necessary on the master.
This patch makes sure that the 'exclude_daemons' flag only
applies to the master, as all interesting operations will
only need them there.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoDisable superfluous restarting of daemons
Helga Velroyen [Thu, 2 Jul 2015 12:42:20 +0000 (14:42 +0200)]
Disable superfluous restarting of daemons

This patch fixes a little glitch where the Ganeti
daemons were stopped and started unnecessarily if
only the cluster certficate was renewed but nothing
else.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoAdd tests exercising the "crashed" state handling
Hrvoje Ribicic [Mon, 6 Jul 2015 17:23:31 +0000 (17:23 +0000)]
Add tests exercising the "crashed" state handling

This patch adds a few tests that make sure the state is handled
properly, using examples taken from a running cluster.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoAdd proper handling of the "crashed" Xen state
Hrvoje Ribicic [Mon, 6 Jul 2015 17:17:41 +0000 (17:17 +0000)]
Add proper handling of the "crashed" Xen state

Whenever an instance would enter the crashed state due to kernel issues
or other horrible problems, Ganeti would not be able to interpret the
data and would report strange and incomprehensible errors. This patch
fixes this by adding proper handling for the "crashed" state.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoHandle SSL setup when downgrading
Helga Velroyen [Wed, 1 Jul 2015 08:45:02 +0000 (10:45 +0200)]
Handle SSL setup when downgrading

This patch will handle the downgrade of the SSL setup
from 2.12 to 2.11. Essentially, all client.pem and
ssconf_master_candidates_certs files will be deleted.
This will kick the cluster in a pre-2.11 mode wrt to
SSL and result in a nagging message to re-run
'gnt-cluster renew-crypto' when as output of 'gnt-cluster
verify'.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoWrite SSH ports to ssconf files
Helga Velroyen [Tue, 30 Jun 2015 08:48:11 +0000 (10:48 +0200)]
Write SSH ports to ssconf files

For the downgrading of the SSL setup from 2.12 to 2.11, we
need to be able to SSH into machines while no daemons are
running. Unfortunately currently the only way to obtain
custom-configured SSH ports is by queries. In order to
access this information with daemons being shutdown, this
patch adds the SSH port information to an ssconf file.

This will also be used to simplify some backend calls for
the *SSH* handling in 2.13.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoNoded: Consider certificate chain in callback
Helga Velroyen [Wed, 24 Jun 2015 12:19:17 +0000 (14:19 +0200)]
Noded: Consider certificate chain in callback

This patch significantly changes the callback that is
called upon receiving an incoming SSL connection. Since
this callback is called not only with the certificate
that the client sends, but also (in some implementations)
with the entire certificate chain of the client
certificate.

In our case, the certficate chain contains
the client certificate and the server certificate as
the one that signed the client certificate. This means
that we have to accept the server certificate, but only
if we receive it with the 'depth' greater than 0, meaning
that this is part of the chain and not the actual
certificate. If the depth value is 0, we can be sure
to have received the actual certficate and match it
against the list of master candidate certificates as
before.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoCluster-keys-replacement: update documentation
Helga Velroyen [Wed, 24 Jun 2015 12:03:03 +0000 (14:03 +0200)]
Cluster-keys-replacement: update documentation

This patch updates the cluster-keys-replacement document
which assists user about how to replace the crypto keys
for their cluster. This now reflects the changes wrt
server/client certificates.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoBackend: Use timestamp as serial no for server cert
Helga Velroyen [Wed, 24 Jun 2015 11:27:30 +0000 (13:27 +0200)]
Backend: Use timestamp as serial no for server cert

So far, all of Ganeti's server certificates had the serial
number '1'. While this works, it makes it hard to
distinguish situations where the certificate is
renewed from those where it wasn't. This patch uses
a timestamp as serial number.

While this is still not stricly according to the SSL RFC,
it is at least a number that is stricly growing and we
can be sure that no two different server certificates
will have the same serial number.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoUPGRADE: add note about 2.12.5
Helga Velroyen [Wed, 24 Jun 2015 11:22:02 +0000 (13:22 +0200)]
UPGRADE: add note about 2.12.5

This patch adds comments to the upgrade documentation
to advise users to rerun renew-crypto if they update
to 2.12.5.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoNEWS: Mention issue 1094
Helga Velroyen [Wed, 24 Jun 2015 11:19:46 +0000 (13:19 +0200)]
NEWS: Mention issue 1094

This patch updates the NEWS file to advise users to rerun
renew-crypto after an update to 2.12.5.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoman: mention changes in renew-crypto
Helga Velroyen [Wed, 24 Jun 2015 11:17:19 +0000 (13:17 +0200)]
man: mention changes in renew-crypto

This updates the gnt-cluster man page wrt to the changes
about server and client certificates and how they affect
the operation 'gnt-cluster renew-crypto'.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoVerify: warn about self-signed client certs
Helga Velroyen [Wed, 24 Jun 2015 09:56:23 +0000 (11:56 +0200)]
Verify: warn about self-signed client certs

Since from this patch series on, there should be no
self-sigend certificates in a cluster anymore, add
a warning to cluster-verify to nag people to renew
their certificates.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoBootstrap: validate SSL setup before starting noded
Helga Velroyen [Mon, 22 Jun 2015 13:01:04 +0000 (15:01 +0200)]
Bootstrap: validate SSL setup before starting noded

This patch adds a few checks which ensure that all
files necessary for proper SSL communication are
in place before noded is started on the master node.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoClean up configuration of curl request
Helga Velroyen [Mon, 22 Jun 2015 12:43:12 +0000 (14:43 +0200)]
Clean up configuration of curl request

This is a small patch cleaning up some thing in the
composition of the pycurl object for RPC calls.
For example, it removes some superfluous 'str' and
increases the logging level to warning when the
server cert is used.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRenew-crypto: remove superflous copying of node certs
Helga Velroyen [Mon, 22 Jun 2015 08:59:09 +0000 (10:59 +0200)]
Renew-crypto: remove superflous copying of node certs

Since now the server certificates are copied in their
own dedicated function, remove adding their file name
in the general function for renewing crypto tokens.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRenew-crypto: propagate verbose and debug option
Helga Velroyen [Fri, 19 Jun 2015 11:36:06 +0000 (13:36 +0200)]
Renew-crypto: propagate verbose and debug option

This patch enables the user to add --debug and/or --verbose
to the call of 'renew-crypto'. This way, more output is
shown to debug SSL problems easier.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoNoded: log the certificate and digest on noded startup
Helga Velroyen [Fri, 19 Jun 2015 09:52:36 +0000 (11:52 +0200)]
Noded: log the certificate and digest on noded startup

This patch adds logging of the filename and the digest of the
certificate which is loaded by noded on startup. This will
help debugging SSL problems as it will make clear whether or
not the noded is still using a stale/replaced/old server
certificate after a renewal.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoQA: reload rapi cert after renew crypto
Helga Velroyen [Thu, 18 Jun 2015 13:52:30 +0000 (15:52 +0200)]
QA: reload rapi cert after renew crypto

When running the QA, we copy the rapi certficate to the
machine which steers the QA to use it later in the QA
for testing RAPI calls. However, before we get to that
part of the QA, the rapi certificate is replaced when
'gnt-renew crypto' is called.

This patch makes sure that the new rapi certificate is
copied to the steering machine so that later RAPI calls
do not fail. It remains mysterious how this worked before.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoPrepare-node-join: use common functions
Helga Velroyen [Tue, 16 Jun 2015 15:46:04 +0000 (17:46 +0200)]
Prepare-node-join: use common functions

This patch makes prepare_node_join use some of the functions
that were moved to tools/common.py. The respective unittests
are removed, because they are already tested in
common_unittest.py.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRenew-crypto: remove dead code
Helga Velroyen [Tue, 16 Jun 2015 15:35:46 +0000 (17:35 +0200)]
Renew-crypto: remove dead code

This patch removes the code for renewing the master
nodes' client certificate using SSL. This is no longer
needed, as the master nodes' certificate is created
in gnt_cluster.py already.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoInit: add master client certificate to configuration
Helga Velroyen [Tue, 16 Jun 2015 14:17:27 +0000 (16:17 +0200)]
Init: add master client certificate to configuration

This patch adds a few steps to bootstrap.py. After the
creation of the server (cluster) certificate and the
master node's client certificate, the digest of that
client certificate is added to the configuration and
by an update of the configuraiton written to the
ssconf_master_candidates_certs file.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRenew-crypto: rebuild digest map of all nodes
Helga Velroyen [Tue, 16 Jun 2015 12:40:12 +0000 (14:40 +0200)]
Renew-crypto: rebuild digest map of all nodes

During a renew-crypto operation, all nodes will create
new client certificates. Afterwards, the fingerprints
(digests) of the master candidate nodes needs to be
collected and added to the configuration. This is done
by an RPC call, which will succeed as the master
node's certficate digest was propagated to the nodes
before.

This also removes two unittest which are no longer
necessary, because there will be no RPC call from
the master to itself anymore.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoNoded: make "bootstrap" a constant
Helga Velroyen [Tue, 16 Jun 2015 12:24:11 +0000 (14:24 +0200)]
Noded: make "bootstrap" a constant

Noded uses the constant "bootstrap" when starting
without client certificates. This patch moves the
constant to Constants.hs.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agonode-daemon-setup: generate client certificate
Helga Velroyen [Mon, 15 Jun 2015 14:43:24 +0000 (16:43 +0200)]
node-daemon-setup: generate client certificate

So far, the client certificate of a node that is added
to the cluster was created in LUNodeAdd using an RPC
call. This is now simplified by creating the certificate
already in tools/node_daemon_setup.py and only retrieving
its fingerprint by RPC to add it to the configuration.

This simplifies the backend function from only reading
the fingerprint instead of creating the certificate.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agotools: Move (Re)GenerateClientCert to common
Helga Velroyen [Mon, 15 Jun 2015 14:36:24 +0000 (16:36 +0200)]
tools: Move (Re)GenerateClientCert to common

So far the generation of client certificates was only
called from ssl_update.py used in when calling 'gnt-cluster
renew-crypto'. This patch moves the function from
ssl_update.py to tools/common.py, because it will also
be needed by prepare_node_join.py when adding nodes
(see next patch in the series).

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRenew cluster and client certificates together
Helga Velroyen [Wed, 10 Jun 2015 10:56:15 +0000 (12:56 +0200)]
Renew cluster and client certificates together

So far, the cluster certificate and the individual node
certificate could be renewed independent of each other.
This is no longer possible, because when renewing the
server certificate, all node certificates need to be
renewed as well, because they are signed by the server
certificate. This patch couples the two operations
together.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoInit: create the master's client cert in bootstrap
Helga Velroyen [Tue, 9 Jun 2015 15:56:09 +0000 (17:56 +0200)]
Init: create the master's client cert in bootstrap

This patch extends bootstrap.py to not only create
the cluster certificate but also the master node's
client certificate.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRenew client certs using ssl_update tool
Helga Velroyen [Tue, 9 Jun 2015 12:19:15 +0000 (14:19 +0200)]
Renew client certs using ssl_update tool

This patch integrates renewing the client certificate
of non-master nodes using the new ssl_update tool.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoRun functions while (some) daemons are stopped
Helga Velroyen [Tue, 9 Jun 2015 09:10:04 +0000 (11:10 +0200)]
Run functions while (some) daemons are stopped

For the new renew-crypto operation, we need to run
functions while most of the daemons are stopped,
except for WConfd. This refactors our code a bit
and generalizes the method that runs functions
while *all* daemons are stopped to one that
accepts a list of daemons to not be stopped.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoBack up old client.pem files
Helga Velroyen [Mon, 8 Jun 2015 09:43:00 +0000 (11:43 +0200)]
Back up old client.pem files

For post-mortems, let's make a backup of the client
certificate before renewing them.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoIntroduce ssl_update tool
Helga Velroyen [Fri, 5 Jun 2015 13:45:00 +0000 (15:45 +0200)]
Introduce ssl_update tool

In order to renew client certificates via SSH (rather than
on the fly via SSL as it was before), we need a new tool
which can be called on remote nodes via SSH.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agox509 function for creating signed certs
Helga Velroyen [Fri, 5 Jun 2015 13:35:00 +0000 (15:35 +0200)]
x509 function for creating signed certs

So far, all our SSL certficates were self-signed. As from
this patch series on client certificates will be signed by
the cluster certificate, we need a utility function for
creation of not self-signed certificates.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoAdd tools/common.py from 2.13
Helga Velroyen [Wed, 3 Jun 2015 11:53:15 +0000 (13:53 +0200)]
Add tools/common.py from 2.13

We will need some functions from tools/common.py, which
are only present from 2.13 on. Unfortunately there were
not clear commits for that, so cherry-picking is not
an option. This patch simply copies the file and one
has to be careful with the next merge.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoConsider ECDSA in SSH setup
Helga Velroyen [Wed, 1 Jul 2015 12:24:11 +0000 (14:24 +0200)]
Consider ECDSA in SSH setup

So far, Ganeti did only care about DSA and RSA host
keys. With the rising popularity of ECDSA, we should
support this key type as well, as it is already
enabled by default in many common distributions.

This fixes Issue 1098.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoUpdate documentation of watcher and RAPI daemon
Helga Velroyen [Thu, 2 Jul 2015 12:10:24 +0000 (14:10 +0200)]
Update documentation of watcher and RAPI daemon

.. to reflect the relationship between the RAPI daemons'
-b option and the watchers --rapi-ip option.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoWatcher: add option for setting RAPI IP
Helga Velroyen [Thu, 2 Jul 2015 11:38:17 +0000 (13:38 +0200)]
Watcher: add option for setting RAPI IP

Per default, the RAPI daemon binds to 0.0.0.0 when being
started. This means it serves from any IP the machine is
configured for. This works well together with the watcher
which always polls the RAPI daemons on 127.0.0.1 and
restarts it when it is not reachable.

If a user decides to start the RAPI daemon with a particular
IP other than 127.0.0.1 (using the option -b, for example
set in /etc/default/ganeti), RAPI will only serve from that
IP and thus it will not be reachable from 127.0.0.1. Since
the watcher only polls on this IP, it will inevitably fail
to connect to the RAPI daemon and thus restart it every five
minutes.

To solve this, this patch adds an option --rapi-ip to the
watcher. Whenever -b of the RAPI daemon is set, the watcher
needs to be fed the same IP with --rapi-ip (which means
editing /etc/cron.d/ganeti for example). This is not optimal
regarding user experience (as it is easy to forget one of
the two places), but the alternative would be to make this
a ganeti configuration parameter which is fed to both, RAPI
daemon and watcher, but this would be significantly more
effort for this relatively rarely used feature.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoFix capitalization of TestCase
Helga Velroyen [Fri, 3 Jul 2015 09:04:21 +0000 (11:04 +0200)]
Fix capitalization of TestCase

.. and with this unbreak the tests.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoTrigger renew-crypto on downgrade to 2.11
Helga Velroyen [Wed, 1 Jul 2015 08:16:34 +0000 (10:16 +0200)]
Trigger renew-crypto on downgrade to 2.11

With the upcoming changes in 2.12, is it necessary to run
'gnt-cluster renew-crypto --new-node-certificates'. To
ensure that our QA runs smoothely, this means that this
command needs to be added to the post-upgrade hooks of
2.11. To ensure that it is only run when coming from
2.12.X or from before 2.11, the utility functions are
extended by an equal operator for versions.

Note that it is unlikely that 2.11 will get another release,
so this is mainly to fix our QA. However, users downgrading
to a previous version of 2.11 will get a nagging message
to re-run renew-crypto manually.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoWhen connecting to Metad fails, log the full stack trace
Petr Pudlak [Thu, 2 Jul 2015 13:27:13 +0000 (15:27 +0200)]
When connecting to Metad fails, log the full stack trace

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoSet up the Metad client with allow_non_master
Petr Pudlak [Thu, 2 Jul 2015 13:11:00 +0000 (15:11 +0200)]
Set up the Metad client with allow_non_master

.. since the communication takes place on non-master nodes.

This ensures the client properly retries if there is a communication
failure.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoSet up the configuration client properly on non-masters
Petr Pudlak [Thu, 2 Jul 2015 09:29:28 +0000 (11:29 +0200)]
Set up the configuration client properly on non-masters

If the configuration client is opened in the 'accept_foreign' mode,
meaning it is running on a non-master node temporarily, the option
needs to be propagated to the RPC client as well.

This fixes issue #1115.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoAdd the 'allow_non_master' option to the WConfd RPC client
Petr Pudlak [Thu, 2 Jul 2015 09:28:41 +0000 (11:28 +0200)]
Add the 'allow_non_master' option to the WConfd RPC client

While at it, fix the call to the AbstractStubClient to properly pass the
keyword arguments.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoAdd the option to disable master checks to the RPC client
Petr Pudlak [Thu, 2 Jul 2015 09:26:18 +0000 (11:26 +0200)]
Add the option to disable master checks to the RPC client

The option is propagated to the Transport class and allows to disable
checks for the master node, if the client is run on a different node on
purpose.

While at it, fix the documentation for the arguments of the constructors
of the classes.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoAdd 'allow_non_master' to the Luxi test transport class too
Petr Pudlak [Thu, 2 Jul 2015 11:51:34 +0000 (13:51 +0200)]
Add 'allow_non_master' to the Luxi test transport class too

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoAdd 'allow_non_master' to FdTransport for compatibility
Petr Pudlak [Thu, 2 Jul 2015 09:27:13 +0000 (11:27 +0200)]
Add 'allow_non_master' to FdTransport for compatibility

Since it serves as an alternative to the Transport class, it should
support the same constructor options, even if it doesn't use them.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoProperly document all constructor arguments of Transport
Petr Pudlak [Thu, 2 Jul 2015 09:58:02 +0000 (11:58 +0200)]
Properly document all constructor arguments of Transport

.. while documenting allow_non_master.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoAllow the Transport class to be used for non-master nodes
Petr Pudlak [Fri, 5 Jun 2015 12:13:48 +0000 (14:13 +0200)]
Allow the Transport class to be used for non-master nodes

If a communication failure occurred and the caller was not running on
the master node, Transport assumed that this itself was the cause of
the error condition.

However, for communication with the metadata daemon we need to support
non-master nodes as well.

Add a parameter that allows to use the class on non-master nodes.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

Cherry-picked-from: ade70feb258a57ae0565395ba48ac2b3ef02b1c0
Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoDon't define the set of all daemons twice
Klaus Aehlig [Tue, 30 Jun 2015 15:20:33 +0000 (17:20 +0200)]
Don't define the set of all daemons twice

Currently, we have two places where we define the
list of all Ganeti daemons: the type GanetiDaemon
in Ganeti.Runtime and the constant daemons
in Ganeti.Constants. Avoid this duplication by
using Bounded GanetiDaemons and Enum GanetiDaemons.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Helga Velroyen <helgav@google.com>

5 years agoMerge branch 'stable-2.11' into stable-2.12
Petr Pudlak [Mon, 29 Jun 2015 13:33:39 +0000 (15:33 +0200)]
Merge branch 'stable-2.11' into stable-2.12

* stable-2.11
  Downgrade log-message for rereading job
  Dowgrade log-level for successful requests

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoDowngrade log-message for rereading job
Klaus Aehlig [Mon, 29 Jun 2015 09:34:13 +0000 (11:34 +0200)]
Downgrade log-message for rereading job

The fact that luxid is rereading a job file because it has
changed on disk is mainly of internal interest for debugging.
Hence downgrade the log-level accordingly.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoDowgrade log-level for successful requests
Klaus Aehlig [Mon, 29 Jun 2015 09:30:13 +0000 (11:30 +0200)]
Dowgrade log-level for successful requests

Originally, only queries used the be served by haskell daemons
over domain sockets. As they were not too frequent, it was OK
to log each of them at INFO level. However, with requests as
frequent as WaitForJobChange served via luxid, logs fill up
to quickly. So log at debug level only.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>

5 years agoUpdate design doc with solution for Issue 1094
Helga Velroyen [Tue, 2 Jun 2015 11:52:25 +0000 (13:52 +0200)]
Update design doc with solution for Issue 1094

Fixing issue 1094 unfortunately will result in a bigger
change. This change is big enough to be documented in
the node-security design doc.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

5 years agoPrevent multiple communication nics for one instance
Lisa Velden [Tue, 23 Jun 2015 15:16:42 +0000 (17:16 +0200)]
Prevent multiple communication nics for one instance

Check if a nic name is already in the list of all nics before adding it.
Expand the instance name before that check to ensure that we are always
checking for the correct name.

Signed-off-by: Lisa Velden <velden@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>

5 years agoRemove outdated reference to ganeti-masterd
Klaus Aehlig [Mon, 22 Jun 2015 16:24:38 +0000 (16:24 +0000)]
Remove outdated reference to ganeti-masterd

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>