Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[SOLVED] NetworkManager issues

Linux Kernel, Network, and Services configuration.
Message
Author
Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

[SOLVED] NetworkManager issues

#1 Post by Mike »

I'll start by saying that this isn't really something that needs to be solved. Its more that I'm interested in any feedback of where it may have been going wrong.

Yesterday I was having some issues with NetworkManager in Gnome 3.30. What was happening is that if I used to NetworkManager to configure the connection I was getting errors like the example below. Even though it is stating the the ssid was not found it is correct. So as an attempt to eliminate testing as a problem, I quickly installed stable into a separate partition (separate /boot, same /home) which resulted in the same issue. In both cases the firmware was installed.

Code: Select all

Oct  6 14:52:49 debian NetworkManager[571]: <info>  [1538862769.1114] device (wlx60a44cec22f5): supplicant interface state: authenticating -> disconnected
Oct  6 14:52:49 debian NetworkManager[571]: <info>  [1538862769.6119] device (wlx60a44cec22f5): supplicant interface state: disconnected -> scanning
Oct  6 14:52:52 debian NetworkManager[571]: <warn>  [1538862772.4955] device (wlx60a44cec22f5): Activation: (wifi) association took too long, failing activation
Oct  6 14:52:52 debian NetworkManager[571]: <info>  [1538862772.4955] device (wlx60a44cec22f5): state change: config -> failed (reason 'ssid-not-found') [50 120 53]
Oct  6 14:52:52 debian NetworkManager[571]: <warn>  [1538862772.4959] device (wlx60a44cec22f5): Activation: failed for connection 'TELUS2084-5G'
Oct  6 14:52:52 debian NetworkManager[571]: <info>  [1538862772.5278] device (wlx60a44cec22f5): supplicant interface state: scanning -> disconnected
Oct  6 14:52:52 debian NetworkManager[571]: <info>  [1538862772.5368] device (wlx60a44cec22f5): state change: failed -> disconnected (reason 'none') [120 30 0]
Oct  6 14:52:52 debian kernel: [   84.044513] IPv6: ADDRCONF(NETDEV_UP): wlx60a44cec22f5: link is not ready
Where is gets odd is that if I configure the interface manually in /etc/interfaces everything works beautify. So I have removed NetworkManager since I don't need it anymore and I think it will stay that way now since my unmanaged connection seems to be working just fine. I would however be interested if anyone else has run into this issue. I would be interested in why NetworkManager seemed to be misbehaving.

I have since configured stable with a similar setup to what I was using in Testing + firefox from Sid. I would appear that for my use I don't really need to be running testing and getting piles of updates. I may just stay on stretch now and enjoy the calmer update frequency. Coming back to debian from Fedora I went to testing initially but Stable + some selected backports seems to be working just fine for now. That and I don't really want to mess with something thats working right now. :)
Last edited by Mike on 2018-10-08 23:47, edited 1 time in total.

User avatar
bw123
Posts: 4015
Joined: 2011-05-09 06:02
Has thanked: 1 time
Been thanked: 28 times

Re: NetworkManager issues

#2 Post by bw123 »

There are some really strange issues with networkmanager. I decided to use it on my netbook awhile back and did some research. The issues are pretty well covered on it's bug page, https://bugs.debian.org/network-manager

From what I have read, some people believe these issues are driver related, affecting different devices in different ways. Others say wpasupplicant is the cause. Then there are those that blam the persistent naming features introduced with systemd/udev. Many users find relief by disabling or tweaking the random MAC features in networkmanager.

It's your call, I think it would be great if it got pinned down and improved. I have it very working very reliable on my old b43 wifi but it took a lot of tweaking and config trial and error. If you have the time, dig deeper and file a bug report with what you find out? Might help someone someday...
resigned by AI ChatGPT

Bulkley
Posts: 6383
Joined: 2006-02-11 18:35
Has thanked: 2 times
Been thanked: 39 times

Re: NetworkManager issues

#3 Post by Bulkley »

NetworkManager is just a GUI; wpa-supplicant does the work. If you have a desktop that stays in one place and only uses one connection then a /etc/network/interfaces setup is all you need as you found out. Users seem to like NetworkManager for laptops that move around a lot. Frankly NetworkManager is finicky. Some users like Wicd; I prefer wpagui for a mobile machine.

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: NetworkManager issues

#4 Post by Mike »

bw123 wrote:There are some really strange issues with networkmanager. I decided to use it on my netbook awhile back and did some research. The issues are pretty well covered on it's bug page, https://bugs.debian.org/network-manager
Thanks for the link, I'll have a browse through those. I'm sure I'll get back to investigating this but for the time being I'm going to take a bit of a break from digging around wireless configurations and doing the trial and error thing. If I do find anything that points to a cause I'll definitely be reporting a bug, or adding to an existing on depending on if I find one thats an exact match.

I may try and borrow another wireless adapter from someone that is not Asus/Realtek based. Switching to a different driver may at least eliminate it being related to a particular driver.

However tonight is Thanksgiving dinner for me. :)

L_V
Posts: 1477
Joined: 2007-03-19 09:04
Been thanked: 11 times

Re: NetworkManager issues

#5 Post by L_V »

You should take care at the date of each bug...
First one: 2007: network-manager doesn't ignore aliased interfaces in /e/n/i

I wonder if some troubles are not caused by mixing differrent network system configurations.
Starting by having a look on these status might help:

Code: Select all

systemctl status {systemd-networkd,systemd-resolved,networking,NetworkManager,systemd-hostnamed,openvpn} |egrep -v 'man:|http'
@Mike
You have disabled NetworkManager.
Could you try to totally purge it and reinstall it ?

+ don't mix Stretch + Testing + SID for this kind of tests...... Only pure Stretch to see.

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: NetworkManager issues

#6 Post by Mike »

I think I am liking the system without NetworkManager, it is looking like its probably more trouble than its worth for a system that is always connecting to the same network. However since it would be good to know what the cause is here are the results of another attempt. :) Worth noting is that NetworkManager was working in Fedora before I moved back to debian so I don't think its any issue with the adapter itself.
L_V wrote: I wonder if some troubles are not caused by mixing differrent network system configurations.
Starting by having a look on these status might help:

Code: Select all

systemctl status {systemd-networkd,systemd-resolved,networking,NetworkManager,systemd-hostnamed,openvpn} |egrep -v 'man:|http'
Here is the result of that query.

Code: Select all

● systemd-networkd.service - Network Service
   Loaded: loaded (/lib/systemd/system/systemd-networkd.service; disabled; vendor preset: enabled)
   Active: inactive (dead)

● systemd-resolved.service - Network Name Resolution
   Loaded: loaded (/lib/systemd/system/systemd-resolved.service; disabled; vendor preset: enabled)
  Drop-In: /lib/systemd/system/systemd-resolved.service.d
           └─resolvconf.conf
   Active: inactive (dead)

● networking.service - Raise network interfaces
   Loaded: loaded (/lib/systemd/system/networking.service; enabled; vendor preset: enabled)
   Active: active (exited) since Mon 2018-10-08 14:50:29 PDT; 5min ago
  Process: 577 ExecStart=/sbin/ifup -a --read-environment (code=exited, status=0/SUCCESS)
  Process: 574 ExecStartPre=/bin/sh -c [ "$CONFIGURE_INTERFACES" != "no" ] && [ -n "$(ifquery --read-environment --list --exclude=lo)" ] && udevadm settle (code=exited, status=1/FAILURE)
 Main PID: 577 (code=exited, status=0/SUCCESS)

● NetworkManager.service - Network Manager
   Loaded: loaded (/lib/systemd/system/NetworkManager.service; enabled; vendor preset: enabled)
   Active: active (running) since Mon 2018-10-08 14:50:31 PDT; 5min ago
 Main PID: 601 (NetworkManager)
    Tasks: 3 (limit: 4915)
   CGroup: /system.slice/NetworkManager.service
           └─601 /usr/sbin/NetworkManager --no-daemon

● systemd-hostnamed.service - Hostname Service
   Loaded: loaded (/lib/systemd/system/systemd-hostnamed.service; static; vendor preset: enabled)
   Active: inactive (dead)
L_V wrote: @Mike
You have disabled NetworkManager.
Could you try to totally purge it and reinstall it ?
Did this yesterday with no luck, and just tried it again. The result is the same errors.
L_V wrote: + don't mix Stretch + Testing + SID for this kind of tests...... Only pure Stretch to see.
Its not quite pure stretch any more. There are a couple of backports installed (virtualbox, libreoffice) this shouldn't affect Network manager. I did try this before adding the backports yesterday and it was the same problem then too.

L_V
Posts: 1477
Joined: 2007-03-19 09:04
Been thanked: 11 times

Re: NetworkManager issues

#7 Post by L_V »

networking.service should not be active with NetworkManager.
Can you try to disable it ?

Code: Select all

# systemctl disable --now networking.service
# systemctl restart NetworkManager.service

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: NetworkManager issues

#8 Post by Mike »

L_V wrote:networking.service should not be active with NetworkManager.
Can you try to disable it ?

Code: Select all

# systemctl disable --now networking.service
# systemctl restart NetworkManager.service
Same issue with networking.service disabled.

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: NetworkManager issues

#9 Post by Mike »

This is a bit interesting since I am using an ASUS USB-N53 dongle.

https://bugs.debian.org/cgi-bin/bugrepo ... =842422#10

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: NetworkManager issues

#10 Post by Mike »

Disabled predictable naming by masking udevs link file. Now Network-Manager works.

Code: Select all

ln -s /dev/null /etc/systemd/network/99-default.link

L_V
Posts: 1477
Joined: 2007-03-19 09:04
Been thanked: 11 times

Re: [SOLVED] NetworkManager issues

#11 Post by L_V »

Sorry but I don't think you can call this a "solution", but more a really weird unclear workaround.

"/etc/systemd/network/99-default.link" should not exist.
The systemd’s predictable network names are defined by /lib/systemd/network/99-default.link

Code: Select all

[Link]
NamePolicy=kernel database onboard slot path
MACAddressPolicy=persistent
I would have investigated differently by digging into the udev rules.
Then keep in mind that you can have new surprises later on.

Just to see:

Code: Select all

lsmod |grep ^rt
nmcli d
apt-cache policy network-manager | head -n2
cat /etc/NetworkManager/NetworkManager.conf
lsinitramfs /boot/initrd.img-$(uname -r) | grep net

User avatar
bw123
Posts: 4015
Joined: 2011-05-09 06:02
Has thanked: 1 time
Been thanked: 28 times

Re: [SOLVED] NetworkManager issues

#12 Post by bw123 »

All of the solutions I have seen for this type of nm problem are very weird unclear workarounds. I'm hopeful that people will find out why it is so inconsistent with different hardware and fix it eventually, or replace it with a better tool.
resigned by AI ChatGPT

L_V
Posts: 1477
Joined: 2007-03-19 09:04
Been thanked: 11 times

Re: [SOLVED] NetworkManager issues

#13 Post by L_V »

I cannot believe one second that creating a null link on a file unused by Stretch can be a solution or even a workaround.
The problem is not NetworkManager, but udev, /lib/systemd/network/99-default.link being provided by udev.

Default network name can be defined on different criteria, and the history of the system over the time, through system updates in /usr/lib/udev/rules.d/ can be the problem for an old network USB device.
I don"t think Mike has a clean Stretch.
I see at least 4 solutions or workarounds, but not creating a null link not used by Stretch.
Then if Mike is happy with this weird let's say "solution", all is fine....

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: [SOLVED] NetworkManager issues

#14 Post by Mike »

L_V wrote:I cannot believe one second that creating a null link on a file unused by Stretch can be a solution or even a workaround.
The problem is not NetworkManager, but udev, /lib/systemd/network/99-default.link being provided by udev.

Default network name can be defined on different criteria, and the history of the system over the time, through system updates in /usr/lib/udev/rules.d/ can be the problem for an old network USB device.
I don"t think Mike has a clean Stretch.
I see at least 4 solutions or workarounds, but not creating a null link not used by Stretch.
Then if Mike is happy with this weird let's say "solution", all is fine....
The system really doesn't have much history over time.... this installation is only a day old, and it is only using stretch repos and a couple of packages installed from stretch backports. So in terms of debian installs its actually what I would consider very clean install of stretch. There are actually very little in the way of applications installed at this point.

All the link does is masks Predictable Network Interface Names as documented here. https://www.freedesktop.org/wiki/Softwa ... faceNames/ and here https://wiki.archlinux.org/index.php/Ne ... face_names

The result is with Predictable interface names enabled = borkage, and disabled it works. This may be specific to the rt2800 driver. You can toggle the borkage just by add / removing the link.

Just out of curiosity even though the system is pretty clean now, I'll install a minimal stretch with no backports to confirm. I have loads of drive space so its not that big of a job to have another installation.

User avatar
bw123
Posts: 4015
Joined: 2011-05-09 06:02
Has thanked: 1 time
Been thanked: 28 times

Re: [SOLVED] NetworkManager issues

#15 Post by bw123 »

Mike wrote:
L_V wrote:I cannot believe one second that creating a null link on a file unused by Stretch can be a solution or even a workaround.
The problem is not NetworkManager, but udev, /lib/systemd/network/99-default.link being provided by udev.
<snip>
Just out of curiosity even though the system is pretty clean now, I'll install a minimal stretch with no backports to confirm. I have loads of drive space so its not that big of a job to have another installation.
Thanks Mike, I found the same thing to be true when using several older devices, ralink, realtek, also the b43.
Disabling predictable names either thru the null link for 99-default.link or net.ifnames=0 kernel parameter, fixes the issue.

