Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] OpenRC 0.5.1 does not start my network correctly
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
mv
Watchman
Watchman


Joined: 20 Apr 2005
Posts: 6749

PostPosted: Tue Oct 20, 2009 9:32 am    Post subject: Reply with quote

I must say that this is not an appropriate solution: Your "solution" is to use oldnet but not the network script. However, the "new style" how it should work is only with the network script. For this, I also sometimes get false paths.

I suppose that it is really a bug in dhcpcd: Sometimes the route is set correctly, but usually not at the first run. Only after stopping and restarting dhcpcd the route is set correctly.
More precisely: If dhcpcd "works" (usually only after the second start) I get the output
Code:
$ route -n               
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
[correct ip]    0.0.0.0         255.255.254.0   U      202    0        0 eth0
127.0.0.0       -               255.0.0.0       !        0    -        0 -
127.0.0.0       127.0.0.1       255.0.0.0       UG       0    0        0 lo
0.0.0.0         [correct gateway]  0.0.0.0      UG     202    0        0 eth0

but if it does not work, the last line is simply missing from the output. dhcpcd must have got its lease, because otherwise the first line could not be there, so it must have simlpy "forgotten" to add the route.

I guess a bug should be reported to Uberlord, but currently I have to many other things to do...
Back to top
View user's profile Send private message
Guinpen
Guru
Guru


Joined: 08 Dec 2004
Posts: 393

PostPosted: Tue Oct 20, 2009 9:39 am    Post subject: Reply with quote

I see. BTW, what is meaning of the second line and why is it there?
Back to top
View user's profile Send private message
Mike Hunt
Watchman
Watchman


Joined: 19 Jul 2009
Posts: 5287

PostPosted: Tue Oct 20, 2009 1:35 pm    Post subject: Reply with quote

Hmmm, I have not had the experience of false paths or the need to restart dhcpcd with openrc-0.5.0
I'm not getting that second line either. What can that be if there is no interface.
Code:
127.0.0.0       -               255.0.0.0       !        0    -        0 -


Code:
# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
[correct ip]    0.0.0.0         255.255.255.0   U     202    0        0 eth0
127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0 lo
0.0.0.0        [correct gateway]0.0.0.0         UG    202    0        0 eth0
Back to top
View user's profile Send private message
sera
Retired Dev
Retired Dev


Joined: 29 Feb 2008
Posts: 1017
Location: CET

PostPosted: Tue Oct 20, 2009 2:25 pm    Post subject: Reply with quote

Godji wrote:
I see. BTW, what is meaning of the second line and why is it there?


This means there is an unreachable route to the loopback interface and it's done in the network script, therefore, Mike Hunt, you wont see it. I asked UberLord why but didn't got an answer so far.

Edit: Here post 6016059
Back to top
View user's profile Send private message
mv
Watchman
Watchman


Joined: 20 Apr 2005
Posts: 6749

PostPosted: Wed Oct 21, 2009 8:35 pm    Post subject: Reply with quote

Finally, I found some time to look in the thing again. The cause for the problem is rather simple: If /etc/init.d/network runs after dhcpcd, it mangles some of the routes which dhcpcd has set. Therefore the non-reproducing effect: It appears not to be defined by dependencies what starts earlier. So I have just put
/etc/conf.d/dhcpcd wrote:
rc_need="network"

and everything is fine now. (Well, everything except for the lack of support for pppd in the new network scripts, but this is another story - unfortunately more serious, for which I still see no reasonable solution except for using oldnet.)
Back to top
View user's profile Send private message
gcasillo
l33t
l33t


Joined: 23 Sep 2003
Posts: 739
Location: Cincinnati, Ohio, USA

PostPosted: Sat Oct 24, 2009 6:27 am    Post subject: Re: [SOLVED] OpenRC 0.5.1 does not start my network correctl Reply with quote

Godji wrote:
4) Add the following to /etc/dhcpcd.conf:
Code:
waitip

Just wanted to say thanks for sharing this tip. Appears to resolve the issue I was having. :)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum