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

 

 

 

Making NetworkManager default

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
d3viant
Posts: 24
Joined: 2017-05-17 23:36

Making NetworkManager default

#1 Post by d3viant »

I installed Debian as a dual boot with Windows 10 last night and immediately had no connection to my wireless card. I had to enable wlan0 manually.

Today, seemingly at random, my internet went "down" and when I checked /etc/NetworkManager/NetworkManager.conf -- my changes had reverted!

Is there a way to make them permanent?
This evening, I added:
[main]
plugins=ifupdown,keyfile

[ifupdown]
managed=true
Was previously 'false,' and still modified the OpenDNS nameservers I used in /etc/resolv/conf - is there anything else I have to do?
Would adding my nameserver entries in /etc/networks suffice?

Or, adding a dns-namservers entry to /etc/network/interfaces? Which is presently:

Code: Select all

auto wlan0
iface wlan0 inet dhcp
        wpa-ssid "my_ssid_broacast"
        wpa-psk "wifi_password"
^ This is what I had to add to get online last night.


I am also experiencing a slow boot-up:
systemd-analyze blame results in:

Code: Select all

         11.443s networking.service
          3.714s ModemManager.service
          2.949s accounts-daemon.service
          2.494s alsa-restore.service
          2.492s pppd-dns.service
          2.480s bluetooth.service
          2.327s systemd-logind.service
          2.250s rsyslog.service
          2.250s rc-local.service
          2.249s systemd-user-sessions.service
          2.236s avahi-daemon.service
          1.722s systemd-fsck@dev-disk-by\x2duuid-C636\x2d32A8.service
          1.537s minissdpd.service
          1.144s keyboard-setup.service
          1.067s systemd-rfkill@rfkill1.service
          1.066s systemd-rfkill@rfkill0.service
           766ms packagekit.service
           764ms systemd-rfkill@rfkill3.service
           656ms systemd-tmpfiles-setup-dev.service
           646ms kbd.service
           570ms systemd-setup-dgram-qlen.service
           569ms dev-hugepages.mount
           532ms sys-kernel-debug.mount
I assume that's indicative of a misconfiguration somewhere, but I'm not sure where to look.

lshw

Code: Select all

debian                    
    description: Computer
    width: 64 bits
    capabilities: smbios-2.8 vsyscall32
  *-core
       description: Motherboard
       physical id: 0
     *-memory
          description: System memory
          physical id: 0
          size: 7752MiB
     *-cpu
          product: Intel(R) Core(TM) i3-6100U CPU @ 2.30GHz
          vendor: Intel Corp.
          physical id: 1
          bus info: cpu@0
          size: 400MHz
          capacity: 2301MHz
          width: 64 bits
          capabilities: fpu fpu_exception wp vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp x86-64 constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch ida arat epb xsaveopt pln pts dtherm tpr_shadow vnmi flexpriority ept vpid fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm mpx rdseed adx smap clflushopt cpufreq
     *-pci
          description: Host bridge
          product: Intel Corporation
          vendor: Intel Corporation
          physical id: 100
          bus info: pci@0000:00:00.0
          version: 08
          width: 32 bits
          clock: 33MHz
        *-display UNCLAIMED
             description: VGA compatible controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 2
             bus info: pci@0000:00:02.0
             version: 07
             width: 64 bits
             clock: 33MHz
             capabilities: pciexpress msi pm vga_controller bus_master cap_list
             configuration: latency=0
             resources: memory:a1000000-a1ffffff memory:90000000-9fffffff ioport:6000(size=64)
        *-usb
             description: USB controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 14
             bus info: pci@0000:00:14.0
             version: 21
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi xhci bus_master cap_list
             configuration: driver=xhci_hcd latency=0
             resources: irq:139 memory:a3300000-a330ffff
           *-usbhost:0
                product: xHCI Host Controller
                vendor: Linux 3.16.0-4-amd64 xhci_hcd
                physical id: 0
                bus info: usb@2
                logical name: usb2
                version: 3.16
                capabilities: usb-3.00
                configuration: driver=hub slots=6 speed=5000Mbit/s
           *-usbhost:1
                product: xHCI Host Controller
                vendor: Linux 3.16.0-4-amd64 xhci_hcd
                physical id: 1
                bus info: usb@1
                logical name: usb1
                version: 3.16
                capabilities: usb-2.00
                configuration: driver=hub slots=12 speed=480Mbit/s
              *-usb:0
                   description: Wireless interface
                   product: 802.11n NIC
                   vendor: Realtek
                   physical id: 2
                   bus info: usb@1:2
                   logical name: wlan1
                   version: 0.00
                   serial: E0B2F1A9666E
                   capabilities: usb-2.00 ethernet physical wireless
                   configuration: broadcast=yes driver=r8188eu ip=192.168.0.22 maxpower=500mA multicast=yes speed=480Mbit/s wireless=IEEE 802.11bgn
              *-usb:1
                   description: USB hub
                   product: USB2.0 Hub
                   vendor: GenesysLogic
                   physical id: 4
                   bus info: usb@1:4
                   version: 4.02
                   capabilities: usb-2.10
                   configuration: driver=hub maxpower=100mA slots=4 speed=480Mbit/s
                 *-usb
                      description: Mouse
                      product: Optical USB Mouse
                      vendor: Logitech
                      physical id: 1
                      bus info: usb@1:4.1
                      version: 3.40
                      capabilities: usb-2.00
                      configuration: driver=usbhid maxpower=100mA speed=2Mbit/s
              *-usb:2
                   description: Video
                   product: EasyCamera
                   vendor: Azurewave
                   physical id: 5
                   bus info: usb@1:5
                   version: 16.04
                   serial: 0x0001
                   capabilities: usb-2.00
                   configuration: driver=uvcvideo maxpower=500mA speed=480Mbit/s
              *-usb:3
                   description: Generic USB device
                   product: USB2.0-CRW
                   vendor: Generic
                   physical id: 6
                   bus info: usb@1:6
                   version: 39.60
                   serial: 20100201396000000
                   capabilities: usb-2.00
                   configuration: driver=rtsx_usb maxpower=500mA speed=480Mbit/s
              *-usb:4
                   description: Bluetooth wireless interface
                   product: Bluetooth Radio
                   vendor: Realtek
                   physical id: 7
                   bus info: usb@1:7
                   version: 2.00
                   serial: 00e04c000001
                   capabilities: bluetooth usb-2.10
                   configuration: driver=btusb maxpower=500mA speed=12Mbit/s
        *-generic UNCLAIMED
             description: Signal processing controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 14.2
             bus info: pci@0000:00:14.2
             version: 21
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi bus_master cap_list
             configuration: latency=0
             resources: memory:a332a000-a332afff
        *-communication UNCLAIMED
             description: Communication controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 16
             bus info: pci@0000:00:16.0
             version: 21
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi cap_list
             configuration: latency=0
             resources: memory:a332b000-a332bfff
        *-storage
             description: SATA controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 17
             bus info: pci@0000:00:17.0
             version: 21
             width: 32 bits
             clock: 66MHz
             capabilities: storage msi pm ahci_1.0 bus_master cap_list
             configuration: driver=ahci latency=0
             resources: irq:140 memory:a3328000-a3329fff memory:a332e000-a332e0ff ioport:6080(size=8) ioport:6088(size=4) ioport:6060(size=32) memory:a332c000-a332c7ff
        *-pci:0
             description: PCI bridge
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1c
             bus info: pci@0000:00:1c.0
             version: f1
             width: 32 bits
             clock: 33MHz
             capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
             configuration: driver=pcieport
             resources: irq:16 ioport:5000(size=4096) memory:a3200000-a32fffff ioport:a3000000(size=1048576)
           *-network
                description: Ethernet interface
                product: RTL8101E/RTL8102E PCI Express Fast Ethernet controller
                vendor: Realtek Semiconductor Co., Ltd.
                physical id: 0
                bus info: pci@0000:01:00.0
                logical name: eth0
                version: 07
                serial: 1c:39:47:e7:6c:e9
                size: 10Mbit/s
                capacity: 100Mbit/s
                width: 64 bits
                clock: 33MHz
                capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation
                configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=half firmware=rtl8106e-1_0.0.1 06/29/12 latency=0 link=no multicast=yes port=MII speed=10Mbit/s
                resources: irq:138 ioport:5000(size=256) memory:a3200000-a3200fff memory:a3000000-a3003fff
        *-pci:1
             description: PCI bridge
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1c.5
             bus info: pci@0000:00:1c.5
             version: f1
             width: 32 bits
             clock: 33MHz
             capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
             configuration: driver=pcieport
             resources: irq:17 ioport:4000(size=4096) memory:a3100000-a31fffff
           *-network
                description: Wireless interface
                product: RTL8821AE 802.11ac PCIe Wireless Network Adapter
                vendor: Realtek Semiconductor Co., Ltd.
                physical id: 0
                bus info: pci@0000:02:00.0
                logical name: wlan0
                version: 00
                serial: 78:45:61:cb:75:81
                width: 64 bits
                clock: 33MHz
                capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
                configuration: broadcast=yes driver=rtl8821ae driverversion=3.16.0-4-amd64 firmware=N/A latency=0 link=no multicast=yes wireless=IEEE 802.11abgn
                resources: irq:17 ioport:4000(size=256) memory:a3100000-a3103fff
        *-pci:2
             description: PCI bridge
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1d
             bus info: pci@0000:00:1d.0
             version: f1
             width: 32 bits
             clock: 33MHz
             capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
             configuration: driver=pcieport
             resources: irq:16 ioport:3000(size=4096) memory:a2000000-a2ffffff ioport:a0000000(size=16777216)
        *-isa
             description: ISA bridge
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1f
             bus info: pci@0000:00:1f.0
             version: 21
             width: 32 bits
             clock: 33MHz
             capabilities: isa bus_master
             configuration: latency=0
        *-memory UNCLAIMED
             description: Memory controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1f.2
             bus info: pci@0000:00:1f.2
             version: 21
             width: 32 bits
             clock: 33MHz (30.3ns)
             capabilities: bus_master
             configuration: latency=0
             resources: memory:a3324000-a3327fff
        *-multimedia
             description: Audio device
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1f.3
             bus info: pci@0000:00:1f.3
             version: 21
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi bus_master cap_list
             configuration: driver=snd_hda_intel latency=32
             resources: irq:141 memory:a3320000-a3323fff memory:a3310000-a331ffff
        *-serial UNCLAIMED
             description: SMBus
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1f.4
             bus info: pci@0000:00:1f.4
             version: 21
             width: 64 bits
             clock: 33MHz
             configuration: latency=0
             resources: memory:a332d000-a332d0ff ioport:6040(size=32)
     *-scsi:0
          physical id: 2
          logical name: scsi0
          capabilities: emulated
        *-disk
             description: ATA Disk
             product: TOSHIBA MQ01ABD1
             vendor: Toshiba
             physical id: 0.0.0
             bus info: scsi@0:0.0.0
             logical name: /dev/sda
             version: 6E
             serial: 86JSPU91T
             size: 931GiB (1TB)
             capabilities: gpt-1.00 partitioned partitioned:gpt
             configuration: ansiversion=5 guid=0bfcdc3a-d9e4-48f3-b540-17b6ed435b2e logicalsectorsize=512 sectorsize=4096
           *-volume:0 UNCLAIMED
                description: Windows FAT volume
                vendor: MSDOS5.0
                physical id: 1
                bus info: scsi@0:0.0.0,1
                version: FAT32
                serial: c636-32a8
                size: 255MiB
                capacity: 259MiB
                capabilities: boot fat initialized
                configuration: FATs=2 filesystem=fat label=SYSTEM_DRV name=EFI system partition
           *-volume:1
                description: reserved partition
                vendor: Windows
                physical id: 2
                bus info: scsi@0:0.0.0,2
                logical name: /dev/sda2
                serial: 75e03c0d-ab82-472b-b47b-48550a4a99eb
                capacity: 15MiB
                capabilities: nofs
                configuration: name=Microsoft reserved partition
           *-volume:2
                description: Windows NTFS volume
                vendor: Windows
                physical id: 3
                bus info: scsi@0:0.0.0,3
                logical name: /dev/sda3
                version: 3.1
                serial: 8ca72e2f-1194-7b41-9fa1-34c9475e2295
                size: 579GiB
                capacity: 579GiB
                capabilities: ntfs initialized
                configuration: clustersize=4096 created=2016-09-11 00:41:58 filesystem=ntfs label=Windows modified_by_chkdsk=true mounted_on_nt4=true name=Basic data partition resize_log_file=true state=dirty upgrade_on_mount=true
           *-volume:3
                description: Windows NTFS volume
                vendor: Windows
                physical id: 4
                bus info: scsi@0:0.0.0,4
                logical name: /dev/sda4
                version: 3.1
                serial: 5e206bb6-0348-a047-a7d4-d86fa05d03c1
                size: 24GiB
                capacity: 24GiB
                capabilities: ntfs initialized
                configuration: clustersize=4096 created=2016-09-11 02:53:56 filesystem=ntfs label=BACKUPDRIVERS modified_by_chkdsk=true mounted_on_nt4=true name=Basic data partition resize_log_file=true state=dirty upgrade_on_mount=true
           *-volume:4
                description: Windows NTFS volume
                vendor: Windows
                physical id: 5
                bus info: scsi@0:0.0.0,5
                logical name: /dev/sda5
                version: 3.1
                serial: b4a7-4c43
                size: 995MiB
                capacity: 999MiB
                capabilities: boot precious readonly hidden nomount ntfs initialized
                configuration: clustersize=4096 created=2016-09-11 02:53:58 filesystem=ntfs label=WINRE_DRV modified_by_chkdsk=true mounted_on_nt4=true name=Basic data partition resize_log_file=true state=dirty upgrade_on_mount=true
           *-volume:5
                description: Windows NTFS volume
                vendor: Windows
                physical id: 6
                bus info: scsi@0:0.0.0,6
                logical name: /dev/sda6
                version: 3.1
                serial: 9caa-1a04
                size: 11GiB
                capacity: 11GiB
                capabilities: boot precious readonly hidden nomount ntfs initialized
                configuration: clustersize=4096 created=2016-09-11 02:54:03 filesystem=ntfs label=LENOVO_PART modified_by_chkdsk=true mounted_on_nt4=true name=Basic data partition resize_log_file=true state=dirty upgrade_on_mount=true
           *-volume:6
                description: Windows FAT volume
                vendor: MSDOS5.0
                physical id: 7
                bus info: scsi@0:0.0.0,7
                logical name: /dev/sda7
                version: FAT32
                serial: ce40-098a
                size: 992MiB
                capacity: 999MiB
                capabilities: precious readonly hidden nomount fat initialized
                configuration: FATs=2 filesystem=fat label=LRS_ESP name=Basic data partition
           *-volume:7
                description: EXT4 volume
                vendor: Linux
                physical id: 8
                bus info: scsi@0:0.0.0,8
                logical name: /dev/sda8
                logical name: /
                version: 1.0
                serial: 91c33624-4787-4fa0-86f5-bd1986acf349
                size: 305GiB
                capabilities: journaled extended_attributes large_files huge_files dir_nlink recover extents ext4 ext2 initialized
                configuration: created=2017-05-16 20:01:28 filesystem=ext4 lastmountpoint=/ modified=2017-05-17 12:47:13 mount.fstype=ext4 mount.options=rw,relatime,errors=remount-ro,data=ordered mounted=2017-05-17 17:47:17 state=mounted
           *-volume:8
                description: Linux swap volume
                vendor: Linux
                physical id: 9
                bus info: scsi@0:0.0.0,9
                logical name: /dev/sda9
                version: 1
                serial: 4218deb3-c260-42b3-851e-e34b2c99850b
                size: 7937MiB
                capacity: 7938MiB
                capabilities: nofs swap initialized
                configuration: filesystem=swap pagesize=4095
     *-scsi:1
          physical id: 3
          logical name: scsi1
          capabilities: emulated
        *-cdrom
             description: DVD-RAM writer
             product: DVDRAM GUE0N
             vendor: HL-DT-ST
             physical id: 0.0.0
             bus info: scsi@1:0.0.0
             logical name: /dev/cdrom
             logical name: /dev/cdrw
             logical name: /dev/dvd
             logical name: /dev/dvdrw
             logical name: /dev/sr0
             version: T.02
             capabilities: removable audio cd-r cd-rw dvd dvd-r dvd-ram
             configuration: ansiversion=5 status=nodisc

User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: Making NetworkManager default

#2 Post by orythem27 »

From your description, My guesstimate is that either you encountered a bug in NetworkManager or a driver issue. I'm inclined to believe it's the second case because (a) you mentioned 'internet went "down" randomly' (b) your wireless hardware is a relatively new model made by Realtek.

If I were you, I would:

Firstly, I would try to do a fresh install of Debian 9 to see if newer version of NetworkManager and improved driver code in a newer kernel would help. In fact, this device's PCI ID was first seen in kernel v3.18 and the driver 'rtl8821ae' is backported to Linux 3.16 according to this page.

If that doesn't work, I would try my hands on https://github.com/lwfinger/rtlwifi_new, which supports RTL8821AE.

I believe your other issues are mostly "conflicts" between NetworkManager and ifupdown which wouldn't be a problem anymore if the "main" problem could be resolved.

Regards

User avatar
debiman
Posts: 3063
Joined: 2013-03-12 07:18

Re: Making NetworkManager default

#3 Post by debiman »

i think you are trying to configure something manually that networkmanager would rather have control of.

try
1) getting desired results through networkmanager gui & command line interface
or
2) uninstall networkmanager, and do the manual thing

d3viant
Posts: 24
Joined: 2017-05-17 23:36

Re: Making NetworkManager default

#4 Post by d3viant »

I did some additional testing last night and it appears each time I log out and change desktop environments (Gnome -> LXDE; vice-versa) and not necessarily reboot is when the Network Manager updates/wipes my nameservers. (Hadn't initially considered this to be the culprit, hence the assumption of it being a random disconnect).

I wasn't doing anything special to switch environments; I installed them both via commandline and used Debian's repositories for both.. since its a new install I was testing out GUI to see which one I liked best.
I'd log out of my session, hit the wheel and select which GUI I wanted to log into.

I did a shut down, power up & never lost connectivity and didn't have to intervene to get online.

With that said, is this type of situation still requiring of new drivers?
If so, I'd like to try better drivers opposed to doing an install of Debian 9.
Presumably, these are what I'll need, correct? https://github.com/lwfinger/rtlwifi_new ... /rtl8821ae If so, how do I get them to my system?


Thanks for the hints so far!

User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: Making NetworkManager default

#5 Post by orythem27 »

d3viant wrote:......it appears each time I log out and change desktop environments (Gnome -> LXDE; vice-versa) and not necessarily reboot is when the Network Manager updates/wipes my nameservers.
I think it might be that each time NetworkManager.service is restarted it will re-autogenerate /etc/resolv.conf. And the nameserver it will put in comes from NetworkManager's connection profile, which can be configured by 'Edit Connections...' - '<connection>' - 'IPv4/6 Settings'.
Since you are mixing ifupdown and NetworkManager by setting "managed=true", I guess you might have some related pseudo 'connection' avalible for configuration in 'Edit Connections...'. I haven't verified myself since this mixed setup is usually considered pretty strange. :)
d3viant wrote:(Hadn't initially considered this to be the culprit, hence the assumption of it being a random disconnect).
With that said, is this type of situation still requiring of new drivers?
Well, if this is the case I would take back the suspiction on drivers... :mrgreen: I guess it will be easier if we go all the way back to beginning where the first problem appeared. That is, after a fresh install you "...immediately had no connection.", which is the part we should investigate. Normally if it works, when you click the NM icon in the system tray, you would see a list of nearby access points, and if you select one, it should connect. So it would help a lot if you could describe what exactly happened at that moment.

And as for now, if you verify that if you revert to "managed=false" and remove all configuration from /etc/network/interfaces, would you be greeted with the exact same behaviour as right after a fresh install? If this is the case, then we can start from here and hopefully we'll be able to fix the issue cleanly.

d3viant
Posts: 24
Joined: 2017-05-17 23:36

Re: Making NetworkManager default

#6 Post by d3viant »

orythem27 wrote:
d3viant wrote:......it appears each time I log out and change desktop environments (Gnome -> LXDE; vice-versa) and not necessarily reboot is when the Network Manager updates/wipes my nameservers.
I think it might be that each time NetworkManager.service is restarted it will re-autogenerate /etc/resolv.conf. And the nameserver it will put in comes from NetworkManager's connection profile, which can be configured by 'Edit Connections...' - '<connection>' - 'IPv4/6 Settings'.
I disabled ipv6 from the wifi gui.
Since you are mixing ifupdown and NetworkManager by setting "managed=true", I guess you might have some related pseudo 'connection' avalible for configuration in 'Edit Connections...'. I haven't verified myself since this mixed setup is usually considered pretty strange. :)
This is uncharted territory for me, I was desperate and tried to get creative :)
I set managed=false, restarted network manager and so far, so good!


I just installed Deluge and went to start some torrents, I'm not getting any activity (which ended up being because the seeders were simply slow) so I inspected /var/log/syslog... I think I found the problem (not sure why I didn't look here in the first place..) -- I got the drivers *from* the Debian site and stuck em on a USB so they loaded during install.
wlan0: Failed to initialize driver interface
Since the error is complaining about wlan0 (remember, I manually enabled this in /etc/network/interfaces to originally get online?) I went and changed that to wlan1.. knocked me offline.

Changed it back.. all is good.. for a few minutes. I just had a Debian popup asking me to re-auth my wifi. From syslog:

Code: Select all

May 18 18:04:44 debian kernel: [ 1330.974606] R8188EU: ERROR linked_status_chk(wlan1) disconnect or roaming
May 18 18:04:46 debian kernel: [ 1333.008473] R8188EU: ERROR assoc success
May 18 18:04:46 debian wpa_supplicant[746]: wlan1: Associated with 94:10:3e:x:x:x
May 18 18:04:46 debian wpa_supplicant[746]: wlan1: Trying to associate with 94:10:3e:x:x:x (SSID='myssid' freq=2412 MHz)
May 18 18:04:46 debian wpa_supplicant[746]: wlan1: Association request to the driver failed
May 18 18:04:46 debian kernel: [ 1333.048741] R8188EU: ERROR indicate disassoc
May 18 18:04:46 debian NetworkManager[2715]: <info> (wlan1): supplicant interface state: completed -> associating
May 18 18:04:46 debian wpa_supplicant[746]: wlan1: CTRL-EVENT-DISCONNECTED bssid=94:10:3e:x:x:x reason=0
May 18 18:04:46 debian NetworkManager[2715]: <info> (wlan1): supplicant interface state: associating -> disconnected
May 18 18:04:46 debian kernel: [ 1333.116176] R8188EU: ERROR assoc success
May 18 18:04:46 debian wpa_supplicant[746]: wlan1: Associated with 94:10:3e:x:x:x
May 18 18:04:46 debian NetworkManager[2715]: <info> (wlan1): supplicant interface state: disconnected -> 4-way handshake
May 18 18:04:47 debian NetworkManager[2715]: <info> (wlan1): roamed from BSSID F8:7B:8C:x:x:x (myssid) to 94:10:3e:x:x:x (myssid)
May 18 18:04:47 debian kernel: [ 1334.330644] R8188EU: ERROR ap recv disassoc reason code(14) sta:94:10:3e:x:x:x
May 18 18:04:47 debian wpa_supplicant[746]: wlan1: CTRL-EVENT-DISCONNECTED bssid=94:10:3e:x:x:x reason=0
May 18 18:04:47 debian wpa_supplicant[746]: wlan1: WPA: 4-Way Handshake failed - pre-shared key may be incorrect
May 18 18:04:47 debian wpa_supplicant[746]: wlan1: CTRL-EVENT-SSID-TEMP-DISABLED id=0 ssid="myssid" auth_failures=1 duration=10 reason=WRONG_KEY
May 18 18:04:47 debian kernel: [ 1334.333042] R8188EU: ERROR indicate disassoc
May 18 18:04:47 debian NetworkManager[2715]: <info> (wlan1): supplicant interface state: 4-way handshake -> disconnected
May 18 18:04:47 debian NetworkManager[2715]: <info> Activation (wlan1/wireless): disconnected during association, asking for new key.
May 18 18:04:47 debian NetworkManager[2715]: <info> (wlan1): device state change: activated -> need-auth (reason 'supplicant-disconnect') [100 60 8]
May 18 18:04:47 debian kernel: [ 1334.363599] R8188EU: ERROR sta recv deauth reason code(6) sta:94:10:3e:x:x:x
May 18 18:04:48 debian kernel: [ 1334.368438] R8188EU: ERROR sta recv deauth reason code(6) sta:94:10:3e:x:x:x
No, nothing changed with the key or router.
I *do* have two wifi cards: 1 internal and 1 dongle. I use the dongle because it is significantly faster than the onboard wifi for some reason.
I was not trying to use both at once. I was actually only using Firefox when this occurred.


UPDATE:
It's been a while and I've been periodically checking syslog, so far, this is the only type of activity I'm regularly seeing:

Code: Select all

May 18 19:10:31 debian kernel: [ 5282.697189] [UFW BLOCK] IN=wlan1 OUT= MAC= SRC=192.168.0.22 DST=239.192.152.143 LEN=165 TOS=0x00 PREC=0x00 TTL=1 ID$
May 18 19:10:31 debian kernel: [ 5282.697377] [UFW BLOCK] IN=wlan1 OUT= MAC= SRC=192.168.0.22 DST=239.192.152.143 LEN=165 TOS=0x00 PREC=0x00 TTL=255 $
May 18 19:10:33 debian kernel: [ 5284.700180] [UFW BLOCK] IN=wlan1 OUT= MAC= SRC=192.168.0.22 DST=239.192.152.143 LEN=165 TOS=0x00 PREC=0x00 TTL=1 ID$
May 18 19:10:33 debian kernel: [ 5284.700374] [UFW BLOCK] IN=wlan1 OUT= MAC= SRC=192.168.0.22 DST=239.192.152.143 LEN=165 TOS=0x00 PREC=0x00 TTL=255 $
May 18 19:10:37 debian kernel: [ 5288.705529] [UFW BLOCK] IN=wlan1 OUT= MAC= SRC=192.168.0.22 DST=239.192.152.143 LEN=165 TOS=0x00 PREC=0x00 TTL=1 ID$
May 18 19:10:37 debian kernel: [ 5288.705594] [UFW BLOCK] IN=wlan1 OUT= MAC= SRC=192.168.0.22 DST=239.192.152.143 LEN=165 TOS=0x00 PREC=0x00 TTL=255 $
May 18 19:11:52 debian kernel: [ 5363.814203] [UFW BLOCK] IN=wlan1 OUT= MAC=e0:b2:f1:a9:66:6e:00:00:ca:00:00:03:08:00 SRC=192.168.0.1 DST=224.0.0.1 L$
May 18 19:11:58 debian dhclient: DHCPREQUEST on wlan0 to 192.168.0.1 port 67
May 18 19:11:59 debian dhclient: DHCPACK from 192.168.0.1
May 18 19:11:59 debian dhclient: bound to 192.168.0.13 -- renewal in 1419 seconds.
I'm curious.. it's latched onto wlan1, correct? This is still in /etc/network/interfaces

Code: Select all

auto wlan0
iface wlan0 inet dhcp
        wpa-ssid "myssid
        wpa-psk "mypassword"

setting NetworkManager to managed=false means this is no longer taken, correct?

User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: Making NetworkManager default

#7 Post by orythem27 »

d3viant wrote: I set managed=false, restarted network manager and so far, so good!
setting NetworkManager to managed=false means this is no longer taken, correct?
No, setting "managed=false" will instruct NM to get out of the way for ifupdown. In this case, you would see wlan0 listed as "Device not managed" in the systray nm-applet menu. As long as wlan0 is still configured in /etc/network/interfaces, ifupdown will try to take over.

d3viant wrote:wlan0: Failed to initialize driver interface
At which moment did you see this message? Is it right after installation before you put wlan0 configurations in /etc/network/interfaces?

I guess both the above quoted message and "pre-shared key may be incorrect" indicated some problem with wpa-supplicant. In fact I'm pretty much out of idea at this point, since a problem with wpa-supplicant is a rare occurence to me. And although the keyword 'driver' in the above quoted message actually means userspace drivers such as 'wext' or 'nl80211', I still wouldn't be at all surprised if it is the kernel device driver — which is our initial suspicion — that is actually acting up. This still a real possibility since your internal wireless card is using backported kernel driver, and the external dongle R8188EU is also highly vulnerable to device driver issues — Cheap realtek USB wifi dongles have notoriously buggy firmware and linux kernel drivers.

I'm terribly sorry for not being able to provide specific solutions to the wpa-supplicant problem. But as stated above, the root cause might be elsewhere.

d3viant
Posts: 24
Joined: 2017-05-17 23:36

Re: Making NetworkManager default

#8 Post by d3viant »

UPDATE 2:
Reboot trying to troubleshoot lack of Bluetooth capability (same issue occurs on Ubuntu -- but only after the latest Ubuntu update; was working fine, prior).

Some interesting bits during startup:

Code: Select all

