Bug 1084685

Summary: vdsClient addNetwork doesn't support prefix=
Product: [Retired] oVirt Reporter: Andrew Lau <andrew>
Component: vdsmAssignee: Dan Kenigsberg <danken>
Status: CLOSED INSUFFICIENT_DATA QA Contact: Gil Klein <gklein>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 3.4CC: acathrow, andrew, bazulay, gklein, iheim, mgoldboi, yeylon
Target Milestone: ---   
Target Release: 3.4.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: network
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-01 09:02:23 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Andrew Lau 2014-04-05 12:55:00 UTC
Description of problem:
vdsClient will error when ie. ifcfg-eth1 has the contents prefix=24 rather than netmask=255.255.255.0

The command run is: /usr/bin/vdsClient -s localhost addNetwork bridge=ovirtmgmt nics=eth1 force=False bridged=True ONBOOT=yes bootproto=none ipaddr=172.16.0.11 netmask=255.255.255.0 gateway=172.16.0.1

This is what the hosted-engine script calls.

Below is the output of the vdsm log with the first time failing, then suceeding when the ifcfg-eth1 file is updated.


Thread-15::DEBUG::2014-04-05 22:46:02,234::BindingXMLRPC::1074::vds::(wrapper) return getCapabilities with {'status': {'message': 'Done', 'code': 0}, 'info': {'HBAInventory': {'iSCSI': [{'InitiatorName': 'iqn.1994-05.com.redhat:7c4cc8397e42'}], 'FC': []}, 'packages2': {'kernel': {'release': '431.el6.x86_64', 'buildtime': 1385050509.0, 'version': '2.6.32'}, 'spice-server': {'release': '6.el6_5.1', 'buildtime': 1386756528L, 'version': '0.12.4'}, 'vdsm': {'release': '0.el6', 'buildtime': 1395806448L, 'version': '4.14.6'}, 'qemu-kvm': {'release': '2.415.el6_5.7', 'buildtime': 1396537962L, 'version': '0.12.1.2'}, 'libvirt': {'release': '29.el6_5.5', 'buildtime': 1394099230L, 'version': '0.10.2'}, 'qemu-img': {'release': '2.415.el6_5.7', 'buildtime': 1396537962L, 'version': '0.12.1.2'}, 'mom': {'release': '1.el6', 'buildtime': 1391183641L, 'version': '0.4.0'}}, 'cpuModel': 'Intel(R) Xeon(R) CPU           L5320  @ 1.86GHz', 'hooks': {'before_vm_start': {'50_hostedengine': {'md5': '45dde62155b5412eafbfff5ef265acc2'}}}, 'cpuSockets': '2', 'vmTypes': ['kvm'], 'supportedProtocols': ['2.2', '2.3'], 'networks': {}, 'bridges': {';vdsmdummy;': {'addr': '', 'cfg': {}, 'ipv6addrs': [], 'mtu': '1500', 'netmask': '', 'stp': 'off', 'ipv6gateway': '::', 'gateway': '', 'ports': []}}, 'uuid': '44454C4C-3100-104D-8046-B9C04F583153_00:1e:c9:b6:d8:83', 'lastClientIface': 'lo', 'nics': {'eth2': {'netmask': '', 'addr': '', 'hwaddr': '00:1e:c9:b6:d8:85', 'cfg': {'DEVICE': 'eth2', 'NM_CONTROLLED': 'no', 'BOOTPROTO': 'none', 'ONBOOT': 'yes'}, 'ipv6addrs': ['fe80::21e:c9ff:feb6:d885/64'], 'speed': 1000, 'mtu': '1500'}, 'eth1': {'netmask': '255.255.255.0', 'addr': '172.16.0.11', 'hwaddr': '00:1e:c9:b6:d8:83', 'cfg': {'IPADDR': '172.16.0.11', 'GATEWAY': '172.16.0.1', 'NM_CONTROLLED': 'no', 'PREFIX': '24', 'BOOTPROTO': 'none', 'DEVICE': 'eth1', 'TYPE': 'Ethernet', 'ONBOOT': 'yes'}, 'ipv6addrs': ['fe80::21e:c9ff:feb6:d883/64'], 'speed': 1000, 'mtu': '1500'}, 'eth0': {'netmask': '255.255.252.0', 'addr': '192.168.100.1', 'hwaddr': '00:e0:4c:80:13:02', 'cfg': {'IPADDR': '192.168.100.1', 'GATEWAY': '192.168.103.254', 'NM_CONTROLLED': 'no', 'PREFIX': '22', 'BOOTPROTO': 'none', 'DEVICE': 'eth0', 'TYPE': 'Ethernet', 'ONBOOT': 'yes'}, 'ipv6addrs': [], 'speed': 0, 'mtu': '1500'}}, 'software_revision': '0', 'clusterLevels': ['3.0', '3.1', '3.2', '3.3', '3.4'], 'cpuFlags': u'fpu,vme,de,pse,tsc,msr,pae,mce,cx8,apic,sep,mtrr,pge,mca,cmov,pat,pse36,clflush,dts,acpi,mmx,fxsr,sse,sse2,ss,ht,tm,pbe,syscall,nx,lm,constant_tsc,arch_perfmon,pebs,bts,rep_good,aperfmperf,pni,dtes64,monitor,ds_cpl,vmx,tm2,ssse3,cx16,xtpr,pdcm,dca,lahf_lm,dts,tpr_shadow,vnmi,flexpriority,model_Conroe,model_coreduo,model_core2duo,model_n270', 'ISCSIInitiatorName': 'iqn.1994-05.com.redhat:7c4cc8397e42', 'netConfigDirty': 'False', 'supportedENGINEs': ['3.0', '3.1', '3.2', '3.3', '3.4'], 'reservedMem': '321', 'bondings': {'bond4': {'netmask': '', 'addr': '', 'slaves': [], 'hwaddr': '00:00:00:00:00:00', 'cfg': {}, 'ipv6addrs': [], 'mtu': '1500'}, 'bond0': {'netmask': '', 'addr': '', 'slaves': [], 'hwaddr': '00:00:00:00:00:00', 'cfg': {}, 'ipv6addrs': [], 'mtu': '1500'}, 'bond1': {'netmask': '', 'addr': '', 'slaves': [], 'hwaddr': '00:00:00:00:00:00', 'cfg': {}, 'ipv6addrs': [], 'mtu': '1500'}, 'bond2': {'netmask': '', 'addr': '', 'slaves': [], 'hwaddr': '00:00:00:00:00:00', 'cfg': {}, 'ipv6addrs': [], 'mtu': '1500'}, 'bond3': {'netmask': '', 'addr': '', 'slaves': [], 'hwaddr': '00:00:00:00:00:00', 'cfg': {}, 'ipv6addrs': [], 'mtu': '1500'}}, 'software_version': '4.14', 'memSize': '32105', 'cpuSpeed': '1861.991', 'version_name': 'Snow Man', 'vlans': {'eth1.1': {'netmask': '255.255.255.255', 'iface': 'eth1', 'addr': '172.16.1.5', 'cfg': {'VLAN': 'yes', 'IPADDR': '172.16.1.11', 'NM_CONTROLLED': 'no', 'PREFIX': '24', 'BOOTPROTO': 'none', 'DEVICE': 'eth1.1', 'TYPE': 'Ethernet', 'ONBOOT': 'yes'}, 'ipv6addrs': ['fe80::21e:c9ff:feb6:d883/64'], 'vlanid': 1, 'mtu': '1500'}}, 'cpuCores': '8', 'kvmEnabled': 'true', 'guestOverhead': '65', 'management_ip': '0.0.0.0', 'cpuThreads': '8', 'emulatedMachines': [u'rhel6.5.0', u'pc', u'rhel6.4.0', u'rhel6.3.0', u'rhel6.2.0', u'rhel6.1.0', u'rhel6.0.0', u'rhel5.5.0', u'rhel5.4.4', u'rhel5.4.0'], 'rngSources': ['random'], 'operatingSystem': {'release': '5.el6.centos.11.2', 'version': '6', 'name': 'RHEL'}, 'lastClient': '127.0.0.1'}}
Thread-16::DEBUG::2014-04-05 22:46:02,507::BindingXMLRPC::1067::vds::(wrapper) client [127.0.0.1]::call addNetwork with ('ovirtmgmt', '', '', ['eth1'], {'force': 'False', 'ipaddr': '172.16.0.11', 'ONBOOT': 'yes', 'netmask': '255.255.255.0', 'bootproto': 'none', 'bridged': 'True', 'gateway': '172.16.0.1'}) {}
Thread-16::ERROR::2014-04-05 22:46:03,072::BindingXMLRPC::1086::vds::(wrapper) unexpected error
Traceback (most recent call last):
  File "/usr/share/vdsm/BindingXMLRPC.py", line 1070, in wrapper
    res = f(*args, **kwargs)
  File "/usr/share/vdsm/BindingXMLRPC.py", line 480, in addNetwork
    return api.addNetwork(bridge, vlan, bond, nics, options)
  File "/usr/share/vdsm/API.py", line 1326, in addNetwork
    supervdsm.getProxy().addNetwork(bridge, options)
  File "/usr/share/vdsm/supervdsm.py", line 50, in __call__
    return callMethod()
  File "/usr/share/vdsm/supervdsm.py", line 48, in <lambda>
    **kwargs)
  File "<string>", line 2, in addNetwork
  File "/usr/lib64/python2.6/multiprocessing/managers.py", line 740, in _callmethod
    raise convert_to_error(kind, result)
