Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 366905 - sys-apps/openrc-0.8.2-r1: Sensitive to ordering of broadcast & netmask
Summary: sys-apps/openrc-0.8.2-r1: Sensitive to ordering of broadcast & netmask
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: OpenRC (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: OpenRC Team
URL:
Whiteboard: openrc:oldnet
Keywords:
Depends on:
Blocks: 374183
  Show dependency tree
 
Reported: 2011-05-11 17:22 UTC by Tony Vroon (RETIRED)
Modified: 2013-04-25 23:08 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tony Vroon (RETIRED) gentoo-dev 2011-05-11 17:22:55 UTC
The following configuration is fully functional on baselayout-1 (data obfuscated):

modules=( "iproute2" )
config_eth0=(
    "1.2.3.2 broadcast 1.2.3.127 netmask 255.255.255.128"
)
config_eth1=(
    "2.3.4.69 broadcast 2.3.4.127 netmask 255.255.255.192"
)
routes_eth0=(
    "default via 1.2.3.1"
)
routes_eth1=(
    "default via 2.3.4.65"
)

On baselayout-2 with openrc, the following broken english is emitted:
Error: Either "local" is duplicate, or "netmask" is a garbage.

Networking fails to come up until netmask is specified *before* broadcast. This is a baselayout-1 -> baselayout-2 regression; the error message neither helpful nor specific.
Comment 1 Anthony Basile gentoo-dev 2011-05-11 22:54:09 UTC
Whoah!  I was just talking about that on freenode/#gentoo-base.  I'm not sure its a bug (ie to be fixed in the code), but it should definitely be documented because it caught me on a couple of servers.  For people who don't have physical access to their boxes, they're in a world of pain.
Comment 2 David J Cozatt 2011-05-12 22:31:32 UTC
Is it related? I cannot say...I can say if in /etc/rc.conf with openrc and baselayout-2 that 
unless it is first the 1net.eth* will be ignored

# To disable services, prefix with a !
# Example - rc_hotplug="net.wlan !net.*"
# This allows net.wlan and any service not matching net.* to be plugged.
# Example - rc_hotplug="*"
# This allows all services to be hotplugged
#rc_hotplug="*"
rc_hotplug="!net.eth* net.lo net.wlan0"
Comment 3 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2011-05-20 21:46:03 UTC
Some more context for people that stumble onto this one.

12:23 <@Chainsaw> bonsaikitten: http://bugs.gentoo.org/show_bug.cgi?id=366905
12:23 <@Chainsaw> WilliamH: Said bug may interest you as it is a baselayout-2/openrc regression.
12:28 <@WilliamH> Chainsaw: Hmm, that error message is from iproute2... I'll look at it.
12:30 <@Chainsaw> WilliamH: Thank you.
12:31 <@WilliamH> Chainsaw: I think I know at least partly what's going on.
12:33 <@WilliamH> It may have to do with how we are converting the netmask to iproute2 notation.
12:33 <@WilliamH> ifconfig allows
12:33 <@WilliamH> ifconfig x.x.x.x netmask y.y.y.y
12:33 <@WilliamH> but iproute uses
12:34 <@WilliamH> x.x.x.x/y instead.
12:34 <@WilliamH> so I may need to look at the conversion.
Comment 4 William Hubbs gentoo-dev 2011-05-20 22:27:20 UTC
My plan at this point is to stop trying to guess which tool you are using and require you to use the correct syntax for the selected module.

This was discussed on the development list, and there were no objections raised.
Comment 5 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2011-07-18 23:58:36 UTC
Fixed in commit 6fa6f95. Also supports all of the other iproute2 addr options now.