Dan Kenigsberg has uploaded a new change for review.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
vdsm-reg: eliminate the VDSMBRIDGE macro
VDSMBRIDGE is a historical macro holding the "management bridge" of Vdsm. Nowadays, this bridge may well not exist as management network are better kept bridge-less. The concept of "management bridge" is currently used only within vdsm-reg, and only when it needs to register to a legcay oVirt-Engine that expects the bridge to exist.
This patch hides the unneeded macro within vdsm-reg, to be completely dropped when vdsm-reg is replaced by an ovirt-node-register utility.
Change-Id: Iaa1dae084ae9df44c10e0f6ae43584544dab2b8d Signed-off-by: Dan Kenigsberg danken@redhat.com --- M configure.ac M vdsm_reg/deployUtil.py.in M vdsm_reg/vdsm-reg-setup.in 3 files changed, 11 insertions(+), 12 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/14/24814/1
diff --git a/configure.ac b/configure.ac index 55879e7..72b56e0 100644 --- a/configure.ac +++ b/configure.ac @@ -142,9 +142,6 @@ AC_SUBST([vdsmreglogdir], ['${localstatedir}/log/vdsm-reg']) AC_SUBST([vdsmupgradedir], ['/data/updates'])
-# Network -AC_SUBST([VDSMBRIDGE], ['ovirtmgmt']) - # Engine Name AC_SUBST([ENGINENAME], ['oVirt Engine'])
diff --git a/vdsm_reg/deployUtil.py.in b/vdsm_reg/deployUtil.py.in index 833a93c..d06fc42 100644 --- a/vdsm_reg/deployUtil.py.in +++ b/vdsm_reg/deployUtil.py.in @@ -86,7 +86,7 @@ SCRIPT_NAME_ADD = "addNetwork" SCRIPT_NAME_DEL = "delNetwork" IFACE_CONFIG = "/etc/sysconfig/network-scripts/ifcfg-" -MGT_BRIDGE_NAME = "@VDSMBRIDGE@" +MGT_BRIDGE_NAME = "ovirtmgmt" REMOTE_SSH_KEY_FILE = ('/engine.ssh.key.txt',) CORE_DUMP_PATH = '/var/lib/vdsm/core' CORE_PATTERN = '/proc/sys/kernel/core_pattern' @@ -471,7 +471,7 @@
def preventDuplicate(bridgeName=None): """ - This function checks if the needed bridge (@VDSMBRIDGE@) already exist. + This function checks if the needed MGT_BRIDGE_NAME already exist. """ if bridgeName is None: bridgeName = MGT_BRIDGE_NAME @@ -1006,8 +1006,8 @@
def makeBridge(vdcName, vdsmDir, bridgeName=None): """ - Create (for RHEL) or rename (oVirt default bridge) to @VDSMBRIDGE@ - bridge. + Create (for RHEL) or rename (oVirt default bridge) to + MGT_BRIDGE_NAME. """ logging.debug('makeBridge begin.') if bridgeName is None: diff --git a/vdsm_reg/vdsm-reg-setup.in b/vdsm_reg/vdsm-reg-setup.in index 6489d8a..dbcf81c 100644 --- a/vdsm_reg/vdsm-reg-setup.in +++ b/vdsm_reg/vdsm-reg-setup.in @@ -4,7 +4,7 @@ # Output: none. # # Steps to perform: Initiate Certificate Initalization -# a. Find menagement bridge and rename it to @VDSMBRIDGE@. +# a. Find menagement bridge and rename it to MGT_BRIDGE_NAME. # b. Create .ssh directory and fetch authorized_keys # c. Call VDC registration. # d. Set time according to rhev-m time. @@ -22,12 +22,12 @@ from config import config import deployUtil import createDaemon +from deployUtil import MGT_BRIDGE_NAME
TICKET_RETRIES=3 DEFAULT_CONFIG_FILE="/etc/vdsm-reg/vdsm-reg.conf" VDSM_CONF="/etc/vdsm/vdsm.conf" SCRIPT_NAME_SAVE="vdsm-store-net-config" -MGT_BRIDGE_NAME="@VDSMBRIDGE@"
class Setup: """ @@ -75,7 +75,7 @@
def renameBridge(self): """ - Rename oVirt default bridge to @VDSMBRIDGE@ bridge. + Rename oVirt-node default bridge to MGT_BRIDGE_NAME. """ logging.debug("renameBridge begin.") fReturn = True @@ -91,8 +91,10 @@ out, err, ret = deployUtil._logExec([os.path.join(self.vdsmDir, SCRIPT_NAME_SAVE)]) if ret: fReturn = False - logging.error("renameBridge Failed to persist @VDSMBRIDGE@ " - "bridge changes. out=%s\nerr=%s\nret=%d", out, err, + logging.error("renameBridge Failed to persist %s " + "bridge changes. out=%s\nerr=%s\nret=%d", + MGT_BRIDGE_NAME, + out, err, ret) except: fReturn = False
oVirt Jenkins CI Server has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 1:
Build Successful
http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/7337/ : SUCCESS
http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/6435/ : SUCCESS
http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/7219/ : SUCCESS
Antoni Segura Puimedon has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 1: Code-Review+1
(2 comments)
http://gerrit.ovirt.org/#/c/24814/1//COMMIT_MSG Commit Message:
Line 8: Line 9: VDSMBRIDGE is a historical macro holding the "management bridge" of Line 10: Vdsm. Nowadays, this bridge may well not exist as management network are Line 11: better kept bridge-less. The concept of "management bridge" is currently Line 12: used only within vdsm-reg, and only when it needs to register to a legcay s/legcay/legacy/ Line 13: oVirt-Engine that expects the bridge to exist. Line 14: Line 15: This patch hides the unneeded macro within vdsm-reg, to be completely Line 16: dropped when vdsm-reg is replaced by an ovirt-node-register utility.
http://gerrit.ovirt.org/#/c/24814/1/vdsm_reg/deployUtil.py.in File vdsm_reg/deployUtil.py.in:
Line 85: ERR_NO_ROUTE = 7 Line 86: SCRIPT_NAME_ADD = "addNetwork" Line 87: SCRIPT_NAME_DEL = "delNetwork" Line 88: IFACE_CONFIG = "/etc/sysconfig/network-scripts/ifcfg-" Line 89: MGT_BRIDGE_NAME = "ovirtmgmt" Will this variable be changed by a downstream patch? It makes sense to do so and I approve of that. Line 90: REMOTE_SSH_KEY_FILE = ('/engine.ssh.key.txt',) Line 91: CORE_DUMP_PATH = '/var/lib/vdsm/core' Line 92: CORE_PATTERN = '/proc/sys/kernel/core_pattern' Line 93: XML_QUOTES = {
Yaniv Bronhaim has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 1: Code-Review+1
Dan Kenigsberg has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 1:
(1 comment)
http://gerrit.ovirt.org/#/c/24814/1/vdsm_reg/deployUtil.py.in File vdsm_reg/deployUtil.py.in:
Line 85: ERR_NO_ROUTE = 7 Line 86: SCRIPT_NAME_ADD = "addNetwork" Line 87: SCRIPT_NAME_DEL = "delNetwork" Line 88: IFACE_CONFIG = "/etc/sysconfig/network-scripts/ifcfg-" Line 89: MGT_BRIDGE_NAME = "ovirtmgmt"
Will this variable be changed by a downstream patch? It makes sense to do s
yes. It would keep the downstream patch more localized to the legacy code than now (when it patches configure.ac) Line 90: REMOTE_SSH_KEY_FILE = ('/engine.ssh.key.txt',) Line 91: CORE_DUMP_PATH = '/var/lib/vdsm/core' Line 92: CORE_PATTERN = '/proc/sys/kernel/core_pattern' Line 93: XML_QUOTES = {
oVirt Jenkins CI Server has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 2:
Build Successful
http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/6446/ : SUCCESS
http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/7230/ : SUCCESS
http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/7348/ : SUCCESS
Douglas Schilling Landgraf has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 2: Code-Review+1
Douglas Schilling Landgraf has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 2: Verified+1
I could register a ovirt-node into engine.
Dan Kenigsberg has posted comments on this change.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
Patch Set 2: Code-Review+2
Dan Kenigsberg has submitted this change and it was merged.
Change subject: vdsm-reg: eliminate the VDSMBRIDGE macro ......................................................................
vdsm-reg: eliminate the VDSMBRIDGE macro
VDSMBRIDGE is a historical macro holding the "management bridge" of Vdsm. Nowadays, this bridge may well not exist as management network are better kept bridge-less. The concept of "management bridge" is currently used only within vdsm-reg, and only when it needs to register to a legacy oVirt-Engine that expects the bridge to exist.
This patch hides the unneeded macro within vdsm-reg, to be completely dropped when vdsm-reg is replaced by an ovirt-node-register utility.
Change-Id: Iaa1dae084ae9df44c10e0f6ae43584544dab2b8d Signed-off-by: Dan Kenigsberg danken@redhat.com Reviewed-on: http://gerrit.ovirt.org/24814 Reviewed-by: Antoni Segura Puimedon asegurap@redhat.com Reviewed-by: Yaniv Bronhaim ybronhei@redhat.com Reviewed-by: Douglas Schilling Landgraf dougsland@redhat.com Tested-by: Douglas Schilling Landgraf dougsland@redhat.com --- M configure.ac M vdsm_reg/deployUtil.py.in M vdsm_reg/vdsm-reg-setup.in 3 files changed, 11 insertions(+), 12 deletions(-)
Approvals: Douglas Schilling Landgraf: Verified; Looks good to me, but someone else must approve Yaniv Bronhaim: Looks good to me, but someone else must approve Antoni Segura Puimedon: Looks good to me, but someone else must approve Dan Kenigsberg: Looks good to me, approved
vdsm-patches@lists.fedorahosted.org