From jboggs at redhat.com Mon Aug 1 13:38:07 2011 From: jboggs at redhat.com (Joey Boggs) Date: Mon, 1 Aug 2011 09:38:07 -0400 Subject: [Ovirt-devel] [PATCH] hide kernel messages in admin console Message-ID: <1312205887-19350-1-git-send-email-jboggs@redhat.com> Signed-off-by: Joey Boggs --- scripts/ovirt-admin-shell | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/scripts/ovirt-admin-shell b/scripts/ovirt-admin-shell index 041a5ca..e814756 100755 --- a/scripts/ovirt-admin-shell +++ b/scripts/ovirt-admin-shell @@ -1,3 +1,5 @@ #!/bin/bash . /etc/profile +# Hide kernel messages on the console +dmesg -n 1 sudo /usr/libexec/ovirt-config-setup -- 1.7.5.4 From jboggs at redhat.com Mon Aug 1 16:44:26 2011 From: jboggs at redhat.com (Joey Boggs) Date: Mon, 1 Aug 2011 12:44:26 -0400 Subject: [Ovirt-devel] [PATCH] fix logging for installed nodes writing to /var/log/ovirt.log Message-ID: <1312217066-1321-1-git-send-email-jboggs@redhat.com> Signed-off-by: Joey Boggs --- scripts/ovirtfunctions.py | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-) diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index d38ab6d..f740ffd 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -83,7 +83,7 @@ def parse_defaults(): for line in f: try: line = line.strip() - key, value = line.split("\"", 1) + key, value = line.split("=", 1) key = key.strip("=") value = value.strip("\"") OVIRT_VARS[key] = value @@ -114,7 +114,7 @@ OVIRT_CONFIG_FILES = ["/etc/sysconfig/network-scripts/ifcfg-*", \ "/etc/logrotate.d/ovirt-logrotate.conf" ] def log(log_entry): - if is_firstboot: + if is_firstboot(): log_file = open(OVIRT_TMP_LOGFILE, "a") else: log_file = open(OVIRT_LOGFILE, "a") @@ -194,8 +194,8 @@ def is_booted_from_local_disk(): # was firstboot menu already shown? # state is stored in persistent config partition -def is_firstboot(self): - if not self.OVIRT_VARS.has_key("OVIRT_FIRSTBOOT") or self.OVIRT_VARS["OVIRT_FIRSTBOOT"] == 1: +def is_firstboot(): + if OVIRT_VARS["OVIRT_FIRSTBOOT"] == 1: return True else: return False @@ -1105,3 +1105,5 @@ class PluginBase(object): Must be implemented by the child class. """ pass + +OVIRT_VARS = parse_defaults() -- 1.7.5.4 From pmyers at redhat.com Mon Aug 1 17:37:45 2011 From: pmyers at redhat.com (Perry Myers) Date: Mon, 01 Aug 2011 13:37:45 -0400 Subject: [Ovirt-devel] Condor Cloud + oVirt Node Message-ID: <4E36E469.5050009@redhat.com> I've discussed this a little with Ian off list, but relating to: https://fedoraproject.org/wiki/Features/Condor_Cloud Condor Cloud aims at setting up a bunch of Fedora nodes to act as a mini-cloud managed via the Condor grid infrastructure. So the natural question was... Why not use oVirt Node for this rather than a full Fedora OS install? Pulling condor-cloud and condor RPMs into the core oVirt Node will significantly expand the size of the node and make it more specific purpose, so we thought it made more sense to add this functionality to oVirt Node as a 'plugin' added via edit-livecd to inject it into the ISO offline. So, the flow would look like this: condor-cloud RPM has a script that is bundled with it that is a edit-livecd kickstart, meant to be applied to the stock Fedora oVirt Node that adds Condor and whatever else is needed. So if someone wants to use Condor with oVirt Node they: * install condor-cloud * download ovirt-node ISO * on a F16 host run a command like: edit-node condor-node-plugin.ks * edit-node calls edit-livecd with condor-node-plugin.ks * condor rpm is installed along with deps from fedora repos * Firewall is changed, and whatever else is needed for Condor Node * Condor Node is created as a derivative ISO * User deploys Condor Node and uses Condor Cloud just like they would with Fedora hosts So what we need here to make this work are: * Condor Node kickstart that can be used by the edit-livecd tool * Finish up creating edit-node based on edit-livecd and make Condor Node one of the first examples of an oVirt Node plugin Both of those items are represented on the backlog: https://fedorahosted.org/ovirt/wiki/Backlog Cheers, Perry From mburns at redhat.com Mon Aug 1 18:12:27 2011 From: mburns at redhat.com (Mike Burns) Date: Mon, 1 Aug 2011 14:12:27 -0400 Subject: [Ovirt-devel] [PATCH node] Add missing bnx2x drivers Message-ID: <1312222347-18752-1-git-send-email-mburns@redhat.com> Signed-off-by: Mike Burns --- recipe/common-minimizer.ks | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/recipe/common-minimizer.ks b/recipe/common-minimizer.ks index b9acb85..d542fa8 100644 --- a/recipe/common-minimizer.ks +++ b/recipe/common-minimizer.ks @@ -279,6 +279,7 @@ keep /lib/firmware/adaptec keep /lib/firmware/advansys keep /lib/firmware/bnx2 keep /lib/firmware/bnx2x +keep /lib/firmware/bnx2x* keep /lib/firmware/cxgb3 keep /lib/firmware/cxgb4 keep /lib/firmware/e100 -- 1.7.4.4 From jboggs at redhat.com Tue Aug 2 12:32:47 2011 From: jboggs at redhat.com (Joey Boggs) Date: Tue, 2 Aug 2011 08:32:47 -0400 Subject: [Ovirt-devel] [PATCH] set dmseg in admin-shell to run with sudo Message-ID: <1312288367-29668-1-git-send-email-jboggs@redhat.com> --- scripts/ovirt-admin-shell | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/ovirt-admin-shell b/scripts/ovirt-admin-shell index e814756..84d6762 100755 --- a/scripts/ovirt-admin-shell +++ b/scripts/ovirt-admin-shell @@ -1,5 +1,5 @@ #!/bin/bash . /etc/profile # Hide kernel messages on the console -dmesg -n 1 +sudo dmesg -n 1 sudo /usr/libexec/ovirt-config-setup -- 1.7.5.4 From apevec at redhat.com Tue Aug 2 17:10:13 2011 From: apevec at redhat.com (Alan Pevec) Date: Tue, 2 Aug 2011 19:10:13 +0200 Subject: [Ovirt-devel] [PATCH] in development Fedoras have updates-testing Message-ID: <1312305013-20621-1-git-send-email-apevec@redhat.com> --- recipe/Makefile.am | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/recipe/Makefile.am b/recipe/Makefile.am index b28203c..cca4d99 100644 --- a/recipe/Makefile.am +++ b/recipe/Makefile.am @@ -64,6 +64,7 @@ repos.ks: elif [ 0$(FEDORA) == 0$(CUR_DEVEL) ]; then \ FEDORA_REPO=f$(FEDORA) ;\ FEDORA_REPO_LOC="$(if $(FEDORA_URL),--baseurl=$(FEDORA_URL)/development/$(FEDORA)/$(ARCH)/os,--mirrorlist=$(FEDORA_MIRROR)?repo=fedora-$(FEDORA)&arch=$(ARCH))" ;\ + UPDATE_REPO_LINE="repo --name=$${FEDORA_REPO}-updates-testing $(if $(FEDORA_URL),--baseurl=$(FEDORA_URL)/updates/testing/$(FEDORA)/${ARCH},--mirrorlist=$(FEDORA_MIRROR)?repo=updates-testing-f$(FEDORA)&arch=$(ARCH))\n" ;\ else \ FEDORA_REPO=f$(FEDORA) ;\ FEDORA_REPO_LOC="$(if $(FEDORA_URL),--baseurl=$(FEDORA_URL)/releases/$(FEDORA)/Everything/${ARCH}/os,--mirrorlist=$(FEDORA_MIRROR)?repo=fedora-$(FEDORA)&arch=$(ARCH))" ;\ -- 1.7.3.4 From jboggs at redhat.com Wed Aug 3 01:14:23 2011 From: jboggs at redhat.com (Joey Boggs) Date: Tue, 2 Aug 2011 21:14:23 -0400 Subject: [Ovirt-devel] [PATCH] display ipv6 address in networking details page, also fix ipv6 netmask configurations Message-ID: <1312334063-24026-1-git-send-email-jboggs@redhat.com> rhbz#698650 Signed-off-by: Joey Boggs --- scripts/network.py | 3 +- scripts/ovirt-config-setup.py | 48 ++++++++++++++++++++++++++++++++++------ scripts/ovirtfunctions.py | 20 ++++++++++------ 3 files changed, 54 insertions(+), 17 deletions(-) diff --git a/scripts/network.py b/scripts/network.py index ccc4bd8..f51ee7c 100644 --- a/scripts/network.py +++ b/scripts/network.py @@ -85,9 +85,10 @@ class Network: self.BR_CONFIG += "set %s/DHCPV6C yes\n" % BR_ROOT elif OVIRT_VARS["OVIRT_IPV6"] == "static": self.BR_CONFIG += "set %s/IPV6INIT yes\n" % BR_ROOT - self.BR_CONFIG += "set %s/IPV6ADDR %s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_ADDRESS"]) + self.BR_CONFIG += "set %s/IPV6ADDR %s/%s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_ADDRESS"], OVIRT_VARS["OVIRT_IPV6_NETMASK"]) self.BR_CONFIG += "set %s/IPV6_AUTOCONF no\n" % BR_ROOT self.BR_CONFIG += "set %s/IPV6FORWARDING no\n" % BR_ROOT + self.BR_CONFIG += "set %s/IPV6_DEFAULTGW %s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_GATEWAY"]) else: self.BR_CONFIG += "set %s/IPV6INIT no\n" % BR_ROOT self.BR_CONFIG += "set %s/IPV6_AUTOCONF no\n" % BR_ROOT diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 0de6c2e..8a81feb 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -399,12 +399,15 @@ class NodeConfigScreen(): def ipv6_netmask_callback(self): warn = 0 if not self.ipv6_netdevmask.value() is None and not self.ipv6_netdevmask.value() == "": - if not is_valid_ipv6(self.ipv6_netdevmask.value()): - warn = 1 + try: + if not int(self.ipv6_netdevmask.value()) in range(1,128): + warn = 1 + except: + warn = 1 if warn == 1: self.screen.setColor("BUTTON", "black", "red") self.screen.setColor("ACTBUTTON", "blue", "white") - ButtonChoiceWindow(self.screen, "Network", "Invalid IP Address", buttons = ['Ok']) + ButtonChoiceWindow(self.screen, "Network", "Invalid IPv6 Netmask", buttons = ['Ok']) self.ipv6_netdevmask.set("") self.reset_screen_colors() return @@ -566,9 +569,9 @@ class NodeConfigScreen(): if not interface == "lo": if has_ip_address(interface) or get_ipv6_address(interface): ipv4_address = get_ip_address(interface) - if get_ipv6_address(interface): - ipv6_address = get_ipv6_address(interface) - else: + try: + ipv6_address, netmask = get_ipv6_address(interface) + except: ipv6_address = "" self.network_status[interface] = (ipv4_address,ipv6_address) except: @@ -577,7 +580,10 @@ class NodeConfigScreen(): for key in sorted(self.network_status.iterkeys()): if key.startswith("br"): parent_dev = key[+2:] - del self.network_status[parent_dev] + try: + del self.network_status[parent_dev] + except: + pass for key in sorted(self.network_status.iterkeys()): ipv4_addr, ipv6_addr = self.network_status[key] cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/BOOTPROTO" % str(key) @@ -600,7 +606,7 @@ class NodeConfigScreen(): if ipv6_addr != "": status_text += "%1s: %5s %14s \nIPv6: %1s\n\n" % (key.strip(),dev_bootproto.strip(),ipv4_addr.strip(),ipv6_addr.strip()) else: - status_text += "%1s: %5s %14s \n\n" % (key.strip(),dev_bootproto.strip(),ipv4_addr.strip(),ipv6_addr.strip()) + status_text += "%1s: %5s %14s \n\n" % (key.strip(),dev_bootproto.strip(),ipv4_addr.strip()) status_text.strip() networking = TextboxReflowed(32, status_text, maxHeight=10) networking.setText(status_text) @@ -975,6 +981,32 @@ class NodeConfigScreen(): self.ipv6_netdevmask.setCallback(self.ipv6_netmask_callback) self.ipv6_netdevgateway = Entry(39, "", scroll = 0) self.ipv6_netdevgateway.setCallback(self.ipv6_gateway_callback) + if "OVIRT_IPV6_ADDRESS" in OVIRT_VARS: + self.ipv6_netdevip.set(OVIRT_VARS["OVIRT_IPV6_ADDRESS"]) + else: + try: + current_ip, current_netmask = get_ipv6_address(self.nic_lb.current()) + except: + current_ip = "" + current_netmask = "" + if current_ip == "": + try: + current_ip, current_netmask = get_ipv6_address("br" + self.nic_lb.current()) + except: + pass + if current_ip != "": + self.ipv6_netdevip.set(current_ip) + if "OVIRT_IPV6_NETMASK" in OVIRT_VARS: + self.ipv6_netdevmask.set(OVIRT_VARS["OVIRT_IPV6_NETMASK"]) + else: + if current_ip != "": + self.ipv6_netdevmask.set(current_netmask) + if "OVIRT_IPV6_GATEWAY" in OVIRT_VARS: + self.ipv6_netdevgateway.set(OVIRT_VARS["OVIRT_IPV6_GATEWAY"]) + else: + current_gateway = get_ipv6_gateway(self.nic_lb.current()) + if current_gateway == "": + current_gateway = get_gateway("br" + self.nic_lb.current()) ipv6_grid = Grid (5,4) ipv6_grid.setField(Label("IP Address: "), 0, 1, anchorLeft = 1) ipv6_grid.setField(Label("Netmask: "), 0, 2, anchorLeft = 1) diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index 271b16b..8c7bea5 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -854,18 +854,22 @@ def get_gateway(ifname): return result def get_ipv6_address(interface): - inet6_lookup_cmd = 'ifconfig ' + interface + ' |grep inet6|grep -v Global|awk {\'print $3\'}' + inet6_lookup_cmd = 'ifconfig ' + interface + ' |grep inet6|grep Global|awk {\'print $3\'}' inet6_lookup = subprocess.Popen(inet6_lookup_cmd, shell=True, stdout=PIPE, stderr=STDOUT) ipv6_addr = inet6_lookup.stdout.read() - - if "/" in ipv6_addr: - while not ipv6_addr.endswith("/"): - ipv6_addr = ipv6_addr[:-1] - ipv6_addr = ipv6_addr.strip("/") - return ipv6_addr - + try: + ip, netmask = ipv6_addr.split("/") + return (ip,netmask) + except: + log("unable to determine ip/netmask from: " + ipv6_addr) return False +def get_ipv6_gateway(ifname): + cmd = "ip route list dev "+ ifname + " | awk ' /^default/ {print $3}'" + result = subprocess.Popen(cmd, shell=True, stdout=PIPE, stderr=STDOUT) + result = result.stdout.read().strip() + return result + def has_ip_address(ifname): s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) try: -- 1.7.5.4 From apevec at gmail.com Wed Aug 3 09:07:30 2011 From: apevec at gmail.com (Alan Pevec) Date: Wed, 3 Aug 2011 11:07:30 +0200 Subject: [Ovirt-devel] [PATCH] display ipv6 address in networking details page, also fix ipv6 netmask configurations In-Reply-To: <1312334063-24026-1-git-send-email-jboggs@redhat.com> References: <1312334063-24026-1-git-send-email-jboggs@redhat.com> Message-ID: subject is too long - 1. line should be 50 chars or less, put detailed description in 3. and following lines http://spheredev.org/wiki/Git_for_the_lazy#Writing_good_commit_messages > - ? ? ? ? ? ? ? ?self.BR_CONFIG += "set %s/IPV6ADDR %s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_ADDRESS"]) > + ? ? ? ? ? ? ? ?self.BR_CONFIG += "set %s/IPV6ADDR %s/%s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_ADDRESS"], OVIRT_VARS["OVIRT_IPV6_NETMASK"]) While at it, this whole section could be made more readable by using multi-line string: map=OVIRT_VARS.copy() map["BR_ROOT"]=BR_ROOT self.BR_CONFIG = """ set %(BR_ROOT)s/IPV6ADDR %(OVIRT_IPV6_ADDRESS)s/%(OVIRT_IPV6_NETMASK)s set %(BR_ROOT)s/IPV6_AUTOCONF no set %(BR_ROOT)s/IPV6FORWARDING no set %(BR_ROOT)s/IPV6_DEFAULTGW %(OVIRT_IPV6_GATEWAY)s """ % map > ? ? ? ? ? ? ? ? for key in sorted(self.network_status.iterkeys()): > ? ? ? ? ? ? ? ? ? ? if key.startswith("br"): > ? ? ? ? ? ? ? ? ? ? ? ? parent_dev = key[+2:] > - ? ? ? ? ? ? ? ? ? ? ? ?del self.network_status[parent_dev] > + ? ? ? ? ? ? ? ? ? ? ? ?try: > + ? ? ? ? ? ? ? ? ? ? ? ? ? ?del self.network_status[parent_dev] > + ? ? ? ? ? ? ? ? ? ? ? ?except: > + ? ? ? ? ? ? ? ? ? ? ? ? ? ?pass Why not network_status.pop(parent_dev) ? > ?def get_ipv6_address(interface): > - ? ?inet6_lookup_cmd = 'ifconfig ' + interface + ' |grep inet6|grep -v Global|awk {\'print $3\'}' > + ? ?inet6_lookup_cmd = 'ifconfig ' + interface + ' |grep inet6|grep Global|awk {\'print $3\'}' Better use ip command, ifconfig is obsolete: inet6_lookup_cmd = "ip addr show dev %s | awk '$1==\"inet6\" && $4==\"global\" { print $2 }'" % interface BTW, a general note, when parsing command output you must ensure locale but in case of ovirt/rhevh that's fixed in the image. Best would be to replace it with python-only code, there's http://pypi.python.org/pypi/netifaces - it's in F16 so we could have a look at it. Alan From mburns at redhat.com Wed Aug 3 15:06:29 2011 From: mburns at redhat.com (Mike Burns) Date: Wed, 3 Aug 2011 11:06:29 -0400 Subject: [Ovirt-devel] [PATCH node] Handle installs to usb devices with FS on root device Message-ID: <1312383989-5686-1-git-send-email-mburns@redhat.com> The check for valid devices looked to see if a filesystem was installed on the device chosen. It was intended to check for whether the device was a partition or not. Using DEVTYPE solves this. rhbz#698158 Signed-off-by: Mike Burns --- scripts/ovirt-boot-functions | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ovirt-boot-functions b/scripts/ovirt-boot-functions index 9710eb2..4c037be 100644 --- a/scripts/ovirt-boot-functions +++ b/scripts/ovirt-boot-functions @@ -57,10 +57,10 @@ find_disk() { # /dev/disk/by-id/{ata,cciss,scsi,usb}* correctly, # so manually enumerate them for d in $(ls /dev/disk/by-id/ata* /dev/disk/by-id/cciss* /dev/disk/by-id/scsi* /dev/disk/by-id/usb* 2>/dev/null); do - ID_FS_USAGE= + DEVTYPE= eval $(udev_info $(readlink -f $d) property "--export") # ID_FS_USAGE is set for partitions - if [ -z "$ID_FS_USAGE" -a "$ID_BUS" = "$bus" ]; then + if [ "$DEVTYPE" = "disk" -a "$ID_BUS" = "$bus" ]; then if [ -z "$serial" -o "$serial" = "ALL" \ -o "$ID_SERIAL" = "$serial" ]; then local dev="$(readlink -e $d)" -- 1.7.4.4 From jboggs at redhat.com Wed Aug 3 18:38:20 2011 From: jboggs at redhat.com (Joey Boggs) Date: Wed, 3 Aug 2011 14:38:20 -0400 Subject: [Ovirt-devel] [PATCH] display ipv6 address in networking details page, also fix ipv6 netmask configurations. Message-ID: <1312396700-9864-1-git-send-email-jboggs@redhat.com> rhbz#698650 Signed-off-by: Joey Boggs --- scripts/network.py | 3 +- scripts/ovirt-config-setup.py | 46 +++++++++++++++++++++++++++++++++------- scripts/ovirtfunctions.py | 22 +++++++++++-------- 3 files changed, 53 insertions(+), 18 deletions(-) diff --git a/scripts/network.py b/scripts/network.py index ccc4bd8..f51ee7c 100644 --- a/scripts/network.py +++ b/scripts/network.py @@ -85,9 +85,10 @@ class Network: self.BR_CONFIG += "set %s/DHCPV6C yes\n" % BR_ROOT elif OVIRT_VARS["OVIRT_IPV6"] == "static": self.BR_CONFIG += "set %s/IPV6INIT yes\n" % BR_ROOT - self.BR_CONFIG += "set %s/IPV6ADDR %s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_ADDRESS"]) + self.BR_CONFIG += "set %s/IPV6ADDR %s/%s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_ADDRESS"], OVIRT_VARS["OVIRT_IPV6_NETMASK"]) self.BR_CONFIG += "set %s/IPV6_AUTOCONF no\n" % BR_ROOT self.BR_CONFIG += "set %s/IPV6FORWARDING no\n" % BR_ROOT + self.BR_CONFIG += "set %s/IPV6_DEFAULTGW %s\n" % (BR_ROOT, OVIRT_VARS["OVIRT_IPV6_GATEWAY"]) else: self.BR_CONFIG += "set %s/IPV6INIT no\n" % BR_ROOT self.BR_CONFIG += "set %s/IPV6_AUTOCONF no\n" % BR_ROOT diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 0de6c2e..8c6c8af 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -399,12 +399,15 @@ class NodeConfigScreen(): def ipv6_netmask_callback(self): warn = 0 if not self.ipv6_netdevmask.value() is None and not self.ipv6_netdevmask.value() == "": - if not is_valid_ipv6(self.ipv6_netdevmask.value()): - warn = 1 + try: + if not int(self.ipv6_netdevmask.value()) in range(1,128): + warn = 1 + except: + warn = 1 if warn == 1: self.screen.setColor("BUTTON", "black", "red") self.screen.setColor("ACTBUTTON", "blue", "white") - ButtonChoiceWindow(self.screen, "Network", "Invalid IP Address", buttons = ['Ok']) + ButtonChoiceWindow(self.screen, "Network", "Invalid IPv6 Netmask", buttons = ['Ok']) self.ipv6_netdevmask.set("") self.reset_screen_colors() return @@ -566,9 +569,9 @@ class NodeConfigScreen(): if not interface == "lo": if has_ip_address(interface) or get_ipv6_address(interface): ipv4_address = get_ip_address(interface) - if get_ipv6_address(interface): - ipv6_address = get_ipv6_address(interface) - else: + try: + ipv6_address, netmask = get_ipv6_address(interface) + except: ipv6_address = "" self.network_status[interface] = (ipv4_address,ipv6_address) except: @@ -577,7 +580,8 @@ class NodeConfigScreen(): for key in sorted(self.network_status.iterkeys()): if key.startswith("br"): parent_dev = key[+2:] - del self.network_status[parent_dev] + if self.network_status.has_key(parent_dev): + del self.network_status[parent_dev] for key in sorted(self.network_status.iterkeys()): ipv4_addr, ipv6_addr = self.network_status[key] cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/BOOTPROTO" % str(key) @@ -600,7 +604,7 @@ class NodeConfigScreen(): if ipv6_addr != "": status_text += "%1s: %5s %14s \nIPv6: %1s\n\n" % (key.strip(),dev_bootproto.strip(),ipv4_addr.strip(),ipv6_addr.strip()) else: - status_text += "%1s: %5s %14s \n\n" % (key.strip(),dev_bootproto.strip(),ipv4_addr.strip(),ipv6_addr.strip()) + status_text += "%1s: %5s %14s \n\n" % (key.strip(),dev_bootproto.strip(),ipv4_addr.strip()) status_text.strip() networking = TextboxReflowed(32, status_text, maxHeight=10) networking.setText(status_text) @@ -975,6 +979,32 @@ class NodeConfigScreen(): self.ipv6_netdevmask.setCallback(self.ipv6_netmask_callback) self.ipv6_netdevgateway = Entry(39, "", scroll = 0) self.ipv6_netdevgateway.setCallback(self.ipv6_gateway_callback) + if "OVIRT_IPV6_ADDRESS" in OVIRT_VARS: + self.ipv6_netdevip.set(OVIRT_VARS["OVIRT_IPV6_ADDRESS"]) + else: + try: + current_ip, current_netmask = get_ipv6_address(self.nic_lb.current()) + except: + current_ip = "" + current_netmask = "" + if current_ip == "": + try: + current_ip, current_netmask = get_ipv6_address("br" + self.nic_lb.current()) + except: + pass + if current_ip != "": + self.ipv6_netdevip.set(current_ip) + if "OVIRT_IPV6_NETMASK" in OVIRT_VARS: + self.ipv6_netdevmask.set(OVIRT_VARS["OVIRT_IPV6_NETMASK"]) + else: + if current_ip != "": + self.ipv6_netdevmask.set(current_netmask) + if "OVIRT_IPV6_GATEWAY" in OVIRT_VARS: + self.ipv6_netdevgateway.set(OVIRT_VARS["OVIRT_IPV6_GATEWAY"]) + else: + current_gateway = get_ipv6_gateway(self.nic_lb.current()) + if current_gateway == "": + current_gateway = get_gateway("br" + self.nic_lb.current()) ipv6_grid = Grid (5,4) ipv6_grid.setField(Label("IP Address: "), 0, 1, anchorLeft = 1) ipv6_grid.setField(Label("Netmask: "), 0, 2, anchorLeft = 1) diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index 271b16b..6ef27d3 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -854,18 +854,22 @@ def get_gateway(ifname): return result def get_ipv6_address(interface): - inet6_lookup_cmd = 'ifconfig ' + interface + ' |grep inet6|grep -v Global|awk {\'print $3\'}' + inet6_lookup_cmd = "ip addr show dev %s | awk '$1==\"inet6\" && $4==\"global\" { print $2 }'" % interface inet6_lookup = subprocess.Popen(inet6_lookup_cmd, shell=True, stdout=PIPE, stderr=STDOUT) - ipv6_addr = inet6_lookup.stdout.read() - - if "/" in ipv6_addr: - while not ipv6_addr.endswith("/"): - ipv6_addr = ipv6_addr[:-1] - ipv6_addr = ipv6_addr.strip("/") - return ipv6_addr - + ipv6_addr = inet6_lookup.stdout.read().strip() + try: + ip, netmask = ipv6_addr.split("/") + return (ip,netmask) + except: + log("unable to determine ip/netmask from: " + ipv6_addr) return False +def get_ipv6_gateway(ifname): + cmd = "ip route list dev "+ ifname + " | awk ' /^default/ {print $3}'" + result = subprocess.Popen(cmd, shell=True, stdout=PIPE, stderr=STDOUT) + result = result.stdout.read().strip() + return result + def has_ip_address(ifname): s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) try: -- 1.7.5.4 From jboggs at redhat.com Wed Aug 3 21:08:51 2011 From: jboggs at redhat.com (Joey Boggs) Date: Wed, 3 Aug 2011 17:08:51 -0400 Subject: [Ovirt-devel] [PATCH] update valid_hostname regex checks Message-ID: <1312405731-21680-1-git-send-email-jboggs@redhat.com> rhbz#720956 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 22 +++++++++++++--------- scripts/ovirtfunctions.py | 10 +++++++--- 2 files changed, 20 insertions(+), 12 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 8c6c8af..a8f85cf 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -274,8 +274,8 @@ class NodeConfigScreen(): warn = 0 if not self.ntp_host2.value() is None and not self.ntp_host2.value() == "": if not is_valid_ipv4(self.ntp_host2.value()): - if not is_valid_ipv6(self.ntp_host1.value()): - if not is_valid_hostname(self.ntp_host1.value()): + if not is_valid_ipv6(self.ntp_host2.value()): + if not is_valid_hostname(self.ntp_host2.value()): warn = 1 if warn == 1: self.screen.setColor("BUTTON", "black", "red") @@ -506,11 +506,12 @@ class NodeConfigScreen(): self.reset_screen_colors() def valid_hostname_callback(self): - if not is_valid_hostname(self.net_hostname.value()): - self.screen.setColor("BUTTON", "black", "red") - self.screen.setColor("ACTBUTTON", "blue", "white") - ButtonChoiceWindow(self.screen, "Configuration Check", "Invalid Hostname", buttons = ['Ok']) - self.reset_screen_colors() + if not self.net_hostname.value() == "": + if not is_valid_hostname(self.net_hostname.value()): + self.screen.setColor("BUTTON", "black", "red") + self.screen.setColor("ACTBUTTON", "blue", "white") + ButtonChoiceWindow(self.screen, "Configuration Check", "Invalid Hostname", buttons = ['Ok']) + self.reset_screen_colors() def valid_fqdn_or_ipv4(self): warn = 0 @@ -1143,10 +1144,13 @@ class NodeConfigScreen(): self.menuo = self.menu_list.current() def process_network_config(self): - if self.net_hostname.value() != self.current_hostname and is_valid_hostname(self.net_hostname.value()): + if self.net_hostname.value() == "": + augtool("set", "/files/etc/sysconfig/network/HOSTNAME", "") + os.system("hostname \"" + self.net_hostname.value()+"\"") + elif self.net_hostname.value() != self.current_hostname and is_valid_hostname(self.net_hostname.value()): augtool("set", "/files/etc/sysconfig/network/HOSTNAME", self.net_hostname.value()) os.system("hostname " + self.net_hostname.value()) - ovirt_store_config("/etc/sysconfig/network") + ovirt_store_config("/etc/sysconfig/network") dns_servers = "" ntp_servers = "" if not self.dns_host1.value() == "": diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index ae454e5..2d6fac4 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -781,11 +781,15 @@ def is_valid_ipv6(ip_address): return False def is_valid_hostname(hostname): - regex = "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])\.)*([A-Za-z]|[A-Za-z][A-Za-z0-9\-]*[A-Za-z0-9])$" - if re.match(regex, hostname): + regex_1 = "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])\.)+([a-zA-Z0-9]{2,5})" + regex_2 = "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])\.)*([A-Za-z]|[A-Za-z][A-Za-z0-9\-]*[A-Za-z0-9])$" + if re.match(regex_1, hostname): return True else: - return False + if re.match(regex_2, hostname): + return True + else: + return False def is_valid_nfs(nfs_entry): regex = "^([a-zA-Z0-9_\-]+)([\.][a-zA-Z0-9_\-]+)+([:][/][a-zA-Z0-9\~\(\)_\-]*)+([\.][a-zA-Z0-9\(\)_\-]+)*" -- 1.7.5.4 From mburns at redhat.com Wed Aug 3 22:04:15 2011 From: mburns at redhat.com (Mike Burns) Date: Wed, 03 Aug 2011 18:04:15 -0400 Subject: [Ovirt-devel] RFC: ovirt-node ISO Message-ID: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> As we prepare to push ovirt-node ISOs to ovirt.org while also working on getting an ovirt-node spin into Fedora, there is some debate over whether the version hosted on ovirt.org should use the minimizer kickstart or not. Main argument for including the minimizer kickstart: Size. We're currently looking at something around 130MB for the ISO with minimizer and probably around double that without it (I don't have one built currently without the minimizer so I don't have the actual size). Main argument for not using the minimizer: Consistently with the fedora spin. We can't use the minimizer in the Fedora spins, so providing an ISO that matches the fedora spin would be the same. Any votes or preferences on which we want to host? Mike From pmyers at redhat.com Wed Aug 3 22:45:54 2011 From: pmyers at redhat.com (Perry Myers) Date: Wed, 03 Aug 2011 18:45:54 -0400 Subject: [Ovirt-devel] RFC: ovirt-node ISO In-Reply-To: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> References: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> Message-ID: <4E39CFA2.7080206@redhat.com> On 08/03/2011 06:04 PM, Mike Burns wrote: > As we prepare to push ovirt-node ISOs to ovirt.org while also working on > getting an ovirt-node spin into Fedora, there is some debate over > whether the version hosted on ovirt.org should use the minimizer > kickstart or not. > > Main argument for including the minimizer kickstart: > > Size. We're currently looking at something around 130MB for the ISO > with minimizer and probably around double that without it (I don't have > one built currently without the minimizer so I don't have the actual > size). > > Main argument for not using the minimizer: > > Consistently with the fedora spin. We can't use the minimizer in the > Fedora spins, so providing an ISO that matches the fedora spin would be > the same. > > Any votes or preferences on which we want to host? I vote for keeping blacklisting enabled in ovirt.org ISO for two reasons: 1. I'd like to push Fedora to change this policy over time. But first we just need to get the node into Fedora w/o blacklisting... 2. The RHEVH product uses blacklisting and I would rather that blacklist only be enabled in the product since that reduces our chances of catching errors elsewhere Perry From jboggs at redhat.com Wed Aug 3 23:07:28 2011 From: jboggs at redhat.com (Joey Boggs) Date: Wed, 03 Aug 2011 19:07:28 -0400 Subject: [Ovirt-devel] RFC: ovirt-node ISO In-Reply-To: <4E39CFA2.7080206@redhat.com> References: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> <4E39CFA2.7080206@redhat.com> Message-ID: <4E39D4B0.2020201@redhat.com> On 08/03/2011 06:45 PM, Perry Myers wrote: > On 08/03/2011 06:04 PM, Mike Burns wrote: >> As we prepare to push ovirt-node ISOs to ovirt.org while also working on >> getting an ovirt-node spin into Fedora, there is some debate over >> whether the version hosted on ovirt.org should use the minimizer >> kickstart or not. >> >> Main argument for including the minimizer kickstart: >> >> Size. We're currently looking at something around 130MB for the ISO >> with minimizer and probably around double that without it (I don't have >> one built currently without the minimizer so I don't have the actual >> size). >> >> Main argument for not using the minimizer: >> >> Consistently with the fedora spin. We can't use the minimizer in the >> Fedora spins, so providing an ISO that matches the fedora spin would be >> the same. >> >> Any votes or preferences on which we want to host? > I vote for keeping blacklisting enabled in ovirt.org ISO for two reasons: > > 1. I'd like to push Fedora to change this policy over time. But first > we just need to get the node into Fedora w/o blacklisting... > 2. The RHEVH product uses blacklisting and I would rather that > blacklist only be enabled in the product since that reduces our > chances of catching errors elsewhere > > Perry > > _______________________________________________ > Ovirt-devel mailing list > Ovirt-devel at redhat.com > https://www.redhat.com/mailman/listinfo/ovirt-devel Is there any reason we can't host both? Having the full version might not hurt to someone getting used to the project with the extra items(useful or not), and when they start to deploy to more machines over time would probably switch to the blacklisted one for space reasons esp if using pxe. From pmyers at redhat.com Wed Aug 3 23:13:59 2011 From: pmyers at redhat.com (Perry Myers) Date: Wed, 03 Aug 2011 19:13:59 -0400 Subject: [Ovirt-devel] RFC: ovirt-node ISO In-Reply-To: <4E39D4B0.2020201@redhat.com> References: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> <4E39CFA2.7080206@redhat.com> <4E39D4B0.2020201@redhat.com> Message-ID: <4E39D637.5050009@redhat.com> > Is there any reason we can't host both? Having the full version might > not hurt to someone getting used to the project with the extra > items(useful or not), and when they start to deploy to more machines > over time would probably switch to the blacklisted one for space reasons > esp if using pxe. I have no objection to hosting both From acathrow at redhat.com Thu Aug 4 00:49:55 2011 From: acathrow at redhat.com (Andrew Cathrow) Date: Wed, 3 Aug 2011 20:49:55 -0400 (EDT) Subject: [Ovirt-devel] RFC: ovirt-node ISO In-Reply-To: <4E39CFA2.7080206@redhat.com> Message-ID: <1254522410.612191.1312418995873.JavaMail.root@zmail07.collab.prod.int.phx2.redhat.com> ----- Original Message ----- > From: "Perry Myers" > To: "Mike Burns" > Cc: ovirt-devel at redhat.com > Sent: Wednesday, August 3, 2011 6:45:54 PM > Subject: Re: [Ovirt-devel] RFC: ovirt-node ISO > On 08/03/2011 06:04 PM, Mike Burns wrote: > > As we prepare to push ovirt-node ISOs to ovirt.org while also > > working on > > getting an ovirt-node spin into Fedora, there is some debate over > > whether the version hosted on ovirt.org should use the minimizer > > kickstart or not. > > > > Main argument for including the minimizer kickstart: > > > > Size. We're currently looking at something around 130MB for the ISO > > with minimizer and probably around double that without it (I don't > > have > > one built currently without the minimizer so I don't have the actual > > size). > > > > Main argument for not using the minimizer: > > > > Consistently with the fedora spin. We can't use the minimizer in the > > Fedora spins, so providing an ISO that matches the fedora spin would > > be > > the same. > > > > Any votes or preferences on which we want to host? > > I vote for keeping blacklisting enabled in ovirt.org ISO for two > reasons: > > 1. I'd like to push Fedora to change this policy over time. But first > we just need to get the node into Fedora w/o blacklisting... > 2. The RHEVH product uses blacklisting and I would rather that > blacklist only be enabled in the product since that reduces our > chances of catching errors elsewhere Also the reduced footprint/attack surface is a significant driver for users to deploy oVirt node -vs- Linux distro and blacklisting is an important part of that. > > Perry > > _______________________________________________ > Ovirt-devel mailing list > Ovirt-devel at redhat.com > https://www.redhat.com/mailman/listinfo/ovirt-devel From apevec at gmail.com Thu Aug 4 08:34:38 2011 From: apevec at gmail.com (Alan Pevec) Date: Thu, 4 Aug 2011 10:34:38 +0200 Subject: [Ovirt-devel] RFC: ovirt-node ISO In-Reply-To: <4E39D637.5050009@redhat.com> References: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> <4E39CFA2.7080206@redhat.com> <4E39D4B0.2020201@redhat.com> <4E39D637.5050009@redhat.com> Message-ID: On Thu, Aug 4, 2011 at 1:13 AM, Perry Myers wrote: >> Is there any reason we can't host both? Having the full version might >> not hurt to someone getting used to the project with the extra >> items(useful or not), and when they start to deploy to more machines >> over time would probably switch to the blacklisted one for space reasons >> esp if using pxe. > > I have no objection to hosting both Let's decide on one to avoid confusion. Alan From apevec at gmail.com Thu Aug 4 10:48:50 2011 From: apevec at gmail.com (Alan Pevec) Date: Thu, 4 Aug 2011 12:48:50 +0200 Subject: [Ovirt-devel] RFC: ovirt-node ISO In-Reply-To: <4E39CFA2.7080206@redhat.com> References: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> <4E39CFA2.7080206@redhat.com> Message-ID: On Thu, Aug 4, 2011 at 12:45 AM, Perry Myers wrote: >> Size. ?We're currently looking at something around 130MB for the ISO >> with minimizer and probably around double that without it (I don't have >> one built currently without the minimizer so I don't have the actual >> size). RHEL-6 based image is 130MB, Fedora 16 ISO is 150MB (we have more packages in the ovirt) Fedora image w/o minimizer is around 250MB. > I vote for keeping blacklisting enabled in ovirt.org ISO for two reasons: > > 1. I'd like to push Fedora to change this policy over time. ?But first > ? we just need to get the node into Fedora w/o blacklisting... Yeah, we could argue image minimization techniques are already in Fedora: anaconda initramfs images are selectively including drivers, and dracut is also including files via whitelist (inst command in /usr/share/dracut/modules.d/*/install) Proper way is to change RPM packages and create subpackages for independently usable parts but IIRC that was rejected for the kernel RPM which is the biggest part of our blacklisting. > 2. The RHEVH product uses blacklisting and I would rather that you mean, rather _not_ > ? blacklist only be enabled in the product since that reduces our > ? chances of catching errors elsewhere I'd vote for ISO w/o image minimizer, built directly in koji, but since we're not accepted as Fedora Spin yet (and I'm in minority) let's go with minimized ISO. Alan From mburns at redhat.com Thu Aug 4 13:39:32 2011 From: mburns at redhat.com (Mike Burns) Date: Thu, 04 Aug 2011 09:39:32 -0400 Subject: [Ovirt-devel] RFC: ovirt-node ISO In-Reply-To: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> References: <1312409056.11032.14.camel@mburns-laptop.usersys.redhat.com> Message-ID: <1312465172.3865.1049.camel@beelzebub.mburnsfire.net> On Wed, 2011-08-03 at 18:04 -0400, Mike Burns wrote: > As we prepare to push ovirt-node ISOs to ovirt.org while also working on > getting an ovirt-node spin into Fedora, there is some debate over > whether the version hosted on ovirt.org should use the minimizer > kickstart or not. > > Main argument for including the minimizer kickstart: > > Size. We're currently looking at something around 130MB for the ISO > with minimizer and probably around double that without it (I don't have > one built currently without the minimizer so I don't have the actual > size). > > Main argument for not using the minimizer: > > Consistently with the fedora spin. We can't use the minimizer in the > Fedora spins, so providing an ISO that matches the fedora spin would be > the same. > > Any votes or preferences on which we want to host? > > Mike > Thanks for the input. It seems that the consensus is to post the minimized version on ovirt.org while we work with the Fedora board to get an exception to the rules for the official spin. Thanks Mike -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/x-pkcs7-signature Size: 6117 bytes Desc: not available URL: From apevec at redhat.com Thu Aug 4 14:31:46 2011 From: apevec at redhat.com (Alan Pevec) Date: Thu, 4 Aug 2011 16:31:46 +0200 Subject: [Ovirt-devel] [PATCH] 1 year old typo! Message-ID: <1312468306-10771-1-git-send-email-apevec@redhat.com> --- scripts/ovirt-early | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/ovirt-early b/scripts/ovirt-early index 51a017c..14a45b0 100755 --- a/scripts/ovirt-early +++ b/scripts/ovirt-early @@ -478,7 +478,7 @@ start_ovirt_early () { standalone=1 bootparams="$bootparams $i" ;; - firstboot=no | firsboot=0 | ovirt_firstboot=no | ovirt_firstboot=0 | reinstall=0 | reinstall=no) + firstboot=no | firstboot=0 | ovirt_firstboot=no | ovirt_firstboot=0 | reinstall=0 | reinstall=no) firstboot=0 ;; firstboot* | ovirt_firstboot* | reinstall) -- 1.7.3.4 From apevec at redhat.com Thu Aug 4 14:41:37 2011 From: apevec at redhat.com (Alan Pevec) Date: Thu, 4 Aug 2011 16:41:37 +0200 Subject: [Ovirt-devel] [PATCH 1/2] allow choosing managed mode Message-ID: <1312468897-10846-1-git-send-email-apevec@redhat.com> standalone=1 is the default, as currently used by rhevh. Managed mode (non-standalone) is used by e.g. ovirt-server: during boot node looks up the management server via DNS SRV records, and retrieves its configuration. --- scripts/ovirt-early | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/scripts/ovirt-early b/scripts/ovirt-early index 14a45b0..11911b1 100755 --- a/scripts/ovirt-early +++ b/scripts/ovirt-early @@ -474,6 +474,10 @@ start_ovirt_early () { persist /etc/shadow /etc/passwd fi ;; + standalone=no | standalone=0 | ovirt_standalone=no | ovirt_standalone=0) + standalone=0 + bootparams="$bootparams $i" + ;; standalone* | ovirt_standalone*) standalone=1 bootparams="$bootparams $i" -- 1.7.3.4 From mburns at redhat.com Thu Aug 4 17:19:32 2011 From: mburns at redhat.com (Mike Burns) Date: Thu, 4 Aug 2011 13:19:32 -0400 Subject: [Ovirt-devel] [PATCH node] fix admin password setting Message-ID: <1312478372-28155-1-git-send-email-mburns@redhat.com> We were setting the admin password to be the value of rootpw instead of adminpw rhbz#727563 Signed-off-by: Mike Burns --- scripts/ovirt-early | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/ovirt-early b/scripts/ovirt-early index 11911b1..568c987 100755 --- a/scripts/ovirt-early +++ b/scripts/ovirt-early @@ -700,7 +700,7 @@ start_ovirt_early () { if [ -n "$adminpw" ]; then log "Setting temporary admin password: $adminpw" unmount_config /etc/passwd /etc/shadow - /usr/sbin/usermod -p "$rootpw" admin + /usr/sbin/usermod -p "$adminpw" admin chage -d 0 admin fi if [ -n "$rootpw" ]; then -- 1.7.4.4 From mburns at redhat.com Thu Aug 4 19:49:35 2011 From: mburns at redhat.com (Mike Burns) Date: Thu, 04 Aug 2011 15:49:35 -0400 Subject: [Ovirt-devel] ovirt-node ISO 2.0.1 Released Message-ID: <1312487375.3865.1053.camel@beelzebub.mburnsfire.net> The F16 based iso for ovirt-node 2.0.1-4 has been posted to ovirt.org. Please see http://ovirt.org/download.html for instructions on downloading it. -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/x-pkcs7-signature Size: 6117 bytes Desc: not available URL: From jboggs at redhat.com Thu Aug 4 20:01:42 2011 From: jboggs at redhat.com (Joey Boggs) Date: Thu, 4 Aug 2011 16:01:42 -0400 Subject: [Ovirt-devel] [PATCH] block setup from running in rescue mode Message-ID: <1312488102-31181-1-git-send-email-jboggs@redhat.com> rhbz#683328 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 5 ++++- scripts/ovirtfunctions.py | 11 +++++++++++ 2 files changed, 15 insertions(+), 1 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index a8f85cf..77669d4 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -1603,7 +1603,10 @@ class NodeConfigScreen(): self.restore_console_colors() if __name__ == "__main__": - if is_booted_from_local_disk() or "--force" in sys.argv: + if is_rescue_mode(): + print "Unable to run setup in rescue mode" + sys.exit(1) + elif is_booted_from_local_disk() or "--force" in sys.argv: screen = NodeConfigScreen() screen.start() else: diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index 2d6fac4..dbcad14 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -192,6 +192,17 @@ def is_booted_from_local_disk(): else: return False +def is_rescue_mode(): + ret = os.system("grep -q rescue /proc/cmdline") + if ret == 0: + return True + # check for runlevel 1 + else: + ret = os.system("runlevel|grep 1") + if ret == 0: + return True + return False + # was firstboot menu already shown? # state is stored in persistent config partition def is_firstboot(): -- 1.7.5.4 From mburns at redhat.com Fri Aug 5 13:14:10 2011 From: mburns at redhat.com (Mike Burns) Date: Fri, 5 Aug 2011 09:14:10 -0400 Subject: [Ovirt-devel] [PATCH node] blacklist the libvirt-guests init script Message-ID: <1312550050-15185-1-git-send-email-mburns@redhat.com> In RHEVH, we don't use libvirt-guests init script. rhbz#728433 Signed-off-by: Mike Burns --- recipe/rhevh6-minimizer.ks | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/recipe/rhevh6-minimizer.ks b/recipe/rhevh6-minimizer.ks index f3b5c2e..449f2c1 100644 --- a/recipe/rhevh6-minimizer.ks +++ b/recipe/rhevh6-minimizer.ks @@ -4,3 +4,4 @@ droprpm gettext droprpm hesiod droprpm procmail droprpm sendmail +drop /etc/init.d/libvirt-guests -- 1.7.4.4 From mburns at redhat.com Fri Aug 5 15:02:29 2011 From: mburns at redhat.com (Mike Burns) Date: Fri, 05 Aug 2011 11:02:29 -0400 Subject: [Ovirt-devel] [PATCH node] blacklist the libvirt-guests init script In-Reply-To: <1312550050-15185-1-git-send-email-mburns@redhat.com> References: <1312550050-15185-1-git-send-email-mburns@redhat.com> Message-ID: <1312556549.3865.1872.camel@beelzebub.mburnsfire.net> On Fri, 2011-08-05 at 09:14 -0400, Mike Burns wrote: > In RHEVH, we don't use libvirt-guests init script. > > rhbz#728433 > > Signed-off-by: Mike Burns > --- > recipe/rhevh6-minimizer.ks | 1 + > 1 files changed, 1 insertions(+), 0 deletions(-) > > diff --git a/recipe/rhevh6-minimizer.ks b/recipe/rhevh6-minimizer.ks > index f3b5c2e..449f2c1 100644 > --- a/recipe/rhevh6-minimizer.ks > +++ b/recipe/rhevh6-minimizer.ks > @@ -4,3 +4,4 @@ droprpm gettext > droprpm hesiod > droprpm procmail > droprpm sendmail > +drop /etc/init.d/libvirt-guests Change to +drop /etc/rc.d/init.d/libvirt-guests -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/x-pkcs7-signature Size: 6117 bytes Desc: not available URL: From jboggs at redhat.com Fri Aug 5 23:20:55 2011 From: jboggs at redhat.com (Joey Boggs) Date: Fri, 5 Aug 2011 19:20:55 -0400 Subject: [Ovirt-devel] [PATCH 1/2] update comparison for presenting dowgrade/upgrade/install/reinstall options Message-ID: <1312586456-25950-1-git-send-email-jboggs@redhat.com> rhbz#691679 Signed-off-by: Joey Boggs --- scripts/ovirt-config-installer.py | 16 ++++++++-------- 1 files changed, 8 insertions(+), 8 deletions(-) diff --git a/scripts/ovirt-config-installer.py b/scripts/ovirt-config-installer.py index ff2ccc8..cacce5e 100644 --- a/scripts/ovirt-config-installer.py +++ b/scripts/ovirt-config-installer.py @@ -29,6 +29,7 @@ import dbus import fcntl import gudev import PAM +import rpm QUIT_BUTTON = "Quit" BACK_BUTTON = "Back" @@ -299,17 +300,16 @@ class NodeInstallScreen: try: e_version, e_release = get_installed_version_number() e_full_ver = e_version + "-" + e_release - if e_version <= m_version: - if e_release < m_release: - self.menu_list.append(" Upgrade " + e_full_ver + " to " + m_full_ver, 3) - self.menu_list.append(" ", 4) - else: - self.menu_list.append(" Install " + PRODUCT_SHORT + " " + m_full_ver, 1) - self.menu_list.append(" ", 2) + compare = rpm.labelCompare(('1', e_version, e_release), ('1', m_version, m_release)) + if compare == -1: + self.menu_list.append(" Upgrade " + e_full_ver + " to " + m_full_ver, 3) + elif compare == 1: + self.menu_list.append(" Downgrade " + e_full_ver + " to " + m_full_ver, 3) + else: + self.menu_list.append(" Reinstall " + m_full_ver, 3) except: log("unable to get_version_numbers for upgrade") pass - else: self.menu_list.append("Major version upgrades are unsupported, uninstall existing version first", 0) else: -- 1.7.5.4 From jboggs at redhat.com Fri Aug 5 23:20:56 2011 From: jboggs at redhat.com (Joey Boggs) Date: Fri, 5 Aug 2011 19:20:56 -0400 Subject: [Ovirt-devel] [PATCH 2/2] reset password on upgrade In-Reply-To: <1312586456-25950-1-git-send-email-jboggs@redhat.com> References: <1312586456-25950-1-git-send-email-jboggs@redhat.com> Message-ID: <1312586456-25950-2-git-send-email-jboggs@redhat.com> rhbz#719837 Signed-off-by: Joey Boggs --- scripts/ovirt-config-installer.py | 15 ++++++++++----- 1 files changed, 10 insertions(+), 5 deletions(-) diff --git a/scripts/ovirt-config-installer.py b/scripts/ovirt-config-installer.py index cacce5e..637c64c 100644 --- a/scripts/ovirt-config-installer.py +++ b/scripts/ovirt-config-installer.py @@ -669,16 +669,21 @@ class NodeInstallScreen: def upgrade_node(self): gridform = GridForm(self.screen, "", 2, 2) - gridform.add(Label("Upgrading Hypervisor"), 0, 0, anchorLeft = 1) + # can also cover downgrading/reinstalling so changed to "updating" + gridform.add(Label("Updating Hypervisor"), 0, 0, anchorLeft = 1) progress_bar = Scale(50,100) progress_bar.set(75) gridform.add(progress_bar, 0, 1) gridform.draw() self.screen.refresh() - boot_setup = install.ovirt_boot_setup() - progress_bar.set(100) - self.__current_page = FINISHED_PAGE - return + root_pw_set = password.set_password(self.root_password_1.value(), "root") + if root_pw_set: + admin_pw_set = password.set_password(self.root_password_1.value(), "admin") + if admin_pw_set: + boot_setup = install.ovirt_boot_setup() + progress_bar.set(100) + self.__current_page = FINISHED_PAGE + return def start(self): self.set_console_colors() -- 1.7.5.4 From jboggs at redhat.com Fri Aug 5 23:52:34 2011 From: jboggs at redhat.com (Joey Boggs) Date: Fri, 5 Aug 2011 19:52:34 -0400 Subject: [Ovirt-devel] [PATCH] add disclaimer to press "q" to quit on support log page Message-ID: <1312588354-28446-1-git-send-email-jboggs@redhat.com> rhbz#722386 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 77669d4..0c3f25f 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -1117,7 +1117,9 @@ class NodeConfigScreen(): self.log_menu_list.append(" /var/log/ovirt.log", "/var/log/ovirt.log") self.log_menu_list.append(" /var/log/messages", "/var/log/messages") self.log_menu_list.append(" /var/log/secure", "/var/log/secure") - elements.setField(self.log_menu_list, 0, 2, anchorLeft = 1, padding = (0,0,0,11)) + elements.setField(self.log_menu_list, 0, 2, anchorLeft = 1, padding = (0,0,0,8)) + elements.setField(Label(" After viewing press \"q\" to quit "), 0, 3, anchorLeft = 1, padding = (0,1,0,0)) + return [Label(""), elements] def remote_storage_configuration_page(self, screen): -- 1.7.5.4 From jboggs at redhat.com Mon Aug 8 03:06:19 2011 From: jboggs at redhat.com (Joey Boggs) Date: Sun, 7 Aug 2011 23:06:19 -0400 Subject: [Ovirt-devel] [PATCH] dont list bridge devices in network configuration list Message-ID: <1312772779-26061-1-git-send-email-jboggs@redhat.com> rhbz#720957 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 16 +++++++++++++--- 1 files changed, 13 insertions(+), 3 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 0c3f25f..4ba3ce7 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -786,12 +786,18 @@ class NodeConfigScreen(): to_rem = to_rem + 1 else: dev_vendor = dev_vendor.rstrip(dev_vendor[-to_rem:]) - dev_driver = os.readlink("/sys/class/net/" + dev_interface + "/device/driver") - dev_driver = os.path.basename(dev_driver) + # bridges will fail due to no driver + try: + dev_driver = os.readlink("/sys/class/net/" + dev_interface + "/device/driver") + dev_driver = os.path.basename(dev_driver) + except: + pass nic_addr_file = open("/sys/class/net/" + dev_interface + "/address") dev_address = nic_addr_file.read().strip() cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/BOOTPROTO" % str(dev_interface) dev_bootproto = augtool_get(cmd) + type_cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/TYPE" % str(dev_interface) + dev_type = augtool_get(type_cmd) if dev_bootproto is None: cmd = "/files/etc/sysconfig/network-scripts/ifcfg-br%s/BOOTPROTO" % str(dev_interface) dev_bootproto = augtool_get(cmd) @@ -804,10 +810,14 @@ class NodeConfigScreen(): dev_conf_status = "Configured " if dev_conf_status == "Configured ": self.configured_nics = self.configured_nics + 1 + if dev_type is None: + type_cmd = "/files/etc/sysconfig/network-scripts/ifcfg-br%s/TYPE" % str(dev_interface) + dev_type = augtool_get(type_cmd) except: pass if not dev_interface == "lo" and not dev_interface.startswith("br") and not dev_interface.startswith("bond") and not dev_interface.startswith("sit") and not "." in dev_interface: - self.nic_dict[dev_interface] = "%s,%s,%s,%s,%s,%s" % (dev_interface,dev_bootproto,dev_vendor,dev_address, dev_driver, dev_conf_status) + if not dev_type == "Bridge": + self.nic_dict[dev_interface] = "%s,%s,%s,%s,%s,%s" % (dev_interface,dev_bootproto,dev_vendor,dev_address, dev_driver, dev_conf_status) if len(self.nic_dict) > 5: self.nic_lb = Listbox(height = 5, width = 56, returnExit = 1, scroll = 1) else: -- 1.7.6 From pmyers at redhat.com Mon Aug 8 17:52:44 2011 From: pmyers at redhat.com (Perry Myers) Date: Mon, 08 Aug 2011 13:52:44 -0400 Subject: [Ovirt-devel] oVirt Node Fedora Feature Status In-Reply-To: <4E341234.1010605@redhat.com> References: <4E341234.1010605@redhat.com> Message-ID: <4E40226C.8050900@redhat.com> On 07/30/2011 10:16 AM, Perry Myers wrote: > https://fedoraproject.org/wiki/Ovirt_Node_Spin Wanted to give an update on this. As mentioned earlier, we have approval from QE and Design teams. In the absence of the Spin SIG being able to grant an approval, this was passed to release engineering who reviewed the spin. Unfortunately, based upon the current release engineering rules (which are heavily oriented towards Desktop usage and not Server usage) oVirt Node really can't be accepted as is into Fedora as an official Spin. Details are here: https://fedorahosted.org/rel-eng/ticket/4864 Basically in order to get this accepted by releng it looks like we'd have to make so many fundamental changes to what oVirt Node is, that it wouldn't be worth it in terms of leveraging the Fedora community for visibility and testing. (For example, we already had to remove our blacklisting which increased image size from ~150MB to ~250MB) I think a more reasonable plan would be to focus on oVirt Node as a derivative distribution that is focused on virtualization deployment. We can absolutely highlight that oVirt Node is built on Fedora and leverages the great work that the Fedora team/community has done, but it should be considered a separate distribution that is more closely associated with the oVirt brand/project umbrella. >From that perspective, we would build oVirt Node ISOs in parallel with Fedora releases and host them directly with ovirt.org site. And we'd only need one variant (the one with blacklisting enabled). This should be community decision, not unilateral, so I'd like other people's thoughts on this. Chime in :) Perry From mburns at redhat.com Mon Aug 8 18:14:14 2011 From: mburns at redhat.com (Mike Burns) Date: Mon, 8 Aug 2011 14:14:14 -0400 Subject: [Ovirt-devel] [PATCH node] set admin password if rootpw provided Message-ID: <1312827254-27674-1-git-send-email-mburns@redhat.com> In the case where only rootpw is provided, default adminpw to the value of rootpw rhbz#727563 Signed-off-by: Mike Burns --- scripts/ovirt-early | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/scripts/ovirt-early b/scripts/ovirt-early index 568c987..fa24720 100755 --- a/scripts/ovirt-early +++ b/scripts/ovirt-early @@ -502,6 +502,9 @@ start_ovirt_early () { ;; rootpw=*) rootpw=${i#rootpw=} + if [ -z "$adminpw" ]; then + adminpw=$rootpw + fi ;; snmp_password=*) snmp_password=${i#snmp_password=} -- 1.7.6 From mburns at redhat.com Mon Aug 8 18:22:04 2011 From: mburns at redhat.com (Mike Burns) Date: Mon, 08 Aug 2011 14:22:04 -0400 Subject: [Ovirt-devel] oVirt Node Fedora Feature Status In-Reply-To: <4E40226C.8050900@redhat.com> References: <4E341234.1010605@redhat.com> <4E40226C.8050900@redhat.com> Message-ID: <1312827725.23847.3.camel@mburns-laptop.usersys.redhat.com> On Mon, 2011-08-08 at 13:52 -0400, Perry Myers wrote: > On 07/30/2011 10:16 AM, Perry Myers wrote: > > https://fedoraproject.org/wiki/Ovirt_Node_Spin > > Wanted to give an update on this. > > As mentioned earlier, we have approval from QE and Design teams. In the > absence of the Spin SIG being able to grant an approval, this was passed > to release engineering who reviewed the spin. > > Unfortunately, based upon the current release engineering rules (which > are heavily oriented towards Desktop usage and not Server usage) oVirt > Node really can't be accepted as is into Fedora as an official Spin. > > Details are here: > https://fedorahosted.org/rel-eng/ticket/4864 > > Basically in order to get this accepted by releng it looks like we'd > have to make so many fundamental changes to what oVirt Node is, that it > wouldn't be worth it in terms of leveraging the Fedora community for > visibility and testing. (For example, we already had to remove our > blacklisting which increased image size from ~150MB to ~250MB) > > I think a more reasonable plan would be to focus on oVirt Node as a > derivative distribution that is focused on virtualization deployment. > We can absolutely highlight that oVirt Node is built on Fedora and > leverages the great work that the Fedora team/community has done, but it > should be considered a separate distribution that is more closely > associated with the oVirt brand/project umbrella. +1 > > >From that perspective, we would build oVirt Node ISOs in parallel with > Fedora releases and host them directly with ovirt.org site. And we'd > only need one variant (the one with blacklisting enabled). We would build with each ovirt-node release. I could see providing an ISO for the current Fedora and the next version of Fedora depending on where Fedora is in it's lifecycle. Currently we'd be providing F16 based ISOs only. At least, that's how I see it... > > This should be community decision, not unilateral, so I'd like other > people's thoughts on this. > > Chime in :) > > Perry > > _______________________________________________ > Ovirt-devel mailing list > Ovirt-devel at redhat.com > https://www.redhat.com/mailman/listinfo/ovirt-devel From rbergero at redhat.com Mon Aug 8 18:28:22 2011 From: rbergero at redhat.com (Robyn Bergeron) Date: Mon, 08 Aug 2011 11:28:22 -0700 Subject: [Ovirt-devel] oVirt Node Fedora Feature Status In-Reply-To: <4E40226C.8050900@redhat.com> References: <4E341234.1010605@redhat.com> <4E40226C.8050900@redhat.com> Message-ID: <4E402AC6.4040202@redhat.com> On 08/08/2011 10:52 AM, Perry Myers wrote: > On 07/30/2011 10:16 AM, Perry Myers wrote: >> https://fedoraproject.org/wiki/Ovirt_Node_Spin > Wanted to give an update on this. > > As mentioned earlier, we have approval from QE and Design teams. In the > absence of the Spin SIG being able to grant an approval, this was passed > to release engineering who reviewed the spin. > > Unfortunately, based upon the current release engineering rules (which > are heavily oriented towards Desktop usage and not Server usage) oVirt > Node really can't be accepted as is into Fedora as an official Spin. > > Details are here: > https://fedorahosted.org/rel-eng/ticket/4864 > > Basically in order to get this accepted by releng it looks like we'd > have to make so many fundamental changes to what oVirt Node is, that it > wouldn't be worth it in terms of leveraging the Fedora community for > visibility and testing. (For example, we already had to remove our > blacklisting which increased image size from ~150MB to ~250MB) > > I think a more reasonable plan would be to focus on oVirt Node as a > derivative distribution that is focused on virtualization deployment. > We can absolutely highlight that oVirt Node is built on Fedora and > leverages the great work that the Fedora team/community has done, but it > should be considered a separate distribution that is more closely > associated with the oVirt brand/project umbrella. > > From that perspective, we would build oVirt Node ISOs in parallel with > Fedora releases and host them directly with ovirt.org site. And we'd > only need one variant (the one with blacklisting enabled). You can do this fairly easily via a Fedora Remix. https://fedoraproject.org/wiki/Remix Note that Fedora remixes don't have to include the "Fedora Remix" name - you can essentially call it whatever you'd like. -robyn > This should be community decision, not unilateral, so I'd like other > people's thoughts on this. > > Chime in :) > > Perry From jboggs at redhat.com Mon Aug 8 19:51:07 2011 From: jboggs at redhat.com (Joey Boggs) Date: Mon, 8 Aug 2011 15:51:07 -0400 Subject: [Ovirt-devel] [PATCH] check admin password for upgrade verification Message-ID: <1312833067-14652-1-git-send-email-jboggs@redhat.com> rhbz#719837 Signed-off-by: Joey Boggs --- scripts/ovirt-config-installer.py | 50 +++++++++++++++++-------------------- scripts/ovirt-config-setup.py | 1 - 2 files changed, 23 insertions(+), 28 deletions(-) diff --git a/scripts/ovirt-config-installer.py b/scripts/ovirt-config-installer.py index 637c64c..7c66676 100644 --- a/scripts/ovirt-config-installer.py +++ b/scripts/ovirt-config-installer.py @@ -177,7 +177,7 @@ class NodeInstallScreen: def current_password_callback(self): auth = PAM.pam() auth.start("passwd") - auth.set_item(PAM.PAM_USER, "root") + auth.set_item(PAM.PAM_USER, "admin") global current_password current_password = self.current_password.value() auth.set_item(PAM.PAM_CONV, pam_conv) @@ -590,7 +590,7 @@ class NodeInstallScreen: self.root_password_1 = Entry(15,password = 1) self.root_password_2 = Entry(15,password = 1) - if pwd_set_check("root"): + if pwd_set_check("admin"): elements.setField(Label(" "), 0, 1, anchorLeft = 1) elements.setField(Label("To reset password, please enter the current password "), 0, 2, anchorLeft = 1) pw_elements.setField(Label("Current Password: "), 0, 1, anchorLeft = 1) @@ -649,23 +649,21 @@ class NodeInstallScreen: gridform.add(progress_bar, 0, 1) gridform.draw() self.screen.refresh() - root_pw_set = password.set_password(self.root_password_1.value(), "root") - if root_pw_set: - admin_pw_set = password.set_password(self.root_password_1.value(), "admin") - if admin_pw_set: - gridform.add(progress_bar, 0, 1) - gridform.draw() - self.screen.refresh() - progress_bar.set(75) - gridform = GridForm(self.screen, "", 2, 2) - gridform.add(Label("Installing Bootloader Configuration on: " + self.storage_init ), 0, 0, anchorLeft = 1) - gridform.add(progress_bar, 0, 1) - gridform.draw() - self.screen.refresh() - boot_setup = install.ovirt_boot_setup() - if boot_setup: - progress_bar.set(100) - self.__current_page = FINISHED_PAGE + admin_pw_set = password.set_password(self.root_password_1.value(), "admin") + if admin_pw_set: + gridform.add(progress_bar, 0, 1) + gridform.draw() + self.screen.refresh() + progress_bar.set(75) + gridform = GridForm(self.screen, "", 2, 2) + gridform.add(Label("Installing Bootloader Configuration on: " + self.storage_init ), 0, 0, anchorLeft = 1) + gridform.add(progress_bar, 0, 1) + gridform.draw() + self.screen.refresh() + boot_setup = install.ovirt_boot_setup() + if boot_setup: + progress_bar.set(100) + self.__current_page = FINISHED_PAGE def upgrade_node(self): gridform = GridForm(self.screen, "", 2, 2) @@ -676,14 +674,12 @@ class NodeInstallScreen: gridform.add(progress_bar, 0, 1) gridform.draw() self.screen.refresh() - root_pw_set = password.set_password(self.root_password_1.value(), "root") - if root_pw_set: - admin_pw_set = password.set_password(self.root_password_1.value(), "admin") - if admin_pw_set: - boot_setup = install.ovirt_boot_setup() - progress_bar.set(100) - self.__current_page = FINISHED_PAGE - return + admin_pw_set = password.set_password(self.root_password_1.value(), "admin") + if admin_pw_set: + boot_setup = install.ovirt_boot_setup() + progress_bar.set(100) + self.__current_page = FINISHED_PAGE + return def start(self): self.set_console_colors() diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 4ba3ce7..a83e7e8 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -1305,7 +1305,6 @@ class NodeConfigScreen(): if self.root_password_1.value() != self.root_password_2.value(): ButtonChoiceWindow(self.screen, "Remote Access", "Passwords Do Not Match", buttons = ['Ok']) else: - set_password(self.root_password_1.value(), "root") set_password(self.root_password_1.value(), "admin") ButtonChoiceWindow(self.screen, "Remote Access", "Password Successfully Changed", buttons = ['Ok']) log("\nroot & admin password changed") -- 1.7.6 From damon at damtek.com Mon Aug 8 19:53:30 2011 From: damon at damtek.com (Damon L. Chesser) Date: Mon, 08 Aug 2011 15:53:30 -0400 Subject: [Ovirt-devel] oVirt Node Fedora Feature Status In-Reply-To: <4E40226C.8050900@redhat.com> References: <4E341234.1010605@redhat.com> <4E40226C.8050900@redhat.com> Message-ID: <1312833210.23555.4.camel@dam-main.dam-home> On Mon, 2011-08-08 at 13:52 -0400, Perry Myers wrote: > On 07/30/2011 10:16 AM, Perry Myers wrote: > > https://fedoraproject.org/wiki/Ovirt_Node_Spin > > Wanted to give an update on this. > > As mentioned earlier, we have approval from QE and Design teams. In the > absence of the Spin SIG being able to grant an approval, this was passed > to release engineering who reviewed the spin. > > Unfortunately, based upon the current release engineering rules (which > are heavily oriented towards Desktop usage and not Server usage) oVirt > Node really can't be accepted as is into Fedora as an official Spin. > > Details are here: > https://fedorahosted.org/rel-eng/ticket/4864 > > Basically in order to get this accepted by releng it looks like we'd > have to make so many fundamental changes to what oVirt Node is, that it > wouldn't be worth it in terms of leveraging the Fedora community for > visibility and testing. (For example, we already had to remove our > blacklisting which increased image size from ~150MB to ~250MB) > > I think a more reasonable plan would be to focus on oVirt Node as a > derivative distribution that is focused on virtualization deployment. > We can absolutely highlight that oVirt Node is built on Fedora and > leverages the great work that the Fedora team/community has done, but it > should be considered a separate distribution that is more closely > associated with the oVirt brand/project umbrella. > > >From that perspective, we would build oVirt Node ISOs in parallel with > Fedora releases and host them directly with ovirt.org site. And we'd > only need one variant (the one with blacklisting enabled). > > This should be community decision, not unilateral, so I'd like other > people's thoughts on this. > > Chime in :) > > Perry Just lurking here, however, I don't see a problem with what your propose. There is a dirth of good management interfaces for what otherwise is a good product (KVM). Look forward to testing it. > > _______________________________________________ > Ovirt-devel mailing list > Ovirt-devel at redhat.com > https://www.redhat.com/mailman/listinfo/ovirt-devel -- Damon damon at damtek.com From pmyers at redhat.com Tue Aug 9 00:20:58 2011 From: pmyers at redhat.com (Perry Myers) Date: Mon, 08 Aug 2011 20:20:58 -0400 Subject: [Ovirt-devel] oVirt Node Fedora Feature Status In-Reply-To: <4E402AC6.4040202@redhat.com> References: <4E341234.1010605@redhat.com> <4E40226C.8050900@redhat.com> <4E402AC6.4040202@redhat.com> Message-ID: <4E407D6A.7050502@redhat.com> > You can do this fairly easily via a Fedora Remix. > https://fedoraproject.org/wiki/Remix > > Note that Fedora remixes don't have to include the "Fedora Remix" name - > you can essentially call it whatever you'd like. That's an excellent suggestion. So we'll build just a single oVirt Node ISO that we'll host on ovirt.org. It'll be branded with oVirt brand, logos, etc and will include the blacklisting. And then we'll submit the oVirt Node ISO as a Fedora Remix. One thing to note is: > The Fedora Remix allows you to combine non-Fedora software with > Fedora, but you must observe the appropriate trademark guidelines, > which include removing the fedora-logos, fedora-release, and > fedora-release-notes packages and replacing them with equivalents. We > provide the generic-logos, generic-release, and generic-release-notes > packages for these purposes, but you may also create your own. > Additional guidelines may apply, so please read them, and the > following section as well, for more information. So we'll need to make sure we fix this if we haven't already. Unless anyone has objections (and it doesn't seem that folks do thus far) I propose that we go ahead and deprecate the Spin feature request and just fix the ISO to be a remix * include the Fedora Remix logo somewhere on the graphics we use for bootsplash, etc * remove the fedora-logos/release/release-notes packages and replace with generic Perry From rbergero at redhat.com Tue Aug 9 00:29:01 2011 From: rbergero at redhat.com (Robyn Bergeron) Date: Mon, 08 Aug 2011 17:29:01 -0700 Subject: [Ovirt-devel] oVirt Node Fedora Feature Status In-Reply-To: <4E407D6A.7050502@redhat.com> References: <4E341234.1010605@redhat.com> <4E40226C.8050900@redhat.com> <4E402AC6.4040202@redhat.com> <4E407D6A.7050502@redhat.com> Message-ID: <4E407F4D.5080005@redhat.com> On 08/08/2011 05:20 PM, Perry Myers wrote: >> You can do this fairly easily via a Fedora Remix. >> https://fedoraproject.org/wiki/Remix >> >> Note that Fedora remixes don't have to include the "Fedora Remix" name - >> you can essentially call it whatever you'd like. > That's an excellent suggestion. > > So we'll build just a single oVirt Node ISO that we'll host on > ovirt.org. It'll be branded with oVirt brand, logos, etc and will > include the blacklisting. > > And then we'll submit the oVirt Node ISO as a Fedora Remix. You don't need to submit it anywhere. You can just make it. No permissions needed. :) > One thing to note is: >> The Fedora Remix allows you to combine non-Fedora software with >> Fedora, but you must observe the appropriate trademark guidelines, >> which include removing the fedora-logos, fedora-release, and >> fedora-release-notes packages and replacing them with equivalents. We >> provide the generic-logos, generic-release, and generic-release-notes >> packages for these purposes, but you may also create your own. >> Additional guidelines may apply, so please read them, and the >> following section as well, for more information. > So we'll need to make sure we fix this if we haven't already. > > Unless anyone has objections (and it doesn't seem that folks do thus > far) I propose that we go ahead and deprecate the Spin feature request > and just fix the ISO to be a remix > * include the Fedora Remix logo somewhere on the graphics we use for > bootsplash, etc You aren't required to use the Fedora Remix logo, if you don't want. If you already have bootsplash/other graphics, it's not required to be pulled in. -Robyn > * remove the fedora-logos/release/release-notes packages and replace > with generic > > Perry From jboggs at redhat.com Wed Aug 10 00:30:10 2011 From: jboggs at redhat.com (Joey Boggs) Date: Tue, 09 Aug 2011 20:30:10 -0400 Subject: [Ovirt-devel] oVirt Node Fedora Feature Status In-Reply-To: <4E407F4D.5080005@redhat.com> References: <4E341234.1010605@redhat.com> <4E40226C.8050900@redhat.com> <4E402AC6.4040202@redhat.com> <4E407D6A.7050502@redhat.com> <4E407F4D.5080005@redhat.com> Message-ID: <4E41D112.3060908@redhat.com> On 08/08/2011 08:29 PM, Robyn Bergeron wrote: > On 08/08/2011 05:20 PM, Perry Myers wrote: >>> You can do this fairly easily via a Fedora Remix. >>> https://fedoraproject.org/wiki/Remix >>> >>> Note that Fedora remixes don't have to include the "Fedora Remix" >>> name - >>> you can essentially call it whatever you'd like. >> That's an excellent suggestion. >> >> So we'll build just a single oVirt Node ISO that we'll host on >> ovirt.org. It'll be branded with oVirt brand, logos, etc and will >> include the blacklisting. >> >> And then we'll submit the oVirt Node ISO as a Fedora Remix. > You don't need to submit it anywhere. You can just make it. No > permissions needed. :) >> One thing to note is: >>> The Fedora Remix allows you to combine non-Fedora software with >>> Fedora, but you must observe the appropriate trademark guidelines, >>> which include removing the fedora-logos, fedora-release, and >>> fedora-release-notes packages and replacing them with equivalents. We >>> provide the generic-logos, generic-release, and generic-release-notes >>> packages for these purposes, but you may also create your own. >>> Additional guidelines may apply, so please read them, and the >>> following section as well, for more information. >> So we'll need to make sure we fix this if we haven't already. >> >> Unless anyone has objections (and it doesn't seem that folks do thus >> far) I propose that we go ahead and deprecate the Spin feature request >> and just fix the ISO to be a remix >> * include the Fedora Remix logo somewhere on the graphics we use for >> bootsplash, etc > You aren't required to use the Fedora Remix logo, if you don't want. > If you already have bootsplash/other graphics, it's not required to be > pulled in. > > -Robyn >> * remove the fedora-logos/release/release-notes packages and replace >> with generic >> >> Perry > > _______________________________________________ > Ovirt-devel mailing list > Ovirt-devel at redhat.com > https://www.redhat.com/mailman/listinfo/ovirt-devel Due to difficulties in meeting all the strict requirements we have decided to build as a Fedora Remix allowing us to build the image to our own specifications. We will be retracting our request to be placed into Fedora 16 as a Featured Spin. https://fedoraproject.org/wiki/Remix From jboggs at redhat.com Wed Aug 10 19:03:24 2011 From: jboggs at redhat.com (Joey Boggs) Date: Wed, 10 Aug 2011 15:03:24 -0400 Subject: [Ovirt-devel] [PATCH] remove network page loop when selecting other pages Message-ID: <1313003004-5779-1-git-send-email-jboggs@redhat.com> rhbz#725412 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 5 ++--- scripts/ovirtfunctions.py | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index a83e7e8..4bd46d5 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -1570,13 +1570,12 @@ class NodeConfigScreen(): self.__current_page = menu_choice if self.net_apply_config == 1: self.net_apply_config = 0 - self.__current_page = NETWORK_PAGE elif self.__current_page == NETWORK_DETAILS_PAGE: if pressed == BACK_BUTTON: self.__current_page = NETWORK_PAGE elif self.net_apply_config == 1: self.__current_page = NETWORK_PAGE - elif is_managed(OVIRT_VARS["OVIRT_BOOTPARAMS"]): + elif is_managed(): dev_interface,dev_bootproto,dev_vendor,dev_address,dev_driver,dev_conf_status = self.nic_dict[self.nic_lb.current()].split(",", 5) if self.configured_nics >= 1 and dev_conf_status != "Configured" : ButtonChoiceWindow(self.screen, "Network", "Hypervisor is already managed, unable to configure additional nics", buttons = ['Ok']) @@ -1584,7 +1583,7 @@ class NodeConfigScreen(): elif self.__nic_config_failed == 1: self.__current_page = NETWORK_DETAILS_PAGE else: - self.__current_page = NETWORK_PAGE + self.__current_page = menu_choice elif self.__current_page == SUPPORT_PAGE: log("pressed: " + str(pressed)) if pressed == SHELL_BUTTON: diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index ae3c013..14c7b44 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -142,8 +142,8 @@ def augtool_get(key): return value # return 1 if oVirt Node is running in standalone mode # return 0 if oVirt Node is managed by the oVirt Server -def is_managed(bootparams): - if "ovirt_standalone" in bootparams: +def is_managed(): + if "ovirt_standalone" in OVIRT_VARS["OVIRT_BOOTPARAMS"]: return False else: return True -- 1.7.6 From apevec at redhat.com Wed Aug 10 23:59:09 2011 From: apevec at redhat.com (Alan Pevec) Date: Thu, 11 Aug 2011 01:59:09 +0200 Subject: [Ovirt-devel] [PATCH] install libvirtd systemd service on Fedora Message-ID: <1313020749-9790-1-git-send-email-apevec@redhat.com> unit file taken from http://www.redhat.com/archives/libvir-list/2011-July/msg00343.html (modified to include Before=ovirt-post) --- Makefile.am | 1 + libvirtd.service | 16 ++++++++++++++++ ovirt-node.spec.in | 15 ++++++++++++++- recipe/ovirt16-install.ks | 2 +- 4 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 libvirtd.service diff --git a/Makefile.am b/Makefile.am index fe826f5..58a105e 100644 --- a/Makefile.am +++ b/Makefile.am @@ -27,6 +27,7 @@ SUBDIRS = \ EXTRA_DIST = \ vlan.modules \ + libvirtd.service \ libvirtd.upstart \ ovirt-node.spec \ ovirt-node.spec.in \ diff --git a/libvirtd.service b/libvirtd.service new file mode 100644 index 0000000..7a4a625 --- /dev/null +++ b/libvirtd.service @@ -0,0 +1,16 @@ +[Unit] +Description=Virtualization daemon +After=syslog.target +After=udev.target +After=avahi.target +After=dbus.target +Before=libvirt-guests.service +Before=ovirt-post.service + +[Service] +EnvironmentFile=-/etc/sysconfig/libvirtd +ExecStart= /usr/sbin/libvirtd $LIBVIRTD_ARGS +ExecReload=/bin/kill -HUP $MAINPID + +[Install] +WantedBy=multi-user.target diff --git a/ovirt-node.spec.in b/ovirt-node.spec.in index b2ad85b..60d3276 100644 --- a/ovirt-node.spec.in +++ b/ovirt-node.spec.in @@ -20,6 +20,7 @@ BuildRequires: automake autoconf Requires(post): /sbin/chkconfig Requires(preun): /sbin/chkconfig %if 0%{?fedora} +Requires: systemd-units Requires: python-augeas Requires: glusterfs-client >= 2.0.1 Requires: anyterm @@ -108,9 +109,16 @@ make install DESTDIR=%{buildroot} %{__install} -p -m0644 logrotate/ovirt-logrotate %{buildroot}%{_sysconfdir}/cron.d %{__install} -p -m0644 logrotate/ovirt-logrotate.conf %{buildroot}%{_sysconfdir}/logrotate.d/ovirt-node -# configure libvirtd upstart job +%if 0%{?fedora} +# install libvirtd systemd service +%{__install} -d -m0755 %{buildroot}%{_unitdir} +%{__install} -p -m0644 libvirtd.service %{buildroot}%{_unitdir} +%endif +%if 0%{?rhel} +# install libvirtd upstart job %{__install} -d -m0755 %{buildroot}%{_sysconfdir}/init %{__install} -p -m0644 libvirtd.upstart %{buildroot}%{_sysconfdir}/init/libvirtd.conf +%endif # load vlan module %{__install} -d -m0755 %{buildroot}%{_sysconfdir}/sysconfig/modules %{__install} -p -m0755 vlan.modules %{buildroot}%{_sysconfdir}/sysconfig/modules @@ -231,7 +239,12 @@ fi %{_sysconfdir}/ovirt-config-boot.d %config(noreplace) %{_sysconfdir}/sysconfig/node-config +%if 0%{?fedora} +%{_unitdir}/libvirtd.service +%endif +%if 0%{?rhel} %{_sysconfdir}/init/libvirtd.conf +%endif %{_sysconfdir}/sysconfig/modules/vlan.modules diff --git a/recipe/ovirt16-install.ks b/recipe/ovirt16-install.ks index 29684af..7b99b5e 100644 --- a/recipe/ovirt16-install.ks +++ b/recipe/ovirt16-install.ks @@ -1 +1 @@ -services --enabled=auditd,ntpd,ntpdate,iptables,network,rsyslog,multipathd,snmpd,ovirt-early,ovirt,ovirt-post,anyterm,collectd,libvirt-qmf,matahari-host --disabled=libvirtd +services --enabled=auditd,ntpd,ntpdate,iptables,network,rsyslog,multipathd,snmpd,ovirt-early,ovirt,ovirt-post,anyterm,collectd,libvirt-qmf,matahari-host,libvirtd -- 1.7.3.4 From apevec at redhat.com Thu Aug 11 00:01:03 2011 From: apevec at redhat.com (Alan Pevec) Date: Thu, 11 Aug 2011 02:01:03 +0200 Subject: [Ovirt-devel] [PATCH] all .py are under /usr Message-ID: <1313020863-9838-1-git-send-email-apevec@redhat.com> avoids traversing /proc --- recipe/image-minimizer.ks.in | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/recipe/image-minimizer.ks.in b/recipe/image-minimizer.ks.in index 2518c5c..956bc20 100644 --- a/recipe/image-minimizer.ks.in +++ b/recipe/image-minimizer.ks.in @@ -5,7 +5,7 @@ %post echo "Removing python source files" -find / -name '*.py' -exec rm -f {} \; -find / -name '*.pyo' -exec rm -f {} \; +find /usr -name '*.py' -exec rm -f {} \; +find /usr -name '*.pyo' -exec rm -f {} \; %end -- 1.7.3.4 From apevec at redhat.com Thu Aug 11 00:02:32 2011 From: apevec at redhat.com (Alan Pevec) Date: Thu, 11 Aug 2011 02:02:32 +0200 Subject: [Ovirt-devel] [PATCH] fix augtool calls Message-ID: <1313020953-9913-1-git-send-email-apevec@redhat.com> parse input augtool strings to oper,key,value --- scripts/network.py | 32 ++++++++++++++++---------------- 1 files changed, 16 insertions(+), 16 deletions(-) diff --git a/scripts/network.py b/scripts/network.py index f51ee7c..65b551c 100644 --- a/scripts/network.py +++ b/scripts/network.py @@ -165,11 +165,11 @@ class Network: ntpconf = ntpconf.split("\n") for line in ntpconf: try: - oper, file, value = line.split() + oper, key, value = line.split() + augtool(oper, key, value) except: - oper, file = line.split() - - augtool(oper, line, "") + oper, key = line.split() + augtool(oper, key, "") if OVIRT_VARS.has_key("OVIRT_NTP"): offset=1 @@ -201,33 +201,33 @@ class Network: for line in self.IF_CONFIG: log(line) try: - oper, file, value = line.split() - augtool(oper, file, value) + oper, key, value = line.split() + augtool(oper, key, value) except: - oper, file = line.split() - augtool(oper, line, "") + oper, key = line.split() + augtool(oper, key, "") for line in self.BR_CONFIG: log(line) try: - oper, file, value = line.split() - augtool(oper, file, value) + oper, key, value = line.split() + augtool(oper, key, value) except: try: - oper, file = line.split() - augtool(oper, line, "") + oper, key = line.split() + augtool(oper, key, "") except: pass for line in self.VL_CONFIG.split("\n"): log(line) try: - oper, file, value = line.split() - augtool(oper, file, value) + oper, key, value = line.split() + augtool(oper, key, value) except: try: - oper, file = line.split() - augtool(oper, line, "") + oper, key = line.split() + augtool(oper, key, "") except: pass -- 1.7.3.4 From apevec at redhat.com Thu Aug 11 00:02:33 2011 From: apevec at redhat.com (Alan Pevec) Date: Thu, 11 Aug 2011 02:02:33 +0200 Subject: [Ovirt-devel] [PATCH] persist only configured network configs In-Reply-To: <1313020953-9913-1-git-send-email-apevec@redhat.com> References: <1313020953-9913-1-git-send-email-apevec@redhat.com> Message-ID: <1313020953-9913-2-git-send-email-apevec@redhat.com> blind ifcfg-* persists too much also add mac/nic mapping missing in network.py rhbz#725392 Signed-off-by: Alan Pevec --- scripts/network.py | 48 +++++++++++++++++++++++++++----------- scripts/ovirt-config-networking | 22 +++++++++++------ scripts/ovirt-functions | 1 - scripts/ovirtfunctions.py | 13 ---------- 4 files changed, 48 insertions(+), 36 deletions(-) diff --git a/scripts/network.py b/scripts/network.py index 65b551c..50d4624 100644 --- a/scripts/network.py +++ b/scripts/network.py @@ -17,6 +17,7 @@ # MA 02110-1301, USA. A copy of the GNU General Public License is # also available at http://www.gnu.org/copyleft/gpl.html. from ovirtnode.ovirtfunctions import * +from glob import glob import tempfile import sys @@ -25,12 +26,12 @@ class Network: def __init__(self): OVIRT_VARS = parse_defaults() self.WORKDIR=tempfile.mkdtemp() - self.IFSCRIPTS_PATH ="/etc/sysconfig/network-scripts/" - self.IFCONFIG_FILE_ROOT="/files/etc/sysconfig/network-scripts/ifcfg" - self.NTPCONF_FILE_ROOT="/files/etc/ntp" + self.IFSCRIPTS_PATH ="/etc/sysconfig/network-scripts/ifcfg-" + self.IFCONFIG_FILE_ROOT="/files%s" % self.IFSCRIPTS_PATH self.NTP_CONFIG_FILE="/etc/ntp.conf" self.NTPSERVERS="" - self.CONFIGURED_NIC= "" + self.CONFIGURED_NIC = "" + self.CONFIGURED_NICS = [] self.IF_CONFIG = "" self.BR_CONFIG = "" self.VL_CONFIG = "" @@ -62,13 +63,15 @@ class Network: nic_hwaddr = n_address.readline().strip("\n") n_address.close() BRIDGE = "br" + self.CONFIGURED_NIC + self.CONFIGURED_NICS.append(self.CONFIGURED_NIC) + self.CONFIGURED_NICS.append(BRIDGE) IF_FILENAME = self.WORKDIR + "/augtool-" + self.CONFIGURED_NIC BR_FILENAME = self.WORKDIR + "/augtool-" + BRIDGE log("\nConfigure $BRIDGE for use by $NIC..\n\n") - IF_ROOT = "%s-%s" % (self.IFCONFIG_FILE_ROOT, self.CONFIGURED_NIC) + IF_ROOT = "%s%s" % (self.IFCONFIG_FILE_ROOT, self.CONFIGURED_NIC) self.IF_CONFIG += "rm %s\nset %s/DEVICE %s\n" % (IF_ROOT, IF_ROOT, self.CONFIGURED_NIC) self.IF_CONFIG += "set %s/HWADDR %s\n" % (IF_ROOT, nic_hwaddr) - BR_ROOT = "%s-%s" % (self.IFCONFIG_FILE_ROOT, BRIDGE) + BR_ROOT = "%s%s" % (self.IFCONFIG_FILE_ROOT, BRIDGE) self.BR_CONFIG += "rm %s\nset %s/DEVICE %s\n" % (BR_ROOT, BR_ROOT, BRIDGE) self.BR_CONFIG += "set %s/TYPE Bridge\n" % BR_ROOT self.BR_CONFIG += "set %s/PEERNTP yes\n" % BR_ROOT @@ -96,6 +99,7 @@ class Network: if OVIRT_VARS.has_key("OVIRT_VLAN"): + self.CONFIGURED_NICS.append("%s.%s" % (self.CONFIGURED_NIC, VLAN_ID)) VLAN_ID=OVIRT_VARS["OVIRT_VLAN"] VL_ROOT = "%s.%s" % (IF_ROOT, VLAN_ID) self.VL_CONFIG += "rm %s\n" % VL_ROOT @@ -187,16 +191,17 @@ class Network: log("Configuring network") os.system("ifdown br" + self.CONFIGURED_NIC) for vlan in os.listdir("/proc/net/vlan/"): + # XXX wrong match e.g. eth10.1 with eth1 if self.CONFIGURED_NIC in vlan: os.system("vconfig rem " + vlan + "&> /dev/null") ovirt_safe_delete_config(self.IFSCRIPTS_PATH + vlan) os.system("rm -rf " + self.IFSCRIPTS_PATH + vlan) - for script in os.listdir(self.IFSCRIPTS_PATH): - if self.CONFIGURED_NIC in script: - log("Removing Script: " + script) - ovirt_safe_delete_config("/etc/sysconfig/network-scripts/" + script) - augtool("rm", "/files/etc/sysconfig/network-scripts/ifcfg-br"+self.CONFIGURED_NIC, "") + for script in glob("%s%s*" % (self.IFSCRIPTS_PATH, self.CONFIGURED_NIC)): + # XXX wrong match e.g. eth10 with eth1* (need * to cover VLANs) + log("Removing Script: " + script) + ovirt_safe_delete_config(script) + augtool("rm", self.IFCONFIG_FILE_ROOT+"br"+self.CONFIGURED_NIC, "") for line in self.IF_CONFIG: log(line) @@ -231,15 +236,30 @@ class Network: except: pass + # preserve current MAC mappings for *all physical* network interfaces + for nicdev in glob('/sys/class/net/*/device'): + nic=nicdev.split('/')[4] + if nic != self.CONFIGURED_NIC: + f=open('/sys/class/net/%s/address' % nic) + mac=f.read().strip() + f.close() + if len(mac) > 0: + self.CONFIGURED_NICS.append(nic) + nicroot = "%s%s" % (self.IFCONFIG_FILE_ROOT, nic) + # XXX augtool does save every time! + augtool("set", "%s/DEVICE" % nicroot, nic) + augtool("set", "%s/HWADDR" % nicroot, mac) + augtool("set", "%s/ONBOOT" % nicroot, "no") + net_configured=1 - for i in os.listdir("/etc/sysconfig/network-scripts/"): - if "ifcfg" in i: - ovirt_store_config("/etc/sysconfig/network-scripts/" + i) + for nic in self.CONFIGURED_NICS: + ovirt_store_config("%s%s" % (self.IFSCRIPTS_PATH, nic) ) ovirt_store_config(self.NTP_CONFIG_FILE) log("Network configured successfully") if net_configured == 1: log("\nStopping Network service") os.system("service network stop &> /dev/null") + # XXX eth assumed in breth brctl_cmd = "brctl show|grep breth|awk '{print $1}'" brctl = subprocess.Popen(brctl_cmd, shell=True, stdout=PIPE, stderr=STDOUT) brctl_output = brctl.stdout.read() diff --git a/scripts/ovirt-config-networking b/scripts/ovirt-config-networking index 6ddd805..30c8d2d 100755 --- a/scripts/ovirt-config-networking +++ b/scripts/ovirt-config-networking @@ -21,6 +21,7 @@ NTPCONF_FILE_ROOT="/files/etc/ntp" NTP_CONFIG_FILE="/etc/ntp.conf" NTPSERVERS="" CONFIGURED_NIC="" +CONFIGURED_NICS="" VLAN_ID="" VL_ROOT="" @@ -561,12 +562,14 @@ if ls "$WORKDIR"/augtool-* > /dev/null 2>&1 ; then config="$WORKDIR"/config-augtool cat "$WORKDIR"/augtool-* > $config - # must preserve current eth/MAC mapping for *all* network interfaces, + CONFIGURED_NICS="$CONFIGURED_NIC br$CONFIGURED_NIC" + if [ -n "${VLAN_ID}" ]; then + CONFIGURED_NICS="$CONFIGURED_NICS $CONFIGURED_NIC.$VLAN_ID" + fi + # preserve current MAC mappings for *all physical* network interfaces # to avoid dev$RANDOM rhbz#489927 - # TODO use udev rules to persist network interfaces - for eth in $(ls -d /sys/class/net/eth*|grep -v '\.') ; do - nic=$(basename $eth) - mac=$(cat $eth/address) + for nic in $(ls -d /sys/class/net/*/device|cut -d/ -f5) ; do + mac=$(cat /sys/class/net/$nic/address) if [ -n "$nic" -a -n "$mac" ]; then if_root="$IFCONFIG_FILE_ROOT-$nic" printf "\nset $if_root/DEVICE $nic" >> $config @@ -578,6 +581,7 @@ if ls "$WORKDIR"/augtool-* > /dev/null 2>&1 ; then fi if [ ${CONFIGURED_NIC} != $nic ]; then printf "\nset $if_root/ONBOOT no" >> $config + CONFIGURED_NICS="$CONFIGURED_NICS $nic" fi printf "\nset $if_root/HWADDR $mac" >> $config printf "\n" >> $config @@ -588,9 +592,10 @@ if ls "$WORKDIR"/augtool-* > /dev/null 2>&1 ; then if [ $? = 0 ]; then log "Network configured successfully" net_configured=1 - ovirt_store_config \ - /etc/sysconfig/network-scripts/ifcfg* \ - $NTP_CONFIG_FILE + for nic in $CONFIGURED_NICS; do + ovirt_store_config /etc/sysconfig/network-scripts/ifcfg-$nic + done + ovirt_store_config $NTP_CONFIG_FILE else log "Error configuring network, see $OVIRT_LOGFILE" stop_log @@ -601,6 +606,7 @@ stop_log if [ "$net_configured" = 1 ]; then service network stop > /dev/null 2>&1 + # XXX eth assumed in breth for i in `brctl show | grep breth | awk '{print $1}'` do ifconfig $i down diff --git a/scripts/ovirt-functions b/scripts/ovirt-functions index 6ee3736..fd99bdf 100644 --- a/scripts/ovirt-functions +++ b/scripts/ovirt-functions @@ -23,7 +23,6 @@ OVIRT_BACKUP_DIR=/var/lib/ovirt-backup MANAGEMENT_SCRIPTS_DIR=/etc/node.d OVIRT_CONFIG_FILES="\ - /etc/sysconfig/network-scripts/ifcfg-* \ /etc/rsyslog.conf \ /etc/libvirt/libvirtd.conf \ /etc/sasl2/libvirt.conf \ diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index ae3c013..0c94363 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -100,19 +100,6 @@ OVIRT_BACKUP_DIR="/var/lib/ovirt-backup" MANAGEMENT_SCRIPTS_DIR="/etc/node.d" -OVIRT_CONFIG_FILES = ["/etc/sysconfig/network-scripts/ifcfg-*", \ - "/etc/rsyslog.conf", \ - "/etc/libvirt/libvirtd.conf", \ - "/etc/sasl2/libvirt.conf", \ - "/etc/libvirt/passwd.db", \ - "/etc/passwd", \ - "/etc/shadow", \ - "/etc/ssh/ssh_host*_key*", \ - "/etc/default/ovirt", \ - "/etc/sysconfig/network", \ - "/etc/collectd.conf", \ - "/etc/logrotate.d/ovirt-logrotate.conf" ] - def log(log_entry): if is_firstboot(): log_file = open(OVIRT_TMP_LOGFILE, "a") -- 1.7.3.4 From jboggs at redhat.com Thu Aug 11 19:52:15 2011 From: jboggs at redhat.com (Joey Boggs) Date: Thu, 11 Aug 2011 15:52:15 -0400 Subject: [Ovirt-devel] [PATCH] map nics-> bridges correctly in network pages, when cancelling nic configuration return to network page Message-ID: <1313092335-13501-1-git-send-email-jboggs@redhat.com> rhbz#720568 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 41 +++++++++++++++++------------------------ 1 files changed, 17 insertions(+), 24 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 4bd46d5..bddf6aa 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -774,6 +774,7 @@ class NodeConfigScreen(): try: dev_interface = device.get_property("INTERFACE") dev_vendor = device.get_property("ID_VENDOR_FROM_DATABASE") + dev_type = device.get_property("DEVTYPE") try: dev_vendor = dev_vendor.replace(",", "") except AttributeError: @@ -797,9 +798,10 @@ class NodeConfigScreen(): cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/BOOTPROTO" % str(dev_interface) dev_bootproto = augtool_get(cmd) type_cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/TYPE" % str(dev_interface) - dev_type = augtool_get(type_cmd) + bridge_cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/BRIDGE" % str(dev_interface) + dev_bridge = augtool_get(bridge_cmd) if dev_bootproto is None: - cmd = "/files/etc/sysconfig/network-scripts/ifcfg-br%s/BOOTPROTO" % str(dev_interface) + cmd = "/files/etc/sysconfig/network-scripts/ifcfg-%s/BOOTPROTO" % str(dev_bridge) dev_bootproto = augtool_get(cmd) if dev_bootproto is None: dev_bootproto = "Disabled" @@ -810,20 +812,17 @@ class NodeConfigScreen(): dev_conf_status = "Configured " if dev_conf_status == "Configured ": self.configured_nics = self.configured_nics + 1 - if dev_type is None: - type_cmd = "/files/etc/sysconfig/network-scripts/ifcfg-br%s/TYPE" % str(dev_interface) - dev_type = augtool_get(type_cmd) except: pass - if not dev_interface == "lo" and not dev_interface.startswith("br") and not dev_interface.startswith("bond") and not dev_interface.startswith("sit") and not "." in dev_interface: - if not dev_type == "Bridge": - self.nic_dict[dev_interface] = "%s,%s,%s,%s,%s,%s" % (dev_interface,dev_bootproto,dev_vendor,dev_address, dev_driver, dev_conf_status) + if not dev_interface == "lo" and not dev_interface.startswith("bond") and not dev_interface.startswith("sit") and not "." in dev_interface: + if not dev_type == "bridge": + self.nic_dict[dev_interface] = "%s,%s,%s,%s,%s,%s,%s" % (dev_interface,dev_bootproto,dev_vendor,dev_address, dev_driver, dev_conf_status,dev_bridge) if len(self.nic_dict) > 5: self.nic_lb = Listbox(height = 5, width = 56, returnExit = 1, scroll = 1) else: self.nic_lb = Listbox(height = 5, width = 56, returnExit = 1, scroll = 0) for key in sorted(self.nic_dict.iterkeys()): - dev_interface,dev_bootproto,dev_vendor,dev_address,dev_driver,dev_conf_status = self.nic_dict[key].split(",", 5) + dev_interface,dev_bootproto,dev_vendor,dev_address,dev_driver,dev_conf_status,dev_bridge = self.nic_dict[key].split(",", 6) to_rem = len(dev_vendor) - 10 # if negative pad name space if to_rem < 1: @@ -861,7 +860,8 @@ class NodeConfigScreen(): link_status = "Active" else: link_status = "Inactive" - interface,bootproto,vendor,address,driver,conf_status = self.nic_dict[self.nic_lb.current()].split(",", 5) + dev = self.nic_lb.current() + interface,bootproto,vendor,address,driver,conf_status,dev_bridge = self.nic_dict[dev].split(",", 6) nic_detail_grid = Grid(6, 10) nic_detail_grid.setField(Label("Interface: "), 0, 1, anchorLeft = 1, padding=(0,0,1,0)) nic_detail_grid.setField(Label("Protocol: "), 0, 2, anchorLeft = 1, padding=(0,0,1,0)) @@ -901,28 +901,24 @@ class NodeConfigScreen(): self.ipv4_netdevmask.setCallback(self.ipv4_netmask_callback) self.ipv4_netdevgateway = Entry(16, "", scroll = 0) self.ipv4_netdevgateway.setCallback(self.ipv4_gateway_callback) + if not dev_bridge is None: + dev = dev_bridge if "OVIRT_IP_ADDRESS" in OVIRT_VARS: self.ipv4_netdevip.set(OVIRT_VARS["OVIRT_IP_ADDRESS"]) else: - current_ip = get_ip_address(self.nic_lb.current()) - if current_ip == "": - current_ip = get_ip_address("br" + self.nic_lb.current()) + current_ip = get_ip_address(dev) if current_ip != "": self.ipv4_netdevip.set(current_ip) if "OVIRT_IP_NETMASK" in OVIRT_VARS: self.ipv4_netdevmask.set(OVIRT_VARS["OVIRT_IP_NETMASK"]) else: - current_netmask = get_netmask(self.nic_lb.current()) - if current_netmask == "": - current_netmask = get_netmask("br" + self.nic_lb.current()) - if current_ip != "": + current_netmask = get_netmask(dev) + if current_netmask != "": self.ipv4_netdevmask.set(current_netmask) if "OVIRT_IP_GATEWAY" in OVIRT_VARS: self.ipv4_netdevgateway.set(OVIRT_VARS["OVIRT_IP_GATEWAY"]) else: - current_gateway = get_gateway(self.nic_lb.current()) - if current_gateway == "": - current_gateway = get_gateway("br" + self.nic_lb.current()) + current_gateway = get_gateway(dev) if is_valid_ipv4(current_gateway) or is_valid_ipv6(current_gateway): self.ipv4_netdevgateway.set(current_gateway) ipv4_grid = Grid (5,3) @@ -1576,10 +1572,7 @@ class NodeConfigScreen(): elif self.net_apply_config == 1: self.__current_page = NETWORK_PAGE elif is_managed(): - dev_interface,dev_bootproto,dev_vendor,dev_address,dev_driver,dev_conf_status = self.nic_dict[self.nic_lb.current()].split(",", 5) - if self.configured_nics >= 1 and dev_conf_status != "Configured" : - ButtonChoiceWindow(self.screen, "Network", "Hypervisor is already managed, unable to configure additional nics", buttons = ['Ok']) - self.__current_page = NETWORK_PAGE + self.__current_page = NETWORK_PAGE elif self.__nic_config_failed == 1: self.__current_page = NETWORK_DETAILS_PAGE else: -- 1.7.6 From mburns at redhat.com Mon Aug 15 18:42:54 2011 From: mburns at redhat.com (Mike Burns) Date: Mon, 15 Aug 2011 14:42:54 -0400 Subject: [Ovirt-devel] [PATCH node] Don't start ntp daemons until networking is started Message-ID: <1313433774-30560-1-git-send-email-mburns@redhat.com> - Default NETWORKING=no in /etc/sysconfig/network - Update to yes when configuring network through TUI or firstboot - After configuration in TUI, (re)start ntp daemons rhbz#675870 Signed-off-by: Mike Burns --- recipe/common-post.ks | 6 ++++++ scripts/network.py | 10 +++++++++- scripts/ovirt-config-networking | 1 + 3 files changed, 16 insertions(+), 1 deletions(-) diff --git a/recipe/common-post.ks b/recipe/common-post.ks index 4507959..e9a8a28 100644 --- a/recipe/common-post.ks +++ b/recipe/common-post.ks @@ -225,3 +225,9 @@ mkdir -p /root/.virt-manager /home/admin/.virt-manager #symlink virt-manager-tui pointer file to .pyc version sed -i "s/tui.py/tui.pyc/g" /usr/bin/virt-manager-tui + +#set NETWORKING off by default +augtool << \EOF_NETWORKING +set /files/etc/sysconfig/network/NETWORKING no +save +EOF_NETWORKING diff --git a/scripts/network.py b/scripts/network.py index 50d4624..ea16212 100644 --- a/scripts/network.py +++ b/scripts/network.py @@ -184,6 +184,9 @@ class Network: elif offset == 2: augtool("set", "/files/etc/ntp.conf/server[2]", server) offset = offset + 1 + os.system("service ntpd stop &> /dev/null") + os.system("service ntpdate start &> /dev/null") + os.system("service ntpd start &> /dev/null") def save_network_configuration(self): net_configured=0 @@ -255,10 +258,13 @@ class Network: for nic in self.CONFIGURED_NICS: ovirt_store_config("%s%s" % (self.IFSCRIPTS_PATH, nic) ) ovirt_store_config(self.NTP_CONFIG_FILE) + augtool("set", "/files/etc/sysconfig/network/NETWORKING", "yes") + ovirt_store_config("/etc/sysconfig/network") log("Network configured successfully") if net_configured == 1: - log("\nStopping Network service") + log("\nStopping Network services") os.system("service network stop &> /dev/null") + os.system("service ntpd stop &> /dev/null") # XXX eth assumed in breth brctl_cmd = "brctl show|grep breth|awk '{print $1}'" brctl = subprocess.Popen(brctl_cmd, shell=True, stdout=PIPE, stderr=STDOUT) @@ -270,6 +276,8 @@ class Network: os.system(del_br_cmd) log("\nStarting Network service") os.system("service network start &> /dev/null") + os.system("service ntpdate start &> /dev/null") + os.system("service ntpd start &> /dev/null") if OVIRT_VARS.has_key("NTP"): log("Testing NTP Configuration") test_ntp_configuration() diff --git a/scripts/ovirt-config-networking b/scripts/ovirt-config-networking index cb96ab5..116159e 100755 --- a/scripts/ovirt-config-networking +++ b/scripts/ovirt-config-networking @@ -563,6 +563,7 @@ if ls "$WORKDIR"/augtool-* > /dev/null 2>&1 ; then config="$WORKDIR"/config-augtool cat "$WORKDIR"/augtool-* > $config + echo "set /files/etc/sysconfig/network/NETWORKING yes" >> $config CONFIGURED_NICS="$CONFIGURED_NIC br$CONFIGURED_NIC" if [ -n "${VLAN_ID}" ]; then CONFIGURED_NICS="$CONFIGURED_NICS $CONFIGURED_NIC.$VLAN_ID" -- 1.7.4.4 From mburns at redhat.com Wed Aug 17 17:13:34 2011 From: mburns at redhat.com (Mike Burns) Date: Wed, 17 Aug 2011 13:13:34 -0400 Subject: [Ovirt-devel] [PATCH node] cciss autoinstall fix Message-ID: <1313601214-7784-1-git-send-email-mburns@redhat.com> Signed-off-by: Mike Burns --- scripts/ovirt-config-storage | 21 +++++++++++++++------ 1 files changed, 15 insertions(+), 6 deletions(-) diff --git a/scripts/ovirt-config-storage b/scripts/ovirt-config-storage index c8fb049..46f7e19 100755 --- a/scripts/ovirt-config-storage +++ b/scripts/ovirt-config-storage @@ -83,6 +83,7 @@ get_multipath_deps() { translate_multipath_device() { #trim so that only sdX is stored, but support passing /dev/sdX local dev="$1" + local dm_dev if [ -z "$dev" ]; then return 1 @@ -90,15 +91,23 @@ translate_multipath_device() { if [[ "$dev" =~ "/dev/mapper" ]]; then echo "$dev" return 0 - fi + elif [[ "$dev" =~ "/dev/cciss" ]]; then + #rename to cciss!device + dev2="cciss\!$(basename "$dev")" + dm_dev="/dev/$(basename $(ls -d /sys/block/$dev2/holders/dm* | head -n1))" + if [ -z "$dm_dev" ]; then + echo "$dev" + return + fi + else - if ! multipath -ll "$dev" 2>&1 >/dev/null; then - echo "$dev" - return + if ! multipath -ll "$dev" 2>&1 >/dev/null; then + echo "$dev" + return + fi + dm_dev=/dev/$(multipath -ll "$dev" | egrep dm-[0-9]+ | sed -r 's/^.* (dm-[0-9]+) .*$/\1/') fi - local dm_dev=/dev/$(multipath -ll "$dev" | egrep dm-[0-9]+ | sed -r 's/^.* (dm-[0-9]+) .*$/\1/') - local mpath_device=$(get_dm_device "$dm_dev") if [ -z "$mpath_device" ]; then -- 1.7.4.4 From jboggs at redhat.com Mon Aug 22 00:47:13 2011 From: jboggs at redhat.com (Joey Boggs) Date: Sun, 21 Aug 2011 20:47:13 -0400 Subject: [Ovirt-devel] [PATCH] move back to network page after applying settings Message-ID: <1313974033-25626-1-git-send-email-jboggs@redhat.com> rhbz#699339 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 8621ba8..e040a99 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -1586,6 +1586,8 @@ class NodeConfigScreen(): if menu_choice == NETWORK_PAGE: if pressed == RESET_BUTTON: self.__current_page = NETWORK_PAGE + elif pressed == APPLY_BUTTON: + self.__current_page == NETWORK_PAGE else: self.__current_page = NETWORK_DETAILS_PAGE else: -- 1.7.6 From mburns at redhat.com Mon Aug 22 13:55:16 2011 From: mburns at redhat.com (Mike Burns) Date: Mon, 22 Aug 2011 09:55:16 -0400 Subject: [Ovirt-devel] [PATCH node] handle wildcards appropriately in dracut plugin Message-ID: <1314021316-15357-1-git-send-email-mburns@redhat.com> when specifying a list of devices, one with a wildcard, the dracut plugin would attempt to use all devices matching the wildcard instead of just the first device. Ex. storage_init=/dev/vd*,/dev/sda should match /dev/vda and /dev/sda only, but if /dev/vdb, /dev/vdc etc existed, it would match all of those as well. rhbz#726843 Signed-off-by: Mike Burns --- dracut/ovirt-cleanup.sh | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/dracut/ovirt-cleanup.sh b/dracut/ovirt-cleanup.sh index e36a265..1d7db84 100755 --- a/dracut/ovirt-cleanup.sh +++ b/dracut/ovirt-cleanup.sh @@ -55,12 +55,15 @@ info "Found storage_init: $storage_init" # Since we only care which disks are being used, change to a single list storage_init="$(echo "$storage_init" | sed 's/;/,/')" info "Replaced all ';' with ',' : $storage_init" +storage_init="$(echo "$storage_init" | sed 's/\*/\\\*/')" +info "Escaped all asterisks: $storage_init" oldIFS=$IFS lvm pvscan 2>/dev/null IFS="," for dev in $storage_init; do + dev="$(echo "$dev" | sed 's/\\\*/\*/g')" device=$(IFS=$oldIFS parse_disk_id "$dev") info "After parsing \"$dev\", we got \"$device\"" echo "Wiping LVM from device: ${device}" -- 1.7.4.4 From mburns at redhat.com Mon Aug 22 14:12:55 2011 From: mburns at redhat.com (Mike Burns) Date: Mon, 22 Aug 2011 10:12:55 -0400 Subject: [Ovirt-devel] [PATCH node] allow o-c-password to set admin password Message-ID: <1314022376-17543-1-git-send-email-mburns@redhat.com> Provides a way to set the admin password if the adminpw option was omitted from autoinstall options rhbz#725984 Signed-off-by: Mike Burns --- scripts/ovirt-config-password | 11 +++++++---- 1 files changed, 7 insertions(+), 4 deletions(-) diff --git a/scripts/ovirt-config-password b/scripts/ovirt-config-password index fea4efa..6405f7c 100755 --- a/scripts/ovirt-config-password +++ b/scripts/ovirt-config-password @@ -39,12 +39,13 @@ function prompt_sasl_user { set_password () { printf "\n\n Password Configuration\n\n" + local user=${1-root} # prompt user # Set the password for the root user first - printf "\nSystem Administrator (root):\n" + printf "\nSystem Administrator ($user):\n" unmount_config /etc/shadow - passwd root + passwd $user ovirt_store_config /etc/shadow } @@ -69,7 +70,8 @@ toggle_ssh () { fi } -PASSWORD="Set administrator password" +PASSWORD="Set root password" +ADMIN_PASSWORD="Set admin user password" SSH="Toggle SSH password authentication" QUIT="Quit and Return To Menu" @@ -87,10 +89,11 @@ else printf "\nSSH password authentication is currently ${state}.\n\n" PS3="Please select an option: " - select option in "$PASSWORD" "$SSH" "$QUIT" + select option in "$PASSWORD" "$ADMIN_PASSWORD" "$SSH" "$QUIT" do case $option in $PASSWORD) set_password; break;; + $ADMIN_PASSWORD) set_password admin; break;; $SSH) toggle_ssh; break;; $QUIT) exit;; esac -- 1.7.4.4 From mburns at redhat.com Tue Aug 23 20:47:34 2011 From: mburns at redhat.com (Mike Burns) Date: Tue, 23 Aug 2011 16:47:34 -0400 Subject: [Ovirt-devel] [PATCH node] fix read-only root error on boot Message-ID: <1314132454-30824-1-git-send-email-mburns@redhat.com> Starting udev: /sbin/restorecon set context /dev/.initramfs/live->system_u:object_r:device_t:s0 failed:'Read-only file system' Resolves: rhbz#675868 Signed-off-by: Mike Burns --- recipe/common-post.ks | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/recipe/common-post.ks b/recipe/common-post.ks index a17e899..cf5bc72 100644 --- a/recipe/common-post.ks +++ b/recipe/common-post.ks @@ -79,6 +79,7 @@ sed -i '/^files \/etc*/ s/^/#/' /etc/rwtab cat > /etc/rwtab.d/ovirt << \EOF_rwtab_ovirt files /etc dirs /var/lib/multipath +dirs /dev/.initramfs/live dirs /var/lib/net-snmp dirs /var/lib/dnsmasq files /root/.ssh -- 1.7.4.4 From mburns at redhat.com Thu Aug 25 13:57:33 2011 From: mburns at redhat.com (Mike Burns) Date: Thu, 25 Aug 2011 09:57:33 -0400 Subject: [Ovirt-devel] [PATCH node] always remove HostVG in dracut when reinstall/uninstall/firstboot passed Message-ID: <1314280653-27625-1-git-send-email-mburns@redhat.com> rhbz#733274 Signed-off-by: Mike Burns --- dracut/install | 1 + dracut/ovirt-cleanup.sh | 14 +++++++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/dracut/install b/dracut/install index 1832b89..000272a 100755 --- a/dracut/install +++ b/dracut/install @@ -2,6 +2,7 @@ inst yes inst head +inst awk inst_hook pre-pivot 01 "$moddir/ovirt-cleanup.sh" inst_simple "$moddir/ovirt-boot-functions" /sbin/ovirt-boot-functions diff --git a/dracut/ovirt-cleanup.sh b/dracut/ovirt-cleanup.sh index 1d7db84..c96d6fe 100755 --- a/dracut/ovirt-cleanup.sh +++ b/dracut/ovirt-cleanup.sh @@ -40,10 +40,19 @@ if [ $? -eq 1 ]; then storage_init="$(getargs ovirt_init)" if [ $? -eq 1 ]; then info "storage_init or ovirt_init arguments not found" - return 0 + else + info "Found storage_init: $storage_init" fi fi -info "Found storage_init: $storage_init" + +# Check for HostVG +lvm pvscan >/dev/null 2>&1 + +for hostvg in $(lvm pvs --noheadings -o vg_name,pv_name 2>/dev/null | awk '/^ HostVG/{print $2}'); do + storage_init="$hostvg,$storage_init" + info "Found HostVG on $hostvg" +done + # storage_init is passed in a specific format # A comma separated list of HostVG devices @@ -60,7 +69,6 @@ info "Escaped all asterisks: $storage_init" oldIFS=$IFS -lvm pvscan 2>/dev/null IFS="," for dev in $storage_init; do dev="$(echo "$dev" | sed 's/\\\*/\*/g')" -- 1.7.4.4 From mburns at redhat.com Thu Aug 25 17:06:53 2011 From: mburns at redhat.com (Mike Burns) Date: Thu, 25 Aug 2011 13:06:53 -0400 Subject: [Ovirt-devel] [PATCH node] Remove libvirt-cim Message-ID: <1314292013-15646-1-git-send-email-mburns@redhat.com> Since libvirt-cim is an alternate management tool, we're dropping it from the core ovirt-node image. It makes more sense as a plugin where all configuration and setup is kept separate to be used only by those that want the functionality. rhbz#727532 Signed-off-by: Mike Burns --- recipe/common-pkgs.ks | 2 -- recipe/ovirt16-post.ks | 4 ---- recipe/rhevh6-post.ks | 4 ---- 3 files changed, 0 insertions(+), 10 deletions(-) diff --git a/recipe/common-pkgs.ks b/recipe/common-pkgs.ks index f07146f..f4e298a 100644 --- a/recipe/common-pkgs.ks +++ b/recipe/common-pkgs.ks @@ -110,5 +110,3 @@ python-hivex febootstrap-supermin-helper # sosreport soft-dep rpm-python -# alternate management framework -libvirt-cim diff --git a/recipe/ovirt16-post.ks b/recipe/ovirt16-post.ks index 0229201..848a72c 100644 --- a/recipe/ovirt16-post.ks +++ b/recipe/ovirt16-post.ks @@ -98,8 +98,6 @@ cat > /etc/sysconfig/iptables << \EOF -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT -A INPUT -p icmp -j ACCEPT -A INPUT -i lo -j ACCEPT -# libvirt-cim --A INPUT -p tcp --dport 5989 -j ACCEPT # SSH -A INPUT -p tcp --dport 22 -j ACCEPT # guest consoles @@ -123,8 +121,6 @@ cat > /etc/sysconfig/ip6tables << \EOF -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT -A INPUT -p ipv6-icmp -j ACCEPT -A INPUT -i lo -j ACCEPT -# libvirt-cim --A INPUT -p tcp --dport 5989 -j ACCEPT # SSH -A INPUT -p tcp --dport 22 -j ACCEPT # guest consoles diff --git a/recipe/rhevh6-post.ks b/recipe/rhevh6-post.ks index 12ce342..7386249 100644 --- a/recipe/rhevh6-post.ks +++ b/recipe/rhevh6-post.ks @@ -168,8 +168,6 @@ cat > /etc/sysconfig/iptables << \EOF -A INPUT -p tcp --dport 54321 -j ACCEPT # libvirt tls -A INPUT -p tcp --dport 16514 -j ACCEPT -# libvirt-cim --A INPUT -p tcp --dport 5989 -j ACCEPT # SSH -A INPUT -p tcp --dport 22 -j ACCEPT # guest consoles @@ -195,8 +193,6 @@ cat > /etc/sysconfig/ip6tables << \EOF -A INPUT -i lo -j ACCEPT # libvirt tls -A INPUT -p tcp --dport 16514 -j ACCEPT -# libvirt-cim --A INPUT -p tcp --dport 5989 -j ACCEPT # SSH -A INPUT -p tcp --dport 22 -j ACCEPT # guest consoles -- 1.7.4.4 From mburns at redhat.com Thu Aug 25 18:07:32 2011 From: mburns at redhat.com (Mike Burns) Date: Thu, 25 Aug 2011 14:07:32 -0400 Subject: [Ovirt-devel] [PATCH node 1/3] add reinstall and uninstall options to boot menu Message-ID: <1314295652-21116-1-git-send-email-mburns@redhat.com> rhbz#733357 Signed-off-by: Mike Burns --- recipe/common-nochroot.ks | 19 +++++++++++++++++-- 1 files changed, 17 insertions(+), 2 deletions(-) diff --git a/recipe/common-nochroot.ks b/recipe/common-nochroot.ks index c5d009f..c6dd76d 100644 --- a/recipe/common-nochroot.ks +++ b/recipe/common-nochroot.ks @@ -17,6 +17,9 @@ sed -i -e 's/ quiet//' $LIVE_ROOT/isolinux/isolinux.cfg # Remove Verify and Boot option sed -i -e '/label check0/{N;N;N;d;}' $LIVE_ROOT/isolinux/isolinux.cfg +# Rename Boot option to Install or Upgrade +sed -i 's/^ menu label Boot$/ menu label Install or Upgrade/' $LIVE_ROOT/isolinux/isolinux.cfg + # add serial console boot entry menu=$(mktemp) awk ' @@ -27,9 +30,21 @@ linux0==1 && $1=="append" { linux0==1 && $1=="label" && $2!="linux0" { linux0=2 print "label serial-console" - print " menu label Boot with serial console" + print " menu label Install or Upgrade with serial console" print " kernel vmlinuz0" - print append0" console=ttyS0,115200n8" + print append0" console=ttyS0,115200n8 " + print "label reinstall" + print " menu label Reinstall" + print " kernel vmlinux0" + print append0" reinstall " + print "label reinstall-serial" + print " menu label Reinstall with serial console" + print " kernel vmlinux0" + print append0" reinstall console=ttyS0,115200n8 " + print "label uninstall" + print " menu label Uninstall" + print " kernel vmlinux0" + print append0" uninstall " } { print } ' $LIVE_ROOT/isolinux/isolinux.cfg > $menu -- 1.7.4.4 From jboggs at redhat.com Fri Aug 26 13:34:27 2011 From: jboggs at redhat.com (Joey Boggs) Date: Fri, 26 Aug 2011 09:34:27 -0400 Subject: [Ovirt-devel] [PATCH] hide logical networks scroll bar when < 4 entries Message-ID: <1314365667-12423-1-git-send-email-jboggs@redhat.com> rhbz#733584 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 17ffdd7..78a6153 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -616,8 +616,12 @@ class NodeConfigScreen(): elements.setField(Label("Networking:"), 0, 0, anchorLeft = 1, anchorTop = 1) elements.setField(networking, 1, 0, anchorLeft = 1, padding=(4, 0, 0, 1)) elements.setField(Label("Logical Network Device MAC Address"),1,4,anchorLeft =1) - self.network_list = Textbox(50, 3, "", scroll = 1) networks = logical_to_physical_networks() + if len(networks) >= 4: + net_scroll = 1 + else: + net_scroll = 0 + self.network_list = Textbox(50, 3, "", scroll = net_scroll) net_entry = "" for key in networks.iterkeys(): device, mac = networks[key] -- 1.7.6 From jboggs at redhat.com Fri Aug 26 14:03:59 2011 From: jboggs at redhat.com (Joey Boggs) Date: Fri, 26 Aug 2011 10:03:59 -0400 Subject: [Ovirt-devel] [PATCH] declare VLAN_ID before using Message-ID: <1314367439-14693-1-git-send-email-jboggs@redhat.com> rhbz#733585 Signed-off-by: Joey Boggs --- scripts/network.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/network.py b/scripts/network.py index ea16212..25cd2e3 100644 --- a/scripts/network.py +++ b/scripts/network.py @@ -99,8 +99,8 @@ class Network: if OVIRT_VARS.has_key("OVIRT_VLAN"): - self.CONFIGURED_NICS.append("%s.%s" % (self.CONFIGURED_NIC, VLAN_ID)) VLAN_ID=OVIRT_VARS["OVIRT_VLAN"] + self.CONFIGURED_NICS.append("%s.%s" % (self.CONFIGURED_NIC, VLAN_ID)) VL_ROOT = "%s.%s" % (IF_ROOT, VLAN_ID) self.VL_CONFIG += "rm %s\n" % VL_ROOT self.VL_CONFIG += "set %s/DEVICE %s.%s\n" % (VL_ROOT, self.CONFIGURED_NIC, VLAN_ID) -- 1.7.6 From mburns at redhat.com Fri Aug 26 15:26:53 2011 From: mburns at redhat.com (Mike Burns) Date: Fri, 26 Aug 2011 11:26:53 -0400 Subject: [Ovirt-devel] [PATCH node 1/3] add reinstall and uninstall options to boot menu In-Reply-To: <1314295652-21116-1-git-send-email-mburns@redhat.com> References: <1314295652-21116-1-git-send-email-mburns@redhat.com> Message-ID: <1314372413.4052.34.camel@beelzebub.mburnsfire.net> On Thu, 2011-08-25 at 14:07 -0400, Mike Burns wrote: > rhbz#733357 > > Signed-off-by: Mike Burns > --- > recipe/common-nochroot.ks | 19 +++++++++++++++++-- > 1 files changed, 17 insertions(+), 2 deletions(-) > > diff --git a/recipe/common-nochroot.ks b/recipe/common-nochroot.ks > index c5d009f..c6dd76d 100644 > --- a/recipe/common-nochroot.ks > +++ b/recipe/common-nochroot.ks > @@ -17,6 +17,9 @@ sed -i -e 's/ quiet//' $LIVE_ROOT/isolinux/isolinux.cfg > # Remove Verify and Boot option > sed -i -e '/label check0/{N;N;N;d;}' $LIVE_ROOT/isolinux/isolinux.cfg > > +# Rename Boot option to Install or Upgrade > +sed -i 's/^ menu label Boot$/ menu label Install or Upgrade/' $LIVE_ROOT/isolinux/isolinux.cfg > + > # add serial console boot entry > menu=$(mktemp) > awk ' > @@ -27,9 +30,21 @@ linux0==1 && $1=="append" { > linux0==1 && $1=="label" && $2!="linux0" { > linux0=2 > print "label serial-console" > - print " menu label Boot with serial console" > + print " menu label Install or Upgrade with serial console" > print " kernel vmlinuz0" > - print append0" console=ttyS0,115200n8" > + print append0" console=ttyS0,115200n8 " > + print "label reinstall" > + print " menu label Reinstall" > + print " kernel vmlinux0" should be vmlinuz0 > + print append0" reinstall " > + print "label reinstall-serial" > + print " menu label Reinstall with serial console" > + print " kernel vmlinux0" should be vmlinuz0 > + print append0" reinstall console=ttyS0,115200n8 " > + print "label uninstall" > + print " menu label Uninstall" > + print " kernel vmlinux0" should be vmlinuz0 > + print append0" uninstall " > } > { print } > ' $LIVE_ROOT/isolinux/isolinux.cfg > $menu From jboggs at redhat.com Fri Aug 26 18:43:59 2011 From: jboggs at redhat.com (Joey Boggs) Date: Fri, 26 Aug 2011 14:43:59 -0400 Subject: [Ovirt-devel] [PATCH] handle single dns entry and remove secondary entry if blank Message-ID: <1314384239-3613-1-git-send-email-jboggs@redhat.com> rhbz#699339 Signed-off-by: Joey Boggs --- scripts/network.py | 22 +++++++++++++--------- 1 files changed, 13 insertions(+), 9 deletions(-) diff --git a/scripts/network.py b/scripts/network.py index 25cd2e3..d79a676 100644 --- a/scripts/network.py +++ b/scripts/network.py @@ -143,16 +143,20 @@ class Network: def configure_dns(self): if OVIRT_VARS.has_key("OVIRT_DNS"): DNS=OVIRT_VARS["OVIRT_DNS"] - if not DNS is None: - try: - DNS1, DNS2 = DNS.split(",", 1) - if not DNS1 is None: - augtool("set", "/files/etc/resolv.conf/nameserver[1]", DNS1) - if not DNS2 is None: - augtool("set", "/files/etc/resolv.conf/nameserver[2]", DNS2) + try: + if not DNS is None: + DNS = DNS.split(",") + i = 1 + for server in DNS: + setting = "/files/etc/resolv.conf/nameserver[%s]" % i + augtool("set", setting, server) + i = i + i ovirt_store_config("/etc/resolv.conf") - except: - log("Failed to set DNS servers") + except: + log("Failed to set DNS servers") + finally: + if len(DNS) < 2: + augtool("rm", "/files/etc/resolv.conf/nameserver[2]", "") def configure_ntp(self): if OVIRT_VARS.has_key("OVIRT_NTP"): -- 1.7.6 From mburns at redhat.com Tue Aug 30 15:04:51 2011 From: mburns at redhat.com (Mike Burns) Date: Tue, 30 Aug 2011 11:04:51 -0400 Subject: [Ovirt-devel] [PATCH node] don't trigger upgrade when local_boot_trigger is passed Message-ID: <1314716691-789-1-git-send-email-mburns@redhat.com> rhbz#734112 Signed-off-by: Mike Burns --- scripts/ovirt-early | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/ovirt-early b/scripts/ovirt-early index fa24720..fa7d1f5 100755 --- a/scripts/ovirt-early +++ b/scripts/ovirt-early @@ -464,7 +464,7 @@ start_ovirt_early () { fi done ;; - upgrade* | ovirt_upgrade* | local_boot* | ovirt_local_boot*) + upgrade* | ovirt_upgrade* | local_boot | local_boot=* | ovirt_local_boot*) upgrade=1 if ! grep -q admin /etc/passwd; then unmount_config /etc/passwd /etc/shadow -- 1.7.6 From jboggs at redhat.com Tue Aug 30 17:05:57 2011 From: jboggs at redhat.com (Joey Boggs) Date: Tue, 30 Aug 2011 13:05:57 -0400 Subject: [Ovirt-devel] [PATCH] move back to network details when cancelling configuration Message-ID: <1314723957-31572-1-git-send-email-jboggs@redhat.com> rhbz#720568 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 20 +++++++++++++------- 1 files changed, 13 insertions(+), 7 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 3290d4f..09c21ec 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -976,11 +976,14 @@ class NodeConfigScreen(): self.ipv4_disabled_callback() # prepopulate current values only in case of missing values if self.__nic_config_failed == 1: - self.ipv4_netdevip.set(self.ipv4_current_netdevip) - self.ipv4_netdevmask.set(self.ipv4_current_netdevmask) - self.ipv4_netdevgateway.set(self.ipv4_current_netdevgateway) - self.static_ipv4_nic_proto.setValue("*") - self.ipv4_static_callback() + try: + self.ipv4_netdevip.set(self.ipv4_current_netdevip) + self.ipv4_netdevmask.set(self.ipv4_current_netdevmask) + self.ipv4_netdevgateway.set(self.ipv4_current_netdevgateway) + self.static_ipv4_nic_proto.setValue("*") + self.ipv4_static_callback() + except: + pass # ipv6 grids ipv6_main_grid = Grid(6,8) self.disabled_ipv6_nic_proto = Checkbox("Disabled ") @@ -1335,6 +1338,9 @@ class NodeConfigScreen(): self.screen.popWindow() self.net_apply_config = 1 return + else: + self.__nic_config_failed = 1 + return def process_authentication_config(self): self.screen.setColor("BUTTON", "black", "red") @@ -1616,10 +1622,10 @@ class NodeConfigScreen(): self.__current_page = NETWORK_PAGE elif self.net_apply_config == 1: self.__current_page = NETWORK_PAGE - elif is_managed(): - self.__current_page = NETWORK_PAGE elif self.__nic_config_failed == 1: self.__current_page = NETWORK_DETAILS_PAGE + elif is_managed(): + self.__current_page = NETWORK_PAGE else: self.__current_page = menu_choice elif self.__current_page == SUPPORT_PAGE: -- 1.7.6 From jboggs at redhat.com Tue Aug 30 19:20:46 2011 From: jboggs at redhat.com (Joey Boggs) Date: Tue, 30 Aug 2011 15:20:46 -0400 Subject: [Ovirt-devel] [PATCH] block manual setup runs when dropped to shell Message-ID: <1314732046-10265-1-git-send-email-jboggs@redhat.com> rhbz#733589 Signed-off-by: Joey Boggs --- scripts/ovirt-config-setup.py | 7 +++++-- scripts/ovirtfunctions.py | 9 +++++++++ 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py index 09c21ec..00df6fa 100755 --- a/scripts/ovirt-config-setup.py +++ b/scripts/ovirt-config-setup.py @@ -1661,8 +1661,11 @@ if __name__ == "__main__": print "Unable to run setup in rescue mode" sys.exit(1) elif is_booted_from_local_disk() or "--force" in sys.argv: - screen = NodeConfigScreen() - screen.start() + if manual_setup and "--force" not in sys.argv: + print "Unable to run setup manually, Run \"exit\" to return to setup" + else: + screen = NodeConfigScreen() + screen.start() else: print "Setup must be run after installation and reboot" sys.exit(1) diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py index 1bacb3f..09facaf 100644 --- a/scripts/ovirtfunctions.py +++ b/scripts/ovirtfunctions.py @@ -191,6 +191,15 @@ def is_rescue_mode(): return True return False +def manual_setup(): + manual_cmd = "ps -ed|grep ovirt-admin" + manual = subprocess.Popen(manual_cmd, shell=True, stdout=PIPE, stderr=STDOUT) + manual_output = manual.stdout.read().strip() + if len(manual_output): + return True + else: + return False + # was firstboot menu already shown? # state is stored in persistent config partition def is_firstboot(): -- 1.7.6 From mburns at redhat.com Wed Aug 31 23:16:38 2011 From: mburns at redhat.com (Mike Burns) Date: Wed, 31 Aug 2011 19:16:38 -0400 Subject: [Ovirt-devel] [PATCH] block manual setup runs when dropped to shell In-Reply-To: <1314732046-10265-1-git-send-email-jboggs@redhat.com> References: <1314732046-10265-1-git-send-email-jboggs@redhat.com> Message-ID: <1314832598.4058.31.camel@beelzebub.mburnsfire.net> NACK -- see comments inline On Tue, 2011-08-30 at 15:20 -0400, Joey Boggs wrote: > rhbz#733589 > > Signed-off-by: Joey Boggs > --- > scripts/ovirt-config-setup.py | 7 +++++-- > scripts/ovirtfunctions.py | 9 +++++++++ > 2 files changed, 14 insertions(+), 2 deletions(-) > > diff --git a/scripts/ovirt-config-setup.py b/scripts/ovirt-config-setup.py > index 09c21ec..00df6fa 100755 > --- a/scripts/ovirt-config-setup.py > +++ b/scripts/ovirt-config-setup.py > @@ -1661,8 +1661,11 @@ if __name__ == "__main__": > print "Unable to run setup in rescue mode" > sys.exit(1) > elif is_booted_from_local_disk() or "--force" in sys.argv: > - screen = NodeConfigScreen() > - screen.start() > + if manual_setup and "--force" not in sys.argv: > + print "Unable to run setup manually, Run \"exit\" to return to setup" > + else: > + screen = NodeConfigScreen() > + screen.start() > else: > print "Setup must be run after installation and reboot" > sys.exit(1) > diff --git a/scripts/ovirtfunctions.py b/scripts/ovirtfunctions.py > index 1bacb3f..09facaf 100644 > --- a/scripts/ovirtfunctions.py > +++ b/scripts/ovirtfunctions.py > @@ -191,6 +191,15 @@ def is_rescue_mode(): > return True > return False > > +def manual_setup(): > + manual_cmd = "ps -ed|grep ovirt-admin" on first login, it fails. I installed using rootpw to setup root password, then edited /usr/libexec/ovirt-admin-shell to be this: #!/bin/bash . /etc/profile # Hide kernel messages on the console sudo dmesg -n 1 echo $$ ps -ed | grep ovirt-admin sudo /usr/libexec/ovirt-config-setup read x Then logged out and tried login as admin: localhost.localdomain login: admin Password: Last login: Wed Aug 31 22:59:45 on tty1 1938 1938 ttyS0 00:00:00 ovirt-admin-she Unable to run setup manually, Run "exit" to return to setup There are a couple of things that could be done: ps -ed | grep ovirt-admin | grep -v $$ look for ovirt-config-setup already running (also need to filter out current process from results) Look at PPID of ovirt-config-setup and if that is ovirt-admin-shell, then continue with login > + manual = subprocess.Popen(manual_cmd, shell=True, stdout=PIPE, stderr=STDOUT) > + manual_output = manual.stdout.read().strip() > + if len(manual_output): > + return True > + else: > + return False > + > # was firstboot menu already shown? > # state is stored in persistent config partition > def is_firstboot(): From mburns at redhat.com Wed Aug 31 23:22:29 2011 From: mburns at redhat.com (Mike Burns) Date: Wed, 31 Aug 2011 19:22:29 -0400 Subject: [Ovirt-devel] [PATCH node] fix install when VG exists on disk Message-ID: <1314832949-2147-1-git-send-email-mburns@redhat.com> This only affects non-HostVG volume groups. rhbz#733578 Signed-off-by: Mike Burns --- scripts/storage.py | 14 +++++++++++--- 1 files changed, 11 insertions(+), 3 deletions(-) diff --git a/scripts/storage.py b/scripts/storage.py index 5f7f0e3..047bcd1 100644 --- a/scripts/storage.py +++ b/scripts/storage.py @@ -90,13 +90,19 @@ class Storage: vg = subprocess.Popen(vg_cmd, shell=True, stdout=PIPE, stderr=STDOUT) vg_output = vg.stdout.read() for vg in vg_output: - pvs = system("pvscan -o pv_name,vg_uuid --noheadings | grep \"%s\" | egrep -v -q \"%s%s[0-9]+|%s \"") % (vg, dev, part_delim, dev) - if pvs > 0: + pvs_cmd = "pvs -o pv_name,vg_uuid --noheadings | grep \"%s\" | egrep -v -q \"%s%s[0-9]+|%s \"" % (vg, dev, part_delim, dev) + pvs = subprocess.Popen(pvs_cmd, shell=True, stdout=PIPE, stderr=STDOUT) + pvs_output = pvs.stdout.read() + if pvs_output > 0: log("The volume group \"%s\" spans multiple disks.") % vg log("This operation cannot complete. Please manually") log("cleanup the storage using standard disk tools.") sys.exit(1) - wipe_volume_group(vg) + vg_name_cmd = "vgs -o vg_name,vg_uuid --noheadings 2>/dev/null | grep -w \"" + vg + "\" | awk '{print $1}'" + vg_name = subprocess.Popen(vg_name_cmd, shell=True, stdout=PIPE, stderr=STDOUT) + vg_name_output = vg_name.stdout.read() + system("vgchange -an " + vg_name_output) + wipe_volume_group(vg_name_output) return @@ -372,7 +378,9 @@ class Storage: log("Removing old LVM partitions") wipe_volume_group("HostVG") + log("Wiping LVM on HOSTVGDRIVE") self.wipe_lvm_on_disk(self.HOSTVGDRIVE) + log("Wiping LVM on ROOTDRIVE") self.wipe_lvm_on_disk(self.ROOTDRIVE) self.boot_size_si = self.BOOT_SIZE * (1024 * 1024) / (1000 * 1000) if OVIRT_VARS.has_key("OVIRT_ISCSI_ENABLED") and OVIRT_VARS["OVIRT_ISCSI_ENABLED"] == "y": -- 1.7.4.4