# NetworkManager won't start gives  error -2

## warrenc

I am having trouble getting NetworkManager to start per the following.  Any ideas what causes "Error getting login monitor"

```
T410S warren # NetworkManager --no-daemon

NetworkManager[14826]: <info> NetworkManager (version 0.9.8.10) is starting...

NetworkManager[14826]: <info> Read config file /etc/NetworkManager/NetworkManager.conf

NetworkManager[14826]: <info> WEXT support is enabled

Error getting login monitor: -2

(NetworkManager:14826): GLib-WARNING **: (/var/tmp/portage/dev-libs/glib-2.40.0-r1/work/glib-2.40.0/glib/gerror.c:381):g_error_new_valist: runtime check failed: (domain != 0)

NetworkManager[14826]: <info> Loaded plugin keyfile: (c) 2007 - 2010 Red Hat, Inc.  To report bugs please use the NetworkManager mailing list.

NetworkManager[14826]: <error> [1410010036.401479] [main.c:549] main(): failed to initialize settings storage: Could not load plugin 'ifnet': /usr/lib/NetworkManager/libnm-settings-plugin-ifnet.so: cannot open shared object file: No such file or directory

NetworkManager[14826]: <info> exiting (error)

```

----------

## charles17

What about using DHCPCD instead of NetworkManager?

----------

## warrenc

I actually have NetworkManager compiled with dhcpcd use flag and have dhcpcd installed.  When it runs, NetworkManager manages dhcpcd to configure connections.  It is not set to load at boot, which allows Networkmanager to do its job.

----------

## charles17

What is the benefit oft using troublesome networkmanager along with dhcpcd instead oft just dhcpcd?

----------

## warrenc

I have it running on other machines and like the nm-applet interface in kde.

----------

## charles17

Your error message says some file is missing?  Gould you check in one oft the non-trouble installations to which package it belongs? Then compare that package on both machines.

----------

## warrenc

It turned out to be a problem connecting to dbus.  I had dbus compiled with the systemd profile set but I want to keep an openrc system.  

I set the profile to non-systemd and then recompiled the essential packages.  Now it connects as it should.

----------

## UberLord

 *warrenc wrote:*   

> I have it running on other machines and like the nm-applet interface in kde.

 

dhcpcd-qt port is in progress  :Smile: 

dhcpcd-gtk already works fine. You can find that in the dhcpcd-ui package in portage.

----------

## warrenc

Thanks  I will give that a try.

----------

## vespaman

I think I have something similar now; NetworkManager will not start. But I don't get any real information from it;

```
NetworkManager --no-daemon --log-level=DEBUG

(NetworkManager:23976): GLib-WARNING **: (/var/tmp/portage/dev-libs/glib-2.40.2/work/glib-2.40.2/glib/gerror.c:381):g_error_new_valist: runtime check failed: (domain != 0)
```

I tried to rebuild NetworkManager and I get some information about Systemd, which i have never used/installed on this machine;

```

 * Messages for package net-misc/networkmanager-0.9.10.0-r1:

 * 

 * You seem to use 'ifnet' plugin in /etc/NetworkManager/NetworkManager.conf

 * Since it won't be used when running under Systemd, you will need to stop setting

 * ifnet plugin there to allow NetworkManager to work.

 
```

Looking in var/log/messages, I get this;

```
Oct 28 12:27:07 thinkpad NetworkManager[24352]: <info> NetworkManager (version 0.9.10.0) is starting...

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <info> Read config: /etc/NetworkManager/NetworkManager.conf

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <info> WEXT support is enabled

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.127291] [platform/nm-linux-platform.c:3987] setup(): Netlink socket for requests established: -872390880

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.127319] [platform/nm-linux-platform.c:4004] setup(): Netlink socket for events established: -155164896

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.128621] [platform/nm-platform.c:2565] log_link(): signal: link   added: 3: eth0 <UP,LOWER_UP> mtu 1500 ethernet driver 'e1000e' udi '/sys/devices/pci0000:00/0000:00:19.0/net/eth0'

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.128774] [platform/nm-platform.c:2565] log_link(): signal: link   added: 2: wlan0 <DOWN> mtu 1500 wifi driver 'iwlwifi' udi '/sys/devices/pci0000:00/0000:00:1c.1/0000:03:00.0/net/wlan0'

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.128865] [platform/nm-linux-platform.c:587] ethtool_get(): ethtool: Request failed: Operation not supported

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.128894] [platform/nm-platform.c:2565] log_link(): signal: link   added: 1: lo <UP,LOWER_UP> mtu 65536 loopback driver 'unknown' udi '/sys/devices/virtual/net/lo'

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.128974] [nm-dbus-manager.c:190] private_server_new(): (private) creating private socket unix:path=/run/NetworkManager/private.

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.130497] [nm-dbus-manager.c:190] private_server_new(): (dhcp) creating private socket unix:path=/run/NetworkManager/private-dhcp.

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.130628] [nm-dispatcher.c:733] dispatcher_dir_changed(): dispatcher: default script directory '/etc/NetworkManager/dispatcher.d' has scripts

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.130671] [nm-dispatcher.c:735] dispatcher_dir_changed(): dispatcher: pre-up script directory '/etc/NetworkManager/dispatcher.d/pre-up.d' has no scripts

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <debug> [1414495627.130710] [nm-dispatcher.c:735] dispatcher_dir_changed(): dispatcher: pre-down script directory '/etc/NetworkManager/dispatcher.d/pre-down.d' has no scripts

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <info> Loaded plugin keyfile: (c) 2007 - 2013 Red Hat, Inc.  To report bugs please use the NetworkManager mailing list.

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <error> [1414495627.135049] [main.c:613] main(): failed to initialize settings storage: Could not load plugin 'ifnet': /usr/lib/NetworkManager/libnm-settings-plugin-ifnet.so: cannot open shared object file: No such file or directory

Oct 28 12:27:07 thinkpad NetworkManager[24352]: <info> exiting (error)

Oct 28 12:27:15 thinkpad NetworkManager[24358]: <error> [1414495635.994176] [main.c:613] main(): failed to initialize settings storage: Could not load plugin 'ifnet': /usr/lib/NetworkManager/libnm-settings-plugin-ifnet.so: cannot open shared object file: No such file or directory

```

Since I have never messed with systemd, I don't know what to look for. Useflags has -systemd when trying to reemerge dbus.

----------

## warrenc

Can you bring up the wlan0 interface manually?  I am wondering if there is a iwlwifi driver issue.

----------

## vespaman

Yes, if I start it using the init script, it looks alright - driver seams fine.

----------

## G104cch1n0

I am affected by the same issue, i don't use systemd and my dbus doesn't have systemd flag enables, my profile is default/linux/amd64/13.0/desktop/kde

I have just added -systemd to global useflag, and emerge just says nothing to merge, so it seems no packages are using systemd on my system

----Edit----

Solved editing /etc/NetworkManager/NetworkManager.conf removing ifnet plugin

[main]

#plugins=ifnet,keyfile

plugins=keyfile

----------

## vespaman

 *G104cch1n0 wrote:*   

> 
> 
> Solved editing /etc/NetworkManager/NetworkManager.conf removing ifnet plugin
> 
> [main]
> ...

 

Thanks! That did it for me as well.

----------

