I would like to include this interdiff as well.
I will make a proper patch out of it.
diff --git a/lib/cmdlib/instance_operation.py b/lib/cmdlib/instance_operation.py
index 6f9258a..788b496 100644
--- a/lib/cmdlib/instance_operation.py
+++ b/lib/cmdlib/instance_operation.py
@@ -207,11 +207,11 @@ class LUInstanceShutdown(LogicalUnit):
"""Check arguments.
"""
- if self.op.no_remember and self.op.admin_state_source:
+ if self.op.no_remember and self.op.admin_state_source is not None:
self.LogWarning("Parameter 'admin_state_source' has no effect if used"
" with parameter 'no_remember'")
- if not self.op.admin_state_source:
+ if self.op.admin_state_source is None:
self.op.admin_state_source = constants.ADMIN_SOURCE
Thanks,
Jose
On Jun 06 10:51, Jose A. Lopes wrote:
> This patch series fixes how the KVM daemon is started/stopped. After
> this patch series, the KVM daemon will be started by default at during
> its initialization it will decide whether it should continue running
> or exit. This decision is based on the enabled hypervisors, and the
> user shutdown and vm capable attributes which are made available
> through Ssconf. This patch series also introduces the cluster
> parameter '--user-shutdown' which enables/disables user shutdown at
> the cluster level.
>
> Overall:
> * fix technical debt
> * add user shutdown cluster parameter (including boilerplate)
> * extend ssconf with enabled hypervisors, user shutdown and vm capable
> * modify kvmd to exit if conditions are not met
> * add RPC to start/stop daemon on a node
> * start/stop kvmd if conditions are changed (enabled hypervisors, user
> shutdown and vm capable)
> * extend QA to test modifications to these parameters
>
> Jose A. Lopes (11):
> Fix docstring
> Fix docstrings for hvparams
> Fix docstring and relax type contraints
> Remove unused local variable
> Reuse existing helper function to stop a daemon
> Add 'enabled_user_shutdown' cluster field
> Add hypervisor list, user shutdown, and vm capable to Ssconf
> KVM daemon decides if it should run
> RPC to start/stop a daemon on a node
> Modify how the KVM daemon is started/stopped
> Extend QA with cluster wide user shutdown tests
>
> daemons/daemon-util.in | 1 +
> lib/backend.py | 28 +++++++++--
> lib/bootstrap.py | 9 +++-
> lib/cli.py | 7 +++
> lib/client/gnt_cluster.py | 18 +++++--
> lib/cmdlib/cluster.py | 23 +++++++--
> lib/cmdlib/common.py | 62 +++++++++++++++++++++++
> lib/cmdlib/node.py | 7 ++-
> lib/config.py | 5 ++
> lib/http/server.py | 2 +-
> lib/hypervisor/hv_kvm.py | 15 +++---
> lib/objects.py | 4 ++
> lib/rpc_defs.py | 4 ++
> lib/server/noded.py | 8 +++
> lib/ssconf.py | 22 +++++++++
> lib/watcher/__init__.py | 2 +
> qa/ganeti-qa.py | 1 +
> qa/qa_cluster.py | 100
> ++++++++++++++++++++++++++++++++++++++
> qa/qa_instance.py | 2 +
> src/Ganeti/Constants.hs | 6 +++
> src/Ganeti/Daemon.hs | 1 +
> src/Ganeti/Kvmd.hs | 28 ++++++++++-
> src/Ganeti/Objects.hs | 1 +
> src/Ganeti/OpCodes.hs | 1 +
> src/Ganeti/OpParams.hs | 7 +++
> src/Ganeti/Query/Server.hs | 2 +
> src/Ganeti/Ssconf.hs | 40 ++++++++++++++-
> src/Ganeti/Types.hs | 1 +
> src/Ganeti/Utils.hs | 4 +-
> test/hs/Test/Ganeti/OpCodes.hs | 2 +-
> test/py/cfgupgrade_unittest.py | 1 +
> test/py/daemon-util_unittest.bash | 4 +-
> tools/cfgupgrade | 4 ++
> 33 files changed, 394 insertions(+), 28 deletions(-)
>
> --
> 2.0.0.526.g5318336
>
--
Jose Antonio Lopes
Ganeti Engineering
Google Germany GmbH
Dienerstr. 12, 80331, München
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Geschäftsführer: Graham Law, Christine Elizabeth Flores
Steuernummer: 48/725/00206
Umsatzsteueridentifikationsnummer: DE813741370