- Aug 04, 2009
-
-
Iustin Pop authored
This patch adds a new opcode and lu for checking disk sizes. Currently it does only top-level disk verification, and also doesn't check primary/secondary node size mismatches (these two are added as TODOs in the Exec() function of the LU). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Note that this exports the disk size as bdev returns it, in bytes. The value will be converted to MiB in cmdlib. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This patch adds a GetActualSize for block devices that returns the actual disk size. It is done using blockdev (and stat for file storage). While this could be done via reading /sys/block/N/size, that is not as simple as running blockdev, as the correspondence between an LV and its sys entry is not straightforward. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This patch modified OpActivateDisks, LUActivateDisks and gnt-instance activate-disks to support and pass this option to _AssembleInstanceDisks. The patch is quite trivial I think; there should be no issues from it except if used when not needed. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This patch adds an optional parameter to _AssembleInstanceDisks that allows ignoring of size information by making a copy of the disk structure and setting the size to zero. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This method recursively resets the size of the disk and its children to zero. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
This patch changes the DRBD8 class (the only one to use the size in Assemble) to ignore the size in Assemble when a zero size is passed. This will allow activation of disks even when the size recorded in the configuration is wrong. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This is identical to dc30b0e4 but applied to gnt-backup. Thanks to user ocaner for catching it. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Instead of multiple uploads to each node, this script copies everything as needed to the temporary directory, exactly as to be installed in the destination machine, then runs only one rsync per host. This is more dangerous (we can break /etc now), but for development machines is fine. The patch then also uploads the bash completions and the current name for the cron job (I think that ganeti-master-cron is a deprecated name, not that someone actually intends to upload a file named like that). A flag --no-cron is added to skip uploading the cron file if desired. The patch also changes rsync to propagate the file permissions. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Aug 03, 2009
-
-
Iustin Pop authored
This small patch adds a simple Copy method that is can be used for 'throw-away' copies of objects. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Jul 29, 2009
-
-
Guido Trotter authored
When the parameter is set to True and start_daemons is also True, ganeti-masterd will be started with the new --no-voting --yes-do-it options. This new option is set to True only on masterfailover, when no_voting is used. This changed the behavior from 2.0, where we didn't start the master daemon at all, when this option was used. The manpage is also updated to remove the 2.0 only change. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 17, 2009
-
-
Iustin Pop authored
Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Jul 16, 2009
-
-
Raiford Storey authored
[iustin@google.com: slightly reworded the explanation for offline and changed the commit message] Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Iustin Pop authored
In order not to change the default during a stable series, we modify configure.ac to default to one stripe, in effect keeping the status quo (well, minus the LVM Attach() changes). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
LVM has issues when growing stripped volumes, so it's best to specify the growth in exact multiples of the full stripe size (as precise as possible). For this we need to do a couple of changes: - in LVM Attach(), we query additionally the VG extent size and the LV stripe count; since this makes lvs return a (possibly) multi-line output, we now split it into lines and only take the last one - in LVM Grow(), we round up the increase in multiples of the full stripe size The patch also sets the correct target size in DRBD growth. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
- Jul 13, 2009
-
-
Iustin Pop authored
This patch adds instance reinstall to RAPI, with two optional parameters: - ‘os', in order to change the OS on reinstall - ‘nostartup’, in order to leave the instance down after reinstall The call will first shutdown the instance, the reinstall it, and unless ‘nostartup’ has been passed and is equal to 1, it will be started automatically. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Jul 08, 2009
-
-
Guido Trotter authored
This allows failing over in certain corner cases, such as a 2 node cluster with one node down. The man page is also updated to document this dangerous option and how to recover from this situation. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
This will be used by ganeti-noded to start ganeti-masterd in a --no-voting masterfailover. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 01, 2009
-
-
Iustin Pop authored
With the change to stripped LVs, the actual size of a meta device (which is small) can be more than we expected (for non-stripped LVs). This patch increases from 160MB to 1GB the accepted size, and updates the comment with the rationale behind this change. Note that we do want even meta devices stripped, since it can increase metadata update. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
- Jun 30, 2009
-
-
Iustin Pop authored
Currently, when draining nodes we reset their master candidate flag, but we don't instruct them to demote themselves. This leads to “ERROR: file '/var/lib/ganeti/config.data' should not exist on non master candidates (and the file is outdated)”. This patch simply adds a call to node_demote_from_mc in this case. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
This patch fixes a few node readd issues. Currently, the node readd consists of two opcodes: - OpSetNodeParms, which resets the offline/drained flags - OpAddNode (with readd=True), which reconfigures the node The problem is that between these two, the configuration is inconsistent for certain cluster configurations. Thus, this patch removes the first opcode and modified the LUAddNode to deal with this case too. The patch also modifies the computation of the intended master_candidate status, and actually sets the readded node to master candidate if needed. Previously, we didn't modify the existing node at all. Finally, the patch modifies the bottom of the Exec() function for this LU to: - trigger a node update, which in turn redistributes the ssconf files to all nodes (and thus the new node too) - if the new node is not a master candidate, then call the node_demote_from_mc RPC so that old master files are cleared My testing shows this behaves correctly for various cases. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
If the config file is missing when the DemoteFromMC() function is called, it will raise a ProgrammerError. Instead of changing the utils.CreateBackup() file which is called from multiple places, for now we only change the DemoteFromMC() function to not call it if the file is not existing (we rely on the master to prevent race conditions here). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
This patch modifies ConfigWriter.GetMasterCandidateStats to allow it to ignore some nodes in the calculation, so that we can use it to predict cluster state without some nodes (which we know we will modify, and thus we should not rely on their state). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
Currently the message for extraneous files on non master candidates is confusing, to say the least. This makes it hopefully more clear. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
- Jun 29, 2009
-
-
Iustin Pop authored
The code for adjusting the candidate pool size was done after the config update, and this means we triggered the save of the config file without fixing the candidate pool, which aborts with an error. The patch just moves it above. The old comment was valid, but we anyway save the config file in MaintainCandidatePool, so this should be safe. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This patch adds a ‘role’ node list field, which shows a one-character node status. This is a simpler way to see the node status than selecting all the flags individually. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Jun 23, 2009
-
-
Iustin Pop authored
Currently the http library only checks credentials when authentication is required. This means that any credentials are accepted on the root resource, for example, which makes problems hard to diagnose - the user/pw works for all queries, until one tries to do a modification at which point fails. This patch changes the PreHandleRequest() function to not ignore credentials when passed, even if we don't require authentication. This makes the behavior of RAPI more predictable. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
The documentation for the reboot was wrong. This patch fixes it and updates the docstring with more details. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Jun 17, 2009
-
-
Iustin Pop authored
Currently running “gnt-instance list -o+vcpus” fails with a cryptic message: Unhandled Ganeti error: vcpus This is due to multiple issues: - in some corner cases cmdlib.py raises an errors.ParameterError but this is not handled by cli.py - LUQueryInstances declares ‘vcpu’ as a supported field, but doesn't handle it, so instead of failing with unknown parameter, e.g.: Failure: prerequisites not met for this operation: Unknown output fields selected: vcpuscd it raises the ParameteError message This patch: - adds handling of 'vcpus' to LUQueryInstances - adds handling of the ParameterError exception to cli.py - changes the 'else: raise errors.ParameterError' in the field handling of LUQueryInstance to an assert, since it's a programmer error if we reached this step With this, a future unhandled parameter will show: gnt-instance list -o+vcpus Unhandled protocol error while talking to the master daemon: Caught exception: Declared but unhandled parameter 'vcpus' Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
The current check in LUCreateInstance.CheckPrereq() is wrong - it only checks if we got an OS, but not if we got a valid OS. This patch fixes it. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
The size of the instance's disk was not shown in “gnt-instance info”. This patch adds it and formats it nicely if possible. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Jun 16, 2009
-
-
Guido Trotter authored
It was mistakenly called --backend Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
Currently we support querying for "mac" "ip" or "bridge", meaning "the one of the first nic. We are not checking that there is a first nic, though, and thus could incur in errors. This patch fixes it by returning "None" should there be no such nic, as it's done when explicitely asking for a nic via nic.<field>/<N> Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
* master: Update NEWS and version for 2.0.1 release gnt-{instance,backup}(8) --nic is actually --net Fix a wrong function name in backend.DrbdAttachNet GNT-CLUSTER(8) fix search-tags example
-
Iustin Pop authored
Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Guido Trotter authored
Fix a typo in the man pages that used the wrong option name. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jun 15, 2009
-
-
Iustin Pop authored
Commit cf8df3f3 "bdev: forward-port ReAttachNet/DisconnectNet" forward-ported 1.2's bdev.DRBD8.ReAttachNet() to 2.0 while renaming it to AttachNet(), but commit 6b93ec9d "Forward-port DrbdNetReconfig" didn't rename all the calls to it and left one ReAttachNet call in backend.py. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Jun 11, 2009
-
-
Guido Trotter authored
Reported in issue 59. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jun 08, 2009
-
-
Iustin Pop authored
This patch enables stripped LVs, falling back to non-stripped if the stripped creation fails. If the configure-time lvm-stripecount is 1, this patch becomes a noop (with an insignificant python-level overhead, but no extra lvm calls). The effect of this patch is that new instances will get stripped LVs from the start, whereas old instances will have their LVs stripped as soon as replace-disks is run for them. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-