LGTM Thanks,
Guido On Wed, Oct 16, 2013 at 9:59 AM, Helga Velroyen <[email protected]> wrote: > I'm sorry, I missed a spot, interdiff: > > diff --git a/lib/client/gnt_cluster.py b/lib/client/gnt_cluster.py > index 03c2a6f..64594ce 100644 > --- a/lib/client/gnt_cluster.py > +++ b/lib/client/gnt_cluster.py > @@ -1088,9 +1088,6 @@ def SetClusterParams(opts, args): > ToStderr("Please give at least one of the parameters.") > return 1 > > - if _CheckNoLvmStorageOptDeprecated(opts): > - return 1 > - > enabled_disk_templates = _GetEnabledDiskTemplates(opts) > vg_name = _GetVgName(opts, enabled_disk_templates) > > > > > On Wed, Oct 16, 2013 at 6:55 PM, Helga Velroyen <[email protected]> wrote: >> >> This removes the deprecation warning for the option >> '--no-lvm-storage'. The deprecation warning was intended >> to be raised in 2.9 and 2.10 and removed after that. >> >> Signed-off-by: Helga Velroyen <[email protected]> >> --- >> lib/cli.py | 6 ------ >> lib/client/gnt_cluster.py | 41 ++++++++++++----------------------------- >> 2 files changed, 12 insertions(+), 35 deletions(-) >> >> diff --git a/lib/cli.py b/lib/cli.py >> index c9314c9..685cd1b 100644 >> --- a/lib/cli.py >> +++ b/lib/cli.py >> @@ -139,7 +139,6 @@ __all__ = [ >> "NOIPCHECK_OPT", >> "NO_INSTALL_OPT", >> "NONAMECHECK_OPT", >> - "NOLVM_STORAGE_OPT", >> "NOMODIFY_ETCHOSTS_OPT", >> "NOMODIFY_SSH_SETUP_OPT", >> "NONICS_OPT", >> @@ -1231,11 +1230,6 @@ ALLOCATABLE_OPT = cli_option("--allocatable", >> dest="allocatable", >> type="bool", default=None, metavar=_YORNO, >> help="Set the allocatable flag on a volume") >> >> -NOLVM_STORAGE_OPT = cli_option("--no-lvm-storage", dest="lvm_storage", >> - help="Disable support for lvm based >> instances" >> - " (cluster-wide)", >> - action="store_false", default=True) >> - >> ENABLED_HV_OPT = cli_option("--enabled-hypervisors", >> dest="enabled_hypervisors", >> help="Comma-separated list of hypervisors", >> diff --git a/lib/client/gnt_cluster.py b/lib/client/gnt_cluster.py >> index c28936b..03c2a6f 100644 >> --- a/lib/client/gnt_cluster.py >> +++ b/lib/client/gnt_cluster.py >> @@ -78,19 +78,6 @@ _EPO_PING_TIMEOUT = 1 # 1 second >> _EPO_REACHABLE_TIMEOUT = 15 * 60 # 15 minutes >> >> >> -def _CheckNoLvmStorageOptDeprecated(opts): >> - """Checks if the legacy option '--no-lvm-storage' is used. >> - >> - """ >> - if not opts.lvm_storage: >> - ToStderr("The option --no-lvm-storage is no longer supported. If you >> want" >> - " to disable lvm-based storage cluster-wide, use the option" >> - " --enabled-disk-templates to disable all of these lvm-base >> disk " >> - " templates: %s" % >> - utils.CommaJoin(constants.DTS_LVM)) >> - return 1 >> - >> - >> def _InitEnabledDiskTemplates(opts): >> """Initialize the list of enabled disk templates. >> >> @@ -156,9 +143,6 @@ def InitCluster(opts, args): >> @return: the desired exit code >> >> """ >> - if _CheckNoLvmStorageOptDeprecated(opts): >> - return 1 >> - >> enabled_disk_templates = _InitEnabledDiskTemplates(opts) >> >> try: >> @@ -2040,13 +2024,13 @@ commands = { >> InitCluster, [ArgHost(min=1, max=1)], >> [BACKEND_OPT, CP_SIZE_OPT, ENABLED_HV_OPT, GLOBAL_FILEDIR_OPT, >> HVLIST_OPT, MAC_PREFIX_OPT, MASTER_NETDEV_OPT, MASTER_NETMASK_OPT, >> - NIC_PARAMS_OPT, NOLVM_STORAGE_OPT, NOMODIFY_ETCHOSTS_OPT, >> - NOMODIFY_SSH_SETUP_OPT, SECONDARY_IP_OPT, VG_NAME_OPT, >> - MAINTAIN_NODE_HEALTH_OPT, UIDPOOL_OPT, DRBD_HELPER_OPT, >> - DEFAULT_IALLOCATOR_OPT, PRIMARY_IP_VERSION_OPT, >> PREALLOC_WIPE_DISKS_OPT, >> - NODE_PARAMS_OPT, GLOBAL_SHARED_FILEDIR_OPT, USE_EXTERNAL_MIP_SCRIPT, >> - DISK_PARAMS_OPT, HV_STATE_OPT, DISK_STATE_OPT, >> ENABLED_DISK_TEMPLATES_OPT, >> - IPOLICY_STD_SPECS_OPT] + INSTANCE_POLICY_OPTS + SPLIT_ISPECS_OPTS, >> + NIC_PARAMS_OPT, NOMODIFY_ETCHOSTS_OPT, NOMODIFY_SSH_SETUP_OPT, >> + SECONDARY_IP_OPT, VG_NAME_OPT, MAINTAIN_NODE_HEALTH_OPT, >> UIDPOOL_OPT, >> + DRBD_HELPER_OPT, DEFAULT_IALLOCATOR_OPT, PRIMARY_IP_VERSION_OPT, >> + PREALLOC_WIPE_DISKS_OPT, NODE_PARAMS_OPT, GLOBAL_SHARED_FILEDIR_OPT, >> + USE_EXTERNAL_MIP_SCRIPT, DISK_PARAMS_OPT, HV_STATE_OPT, >> DISK_STATE_OPT, >> + ENABLED_DISK_TEMPLATES_OPT, IPOLICY_STD_SPECS_OPT] >> + + INSTANCE_POLICY_OPTS + SPLIT_ISPECS_OPTS, >> "[opts...] <cluster_name>", "Initialises a new cluster >> configuration"), >> "destroy": ( >> DestroyCluster, ARGS_NONE, [YES_DOIT_OPT], >> @@ -2121,12 +2105,11 @@ commands = { >> SetClusterParams, ARGS_NONE, >> [FORCE_OPT, >> BACKEND_OPT, CP_SIZE_OPT, ENABLED_HV_OPT, HVLIST_OPT, >> MASTER_NETDEV_OPT, >> - MASTER_NETMASK_OPT, NIC_PARAMS_OPT, NOLVM_STORAGE_OPT, VG_NAME_OPT, >> - MAINTAIN_NODE_HEALTH_OPT, UIDPOOL_OPT, ADD_UIDS_OPT, >> REMOVE_UIDS_OPT, >> - DRBD_HELPER_OPT, DEFAULT_IALLOCATOR_OPT, >> - RESERVED_LVS_OPT, DRY_RUN_OPT, PRIORITY_OPT, >> PREALLOC_WIPE_DISKS_OPT, >> - NODE_PARAMS_OPT, USE_EXTERNAL_MIP_SCRIPT, DISK_PARAMS_OPT, >> HV_STATE_OPT, >> - DISK_STATE_OPT] + SUBMIT_OPTS + >> + MASTER_NETMASK_OPT, NIC_PARAMS_OPT, VG_NAME_OPT, >> MAINTAIN_NODE_HEALTH_OPT, >> + UIDPOOL_OPT, ADD_UIDS_OPT, REMOVE_UIDS_OPT, DRBD_HELPER_OPT, >> + DEFAULT_IALLOCATOR_OPT, RESERVED_LVS_OPT, DRY_RUN_OPT, PRIORITY_OPT, >> + PREALLOC_WIPE_DISKS_OPT, NODE_PARAMS_OPT, USE_EXTERNAL_MIP_SCRIPT, >> + DISK_PARAMS_OPT, HV_STATE_OPT, DISK_STATE_OPT] + SUBMIT_OPTS + >> [ENABLED_DISK_TEMPLATES_OPT, IPOLICY_STD_SPECS_OPT, >> MODIFY_ETCHOSTS_OPT] + >> INSTANCE_POLICY_OPTS + [GLOBAL_FILEDIR_OPT], >> "[opts...]", >> -- >> 1.8.4 >> > > > > -- > -- > Helga Velroyen | Software Engineer | [email protected] | > > 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 -- Guido Trotter 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
