Commit efbd15d8 authored by Helga Velroyen's avatar Helga Velroyen
Browse files

Downgrade 'vif_script'



This patch adds removing the 'vif_script' attribute
from the cluster's config when downgrading from 2.9
to 2.8. Adaption of the unit test is included.
Signed-off-by: default avatarHelga Velroyen <helgav@google.com>
Reviewed-by: default avatarKlaus Aehlig <aehlig@google.com>
parent 1d9f9df7
......@@ -403,6 +403,7 @@ class TestCfgupgrade(unittest.TestCase):
for xen_variant in [constants.HT_XEN_PVM, constants.HT_XEN_HVM]:
xen_params = hvparams[xen_variant]
self.assertTrue(constants.HV_XEN_CMD not in xen_params)
self.assertTrue(constants.HV_VIF_SCRIPT not in xen_params)
def testDowngradeFullConfigBackwardFrom_2_7(self):
"""Test for upgrade + downgrade + upgrade combination."""
......
......@@ -429,6 +429,9 @@ def DowngradeHvparams(config_data):
# 'xen_cmd' was introduced in 2.9
if constants.HV_XEN_CMD in xen_params:
del xen_params[constants.HV_XEN_CMD]
# 'vif_script' was introducted in 2.9
if constants.HV_VIF_SCRIPT in xen_params:
del xen_params[constants.HV_VIF_SCRIPT]
def DowngradeAll(config_data):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment