Bug 974231

Summary: Wicked: ifcfg-macvlan parsing error
Product: [openSUSE] openSUSE Distribution Reporter: Forgotten User YFnd8qeZ4V <forgotten_YFnd8qeZ4V>
Component: NetworkAssignee: wicked maintainers <wicked-maintainers>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: forgotten_YFnd8qeZ4V, mt, pwieczorkiewicz
Version: Leap 42.1Flags: pwieczorkiewicz: needinfo? (forgotten_YFnd8qeZ4V)
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: journal dump which shows that macvlan device app1 starts and macvlan device host refused to start. Both have the same configuration file

Description Forgotten User YFnd8qeZ4V 2016-04-06 09:42:19 UTC
If I add MACVLAN_MODE='passthru' into my ifcfg-macvlan 

ip -d link show mydevice

52: mydevice@lan2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN mode DEFAULT group default 
    link/ether 4a:d6:eb:ca:b5:44 brd ff:ff:ff:ff:ff:ff promiscuity 0 
    macvlan  mode bridge addrgenmode eui64 

shows "bridge" mode.
Comment 1 Marius Tomaschewski 2016-04-06 12:50:23 UTC
The passthru/bridge settings are switched in wicked and MACVLAN_MODE='bridge'
will set 'passthru'...
Comment 2 Pawel Wieczorkiewicz 2016-04-06 14:07:44 UTC
Solution to this problem has been merged upstream:
https://github.com/openSUSE/wicked/pull/635

In the OBS network:wicked:master/wicked repository new RPMs will be shortly (in approx. 1h) built and published. When that happens please download them from [1], install and check whether the problem is fixed.
Thanks.

