You are not logged in.
Hi
I'm trying to use ConnMan on my fully updated Arch + Gnome because the airplane mode does not work with networkmanager,
see https://bbs.archlinux.org/viewtopic.php?pid=2071211
And sometimes networkmanager fails to autoconnect to wi-fi after boot, generally after systemd/kernel updates.
I need to deactivate and re-activate the wi-fi adapter in Wi-Fi module of Gnome settings to be able to connect to wi-fi.
ConnMan connects to wired newtwork, but it does not to wifi.
No wi-fi network is found and wpa_supplicant gives these errors:
● wpa_supplicant.service - WPA supplicant
Loaded: loaded (/usr/lib/systemd/system/wpa_supplicant.service; disabled; preset: disabled)
Active: active (running) since Mon 2023-03-20 11:09:52 -03; 22min ago
Main PID: 1774 (wpa_supplicant)
Tasks: 1 (limit: 9389)
Memory: 4.9M
CPU: 60ms
CGroup: /system.slice/wpa_supplicant.service
└─1774 /usr/bin/wpa_supplicant -u -s -O /run/wpa_supplicant
mar 20 11:09:52 arch-laptop wpa_supplicant[1774]: ioctl[SIOCSIWSCAN]: Operation not supported
mar 20 11:09:52 arch-laptop wpa_supplicant[1774]: wlan0: CTRL-EVENT-SCAN-FAILED ret=-1
mar 20 11:09:55 arch-laptop wpa_supplicant[1774]: ioctl[SIOCSIWSCAN]: Operation not supported
mar 20 11:09:55 arch-laptop wpa_supplicant[1774]: wlan0: CTRL-EVENT-SCAN-FAILED ret=-1
mar 20 11:10:04 arch-laptop wpa_supplicant[1774]: ioctl[SIOCSIWSCAN]: Operation not supported
mar 20 11:10:04 arch-laptop wpa_supplicant[1774]: wlan0: CTRL-EVENT-SCAN-FAILED ret=-1
mar 20 11:10:31 arch-laptop wpa_supplicant[1774]: ioctl[SIOCSIWSCAN]: Operation not supported
mar 20 11:10:31 arch-laptop wpa_supplicant[1774]: wlan0: CTRL-EVENT-SCAN-FAILED ret=-1
mar 20 11:10:42 arch-laptop wpa_supplicant[1774]: wlan0: CTRL-EVENT-DSCP-POLICY clear_all
mar 20 11:10:42 arch-laptop wpa_supplicant[1774]: wlan0: CTRL-EVENT-DSCP-POLICY clear_all
ConnMan also fails to connect to wifi with iwd backend.
How to solve this problem?
Thanks for reading.
Last edited by Strangiato (2023-03-22 18:29:07)
Offline
I'm trying to use ConnMan on my fully updated Arch + Gnome because the airplane mode does not work with networkmanager
And sometimes networkmanager fails to autoconnect to wi-fi after boot
Errr…
Please post the output of
find /etc/systemd -type l -exec test -f {} \; -print | awk -F'/' '{ printf ("%-40s | %s\n", $(NF-0), $(NF-1)) }' | sort -f
Offline
$ find /etc/systemd -type l -exec test -f {} \; -print | awk -F'/' '{ printf ("%-40s | %s\n", $(NF-0), $(NF-1)) }' | sort -f
avahi-daemon.service | multi-user.target.wants
avahi-daemon.socket | sockets.target.wants
connman.service | multi-user.target.wants
dbus-org.freedesktop.Avahi.service | system
display-manager.service | system
fstrim.timer | timers.target.wants
gcr-ssh-agent.socket | sockets.target.wants
getty@tty1.service | getty.target.wants
gnome-keyring-daemon.socket | sockets.target.wants
hostapd.service | multi-user.target.wants
ntpd.service | multi-user.target.wants
p11-kit-server.socket | sockets.target.wants
pamac-cleancache.timer | timers.target.wants
pipewire-pulse.socket | sockets.target.wants
pipewire-session-manager.service | user
pipewire.socket | sockets.target.wants
reflector.service | multi-user.target.wants
remote-fs.target | multi-user.target.wants
snapd.socket | sockets.target.wants
sshd.service | multi-user.target.wants
var-lib-snapd-snap-core20-1581.mount | multi-user.target.wants
var-lib-snapd-snap-core20-1587.mount | multi-user.target.wants
var-lib-snapd-snap-snapd-15534.mount | multi-user.target.wants
var-lib-snapd-snap-snapd-16292.mount | multi-user.target.wants
wireplumber.service | pipewire.service.wants
xdg-user-dirs-update.service | default.target.wants
Offline
So only connman is enabled.
According to the service status, what fails is the scanning.
Can you connect to the AP using wpa_supplicant or iwd manually? (Stop/disable connman first)
Offline
iwd does not find the wifi device
[iwd]# device wlan0 set-property Powered on
Device wlan0 not found.
Apparently the same with wpa_supplicant
# wpa_supplicant -B -i wlan0 -c /etc/wpa_supplicant/wpa_supplicant.conf
Successfully initialized wpa_supplicant
nl80211: kernel reports: Match already configured
nl80211: Could not configure driver mode
nl80211: deinit ifname=wlan0 disabled_11b_rates=0
wlan0: Failed to initialize driver interface
wlan0: CTRL-EVENT-DSCP-POLICY clear_all
More error:
# ip link set wlan0 up
RTNETLINK answers: Input/output error
But the device exists
$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp1s0: <BROADCAST,MULTICAST,DYNAMIC> mtu 1500 qdisc mq state DOWN group default qlen 1000
link/ether xxxxxxxxxx brd ff:ff:ff:ff:ff:ff
5: wlan0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
link/ether xxxxxxxxxx brd ff:ff:ff:ff:ff:ff
Edit:
kernel errors after "ip link set wlan0 up" command
mar 20 15:29:05 arch-laptop kernel: iwlwifi 0000:02:00.0: Radio type=0x0-0x0-0x0
mar 20 15:29:05 arch-laptop kernel: iwlwifi 0000:02:00.0: Command COEX_PRIORITY_TABLE_CMD failed: FW Error
mar 20 15:29:05 arch-laptop kernel: iwlwifi 0000:02:00.0: Could not complete ALIVE transition: -5
mar 20 15:29:05 arch-laptop kernel: iwlwifi 0000:02:00.0: Failed to run INIT ucode: -5
mar 20 15:29:05 arch-laptop kernel: iwlwifi 0000:02:00.0: Unable to initialize device.
Edit2:
This bug does not occur if ConnMan is active:
# ip link set wlan0 up
RTNETLINK answers: Input/output error
Last edited by Strangiato (2023-03-20 21:18:53)
Offline
So this has probably nothing to do w/ the specific network managing service.
Please post the complete system journal for a boot after attempting to use the NIC:
sudo journalctl -b | curl -F 'file=@-' 0x0.st
Sanity check: is there a parallel windows installation and what does "rfkill" report?
Offline
Complete system journal for a boot after attempting to use the NIC:
$ rfkill
ID TYPE DEVICE SOFT HARD
0 wlan ideapad_wlan unblocked unblocked
1 bluetooth ideapad_bluetooth blocked unblocked
2 wlan phy0 unblocked unblocked
3 bluetooth hci0 blocked unblocked
Offline
There're multiple FW crashes.
Does this also happen w/ the regular (non-zen) kernel?
Also you started connman, the idea is still to try a direct utilization w/ iwd and/or wpa_supplicant
mar 20 18:09:37 arch-laptop wpa_supplicant[443]: nl80211: kernel reports: Match already configured
mar 20 18:09:37 arch-laptop wpa_supplicant[443]: nl80211: Could not configure driver mode
Also disable hostapd (I missed that in your previous output)
Finally
mar 20 18:08:13 arch-laptop kernel: ntfs3: Max link count 4000
mar 20 18:08:13 arch-laptop kernel: ntfs3: Enabled Linux POSIX ACLs support
mar 20 18:08:13 arch-laptop kernel: ntfs3: Read-only LZX/Xpress compression included
Sanity check: is there a parallel windows installation?
Assuming the answer is "yes", 3rd link below. Mandatory.
Disable it (it's NOT the BIOS setting!) and reboot windows and linux twice for voodo reasons.
Offline
The problem also occurs with regular kernel.
I cannot send the log without starting ConnMan to use the wired connection.
No Windows installed. I have a ntfs partition to only store personal files.
I did not reformat it to ext4 because I cannot backup data.
I have another distribution called neon unstable, based on Ubuntu 22.04, installed on this laptop.
The wifi works well on it. Even the airplane mode.
Offline
I cannot send the log without starting ConnMan to use the wired connection.
No, but you can draw it. Dup it into a file and upload that afterwards.
I have another distribution called neon unstable
Which is hopefully not hibernating?
Offline
Hibernation feature is not available on my neon unstable.
After disabling hostapd, I'm able to connect with wpa_supplicant and iwd manually.
ConnMan is still not working as expected. Now it finds the wi-fi networks but it does not autoconnect after login regardless the used backend - iwd or wpa-supplicant. This error occurs with connman_iwd.service:
○ connman_iwd.service - Connection service
Loaded: error (Reason: Unit connman_iwd.service failed to load properly, please adjust/correct and reload service manager: File exists)
Active: inactive (dead)
mar 20 20:24:46 arch-laptop systemd[1]: connman_iwd.service: Two services allocated for the same bus name net.connman, refusing operation.
Edit:
I'm using CMST GUI, I get this error when trying to enable autoconnection:
We received a DBUS reply message indicating an error.
Error Name: net.connman.Error.InvalidService
Error Message: Invalid service
Edit2:
I edited my profille in the terminal, now the wifi autoconnects after boot but I cannot connect with connmanctl:
connmanctl> connect wifi_0cd292b54e33_35364b627073_managed_psk
Error /net/connman/service/wifi_0cd292b54e33_35364b627073_managed_psk: In progress
Error /net/connman/service/wifi_0cd292b54e33_35364b627073_managed_psk: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
connmanctl> connect wifi_0cd292b54e33_35364b627073_managed_psk
Error /net/connman/service/wifi_0cd292b54e33_35364b627073_managed_psk: In progress
connmanctl> connect wifi_0cd292b54e33_35364b627073_managed_psk
Error /net/connman/service/wifi_0cd292b54e33_35364b627073_managed_psk: Protocol driver not attached
connmanctl> connect wifi_0cd292b54e33_35364b627073_managed_psk
Error /net/connman/service/wifi_0cd292b54e33_35364b627073_managed_psk: Input/output error
Last edited by Strangiato (2023-03-21 01:11:19)
Offline
Post an updated system journal.
You've to understand that you cannot just use mutiple tools (eg. wpa_supplicant and iwd) on the same NIC at the same time ("connman_iwd.service: Two services allocated for the same bus name net.connman, refusing operation" looks worrysome)
Running an AP at all or even in parallel and ony any frequency isn't a given feature, https://wiki.archlinux.org/title/Software_access_point
Google your NIC (PCI ID) itr. but from the FW crashes, the answer is likely "no".
Offline
I'm not using wpa_supplicant and iwd at the same time. I'm testing them individually. I mask the wpa_supplicant service before testing ConnMan + iwd or iwd, and I stop/disable iwd service before testing wpa_supplicant.
Here are logs, separate this time, when connecting manually, without ConnMan:
wpa_supplicant (apparently it connects - no error. But there is no connectivity, cannot ping URLs):
http://0x0.st/H-kL.txt
iwd (it connects and there is connectivity):
http://0x0.st/H-kp.txt
Last edited by Strangiato (2023-03-21 11:19:05)
Offline
wpa_supplicant alone won't get you a lease, only a carrier - you'll still have to run dhcpcd.
There're no errors in the log.
iwd will get you a lease if you've https://wiki.archlinux.org/title/Iwd#En … figuration - but that'll possibly clash w/ connman and other high-level services.
If you disable everything else, do you get connection and lease w/ wifi-menu from netctl?
Does that allow you to toggle rfkill on the chip?
(Which is the "airplane" mode, even in a submarine)
Offline
I get connection and connectivity with wifi-menu and netctl. And the airplane mode works.
Offline
So it's not the HW itself.
Assumign the original cause was hostap, try connman (or possibly even NM) again, make sure there're no conflicting services.
Offline
Results:
NM + iwd: wifi connects, but the airplane mode is still not working.
The laptop just disconnects and then immediately reconnects.
NM + wpa_supplicant: same as NM + iwd
ConnMan + iwd: wifi connects, CMST GUI shows error messages when I activate
the airplane mode and I cannot reconnect by disabling the airplane mode.
ConnMan + wpa_supplicant: wifi connects, wifi disconnects when I activate the airplane mode but it does not reconnect when deactivating the airplane mode. No error message this time.
Offline
CMST GUI shows error messages when I activate the airplane mode
Skip the GUI and forget about "airplanes" - can you use rfkill to control the radio?
(Also use rfkill to check that)
Offline
Now I'm using NM + iwd and again the laptop just disconnects and then immediately reconnects after this command
rfkill block all
Last edited by Strangiato (2023-03-21 21:52:48)
Offline
Journal?
What about connman?
Otherwise
I get connection and connectivity with wifi-menu and netctl. And the airplane mode works.
- the less "sophisticated", the more functional
Offline
journal after activating airplane mode:
Offline
iwd is still configured for network configuration and will thus clash w/ NM.
How's the behavior w/ wpa_supplicant?
What's notable is that the radio gets disabled, then gnome-software throws a tantrum and then the radio gets enabled, there's no real failure.
I'd bet on the iwd/NM collision, but would not put it beyond gnome-software to enable the radio to download more flatpaks… so kill/disable that as well.
Offline
I have uninstalled gnome-software.
Here is the log with NM + wpa_supplicant after reboot.
The behavior is the same: wifi disconnects and then immediately reconnects.
Offline
mar 22 10:02:04 arch-laptop wpa_supplicant[464]: rfkill: WLAN hard blocked
mar 22 10:02:04 arch-laptop wpa_supplicant[464]: rfkill: WLAN hard blocked
Are you talking about "airplane mode" all the time because you're causing this w/ some physical key/button/switch?
Offline
yes, I'm pressing the special keyboard key used to activate/deactivate the airplane mode.
The same behavior (disconnection and immediate reconnection) happens after running
rfkill block all
Offline