Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 399193 - net-misc/networkmanager-0.9.2.0-r2: init script needs net.lo
Summary: net-misc/networkmanager-0.9.2.0-r2: init script needs net.lo
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-17 16:37 UTC by Dennis Schridde
Modified: 2013-06-16 18:51 UTC (History)
1 user (show)

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 Dennis Schridde 2012-01-17 16:37:50 UTC
After switching from OpenRC newnet (init.d/network) to the new oldnet (init.d/net) I had a weird problem where networkmanager would try to connect to my wifi, but fail without meaningful error when retrieving the IP configuration via DHCP. I was able to solve this by including the net.lo service in the boot runlevel.

Hence I propose to add "need net.lo" to /etc/init.d/NetworkManager.

Reproducible: Always
Comment 1 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-02-02 00:39:20 UTC
This is very odd; networkmanager-0.9.x automatically calls "/etc/init.d/net.lo start" if it detects an openrc-based system and net.lo is not started.

See openrc_start_lo_if_necessary() in http://cgit.freedesktop.org/NetworkManager/NetworkManager/tree/src/backends/NetworkManagerGentoo.c

Are you using systemd? (if networkmanager detects that systemd is running, it will not attempt to start net.lo).

Are you using dhcpcd? If so, this may be bug #345365 in another form, which should be (hopefully) fixed in networkmanager-0.9.2.0-r3. 

If you are not using systemd and networkmanager-0.9.2.0-r3 does not help, please try to get a meaningful log of the failure; in /etc/NetworkManager/nm-system-settings-conf, you should set

[logging]
level=DEBUG
domains=CORE,SETTINGS,DHCP4,DHCP6

(perhaps add some more logging domains if needed) and attach the output of grep NetworkManager /var/log/messages
Comment 2 Dennis Schridde 2012-02-02 09:13:09 UTC
(In reply to comment #1)
> This is very odd; networkmanager-0.9.x automatically calls "/etc/init.d/net.lo
> start" if it detects an openrc-based system and net.lo is not started.
net.lo was being started by NM, but apparently there was a race condition, or whatever net.lo sets up was required before it was started. (Afaik it also sets the hostname? Maybe someone needed that?)

> Are you using systemd? (if networkmanager detects that systemd is running, it
> will not attempt to start net.lo).
No, I am using sysvinit-2.88-rLatest.

> Are you using dhcpcd? If so, this may be bug #345365 in another form, which
> should be (hopefully) fixed in networkmanager-0.9.2.0-r3. 
Yes, I am using that. Interestingly one "fix" is to start net.lo in the boot runlevel, instead of letting NM start it.

Will try -r3, though.
Comment 3 Dennis Schridde 2012-02-02 13:17:49 UTC
(In reply to comment #1)
> This is very odd; networkmanager-0.9.x automatically calls "/etc/init.d/net.lo
> start" if it detects an openrc-based system and net.lo is not started.
I just asked on IRC and it appears net.lo is in the boot runlevel by default. Is there any reason to assume it is not and start it manually within NM? (Since the FDO Git webinterface is down atm I wasn't able to look at sourcecode comments.)
Comment 4 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-02-03 15:45:01 UTC
(In reply to comment #3)
> I just asked on IRC and it appears net.lo is in the boot runlevel by default.
> Is there any reason to assume it is not and start it manually within NM?

Defensive programming.
Comment 5 Pavel Šimerda 2012-11-04 15:16:36 UTC
Note that in current NetworkManager master, the loopback code is unified and
distribution-specific variants are removed.

commit 3efc2c4b9dda1aeab88f2f09110871cd38c6ed28
Author: Pavel Šimerda <psimerda@redhat.com>
Date:   Wed Aug 1 21:10:15 2012 +0200

    distro: remove nm_backend_enable_loopback()
    
    We don't need to use distribution-specific network scripts to just bring
    up the loopback interface.
    
    I'm not aware of any init dependency problems but even if there are some,
    it is more practical to solve them in the respective configuration files.
    
    This function also tried to add 127.0.0.1 to the list of addresses but
    not ::1. We don't need to set the interfaces up as this is done by the
    kernel.

http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=3efc2c4b9dda1aeab88f2f09110871cd38c6ed28
Comment 6 Pacho Ramos gentoo-dev 2013-06-16 11:55:26 UTC
Please retry with 0.9.8.2
Comment 7 Dennis Schridde 2013-06-16 18:51:16 UTC
I do not use OpenRC anymore - I switched to systemd. Please decide whether to close this bug as invalid or ask someone else to test.