TypeError: 'NoneType' object is not iterable
Thread-17::DEBUG::2014-04-05 23:04:47,840::BindingXMLRPC::1067::vds::(wrapper) client [127.0.0.1]::call addNetwork with ('ovirtmgmt', '', '', ['eth1'], {'force': 'False', 'ipaddr': '172.16.0.11', 'ONBOOT': 'yes', 'netmask': '255.255.255.0', 'bootproto': 'none', 'bridged': 'True', 'gateway': '172.16.0.1'}) {}
Thread-17::ERROR::2014-04-05 23:04:48,335::BindingXMLRPC::1086::vds::(wrapper) unexpected error
Traceback (most recent call last):
  File "/usr/share/vdsm/BindingXMLRPC.py", line 1070, in wrapper
    res = f(*args, **kwargs)
  File "/usr/share/vdsm/BindingXMLRPC.py", line 480, in addNetwork
    return api.addNetwork(bridge, vlan, bond, nics, options)
  File "/usr/share/vdsm/API.py", line 1326, in addNetwork
    supervdsm.getProxy().addNetwork(bridge, options)
  File "/usr/share/vdsm/supervdsm.py", line 50, in __call__
    return callMethod()
  File "/usr/share/vdsm/supervdsm.py", line 48, in <lambda>
    **kwargs)
  File "<string>", line 2, in addNetwork
  File "/usr/lib64/python2.6/multiprocessing/managers.py", line 740, in _callmethod
    raise convert_to_error(kind, result)
