Iustin Pop [Fri, 4 Mar 2011 10:04:10 +0000 (11:04 +0100)]
RAPI: fix evacuate node resource
PollJob returns the whole op_results, hence a list of opcode results.
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Thu, 3 Feb 2011 11:25:04 +0000 (12:25 +0100)]
backend: Disable compression in export info file
The new import/export infrastructure in Ganeti 2.2 and up handles
compression differently. It no longer writes compressed files to the
destination. Unfortunately changing this behaviour would be non-trivial,
so in the meantime setting “compression = none” will hopefully avoid
some confusion.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 26 Jan 2011 15:46:56 +0000 (16:46 +0100)]
Wait for master to become available on initialization
This is analogue to the existing check for a responsive node daemon.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 26 Jan 2011 15:45:11 +0000 (16:45 +0100)]
Start all daemons on cluster initialization
At least ganeti-confd was not started. It got started a few minutes
later by ganeti-watcher. Also move one pylint disable to the effective
line.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 26 Jan 2011 12:17:33 +0000 (13:17 +0100)]
Clarify job processing order in admin guide
The fact that jobs don't necessarily execute in order has been source
for some confusion. Hopefully this update will clarify things.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 26 Jan 2011 12:08:59 +0000 (13:08 +0100)]
Improve option descriptions
Also replace hardcoded “xenvg” with constant.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Iustin Pop [Wed, 26 Jan 2011 13:13:09 +0000 (14:13 +0100)]
Remove two unused variables
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Wed, 26 Jan 2011 12:07:59 +0000 (13:07 +0100)]
Fix LUOSDiagnose and non-vm_capable nodes
This skips non-vm_capable nodes in the OS diagnose search, since such
OSes will not be used anyway on those nodes.
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
René Nussbaumer [Wed, 26 Jan 2011 10:51:33 +0000 (11:51 +0100)]
Rephrasing two error messages for auto promotion
Using auto_promote or auto-promote can lead to confusion on using the
user facing interfaces. While auto-promote is fine for CLI it's not for
RAPI and vice-versa. This patch should eliminate this confusion.
Signed-off-by: René Nussbaumer <rn@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Iustin Pop [Wed, 26 Jan 2011 09:01:41 +0000 (10:01 +0100)]
storage: Check that mapper is either used or None
This is a followup patch to the one moving GetAllocatable out to
module level.
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Michael Hanselmann [Tue, 25 Jan 2011 18:28:59 +0000 (19:28 +0100)]
Fix bug in “gnt-node list-storage”
LVM PV storage units would always show as allocatable, even when they
weren't. For some reason I have not been able to determine, the function
parsing the attributes (“_GetAllocatable”) was not even called and the
list opcode simply returned the attribute string as the value (e.g.
“a-”). Removing “@staticmethod” did the trick and then I just moved it
to module level.
A QA test is included.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 20 Jan 2011 12:05:58 +0000 (13:05 +0100)]
Improve import/export timeout settings
With this patch, the exporting node will retry to connect a few times.
The receiving node will make use of the master's increased timeout (see
previous patch).
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 20 Jan 2011 11:24:14 +0000 (12:24 +0100)]
Increase remote import/export timeout
It's been shown that 60 seconds may not be enough to establish a
connection.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Guido Trotter [Fri, 14 Jan 2011 13:56:41 +0000 (13:56 +0000)]
Allow burnin with hidden OSes
burnin is a cluster/testing feature, so it makes sense that a hidden OS
can be used for it.
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Stephen Shirley [Wed, 12 Jan 2011 10:46:09 +0000 (11:46 +0100)]
last_resort groups prioritized by iallocator plugin
Also change language slightly for preferred groups to look better now
that it's repeated.
Signed-off-by: Stephen Shirley <diamond@google.com>
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Fri, 7 Jan 2011 15:39:34 +0000 (16:39 +0100)]
gnt-instance info: Show disk template
The data was already there, but not shown.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 6 Jan 2011 19:34:26 +0000 (20:34 +0100)]
Remove unused import from client.gnt_instance
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Adeodato Simo <dato@google.com>
Michael Hanselmann [Thu, 6 Jan 2011 15:38:31 +0000 (16:38 +0100)]
gnt-instance console: Improve error reporting
If the SSH command fails, this will give a more detailed error
message than before.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 25 Nov 2010 19:47:44 +0000 (20:47 +0100)]
Increase timeout for connection on remote import
The source cluster has to shut down an instance before it can be
exported. Doing so can take a while, but the default connection timeout
is only 60 seconds. Adding the shutdown timeout on the receiving cluster
should help.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
(cherry picked from commit
dae91d021ecba089c478163b25dc426abb589351)
Michael Hanselmann [Thu, 6 Jan 2011 16:36:38 +0000 (17:36 +0100)]
import-export: Improve timeout error reporting
When the source cluster takes too long to create a snapshot, the
destination would time out. Unfortunately no good error message was
written unless debug logging was enabled, not even to the log file. This
will be improved with this patch.
Another patch to be backported from master will hopefully avoid this
situation completely.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 6 Jan 2011 10:25:32 +0000 (11:25 +0100)]
cfgupgrade: Remove unused “program” variable
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Wed, 5 Jan 2011 17:41:59 +0000 (18:41 +0100)]
cfgupgrade: Check master name, clarify question
- Check hostname and abort if it doesn't match contents of
“ssconf_master_node”, can be overridden using “--ignore-hostname”
parameter.
- Clarify confirmation question and don't mention instances anymore.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 5 Jan 2011 17:52:29 +0000 (18:52 +0100)]
Makefile: Merge build-time reST copying
No need to copy this snippet around, “make” can work harder for us.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 5 Jan 2011 17:48:29 +0000 (18:48 +0100)]
Move doc/upgrade.rst to UPGRADE, copy at build-time
This will allow distributions to install the file as text documentation.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 5 Jan 2011 15:22:33 +0000 (16:22 +0100)]
Import upgrade notes into documentation
This patch formats the upgrade notes currently in the wiki[1] as reST
and adds them to the documentation.
[1] http://code.google.com/p/ganeti/wiki/UpgradeNotes
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Fri, 31 Dec 2010 12:11:05 +0000 (13:11 +0100)]
Fix typo in gnt-instance manpage
s/os-name/os-type/. This was reported in issue 133.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Tue, 21 Dec 2010 18:10:32 +0000 (19:10 +0100)]
jqueue: Fix cancelling while in waitlock in queue
Since the recent change to leave jobs in the “waitlock” status (commit
5fd6b6947), cancelling a job while it's back in the queue would break.
This patch handles these cases and adds a unittest.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Mon, 20 Dec 2010 21:23:13 +0000 (22:23 +0100)]
cli: Extend message for LUXI timeouts
Point out that jobs already submitted continue to run.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Mon, 20 Dec 2010 19:20:18 +0000 (20:20 +0100)]
Fix timeout handling in LUXI client
If the socket can't be read in time, it raises “socket.timeout”, for
which there is special handling code. Unfortunately the exception block
was in the wrong order and “socket.error” caught it before.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Mon, 20 Dec 2010 14:18:36 +0000 (15:18 +0100)]
Merge branch 'stable-2.3' into devel-2.3
* stable-2.3:
Prepare 2.3.1 release
Fix disk status verification in LUClusterVerify
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Mon, 20 Dec 2010 13:15:19 +0000 (14:15 +0100)]
Prepare 2.3.1 release
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 16 Dec 2010 14:19:52 +0000 (15:19 +0100)]
QA: Run cluster-verify as part of all instance tests
“gnt-cluster verify” looks at some per-instance information as well, so
it should be run for each instance type QA tests.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 15 Dec 2010 19:03:18 +0000 (20:03 +0100)]
QA: Fix typo and add “not”
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 15 Dec 2010 17:53:34 +0000 (18:53 +0100)]
ensure-dirs: Speed up when using big queues
The “ensure-dirs” script as included in Ganeti 2.3 is very slow when
working with big queues requiring a change of permissions on many or all
files.
$ find /var/lib/ganeti/queue/ | wc -l
52354
Before this change:
$ time /usr/local/lib/ganeti/ensure-dirs -f
real 16m4.739s
While not adressed in this patch, I'd like to record the overall
ineffiency of the “ensure-dirs” script, even after this change:
$ time /usr/local/lib/ganeti/ensure-dirs -f
real 5m57.362s
[…]
$ strace -e clone,execve -f -c /usr/local/lib/ganeti/ensure-dirs -f
% time seconds usecs/call calls errors syscall
------ ----------- ----------- --------- --------- ----------------
50.08 5.147090 49 104774 clone
49.92 5.131094 49 104739 execve
More changes will be needed. Just for comparision, a small Python
snippet changing permissions on all files (“ensure-dirs” changes the
owner too):
$ time python -c 'import os; from ganeti import utils;
[os.chmod(i, 0644) for i in
utils.ListVisibleFiles("/var/lib/ganeti/queue/archive/big")]'
real 0m0.605s
[…]
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Adeodato Simo [Wed, 15 Dec 2010 17:40:30 +0000 (17:40 +0000)]
Fix gnt-cluster verify with diskless instances
`gnt-cluster verify` was failing with KeyError if there was any
diskless instance in the cluster. This was because _CollectDiskInfo()
was not including these instances in the returned dictionary, but they
were expected to be present in LUVerifyCluster.Exec().
With this commit, we ensure that the dictionary returned by _CollectDiskInfo
includes entries for diskless instances as well.
Signed-off-by: Adeodato Simo <dato@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Tue, 14 Dec 2010 16:56:39 +0000 (17:56 +0100)]
jqueue: Keep jobs in “waitlock” while returning to queue
Iustin Pop reported that a job's file is updated many times while it
waits for locks held by other thread(s). After an investigation it was
concluded that the reason was a design decision for job priorities to
return jobs to the “queued” status if they couldn't acquire all locks.
Changing a jobs' status or priority requires an update to permanent
storage.
In a high-level view this is what happens:
1. Mark as waitlock
2. Write to disk as permanent storage (jobs left in this state by a
crashing master daemon are resumed on restart)
3. Wait for lock (assume lock is held by another thread)
4. Mark as queued
5. Write to disk again
6. Return to workerpool
Another option originally discussed was to leave the job in the
“waitlock” status. Ignoring priority changes, this is what would happen:
1. If not in waitlock
1.1. Assert state == queued
1.2. Mark as waitlock
1.3. Set start_timestamp
1.4. Write to disk as permanent storage
3. Wait for locks (assume lock is held by another thread)
4. Leave in waitlock
5. Return to workerpool
Now let's assume the lock is released by the other thread:
[…]
3. Wait for locks and get them
4. Assert state == waitlock
5. Set state to running
6. Set exec_timestamp
7. Write to disk
As this change reduces the number of writes from two per lock acquire
attempt to two per opcode and one per priority increase (as happens
after 24 acquire attempts (see mcpu._CalculateLockAttemptTimeouts) until
the highest priority is reached), here's the patch to implement it.
Unittests are updated.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Mon, 13 Dec 2010 17:32:27 +0000 (18:32 +0100)]
Improve jqueue unittests
- Verify job file updates
- Ensure queue lock is released while executing opcode
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Miguel Di Ciurcio Filho [Mon, 13 Dec 2010 19:07:34 +0000 (17:07 -0200)]
Update manpages to display version 2.3
Signed-off-by: Miguel Di Ciurcio Filho <miguel.filho@gmail.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Thu, 9 Dec 2010 13:03:18 +0000 (14:03 +0100)]
Fix disk status verification in LUClusterVerify
Commit b8d26c6 added disk status verification, but it has two
(different) bugs for not healthy nodes.
For offline nodes, we don't add at all the disk status to the
instance/node dict, with the result that the instance is not present in
the instdisk dict if all of its nodes are offline. This creates a
KeyError later when we call VerifyInstance with instdisk[instance].
For online nodes, but which don't return a valid disk status, we simply
set the status to None for each disk, but the code in _VerifyInstance
presumes and requires that each status is a valid tuple of length two.
For both these bugs, we redo the instdisk computations to always include
valid data, and we enhance the asserts to check for consistency.
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>
Guido Trotter [Thu, 9 Dec 2010 15:13:00 +0000 (16:13 +0100)]
Merge branch 'devel-2.2' into devel-2.3
* devel-2.2:
Fix rename for file-backed instances
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Guido Trotter [Thu, 9 Dec 2010 15:12:18 +0000 (16:12 +0100)]
Merge branch 'stable-2.2' into devel-2.2
* stable-2.2:
Fix rename for file-backed instances
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Guido Trotter [Thu, 9 Dec 2010 15:10:54 +0000 (16:10 +0100)]
Merge branch 'stable-2.2' into stable-2.3
* stable-2.2:
Fix rename for file-backed instances
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Guido Trotter [Wed, 8 Dec 2010 14:53:48 +0000 (15:53 +0100)]
Fix rename for file-backed instances
Currently the code wrongly changes the disk logical/physical id
component representing the path from "$storage_dir/$iname/disk$seq" to
"$storage_dir/$iname/disk/$seq" (note the additional slash) breaking the
rename.
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 2 Dec 2010 15:47:56 +0000 (16:47 +0100)]
Merge branch 'stable-2.3' into devel-2.3
* stable-2.3:
Bump version for 2.3.1~rc1 release
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 1 Dec 2010 17:33:27 +0000 (18:33 +0100)]
locking: Clarify message for removed locks
Just being told that a lock doesn't exist can be confusing. One case
were this happens is when a job (e.g. instance modify) waits for a job
removing the instance (e.g. export with remove).
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 1 Dec 2010 19:45:06 +0000 (20:45 +0100)]
Bump version for 2.3.1~rc1 release
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 10 Nov 2010 18:43:01 +0000 (19:43 +0100)]
impexpd: Disable OpenSSL compression in socat if possible
This uses an option only available in patched socat versions. More
information is available from the INSTALL update included in this
patch.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 1 Dec 2010 15:55:47 +0000 (16:55 +0100)]
Merge branch 'stable-2.3' into devel-2.3
* stable-2.3:
Bump version for 2.3.0
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 1 Dec 2010 15:03:56 +0000 (16:03 +0100)]
Bump version for 2.3.0
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Tue, 30 Nov 2010 18:26:46 +0000 (19:26 +0100)]
Merge branch 'devel-2.2' into devel-2.3
* devel-2.2:
Correct version check for release candidates
Fix version check
Add script to check version format
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Tue, 30 Nov 2010 17:50:44 +0000 (18:50 +0100)]
Correct version check for release candidates
The tilde needs to be escaped and I forgot the space which should be
used instead.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Adeodato Simo [Tue, 30 Nov 2010 16:05:47 +0000 (16:05 +0000)]
config.py: need explicit %-formatting in errors.OpPrereqError.
Signed-off-by: Adeodato Simo <dato@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Michael Hanselmann [Wed, 24 Nov 2010 19:50:46 +0000 (20:50 +0100)]
Fix version check
Don't ask … all I say is distcheck.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Wed, 24 Nov 2010 19:18:14 +0000 (20:18 +0100)]
Add script to check version format
Only versions of the format “x.y.z” and “x.y.z~(rc|beta)N” (for N>0) are
allowed.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Iustin Pop [Wed, 24 Nov 2010 17:01:57 +0000 (17:01 +0000)]
Merge branch 'devel-2.2' into devel-2.3
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Wed, 24 Nov 2010 16:06:32 +0000 (16:06 +0000)]
Fix coverage reports
Currently, the coverage reports include the unittests themselves, and
this skewes unfairly the reports, as the coverage for the tests is very
high (since they all run).
To fix this, we export the ganeti temp dir from run-in-temp-dir, and we
use that to exclude the tests directory. The patch also fixes a but
related to multiple directories to be omitted (--omit a --omit b is
wrong, it needs to be --omit a,b).
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Fri, 19 Nov 2010 13:10:54 +0000 (14:10 +0100)]
Updates NEWS and configure.ac for 2.3.0~rc1
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Fri, 19 Nov 2010 13:01:14 +0000 (14:01 +0100)]
Merge branch 'devel-2.2' into devel-2.3
* devel-2.2:
Update NEWS & configure.ac for the 2.2.2 release
Fix documentation regarding conversion to drbd
Conflicts:
NEWS (integrated 2.2 changes)
configure.ac (kept our version)
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Fri, 19 Nov 2010 10:42:35 +0000 (11:42 +0100)]
Update NEWS & configure.ac for the 2.2.2 release
This imports the 2.1.8 NEWS entry and adds the 2.2.2 one, then updates the
configure.ac version.
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Iustin Pop [Fri, 19 Nov 2010 10:17:12 +0000 (11:17 +0100)]
Fix documentation regarding conversion to drbd
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Iustin Pop [Fri, 19 Nov 2010 10:17:12 +0000 (11:17 +0100)]
Fix documentation regarding conversion to drbd
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Iustin Pop [Thu, 18 Nov 2010 09:37:34 +0000 (10:37 +0100)]
Reinstall instance: disallow offline secondaries
Currently, reinstallation of a DRBD instance with the secondary node offline does:
node1# gnt-instance reinstall -f instance1
Waiting for job 139053 for instance1...
Thu Nov 18 01:36:09 2010 - WARNING: Could not prepare block device disk/0 on node node3 (is_primary=False, pass=1): Node is marked offline
Thu Nov 18 01:36:09 2010 - WARNING: Could not shutdown block device disk/0 on node node3: Node is marked offline
Job 139053 for instance1 has failed: Failure: command execution error:
Disk consistency error
Since this fails anyway, let's check the secondary nodes, thus
preventing any modifications to the instance (e.g. OS type change):
node1# gnt-instance reinstall -f instance1
Waiting for job 139058 for instance1...
Job 139058 for instance1 has failed: Failure: prerequisites not met for this operation:
error type: wrong_state, error details:
Instance secondary node offline, cannot reinstall: node3
The patch needs modifications to the _CheckNodeOnline function, in order
to display meaningful messages ("Can't use offline node" would be very
confusing for an instance reinstall, since we didn't select a node
manually).
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Iustin Pop [Thu, 18 Nov 2010 09:23:48 +0000 (10:23 +0100)]
QA: check that doubly modifying an OS state is OK
This would have prevented the bug fixed in the previous patch :(
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Iustin Pop [Thu, 18 Nov 2010 09:20:06 +0000 (10:20 +0100)]
Fix breakage in OS state modify
I was using the feedback_fn function incorrectly (it doesn't
automatically expand the arguments).
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Iustin Pop [Wed, 17 Nov 2010 15:28:23 +0000 (16:28 +0100)]
Merge branch 'devel-2.2' into devel-2.3
* devel-2.2:
QA: add tests for gnt-cluster modify -B
LUSetClusterParms: fix validation of beparams
Conflicts:
lib/cmdlib.py (reverted & applied manually the change)
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>
Iustin Pop [Wed, 17 Nov 2010 10:53:10 +0000 (11:53 +0100)]
QA: add tests for gnt-cluster modify -B
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Wed, 17 Nov 2010 10:52:04 +0000 (11:52 +0100)]
LUSetClusterParms: fix validation of beparams
Since the contents of the dict is validated via the ForceDictType, we can
simply require that it is a dict here. The previous check was wrong, as it was
copied from the HV checks (which also doesn't verify the leaf dict type).
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Iustin Pop [Thu, 11 Nov 2010 09:38:44 +0000 (10:38 +0100)]
Add unittests for TemporaryReservationManager
And fix an error message.
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
David Knowles [Wed, 10 Nov 2010 20:57:19 +0000 (15:57 -0500)]
TempReservationManager: Reserved() doesn't work
Note: It appears this has been around since the initial checkin of
TemporaryReservationManager. I have no idea what this could break, so
someone else may want to test this more thoroughly.
Signed-off-by: David Knowles <dknowles@google.com>
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Tue, 9 Nov 2010 13:56:49 +0000 (14:56 +0100)]
Merge branch 'devel-2.2' into devel-2.3
* devel-2.2:
devel/release: Use release-specific Makefile targets
Makefile: Add new dist target for releases
Makefile: Stricter checks for release distchecks
Conflicts:
Makefile.am: Trivial
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Mon, 8 Nov 2010 19:44:00 +0000 (20:44 +0100)]
devel/release: Use release-specific Makefile targets
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Mon, 8 Nov 2010 19:43:39 +0000 (20:43 +0100)]
Makefile: Add new dist target for releases
A new script, autotools/check-tar, is used to check the resulting
.tar.gz file for unwanted contents like wrong file owners or
permissions.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Apollon Oikonomopoulos [Fri, 5 Nov 2010 14:32:48 +0000 (16:32 +0200)]
Update ganeti-os-interface documentation
man/ganeti-os-interace.sgml lacked complete information for the NIC-related
environment variables. Added a reference to NIC_%N_LINK and NIC_%N_MODE and
clarified the reference to NIC_%N_BRIDGE.
Signed-off-by: Apollon Oikonomopoulos <apollon@noc.grnet.gr>
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
Michael Hanselmann [Thu, 4 Nov 2010 13:39:12 +0000 (14:39 +0100)]
Makefile: Check for empty files and dirs on distcheck
Including empty files can cause unnecessary warnings for packagers.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Thu, 4 Nov 2010 14:56:13 +0000 (15:56 +0100)]
Revert commit
e7e23e73, work around Automake bug
After commit
e7e23e73 the build would fail in distcheck on systems with
Automake 1.10. An investigation identified Automake bug #533[1] as the
cause. Applying the changes in Automake commit
3a12ed5e[2] to the
generated Makefile.in file made distcheck work again.
The underlying problem is that in our case both doc/html and
doc/html/.dir were included in the distributed files. When distcheck
copied the former from the source to the staging directory, it was
marked as read-only (distcheck makes the whole source read-only). It
then tried to copy doc/html/.dir from the build directory, which failed.
Automake 1.11 and newer avoid this problem by adjusting the permissions.
Since depending on Automake 1.11 or above is not an option at this time,
a work-around was found by not using a “.dir” file in doc/html, but
using “index.html” as a flag for creating the directory.
[1] http://sourceware.org/cgi-bin/gnatsweb.pl?cmd=view&database=automake&pr=533
[2] http://git.savannah.gnu.org/gitweb/?p=automake.git;a=commit;h=
3a12ed5e97dc193a38dd14e031658cbd329b50ca
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Wed, 3 Nov 2010 12:56:16 +0000 (13:56 +0100)]
Fix disk checks in “gnt-cluster verify”
Tests have shown that the changes in commit
b8d26c6e5 don't work as
wanted. If any disk wasn't found on the node, all disks located on the
same node would show as faulty. The cause was incorrect exception
handling on the node.
This patch changes the RPC call to return a per-disk success/error
status, avoiding the problem.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Luca Bigliardi <shammash@google.com>
Michael Hanselmann [Wed, 3 Nov 2010 12:49:43 +0000 (13:49 +0100)]
QA: Run “gnt-cluster verify” while DRBD instance exists
This tests some parts of the disk information collection.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Luca Bigliardi <shammash@google.com>
Michael Hanselmann [Tue, 2 Nov 2010 13:42:32 +0000 (14:42 +0100)]
Remove empty file from doc/html in distribution
It's not needed and some packaging systems complain about empty
files.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Tue, 2 Nov 2010 13:41:58 +0000 (14:41 +0100)]
Remove shebang line from ganeti.server.*
Some of then were forgotten.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Tue, 2 Nov 2010 13:16:34 +0000 (14:16 +0100)]
Fix typos in NEWS
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Tue, 2 Nov 2010 10:49:55 +0000 (11:49 +0100)]
Bump version for Ganeti 2.3
Also update cfgupgrade and NEWS.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Guido Trotter [Sat, 30 Oct 2010 08:39:22 +0000 (09:39 +0100)]
Add -s option to gnt-node modify
We can now change a nodes' secondary ip.
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Guido Trotter [Mon, 1 Nov 2010 10:17:21 +0000 (10:17 +0000)]
luxi: disable two lint errors
This is already disabled for the same type of request a couple of lines
above. The new code was introduced in
e986f20c but didn't have the
disables.
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Guido Trotter [Mon, 1 Nov 2010 12:44:22 +0000 (12:44 +0000)]
Remove private ip mention in error message
There is no "private" ip in Ganeti, we only have primary and secondary
ones. Whether they are public or private is a per-installation detail.
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Guido Trotter [Sat, 30 Oct 2010 09:16:20 +0000 (10:16 +0100)]
Add ConfigWriter.GetNodeGroup
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Guido Trotter [Sat, 30 Oct 2010 09:15:58 +0000 (10:15 +0100)]
Improve LookupNodeGroup's docstring
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Guido Trotter [Fri, 29 Oct 2010 11:43:13 +0000 (12:43 +0100)]
Merge the common options between import and add
The "I always wanted to do this" commit.
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Guido Trotter [Fri, 29 Oct 2010 10:42:11 +0000 (11:42 +0100)]
Drop the -g shortcut for --vg-name
Changing the volume group is a lot less frequent than acting on a node
group. As such we drop the "-g" shortcut and require the long option to
be passed. In 2.3 the commands which used to accept the volume group as
"-g" won't have any node group option, so no confusion will arise. Later
on we may pass "-g" as the initial node group name to gnt-cluster init,
although that's not strictly necessary, as modifying it later is always
possible.
Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
Michael Hanselmann [Mon, 1 Nov 2010 15:00:57 +0000 (16:00 +0100)]
Update NEWS for Ganeti 2.3
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Mon, 1 Nov 2010 13:01:23 +0000 (14:01 +0100)]
QA: Test ssconf_instance_list file on rename and creation
This test would've caught the bug fixed in the previous patch.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Mon, 1 Nov 2010 13:00:33 +0000 (14:00 +0100)]
config: Write ssconf after renaming instance
This fixes a bug where the ssconf_instance_list file was
not updated after an instance rename.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Mon, 1 Nov 2010 12:59:47 +0000 (13:59 +0100)]
Change qa_utils.ResolveInstanceName to take name
… instead of an object. Allows it to be used in places where
only the name is available.
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Fri, 29 Oct 2010 14:55:05 +0000 (16:55 +0200)]
Makefile: Add PYTHON_BOOTSTRAP to linted code
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Fri, 29 Oct 2010 14:26:28 +0000 (16:26 +0200)]
Make *.in non-executable
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Fri, 29 Oct 2010 14:10:50 +0000 (16:10 +0200)]
Move ganeti-rapi to ganeti.server.rapi
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Fri, 29 Oct 2010 14:08:48 +0000 (16:08 +0200)]
Move ganeti-noded to ganeti.server.noded
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Fri, 29 Oct 2010 14:05:20 +0000 (16:05 +0200)]
Move ganeti-confd to ganeti.server.confd
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Fri, 29 Oct 2010 13:26:20 +0000 (15:26 +0200)]
Move ganeti-masterd to ganeti.server.masterd
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Fri, 29 Oct 2010 13:13:51 +0000 (15:13 +0200)]
Prepare move of daemons to ganeti.server
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>
Michael Hanselmann [Wed, 27 Oct 2010 17:51:30 +0000 (19:51 +0200)]
Move ganeti-watcher to ganeti.watcher
Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: René Nussbaumer <rn@google.com>