Improve backwards compatibility of Issue 649 fix
Commit e6e4ff4cf8d0100f331f94f7a27aa1e03a5d0e7d fixed Issue 649 by switching theseparator for usb_devices from comma to space. That solved the problem withthe command line, but RAPI was able to work with commas too, so, for backwards...
Add missing NEWS entries from stable-2.8
Some fixes where pushed to the stable-2.8 branch without a corresponding NEWSentry. This patch adds them.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Change usb_devices separator to whitespace
The usb_devices parameter was using comma as a list separator, but this cannotwork because comma is already used as the hypervisor parameter separator.
Change it to use whitespace as a separator, in accordance to what already done...
Add support for blktap2 file-driver
Newer Xen versions use blktap2 instead of blktap. This patch adds supportfor it in Ganeti.
Fixes Issue 638.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Thomas Thrainer <thomasth@google.com>
Fix RAPI network tag handling
The network tags were absent from an if check used to actually listtags. The patch fixes the oversight, and adds a proper error message incase the issue occurs again for a new tag type.
Signed-off-by: Hrvoje Ribicic <riba@google.com>...
Add network tag tests to QA
The QA did not have a test for network tags until now, and this patchremedies the situation.
Signed-off-by: Hrvoje Ribicic <riba@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Make network tags searchable
This patch adds the network tags to the tags searched by gnt-clustersearch-tags, and in the process cleans up the code slightly.
Update opcodes test to include network tags
This patch adds the network tags to the list of all other tag typesthat can be tried in QuickCheck tests.
Fix gnt-network list-tags
Define network tags in haskell part.
This fixes issue 641.
Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>Reviewed-by: Hrvoje Ribicic <riba@google.com>
Version bump for 2.8.3
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Update NEWS for 2.8.3 release
List all the changes that happened between 2.8.2 and 2.8.3.
Support reseting arbitrary params of ext disks
If param=default and the param already exists then we removeit from params dict. This is stolen by GetUpdatedParams() whichis used for hvparams modification/inheritance.
This means that 'default' value is not accepted for an arbitrary...
Allow modification of arbitrary params for ext
Disks of ext template are allowed to have arbitrary parametersstored in the Disk object's params slot. Those parameters can bepassed during creation of a new disk, either in LUInstanceCreate()or in LUInsanceSetParams(). Still those parameters can not be...
Do not clear disk.params in UpgradeConfig()
Commits 5dbee5e and cce4616 fix disk upgrades concerning paramsslot. Since 2.7 params slot should be empty and gets filledany time needed.
Still ext template allows passing arbitrary params per disk.These params should be saved in config file for future use....
SetDiskID() before accepting an instance
SetDiskID() fills physical_id slot of a Disk object.
LUInstanceSetParams() does not invoke SetDiskID() upon creation of anew disk. As a result the physical_id slot of the Disk object inconfig data is missing.
In case of ext disk template, in AcceptInstance() we invoke...
Lock group(s) when creating instances
This is required to prevent race conditions such as removing a networkfrom a group and adding an instance at the same time. (See issue 621#2.)
Signed-off-by: Petr Pudlak <pudlak@google.com>Reviewed-by: Thomas Thrainer <thomasth@google.com>...
Fix job error message after unclean master shutdown
According to commit 599ee321eb, any job-related error messages shouldbe encoded within a Ganeti-specific error and not passed on as astring, to allow for easier parsing.
For jobs suffering from an undesirable status after an unclean master...
Add default file_driver if missing
If the file driver of an instance with file based storage is not specified, thedefault one is automatically added by the UpgradeConfig function.
Fixes Issue 571.
Update tests
Update hypervisor unit tests.
Partial cherry-pick from d2e4e099e4248832fef8ed7b0755d01bd4178e3a
Signed-off-by: Jose A. Lopes <jabolopes@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Xen handle domain shutdown
Update Xen backend to properly recognize when a domain has beenshutdown by the user and to properly cleanup a shutdown domain whenGaneti requests Xen to stop this domain.
Partial cherry-pick from 9d22cc90609e3ee8f0f2b34b793a3daced3c0e61...
Fix evacuation out of drained node
Refactor reading live data in htools
This simplifies different handling of individual items.
Cherry-picked from 8c72f7119f50a11661aacba2a1abffdfdc6f7cfa.
Signed-off-by: Jose A. Lopes <jabolopes@google.com>Reviewed-by: Thomas Thrainer <thomasth@google.com>
master-up-setup: Ping multiple times with a shorter interval
In the case of network problems, one ping packet can possibly get lost.Sending multiple packets is safer. The interval between packets is setto 200ms so that the check finishes faster.
Signed-off-by: Petr Pudlak <pudlak@google.com>...
Add a packet number limit to "fping" in master-ip-setup
This fixes issue #630. Apparently there is a bug in fping 3.5 where itloops forever without "-c" given an unreachable host, even though"-c 1" should be the default according to the man page.
The "-c" flag works on Squeeze. Checking the man pages on the Internet,...
Fix a bug in InstanceSetParams concerning names
In case no name is passed in disk modifications we shouldkeep the old one. If name=none then set disk name to None.
Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>Reviewed-by: Jose A. Lopes <jabolopes@google.com>
build_chroot: hard-code the version of blaze-builder
The newest version does not build on Debian squeeze, so avoidit being pulled in as a dependency.
This is the same issue that has been fixed in [1e078ef3] on master.
Fix error printing
Fixes issue 616.
Allow link local IPv6 gateways
Each host using IPv6 always has a link local address in fe80::/10. It iscommon to use fe80::1 as default gateway to ease client configuration.Ganeti prevented this usage, because it made sure that the IPv6 gatewayis in the IPv6 network the instance is connected to....
Fix NODE/NODE_RES locking in LUInstanceCreate
Both NODE and NODE_RES locks were acquired opportunistically if sorequested by the user. LUInstanceCreate requires, however, that theactually locked elements on NODE and NODE_RES level are the same.
This patch changes the locking of NODE_RES such that those locks are not...
eta-reduce isIpV6
This is not only better style, but also fixes a lint error.Also use the infix form of `elem` to increase readability.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Ganeti.Rpc: use brackets for ipv6 addresses
We detect an IPv6 vs V4 address based on columns, rather than passingthe family from the cluster object to be more future proof (in casewe'll ever support mixed clusters).
Unfortunately quite a bit more code is required to test this: we need an...
Update NEWS file with socket permission fix info
The NEWS file now contains a 2.8.3 entry, describing the fix of theprevious patch.
Fix socket permissions after master-failover
When using gnt-cluster master-failover, on the soon-to-be-master theluxi daemon is started by the node daemon. This makes the luxidaemon inherit the node daemon's umask 077, making the communicationsocket unreadable to group members. When using Ganeti with non-root...
Version bump for 2.8.2
Update NEWS file for 2.8.2 release
Add a section in the file for the new upcoming release.
DRBD: ensure peers are UpToDate for dual-primary
DrbdAttachNet supports both, normal primary/secondary node operation, and(during live migration) dual-primary operation. When resources are newlyattached, we poll until we find all of them in connected or syncing operation....
Improve error message for replace-disks
In some conditions, replace-disks will fail if the disks are not properlyactivated. Improve the error message suggesting to run activate-disks beforeexecuting replace-disks.
Fixes Issue 606.
Signed-off-by: Michele Tartara <mtartara@google.com>...
Add all dependencies for confd as test dependencies
Since our tests pull in confd as a dependency, all build dependenciesfor confd are also necessary to run the tests.
Add snap-server to the test-relevenat packages
While snap-server is only needed for the optional monitoring daemon,some tests, notably those testing these optional features, still dependon it. So, if snap-server is missing, the Haskell tests should not be...
Placate warnings on ganeti.outils_unittest.py
Change ovf.py from using 'if foo:' to 'if foo is not None:' checks assuggested by the FutureWarnings the OVF library raises otherwise.This fixes issue 557.
Signed-off-by: Santi Raffa <rsanti@google.com>Reviewed-by: Jose Lopes <jabolopes@google.com>
Version bump for 2.8.1
Also, update the NEWS file accordingly.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Verify that ConfD is running after master-failover
This patch adds additional 'gnt-node list' commands tothe testing of 'gnt-cluster master-failover' in order totest if ConfD (or LuxiD) is still running after amaster-failover.
Signed-off-by: Helga Velroyen <helgav@google.com>...
daemon-util: handle luxid in {start,stop}_master()
Luxid was not handled in start_master() and stop_master() at all. As a result,during a master-failover, luxid would be left running on the old master andwould not start on the new master, leaving the cluster without management until...
Fix typo in storage.FileStorage docstring
Fix path for serial file
It is actually located inside the queue directory.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Improve harep documentation
Add a more complete description of how the tool works.
Fix typo in walkthrough documentation
Fix typo in walkthrough documentation, where 'instance3' should read'instance1' in order to be consistent with the output below in theexample.
Signed-off-by: Jose A. Lopes <jabolopes@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Don't attemp ipv6 ssh in case of ipv4 cluster
In case of a cluster with primary-ip-version=4, there is no needfor cluster to try ipv6 ssh connections which may timeout.So append '-4' on ssh if cluster is ipv4-only
Signed-off-by: Costas Drogos <costas.drogos@gmail.com>...
Fix outdated documentation for users-setup
The --yes-do-it parameter was not properly documented yet. Add it to theadministration guide.
Fix wrong release date in the NEWS file
Version bump for 2.8.0
Add daemon split design doc
This describes the future planned structure of Ganeti daemons.
Merge branch 'stable-2.7' into stable-2.8
Conflicts are trivially solved.
Conflicts: NEWS...
Version bump for 2.7.2
Change the version number and the NEWS file for the 2.7.2 bugfix release.
Add additional tests for utils.Retry
Also have some tests where the time the various components(inspecting the time function, calling the function, etc) havea non-trivial time. Also, have two tests demonstrating thatthe number of retries actually depends on the amount of time...
Make retry tests independent of actual time
Even in the tests, real time is used. While, generally, the assumptionsabout execution time are pretty safe, in some rare circumstances, e.g.,on machines with extremely heavy load they do not hold true, thus rendering...
Fix corner-case in handling of remaining retry time
Consider a remaining time of 0 as already timed out. Otherwise,there is no guarantee that calling utils.Retry with timeout 0will call the function precisely once; it might run in timeshorter than the resolution of timer....
Perform proper cleanup on termination of Haskell daemons
Haskell deamons did not perform proper cleanup at termination. There was no codefor removing the pid file, and the code in LuxiD for removing the unix socketfile was not working, because it is implemented with a "finally" statement,...
Version bump for 2.8 rc3
Also, add to the NEWS file a couple of items that were still missing.
Fix incorrect manpage reference to htools
the manpages for hcheck, hinfo and hroller have an incorrect referenceto htools(7) which does not exist. This patch links them to htools(1).
This bug also fixes Debian BTS#721824 (http://bugs.debian.org/721824)...
Add a default to file-driver when unspecified over RAPI
The file-driver value, used by file-based instances, had a default value whenan instance was being created over the CLI, but not when the instance wascreated through the RAPI.
This patch introduces a default value for the remote API and, while doing so,...
Remove typo from RAPI documentation
"be used instead." was repeated twice.
Describe the files in doc/users in NEWS
While only a small feature, the files in doc/users can influencethe way ganeti is packaged. Hence it should be mentioned in thenews file.
Update the upgrade procedure
Now that users-setup asks for confirmation, explain in theprocedure how asking for this confirmation can be skipped.This skipping is particularly important for users followingthe recommendation of using the distributed shell (dsh)....
Make tools/users-setup explain its actions first
Before doing any changes, make tools/users-setup explain itsactions first, and ask the user for confirmation. If the firstargument is --yes-do-it, this step will be skipped.
Signed-off-by: Klaus Aehlig <aehlig@google.com>...
Generate tools/users-setup from descriptions
Now that we have a machine readable description of the usersto be added to the system, use it to generate the tools/users-setupscript, so that we again have only one authoritative source ofthe user and group requirements. This also has the advantage of...
Provide ganeti user and group data in easy-to-parse form
Upon build time, also generate, in the directory doc/users, filescontaining the groups, the users with their primary group, and theadditional groupmemberships to be added. In this way, packages can use...
Remove dsahostkeypub during config downgrade
Remove the newly-added DSA host public key field from the configuration filewhen downgrading to 2.7, if present. Otherwise masterd will refuse to start.
Signed-off-by: Apollon Oikonomopoulos <apoikos@gmail.com>...
Mark the DSA host pubkey as optional
Commit a9542a4 introduced support for DSA SSH keys. However, the dsahostkeypubfield added to the config is not marked as optional in the Haskell components.As a result, luxid thinks the config file is corrupt and refuses to start. We...
Fix documentation for gnt-node evacuate -p option
Update the documentation to remove the claim that the --primary-onlyoption results in data copies while in fact it only fails over/migratesthe all primary instances.
Signed-off-by: Leon Handreke <lhandreke@google.com>...
NEWS update and version bump for 2.8 rc2
Latest modifications and fixes added to the NEWS file.
Add unit test for GetLinuxNodeInfo
The function was not unit tested previously.
Prepare GetLinuxNodeInfo for testing
The names of the input files are not hardcoded anymore, but they are now defaultparameters.
No changes for the callers, but it's now possible to test the function moreeasily.
Make the DRBD collector more failure-resilient
If information about instances is not available, just log the error andcontinue without it.
Add function to unwrap Results logging failures
Add logWarningIfBad, a utility function similar to exitIfBad, that logs awarning and returns a default value instead of just crashing the program ifthe unpacked value is Bad.
Allow instance mods if only osparams are given
osparams are now recognized as changes, so changing only those withoutother changes works too now.
(cherry picked from commit 5eae613c2e1e65101c5d5f7d2e8ffd7cc6edc7d5)
Signed-off-by: Thomas Thrainer <thomasth@google.com>...
Fix harep manpage title
The harep manpage title underline was one character short, leading inpandoc producing an invalid manpage header.
Signed-off-by: Apollon Oikonomopoulos <apoikos@gmail.com>Reviewed-by: Thomas Thrainer <thomasth@google.com>
Use FQDN to check master node status
The master node name in SS conf is stored as FQDN, so also use the FQDNon each node to check if it is the master node.
This fixes issue 551.
Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Fix batch creation of instances
During batch creation of instances the 'reason' field in opcodes is setto None (but the field is present). This caused problems when adding areasons to the reason trail.
Setting the default value for the 'reason' field to the empty list fixes...
Fix documentation of gnt-instance batch-create
The documentation of gnt-instance batch-create was outdated andcontained invalid examples. This patch corrects the man page andincludes working example inputs.
Support multi instance allocs without iallocator
If all instances in the multi allocation request have already theirprimary and secondary node set, there is no need for an iallocator. Thusdon't require it in this case and omit the call to it all together....
Support DSA SSH keys in bootstrap
As outlined in issue 338, Ganeti failed to initialize a cluster if noRSA SSH key is present on the master node. This patch extends Ganetissupport to DSA keys, so clusters with only DSA keys are possible now.
This fixes issue 338....
Include VCS version in `gnt-cluster version`
Also print the VCS version in the output of `gnt-cluster version`. Thismakes the VCS version also available over RAPI, etc.
Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Document 'viridian' hypervisor parameter
List the 'viridian' hypervisor parameter (valid for Xen HVM) in thegnt-instance manpage.
Support 'viridian' parameter in Xen HVM
This parameter is required to prevent bluescreens in Windows instances.
This fixes issue 233.
Signed-off-by: Heiko Baumann <heibau@googlemail.com>Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Document --no-conflicts-check for gnt-network
gnt-network add and connect do support the --no-conflicts-check option.This is now also documented in the man pages.
This fixes issue 526.
Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Version bump for 2.8.0 rc1
Update NEWS file and version number.
Add Make to the list of dependencies
Make is a required dependency, but it was not specified in the install guide.This commit adds it.
Check for luxid permission during verify config
confd no longer needs access to the noded certificate file, but luxiddoes. Change the check to use the right user.
Add monitoring-query-format.rst to $(docinput)
Commit 431ff2c10 split the monitoring system documentation in two parts but didnot include the new monitoring-query-format.rst to $(docinput). As a result,current tarballs of 2.8 do not ship doc/monitoring-query-format.rst....
Fix documentation building rules
Implement the correct behavior to be kept when sphinx-build is not installed.It was already correctly checked, but instead of just disabling thedocumentation generation, an error message was printed, having "make" fail....
Check disk template in right dict when copying
Due to the structure of the code this condition can't possibly be true.We have to look in the new_diskparams dict instead, otherwise it'd bepossible to try to update a non-existing entry.
(The same patch is in stable-2.7 as 106441d already)....
ganeti.backend_unittest: chmod restricted cmd dir
TestVerifyRestrictedCmdDirectory.testNormal implicitly relies on the currentumask to check the behaviour of backend._VerifyRestrictedCmdDirectory. However,when run under a more relaxed umask (as in the case of the Debian buildd's...
Fix formatting of tuple in error message
The missing str() call caused to raise another exception than the wantedone. Transforming the tuple to string fixes this problem.
Mark the UUID design doc as implemented
The code implementing the UUID design document is included in Ganeti 2.8.
Clarify that cmdlib/ must be removed downgrading
Downgrading from 2.8 to a previous version will fail if the new cmdlib/directory is not removed.
Fix formatting error in the UPGRADE document
An item of the enumerated list was not rendered correctly.