[1] http://download.opensuse.org/repositories/network:/wicked:/master/openSUSE_Leap_42.1/
Comment 3 Forgotten User YFnd8qeZ4V 2016-04-15 09:08:36 UTC
(In reply to Pawel Wieczorkiewicz from comment #2)
> Solution to this problem has been merged upstream:
> https://github.com/openSUSE/wicked/pull/635
> 
> In the OBS network:wicked:master/wicked repository new RPMs will be shortly
> (in approx. 1h) built and published. When that happens please download them
> from [1], install and check whether the problem is fixed.
> Thanks.
> 
> [1]
> http://download.opensuse.org/repositories/network:/wicked:/master/
> openSUSE_Leap_42.1/

I installed wicked-0.6.30-6.1.x86_64 and all dependendant packages from that repository from April 13th, but with the same result.

ip -d link show app1
5: app1@lan2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN mode DEFAULT group default 
    link/ether 08:00:27:6f:9b:c2 brd ff:ff:ff:ff:ff:ff promiscuity 0 
    macvlan  mode passthru addrgenmode eui64 


cat ifcfg-app1
 
BOOTPROTO='dhcp4'
BROADCAST=''
ETHTOOL_OPTIONS=''
MACVLAN_DEVICE='lan2'
MACVLAN_MODE='bridge'
IPADDR=''
MTU=''
NAME='82540EM Gigabit Ethernet Controller'
NETMASK=''
NETWORK=''
REMOTE_IPADDR=''
STARTMODE='auto'
PREFIXLEN=''


The second device ifcfg-host refuses to start at all.
Comment 4 Forgotten User YFnd8qeZ4V 2016-04-15 09:10:15 UTC
Created attachment 673127 [details]
journal dump which shows that macvlan device app1 starts and macvlan device host refused to start. Both have the same configuration file
Comment 6 Marius Tomaschewski 2016-04-18 09:16:58 UTC
(In reply to Franz Reinhardt from comment #3)
> > [1]
> > http://download.opensuse.org/repositories/network:/wicked:/master/
> > openSUSE_Leap_42.1/
> 
> I installed wicked-0.6.30-6.1.x86_64 and all dependendant packages from that
> repository from April 13th, but with the same result.

Did you installed libwicked-0-6 as well? The fix is the libwicked-0-6
package and the master snapshot build does not enforce libwicked update.

In the meantime, the fix is released -- RPMs are currently in:

http://download.opensuse.org/repositories/network:/wicked:/factory/openSUSE_Leap_42.1/

Please ensure, to install packages (libwicked-0-6 wicked wicked-service)
which contain the fix and have this line in the changelog:

  macvlan: fix enum values for BRIDGE and PASSTHRU modes (boo#974231)

e.g.:

$ rpm -qp --changelog wicked-0.6.32-134.1.x86_64.rpm | head -12 | grep macvlan
- macvlan: fix enum values for BRIDGE and PASSTHRU modes (boo#974231)


It works fine for me:

xanthos:/etc/sysconfig/network # vi ifcfg-macvlan0
xanthos:/etc/sysconfig/network # cp ifcfg-macvlan0 ifcfg-macvlan1
xanthos:/etc/sysconfig/network # cat ifcfg-macvlan0
STARTMODE=auto
BOOTPROTO=static
MACVLAN_DEVICE=nic1
MACVLAN_MODE=bridge
xanthos:/etc/sysconfig/network # ip -d link show macvlan0
Device "macvlan0" does not exist.
xanthos:/etc/sysconfig/network # ip -d link show macvlan1
Device "macvlan1" does not exist.
xanthos:/etc/sysconfig/network # wicked ifup macvlan0 macvlan1
macvlan1        up
macvlan0        up
xanthos:/etc/sysconfig/network # ip -d link show macvlan1
10: macvlan1@nic1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN mode DEFAULT group default 
    link/ether f6:f6:17:69:75:10 brd ff:ff:ff:ff:ff:ff promiscuity 0 
    macvlan  mode bridge addrgenmode eui64 
xanthos:/etc/sysconfig/network # ip -d link show macvlan0
11: macvlan0@nic1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN mode DEFAULT group default 
    link/ether 46:8e:0c:cd:f2:8f brd ff:ff:ff:ff:ff:ff promiscuity 0 
    macvlan  mode bridge addrgenmode eui64 
xanthos:/etc/sysconfig/network # ip -d link show nic1 
3: nic1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP mode DEFAULT group default qlen 1000
    link/ether 68:05:ca:0a:39:e7 brd ff:ff:ff:ff:ff:ff promiscuity 0 addrgenmode eui64 

When it does not work for you, please reopen.
Comment 7 Bernhard Wiedemann 2016-04-18 10:00:52 UTC
This is an autogenerated message for OBS integration:
This bug (974231) was mentioned in
https://build.opensuse.org/request/show/390531 42.1 / wicked
Comment 8 Bernhard Wiedemann 2016-04-18 13:43:16 UTC
This is an autogenerated message for OBS integration:
This bug (974231) was mentioned in
https://build.opensuse.org/request/show/390219 Factory / wicked
Comment 9 Forgotten User YFnd8qeZ4V 2016-04-18 15:51:47 UTC
With 0.6.32 it works! THX
Comment 10 Swamp Workflow Management 2016-12-02 17:08:37 UTC
openSUSE-RU-2016:2978-1: An update that has 19 recommended fixes can now be installed.

Category: recommended (moderate)
Bug References: 865573,902897,913861,916613,916948,972471,973355,974231,975466,981887,982231,982952,984088,985894,988794,988954,989741,997027,998413
CVE References: 
Sources used:
openSUSE Leap 42.1 (src):    wicked-0.6.39-12.1
openSUSE 13.2 (src):    wicked-0.6.39-36.1
Comment 11 Swamp Workflow Management 2016-12-19 13:08:24 UTC
SUSE-RU-2016:3192-1: An update that has 19 recommended fixes can now be installed.

Category: recommended (moderate)
Bug References: 865573,902897,913861,916613,916948,972471,973355,974231,975466,981887,982231,982952,984088,985894,988794,988954,989741,997027,998413
CVE References: 
Sources used:
SUSE Linux Enterprise Server 12-SP1 (src):    wicked-0.6.39-28.3.1
SUSE Linux Enterprise Desktop 12-SP1 (src):    wicked-0.6.39-28.3.1