May 18 20:12:38 debian NetworkManager[677]: <warn> interfaces file /etc/network/interfaces.d/* doesn't exist
May 18 20:12:38 debian NetworkManager[677]: <info>       interface-parser: finished parsing file /etc/network/interfaces
May 18 20:12:38 debian NetworkManager[677]: <info> guessed connection type (wlan0) = 802-11-wireless
May 18 20:12:38 debian NetworkManager[677]: Libgcrypt warning: missing initialization - please fix the application
May 18 20:12:38 debian NetworkManager[677]: <info> update_connection_setting_from_if_block: name:wlan0, type:802-11-wireless, id:Ifupdown (wlan0), uu$
May 18 20:12:38 debian NetworkManager[677]: <info> update wireless settings (wlan0).

ay 18 20:12:38 debian NetworkManager[677]: <info> setting wpa ssid = 12
May 18 20:12:38 debian NetworkManager[677]: <info> update wireless security settings (wlan0).
May 18 20:12:38 debian NetworkManager[677]: <info> setting wpa security key: psk=<omitted>
May 18 20:12:38 debian NetworkManager[677]: <warn> nm-ifupdown-connection.c.101 - invalid connection read from /etc/network/interfaces: (2) 802-11-wi$
May 18 20:12:38 debian NetworkManager[677]: <info> adding iface wlan0 to eni_ifaces
May 18 20:12:38 debian NetworkManager[677]: <info> management mode: unmanaged

May 18 20:12:38 debian NetworkManager[677]: <info> devices added (path: /sys/devices/virtual/net/lo, iface: lo)
May 18 20:12:38 debian NetworkManager[677]: <info> device added (path: /sys/devices/virtual/net/lo, iface: lo): no ifupdown configuration found.

With this:

Code: Select all

nm-ifupdown-connection.c.101 - invalid connection read from /etc/network/interfaces
I tried a few variations; I assume the presence of my ssid is what it was complaining about, oops.

Back online with this:

Code: Select all

source /etc/network/interfaces.d/*

# The loopback network interface
#auto lo
#iface lo inet loopback

#auto wlan0
#iface wlan0 inet dhcp
#       wpa-ssid "myssid"
#       wpa-psk "mypassword

auto lo
iface lo inet dhcp
Slow progress.. syslog is no longer filling up with the wlan0: Failed to initialize driver interface every few seconds.

This still a real possibility since your internal wireless card is using backported kernel driver, and the external dongle R8188EU is also highly vulnerable to device driver issues — Cheap realtek USB wifi dongles have notoriously buggy firmware and linux kernel drivers.
Uh oh, I paid $5 for it!
In your opinion, what's the best dongle for a Linux system? I'm not against spending more money on one, I just happened to have it laying around as a backup when I realized my new laptop had a crappy connection.
I'm terribly sorry for not being able to provide specific solutions to the wpa-supplicant problem. But as stated above, the root cause might be elsewhere.
You've been super helpful! Thanks for offering any tips at all, every little bit helps!

If this continues, I'm going to detach the dongle and work on the internal wifi and see if that clears up any issues.

User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: Making NetworkManager default

#9 Post by orythem27 »

d3viant wrote:Back online with this:
#iface wlan0 inet dhcp
So somehow "pure NetworkManager" mode now works, and the initial problem "...installed Debian and immediately had no connection." is intermittent.
d3viant wrote:In your opinion, what's the best dongle for a Linux system?
I can't give a definitive answer, because I've yet to have a wireless card that gave 100% reliable record in Linux, some better, some worse. From all the USB Wi-Fi dongles I've had, I would say Ralink RT5370 and Atheros AR9271 based USB dongles gave me the least troubles overall. But these two chips are all discontinued, which means they are less likely to appear on large B2C sites or a local radioshack. But it's still quite possible to buy dongles with these chipsets on sites such as aliexpress or ebay.
d3viant wrote:is this type of situation still requiring of new drivers?
If so, I'd like to try better drivers opposed to doing an install of Debian 9
If you don't have a particular use case that requires Debian 8, I would recommend doing a fresh install of Debian 9 since I believe rtl8821ae's driver status would be much improved in Linux 4.9.
d3viant wrote:...when I realized my new laptop had a crappy connection.
Well, if your laptop is new, that's another reason to install Debian 9. :mrgreen: :mrgreen:

d3viant
Posts: 24
Joined: 2017-05-17 23:36

Re: Making NetworkManager default

#10 Post by d3viant »

orythem27 wrote: So somehow "pure NetworkManager" mode now works, and the initial problem "...installed Debian and immediately had no connection." is intermittent.
Could this be somehow related to the fact that the OS originated from an ISO and not a CD?
orythem27 wrote: If you don't have a particular use case that requires Debian 8, I would recommend doing a fresh install of Debian 9 since I believe rtl8821ae's driver status would be much improved in Linux 4.9.
The dist upgrade path isn't recommended, in this case?

I'm definitely not pressed on Debian 8; this is my first taste of Debian and I wanted the latest stable release. The ISO's on the Debian site all pointed at 8. (I did read, that the ISO's aren't as up-to-date as the live CDs, which is fine - I don't mind the extra effort. It's a good learning experience.)

There is a "freeze," on 9 according to this wiki: https://wiki.debian.org/DebianStretch and 8 has more recent updates than 9 - is this definitely the best route to go? It being a "testing" distro is a little concerning to me.. I appreciate a good challenge but I'd also like to use Debian as my daily driver.

Based on this thread: http://forums.debian.net/viewtopic.php?f=30&t=133065 I'm not sure I'm ready to use Debian 9. I really don't know what I'm doing just yet. :) Though, if I encounter catastrophe and need to wipe Debian I will probably consider 9. For future reference, is it available on ISO? I could only locate 8.8 for amd64.

User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: Making NetworkManager default

#11 Post by orythem27 »

d3viant wrote: Could this be somehow related to the fact that the OS originated from an ISO and not a CD?
By "ISO" and "CD" did you refer to a USB flash drive and a physical CD/DVD-R disc? :roll: Personally I can't see any difference.
d3viant wrote:The dist upgrade path isn't recommended, in this case?
Well, consider that your Debian 8 installation is kinda 'fresh', you wouldn't lose much work by doing a complete reinstall anyway. I think most people won't have any issue with dist-upgrade, but personally I would prefer a fresh reinstall to "further" ensure a bug-free experience. :mrgreen:
d3viant wrote: 8 has more recent updates than 9
Debian 8 is the current stable release means that it will only receive bug fixes in its lifetime. There will be no new feature or major software version updates. From this point view, the term "stable" in "Debian stable" actually means "not changing" rather than "crashproof".
d3viant wrote:...is this definitely the best route to go? It being a "testing" distro is a little concerning to me...
Better support for recent hardware is already a pretty strong argument. And although technically it's still in the "testing" phase, I would say that it's already so close to being released that the possibility of encountering a bug is pretty low.
d3viant wrote:I appreciate a good challenge but I'd also like to use Debian as my daily driver.
If you hang around in various linux forums, you will see a lot of people claiming that Debian unstable is actually fully qualified as a daily driver. As for Debian testing, there are even more people considering it as "rock solid". By that logic, a freezed debian testing close to release would be "bedrock solid". :mrgreen:
d3viant wrote:For future reference, is it available on ISO? I could only locate 8.8 for amd64.
As for now you can download the "testing" ISO images at http://cdimage.debian.org/cdimage/weekly-builds/.
d3viant wrote:Based on this thread: viewtopic.php?f=30&t=133065 I'm not sure I'm ready to use Debian 9.
To be honest, I'm having slight trouble understanding what the OP is asking in this thread. :lol: Gparted is available in stretch. And the question regarding security repos, because stretch is not yet the current stable release, it won't receive critical security patches in a timely manner, as stated in https://www.debian.org/releases/stretch/. In fact, this is one of the major arguments against using testing, especially in security sensitive use cases, such as a computer directly exposed with a public IP address.

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

Re: Making NetworkManager default

#12 Post by Bulkley »

When it is configured properly NetworkManager is a wonderful program. Otherwise it can drive a user nuts. From my own experience and watching threads on this forum I'm convinced that most problems with NetworkManager are self induced. What many users do in frustration is to disable or remove NetworkManager and install Wicd. Neither is better than the other but it gives you a fresh configuration.

Both NetworkManager and Wicd are simply front end GUI's for wpa_supplicant which does the actual work. If you are using a desktop, you don't need either NetworkManager or Wicd which you found out with your scripts in /etc/network/interfaces. I have run my desktop like this for years and prefer it. You've probably seen this but here: How to use a WiFi interface

If you have a laptop you might prefer this method.

d3viant
Posts: 24
Joined: 2017-05-17 23:36

Re: Making NetworkManager default

#13 Post by d3viant »

orythem27 wrote: By "ISO" and "CD" did you refer to a USB flash drive and a physical CD/DVD-R disc? :roll: Personally I can't see any difference.
USB. I initially assumed they were the same thing, but users around the web insist the iso/usb is out of date.
Debian 8 is the current stable release means that it will only receive bug fixes in its lifetime. There will be no new feature or major software version updates. From this point view, the term "stable" in "Debian stable" actually means "not changing" rather than "crashproof".... Better support for recent hardware is already a pretty strong argument. And although technically it's still in the "testing" phase, I would say that it's already so close to being released that the possibility of encountering a bug is pretty low.
Ah, I see your point!

If you hang around in various linux forums, you will see a lot of people claiming that Debian unstable is actually fully qualified as a daily driver. As for Debian testing, there are even more people considering it as "rock solid". By that logic, a freezed debian testing close to release would be "bedrock solid". :mrgreen:

As for now you can download the "testing" ISO images at http://cdimage.debian.org/cdimage/weekl ... s/stretch/. In fact, this is one of the major arguments against using testing, especially in security sensitive use cases, such as a computer directly exposed with a public IP address.
[/quote]
This is a concern of mine, as I regularly torrent. How much risk is involved for a casual internet user (I don't venture into the dark web or anything like that)

Bulkley - Thanks for the links, I actually haven't come across these yet!
Is it safe to say Networkmanager isn't pre-configured on Debian?

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

Re: Making NetworkManager default

#14 Post by Bulkley »

Is it safe to say Networkmanager isn't pre-configured on Debian?
It is to a point. I don't think it is configured to be as user friendly as I have found in other distros. I've tried a number of live-CD's in which NetworkManager simply works. When I tried it in a Debian install I made a mistake (or two) answering questions that came up and wound up with NetworkManager demanding for an extra password every time I logged on. With my present /etc/network/interfaces configuration wpa_supplicant connects to my Wifi router during the boot process even before I log in.

A desktop computer generally doesn't travel anywhere and only has one Wifi connection to make. Thus, it does not need a GUI Wifi tool. Just remember to hide your /etc/network/interfaces if you put in anything you don't want your neighbourhood scriptkiddy to see like a password.

Code: Select all

# chmod 0600 /etc/network/interfaces

d3viant
Posts: 24
Joined: 2017-05-17 23:36

Re: Making NetworkManager default

#15 Post by d3viant »

Bulkley wrote:
Is it safe to say Networkmanager isn't pre-configured on Debian?
Just remember to hide your /etc/network/interfaces if you put in anything you don't want your neighbourhood scriptkiddy to see like a password.

Code: Select all

# chmod 0600 /etc/network/interfaces
Thank you for the fantastic tip, I hadn't thought of this!

Nice to know I'm in good company with the NetworkManager being a tricky deal! :D

d3viant
Posts: 24
Joined: 2017-05-17 23:36

Re: Making NetworkManager default

#16 Post by d3viant »

Took the plunge and did a fresh install of 9. :D
Thank you to everyone that contributed tips in this thread!

Post Reply