On Tue, Feb 26, 2013 at 03:25:13PM +0400, Yuriy Demchenko wrote:
i've made some additional research on problem #1:
it seems that /usr/share/vdsm/configNetwork.py treats "gateway=null"
value as true, so setting the error flag
in "_addNetworkValidation" method there's a check at line 813:
> if netmask or gateway:
> raise ConfigNetworkError(ne.ERR_BAD_ADDR,
> "Specified netmask or gateway but not ip")
as "ipaddr", sent by engine = "", its check evaluated as false, then
"gateway" evaluated, but it contains value (word "null"), so i
presume evaluated as true and exception is raised.
I believe that this issue is due to code introduced by dreyou.
http://www.dreyou.org/ovirt/vdsm32.patch
diff --git a/vdsm/configNetwork.py b/vdsm/configNetwork.py
index 53debfa..c8a80f1 100755
--- a/vdsm/configNetwork.py
+++ b/vdsm/configNetwork.py
@@ -873,6 +873,11 @@ def addNetwork(network, vlan=None, bonding=None, nics=None,
ipaddr=None,
_netinfo = netinfo.NetInfo()
bridged = utils.tobool(bridged)
+ # Hack here, netmask may be not defined, if this happen,
+ # set netmask to 255.255.255.0
+ if not netmask:
+ netmask = "255.255.255.0"
+
if mtu:
mtu = int(mtu)
I do not know the motivation for it - I hope that Dreyou himself can help.
Dreyou, others - I would very much appreciate it if you send such patches to
upstream
gerrit.ovirt.org. They deserve discussion and hopefully -
incorporation into mainline vdsm.
I've added my notes to
https://bugzilla.redhat.com/show_bug.cgi?id=911957
Yuriy Demchenko
On 02/26/2013 12:37 PM, Yuriy Demchenko wrote:
>Hi,
>
>I'm testing ovirt 3.2 on centos 6.3 (from dreyou repo) and have a
>problems setting up networks:
>1.
>- clean install of ovirt-engine, added a host (6 NICs, only 1
>configured with static ip before adding it to ovirt)
>- set up bonding for ovirtmgmt from 2 NICs - em1+em2
>- set up 2 additional networks ("trunk" with no vlanid, "vlan50"
>with vlanid=50), attached it to cluster
>- trying to set up host networks - assigned "trunk" to one of
>unused NIC, "vlan50" to another, boot protocol in both - "none"
>and when i'm trying to apply changes - i get "Specified netmask or
>gateway but not ip"
>What is wrong? why the hell it thinks i pass some netmask/gw in
>first place? I dont need any ip configuration on this networks,
>i'll be using them only for VM's
>
>2.
>when i'm trying to team NIC's in bonds, i've got choice from only
>3 bonds: "bond0", "bond1", "bond4" - why is that list
is fixed?
>If I've allready defined bond0+bond1 prior adding host to ovirt
>(via kickstart), even if they aren't used - choice list in ovirt
>host networks is short to "bond4" and trying to bond more
>interfaces ends up with "there no bonds available"
Genady has reported this issue to me yesterday :-(.
It is fixed by
http://gerrit.ovirt.org/12447 and deseves a rebuild of vdsm.
Please confirm that my patch solves this issue.