- Jun 10, 2011
-
-
Michael Hanselmann authored
iallocator.rst contains the Ganeti version at the top. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
A while ago a new ``multi-relocate`` mode was proposed and documented. As it turned out, the interface had some deficiencies. With this patch The relocation modes are reduced to two and split into separate iallocator request modes: node-evacuate and change-group. Some request and response requirements are clarified in the documentation. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
Chained jobs need to look at previous jobs, including archived ones. A nice side-effect of this change is the ability to look at archived jobs using “gnt-job info <id>” as long as the ID is known. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
René Nussbaumer authored
This includes an own simple cache implementation and an interface to a memcache instance. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Jun 09, 2011
-
-
Guido Trotter authored
Keys generated under debian sid just read "BEGIN PRIVATE KEY" rather than "BEGIN RSA PRIVATE KEY". Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Jun 08, 2011
-
-
Michael Hanselmann authored
- Use functions in ConfigWriter instead of custom loops - Calculate nodes only once instances locks are acquired, removes one potential race condition - Don't retrieve lists of all node/instance information without locks - Additionally move the end of the node time check window after the first RPC call--the second call isn't involved in checking the node time at all Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Michael Hanselmann authored
LUClusterVerifyConfig verifies a number of configuration settings. For doing so, it needs a consistent list of nodes, groups and instances. So far no locks were acquired at all (except for the BGL in shared mode). This is a race condition (e.g. if a node group is added in parallel) and can be fixed by acquiring the BGL in exclusive mode. Since this LU verifies the cluster-wide configuration, doing so instead of acquiring individual locks is just. Includes one typo fix and one docstring update. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
- Jun 07, 2011
-
-
Michael Hanselmann authored
Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Michael Hanselmann authored
Commit 720f56c8 added the ability to specify tags when creating an instance. The “tags” attribute of an instance object needs to be a set, but the patch's code saved it as a list, causing breakage in other parts of Ganeti. This patch changes the code to use TaggableObject.AddTag, which has a nice side-effect of doing some verification (including max. number of tags). Instance import was also broken (no “tags” attribute in options). Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
- Jun 03, 2011
-
-
Iustin Pop authored
Commit 66bd7445 changed the semantics of _JobProcessor on finished jobs, and updated the related unittests in the 2.4 branch. It was then merged to master, however on master there was an additional test for this case, which was not updated. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Jun 01, 2011
-
-
Apollon Oikonomopoulos authored
Instance hooks now get an INSTANCE_TAGS environment variable, which contains a space-delimited list of the affected instance's tags. Also update the documentation to reflect the change. Signed-off-by:
Apollon Oikonomopoulos <apollon@noc.grnet.gr> Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Apollon Oikonomopoulos authored
Add TAG_ADD_OPT option to cli.py and use it in gnt-instance. Modify cli.GenericInstanceCreate() accordingly. Signed-off-by:
Apollon Oikonomopoulos <apollon@noc.grnet.gr> Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Apollon Oikonomopoulos authored
Add a tag slot to opcodes.OpInstanceCreate. We do not reuse _PTags, as this is intended for OpTagsSet and thus: a) is not documented b) does not carry a default value, making it mandatory Also pass the tags to the iallocator during instance creation. 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 authored
The HTTP client code generates quite a lot of debug log messages. With this patch they're hidden unless explicitely enabled in the code. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
* devel-2.4: jqueue: Fix potential race condition when cancelling queued jobs Fix argument order in ReserveLV and ReserveMAC Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Iustin Pop authored
This makes the type definitions a bit more readable/simpler. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This is not handled yet, this patch just adds parsing of the incoming request. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This can be used for debugging. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- May 31, 2011
-
-
Guido Trotter authored
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
Note that --no-disk-moves and --no-instance-moves are not incompatible, but if both are used no solution can possibly exist. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
While still being ignored, now it gets passed down to the iteration function. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
This option doesn't currently do anything. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
When a job was cancelled, its status would be changed and the file written again. Since this was a final status, the job file could be moved anytime for archival. If the job was still in the queue, however, it would be processed (not fully, just updating the “end_timestamp” attribute) and written again. This was bad as it could leave the same job in two different files. With this patch the processor is changed to return early for finished jobs. Cancelling a queued job will finalize it right away. Unittests are updated. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Currently, we only ht-check the result value from the iallocator, and we send whatever we happen to check manually in the LUs that call the iallocator. This is not good, as we have to duplicate checks in many places, and still we might miss checks. So we add add ht information to the per-request variables. As the cluster data is built in one place, the iallocator code itself (and is more consistent), I didn't add checks to that too. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Currently, the iallocator in 'allocate' requires mem_size on input but serialises that as 'memory'. This inconsistency makes it hard to automatically validate the parameters, hence this patch renames mem_size. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Per the design doc, the target_groups request key "if present, it must either be the empty list, or contain a list of group UUIDs". Currently it defaults to None/null, which is not valid. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
In 'allocate' mode, the documentation specifies that we export the hypervisor value (“Allocation needs, in addition: … hypervisor, the hypervisor of this instance”) and we need that on input, however we don't actually export it. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
Commit fdbe29ee changed the iallocator modes from 'r'/'w' to 'ro'/'rw', but forgot one check in LUTestAllocator. This patch just completes the replacements. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- May 30, 2011
-
-
Michael Hanselmann authored
Until now LUNodeMigrate used multiple tasklets to evacuate all primary instances on a node. In some cases it would acquire all node locks, which isn't good on big clusters. With upcoming improvements to the LUs for instance failover and migration, switching to separate jobs looks like a better option. This patch changes LUNodeMigrate to use LU-generated jobs. While working on this patch, I identified a race condition in LUNodeMigrate.ExpandNames. A node's instances were retrieved without a lock and no verification was done. For RAPI, a new feature string is added and can be used to detect clusters which support more parameters for node migration. The client is updated. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com> Signed-off-by:
Michael Hanselmann <hansmi@google.com>
-
Apollon Oikonomopoulos authored
ConfigWriter.ReserveLV() and Configwriter.ReserveMAC() called TemporaryReservationManager.Reserve() with the ec_id and resource arguments swapped. As a result, two reservation attempts for the same resource type within the same LU would fail, even if the resources requested were different, e.g.: $ gnt-instance add -t sharedfile -o debootstrap+default \ --net 0:mac=00:01:02:03:04:00 \ --net 1:mac=00:01:02:03:04:ff \ --disk 0:size=2g test_instance Failure: prerequisites not met for this operation: error type: resource_not_unique, error details: MAC address 00:01:02:03:04:ff already in use in cluster This patch fixes the argument order in the call to Reserve(). Signed-off-by:
Apollon Oikonomopoulos <apollon@noc.grnet.gr> Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
This fixes a unittest failure on 32 bit systems. A recently added unittest for ht.TJobId uses a rather large number (2347625220). On 64 bit systems it is stored as “int”. On 32 bit systems however, Python uses “long”. The two types can be intermixed in Python as the interpreter will take care of conversions. If one processed too many jobs (2**31) on a 32 bit system, ht would no longer accept the job IDs. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- May 28, 2011
-
-
Tsachy Shacham authored
Signed-off-by:
Tsachy Shacham <tsachy@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- May 27, 2011
-
-
Michael Hanselmann authored
The check for container items is useful for tuples and/or lists with non-uniform values. The “anything” check can be used when any value should be accepted for an item. The job ID check, which uses the regexp check, will be used for expressing opcode dependencies on other jobs. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- May 26, 2011
-
-
Michael Hanselmann authored
* devel-2.4: TLReplaceDisks: Move assertion checking locks Conflicts: lib/cmdlib.py: Trivial Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
Commit 1bee66f3 added assertions for ensuring only the necessary locks are kept while replacing disks. One of them makes sure locks have been released during the operation. Unfortunately the commit added the check as part of a “finally” branch, which is also run when an exception is thrown (in which case the locks may not have been released yet). Errors could be masked by the assertion error. Moving the check out of the “finally” branch fixes the issue. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
- May 25, 2011
-
-
Michael Hanselmann authored
With LU-generated jobs only the ID is known. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
If “SubmitPending” were mixed with calls to “QueueJob”, jobs in the internal structures will get duplicate indices. With this change each queued job is assigned a unique index, which will be used for sorting the results. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-