Turning off MAC randomization while scanning also fixes my issues, BTW> the two things seem related.
resigned by AI ChatGPT

User avatar
bw123
Posts: 4015
Joined: 2011-05-09 06:02
Has thanked: 1 time
Been thanked: 28 times

Re: [SOLVED] NetworkManager issues

#16 Post by bw123 »

Mike wrote:
L_V wrote:I cannot believe one second that creating a null link on a file unused by Stretch can be a solution or even a workaround.
The problem is not NetworkManager, but udev, /lib/systemd/network/99-default.link being provided by udev.
<snip>
Just out of curiosity even though the system is pretty clean now, I'll install a minimal stretch with no backports to confirm. I have loads of drive space so its not that big of a job to have another installation.
Thanks Mike, I found the same thing to be true when using several older devices, ralink, realtek, also the b43.
Disabling predictable names either thru the null link for 99-default.link or net.ifnames=0 kernel parameter, fixes the issue.

Turning off (or tweaking the mask) in MAC randomization while scanning also fixes my issues, BTW> the two things seem related.
https://blogs.gnome.org/thaller/2016/08 ... ger-1-4-0/

EDIT: sorry for the double post, just ignore the noise, ty.
Last edited by bw123 on 2018-10-09 20:53, edited 1 time in total.
resigned by AI ChatGPT

L_V
Posts: 1477
Joined: 2007-03-19 09:04
Been thanked: 11 times

Re: [SOLVED] NetworkManager issues

#17 Post by L_V »

@Mike
Debian is not Archi, Freedesktop gives general guidelines, Debian is Debian, and Jessie is not Stretch, and you can check that you will never find any /etc/systemd/network/99-default.link in Stretch.
Try this:

Code: Select all

dpkg -L udev | grep 99-default.link
You could have provided what I was requiring for investigation (see the commands form my previous post).
There is no logic at all with what you have done, but other identified solutions have some logic behind.
Well I can live with this absolute mystery, don't worry.

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: [SOLVED] NetworkManager issues

#18 Post by Mike »

Reproduced with absolutely pure stretch. With predicable names enabled Network-Manager fails to connect with them disabled it works fine. This is with an installation with only the base gnome installed, and no updates or anything else installed yet.

It also makes no difference how you disable predicatable nameing, using the udev link or ifnames=0 both produce the same result.

Mike
Posts: 57
Joined: 2005-11-16 19:12
Location: Sunshine Coast, BC

Re: [SOLVED] NetworkManager issues

#19 Post by Mike »

L_V wrote:@Mike
Debian is not Archi, Freedesktop gives general guidelines, Debian is Debian, and Jessie is not Stretch, and you can check that you will never find any /etc/systemd/network/99-default.link in Stretch.
Try this:

Code: Select all

dpkg -L udev | grep 99-default.link
You could have provided what I was requiring for investigation (see the commands form my previous post).
There is no logic at all with what you have done, but other identified solutions have some logic behind.
Well I can live with this absolute mystery, don't worry.

Code: Select all

/lib/systemd/network/99-default.link
What does jessie have to do with anything. Its not installed. The behavior is happening in absolutely pure stretch.

L_V
Posts: 1477
Joined: 2007-03-19 09:04
Been thanked: 11 times

Re: [SOLVED] NetworkManager issues

#20 Post by L_V »

Mike wrote:

Code: Select all

/lib/systemd/network/99-default.link
What does Jessie have to do with anything. Its not installed.
Exactly what I said !!
Jessie bug you reported refers to /etc/systemd/network/99-default.link (or Archi & Freedesktop)
How can you explain what you have done in Stretch ?? (and not Jessie or Archi)

Code: Select all

ln -s /dev/null /etc/systemd/network/99-default.link
Stretch does not care of what you have done: this is what I wanted to clarify.
The fact it works now can be a coincidence with networking.service disabling, and/or plug/unplug your usb device, or rebooting.
/etc/systemd/network/99-default.link is not same as /lib/systemd/network/99-default.link : not the same path !!
The commands I was requiring were to clarify.
Yes your problem is related with network naming, but your mix of Jessie+Archi+Freedestktop has nothing to do with Stretch.
I understand the most important for you is that "it works", even with something crazy with no logic at all.

Post Reply