TypeError: 'NoneType' object is not iterable
Thread-18::DEBUG::2014-04-05 23:06:15,531::BindingXMLRPC::1067::vds::(wrapper) client [127.0.0.1]::call addNetwork with ('ovirtmgmt', '', '', ['eth1'], {'force': 'False', 'ipaddr': '172.16.0.11', 'ONBOOT': 'yes', 'netmask': '255.255.255.0', 'bootproto': 'none', 'bridged': 'True', 'gateway': '172.16.0.1'}) {}
Thread-18::DEBUG::2014-04-05 23:06:18,185::BindingXMLRPC::1074::vds::(wrapper) return addNetwork with {'status': {'message': 'Done', 'code': 0}}

Version-Release number of selected component (if applicable):
3.4 GA

How reproducible:
Always

Steps to Reproduce:
1. Configure ifcfg-ethx to use prefix= rather than netmask
2. Run hosted-engine-setup
3. Fails..

Actual results:
Se above.

Expected results:
Should succeed.

Additional info:

Comment 1 Dan Kenigsberg 2014-04-06 21:49:26 UTC
Would you please attach the relevant bits of supervdsm.log?

Comment 2 Andrew Lau 2014-04-10 00:46:12 UTC
Sorry I already destroyed the host and don't have those logs anymore - perhaps I should make a habit to backup log directories..

It is always reproducible, it happened about 5+ occasions. If I have time I'll try reproduce again to get the log output for you.

Comment 3 Dan Kenigsberg 2014-05-01 09:02:23 UTC
Yes, attaching vdsm.log and supervdsm.log when you see " File "/usr/share/vdsm/supervdsm.py" in a traceback would be a good practice.

prefix=24 works just with vdsm from current master branch (commit 47f8e6e1). Please reopen when you have more information.