- Jul 19, 2012
-
-
René Nussbaumer authored
Another release candidate is coming. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
René Nussbaumer authored
Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
René Nussbaumer authored
On node groups we don't have the std field. However, the InstancePolicy object always verifies that the std value is within a given range. As we fill it up with defaults if not set (as it happens to be on node groups) and the min value is higher than the default std value (taken from constants.py) we fail. We overcome this situation by simply let the function know if we want to verify the std value at all. If we don't want to verify std, we just set it to a compliant value (min_v) and continue. We also slightly adapt the error message provided, as we don't have std values on groups. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Iustin Pop authored
Sorry, I forgot that with GenerateTable this needs to be handled manually. Fixed now and tested in both ways. (But to be honest, this should be abstracted in GenerateTable, instead of the 'if' test in all its callers.) Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Iustin Pop authored
This will be run only if 'haskell-confd' QA configuration has been enabled. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
This uses confd to query the DRBD minors, which is very special; no other command currently does so. Since the backend is only implemented in the Haskell version of confd, we have checks that 1) confd is enable, and 2) hs confd is also enabled. If by mistake people do manage to query Python confd, the error message will be clean: Query gave non-ok status '2': not implemented So nothing breaks in an "ugly" way. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
This can be queried remotely since it's a pure configuration query. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Iustin Pop authored
This is not implemented currently. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Iustin Pop authored
This fixes an old FIXME. Since we now how actual DRBD configuration data, we can finally compute the instance's secondary nodes. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Iustin Pop authored
This is a complex field, so we have to do a lot of manual work for now. The complexity arises from the fact that the contents of the field, and the way to parse it, depends on the disk type field, so we don't have a single, static way of parsing it. Hence we needed the extensions to the Template Haskell code. Since we now can both load and save the disk type, we can remove the in-memory (duplicate) disk type from the disk objects, relying only on the logical ID to hold the type information. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Iustin Pop authored
It seems this was not updated since the move to static minors… Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
Currently, we only allow field-by-field de-serialisation. Since we have cases where information about how to un-serialise a field is split across two JSON fields (e.g. disk type and disk logical_id, hypervisor and hvparams, etc.), we need to pass the entire object to custom read functions. Furthermore, since we will have to generate two actual fields from the single in-memory field, we need to extend the custom save function so that they can generate additional fields beyond the "main" field value they currently generate. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
Instead of passing an expression (which cannot come from the current module), we pass a name, which is allowed to reference functions from the module we're in. Since we currently don't have custom fields, we don't need to modify any callers. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
This uses the recently-moved functions to implement partial lookup of names on getNode and getInstance, similar to the Python codebase. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
Currently, the LookupResult, MatchPriority and related functions are locate in Loader.hs, since (so far) only hbal needs them in the selection of instances. However, with the new functionality on confd side, we need these functions there too, but we don't want to import Loader.hs (which pulls in lots of balancing-related code). So we move all these function to BasicTypes.hs, since that module is a leaf one, with no other dependencies. Unittests are slightly adjusted (but they are still tested under the 'Loader' group). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
This is not used, as we need a more complex serialisation, which is done in the saveObjectField function. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
- Jul 18, 2012
-
-
Iustin Pop authored
Commit cce46164 fixed upgrading from other 2.6 versions, but accidentally broke upgrading from 2.5 (disk.params was left as None, which breaks FillDict). The simplest way to handle params is to always set them to an empty dict (disregarding what they currently contain). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
René Nussbaumer authored
While looking at the testability of this piece of code, I found another consistency problem. We have two if branches instead of one, with elif's. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
René Nussbaumer authored
This inconsistency was found during rebalancing. Hbal failed because, Ganeti couldn't load the opcode. After digging through the cause, an inconsistency with the "args" field in the LUXI protocol was triggered by the TemplateHaskell side where it's done uniformed. For SubmitJob and SubmitManyJobs we treat args as one argument, containing the job definition. In every other LUXI call args is actually a list of arguments. This patch fixes this consistency. This change is NOT backwards compatible. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 17, 2012
-
-
René Nussbaumer authored
This bug was found during disk parameter debugging. While looking at the config some values seem present on the disk parameters, but that's not expected behaviour. This patch fixes this, and also fixes the "broken" configs automatically upon masterd restart. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 13, 2012
-
-
René Nussbaumer authored
Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
René Nussbaumer authored
Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
René Nussbaumer authored
Update NEWS regarding rc3 fixes and document changes in behaviour. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 11, 2012
-
-
Agata Murawska authored
Added test checking that it is possible to remove an instance with drbd disk when non-primary node is offline. Signed-off-by:
Agata Murawska <agatamurawska@google.com> Reviewed-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Agata Murawska authored
When we delete DRBD disks from some instance, we do not want to get errors due to nodes other than that instance's primary being offline. Signed-off-by:
Agata Murawska <agatamurawska@google.com> Reviewed-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
- Jul 07, 2012
-
-
Iustin Pop authored
Currently, this is not allowed, so one can't run a replace-disks; this breaks any non-invasive method of recovering the redundancy of the instance if its disks are already stopped (but it still works if the disks on the primary are active). So let's fix this inconsistency. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
- Jul 06, 2012
-
-
René Nussbaumer authored
For compatibility with the old Ganeti version, we want to keep the beparams/memory field around for another release. This patch fixes this regression. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 05, 2012
-
-
Iustin Pop authored
Currently, _RedistributeAncillaryFiles computes two lists: the list of online nodes (for all files redistribution), and the list of vm_capable nodes, for hypervisor-specific files. However, the vm_capable list includes offline nodes too, leading to warning messages: WARNING: Copy of file /etc/xen/xend-config.sxp to node node13.example.com failed: Node is marked offline We fix this by trivially intersecting the vm_capable list with the online one. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Bernardo Dal Seno <bdalseno@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
René Nussbaumer authored
This error does not show up until we exceed the pool of master candidates and have nodes which are not master candidates. The background is that we check for master-ip-setup script on master candidates and expect them not to be on the other nodes. However, we distribute a default master-ip-script which break this assumption. Furthermore, there's no reason why the file should just exists on the master candidates. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 04, 2012
-
-
Iustin Pop authored
This is trivial, but can be used easily from automated builds to check that the git tree is clean: files are not modified and untracked files are not present. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Bernardo Dal Seno <bdalseno@google.com>
-
Iustin Pop authored
Commit 3096524e enabled building of test helpers, but forgot to add them to .gitignore, resulting in "unclean" git status output. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Bernardo Dal Seno <bdalseno@google.com>
-
- Jul 03, 2012
-
-
René Nussbaumer authored
Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Bernardo Dal Seno <bdalseno@google.com>
-
René Nussbaumer authored
Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
René Nussbaumer authored
We are about to release another version of Ganeti 2.6, so we prepare the NEWS file with the changes from rc1 to rc2. Signed-off-by:
René Nussbaumer <rn@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
- Jun 29, 2012
-
-
Iustin Pop authored
This patch works around an issue in our build system. Since we don't use cabal or 'ghc -M', we don't track actual dependencies in our Makefile; this in turn means that editing a file that only is used in the main 'htools' binary will keep triggering 'ghc --make' for the hconfd binary; and this actually takes a bit of time to look at all the dependencies. So to work around this, we add a touch after each ghc --make, such that we trigger the unneeded build at most once. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Iustin Pop authored
The same types are reused a couple of times, so let's add a couple of type aliases for easier change later and readability. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
Looking at the output of hcheck, in human readable mode, it looks like it always starts with a blank line. This is not nice, so I wanted to redo this to start cleanly. However, looking at the code, I realised that we need some internal cleanup; 'perGroupChecks' was doing both pure computation (computing the score/stats) and I/O work (printing the stats), which is ugly, so I split that in two; this allows perGroupChecks to be simpler, and we can therefore first compute the group stats, and start the output with the mode in which we run. So right now, hcheck will first output whether we need to run a rebalance, or if no-simulation is selected, etc., and only then display the actual stats, making the output a bit more consistent. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
While removing split instances check from hcheck, I saw a wrong use of 'length': this should only be used when one needs the actual length of the list, and not when one wants to check whether the list is empty or not (in that case, 'null' should be used). To prevent this in the future, let's add a hlint hint for it, and fix the warning it generates in hbal. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-
Iustin Pop authored
Since hbal can now run rebalances even in the presence of split instances, we can remove this check and always run the rebalance. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Agata Murawska <agatamurawska@google.com>
-