You are not logged in.
For the last several versions of iwd, my laptop is unable to roam successfully.
It happens whenever I switch networks.
Both if I leave my laptop open (e.g. unplug my home wifi router and turn on my phone hotspot), or when I close the lid and go to a friend's house.
Here is a short section from journalctl -b0 -u iwd.service.
It includes a set of detaching and reattaching while I am at my house, it successfully reattaches when I open the lid from sleep.
You can see this cycle in the journalctl output.
Then, when I e.g. close the lid and go to to my friend's, it gets stuck at "DHCP_STATE_SELECTING" on the connection.
My nic gets an IPv6 link-local (fe80:) address when stuck in the "DHCP_STATE_SELECTING" state, but I also have "EnableIPv6=false" as you can see below.
Further, my /etc/resolv.conf file has been cleared by this point, but no DNS servers have been updated by openresolv.
It makes sense to me that openresolv would need an IP to query and/or assign a DNS server.
When I manually "systemctl restart iwd.service", it recovers and connects successfully to the new network.
Then when I go home, I have to complete the dance all over again.
journalctl:
Jul 10 07:32:57 my_host iwd[451]: [DHCPv4] dhcp_client_rx_message:915 Entering state: DHCP_STATE_BOUND
Jul 10 07:32:57 my_host iwd[451]: [DHCPv4] dhcp_client_rx_message:948 T1 expiring in 43200730 ms
Jul 10 17:36:43 my_host iwd[451]: Received Deauthentication event, reason: 4, from_ap: false
Jul 10 17:36:43 my_host iwd[451]: [DHCPv4] l_dhcp_client_stop:1264 Entering state: DHCP_STATE_INIT
Jul 10 17:38:08 my_host iwd[451]: [DHCPv4] l_dhcp_client_start:1219 Entering state: DHCP_STATE_SELECTING
Jul 10 17:38:08 my_host iwd[451]: [DHCPv4] dhcp_client_handle_offer:811 Entering state: DHCP_STATE_REQUESTING
Jul 10 17:38:08 my_host iwd[451]: [DHCPv4] dhcp_client_rx_message:915 Entering state: DHCP_STATE_BOUND
Jul 10 17:38:08 my_host iwd[451]: [DHCPv4] dhcp_client_rx_message:948 T1 expiring in 43200610 ms
Jul 11 06:29:44 my_host iwd[451]: Received Deauthentication event, reason: 3, from_ap: false
Jul 11 06:29:44 my_host iwd[451]: [DHCPv4] l_dhcp_client_stop:1264 Entering state: DHCP_STATE_INIT
Jul 11 06:29:46 my_host iwd[451]: [DHCPv4] l_dhcp_client_start:1219 Entering state: DHCP_STATE_SELECTING
Jul 11 06:29:46 my_host iwd[451]: [DHCPv4] dhcp_client_handle_offer:811 Entering state: DHCP_STATE_REQUESTING
Jul 11 06:29:46 my_host iwd[451]: [DHCPv4] dhcp_client_rx_message:915 Entering state: DHCP_STATE_BOUND
Jul 11 06:29:46 my_host iwd[451]: [DHCPv4] dhcp_client_rx_message:948 T1 expiring in 43199751 ms
Jul 11 07:16:18 my_host iwd[451]: Received Deauthentication event, reason: 3, from_ap: false
Jul 11 07:16:18 my_host iwd[451]: [DHCPv4] l_dhcp_client_stop:1264 Entering state: DHCP_STATE_INIT
Jul 11 07:16:25 my_host iwd[451]: EAP completed with eapSuccess
Jul 11 07:16:25 my_host iwd[451]: [DHCPv4] l_dhcp_client_start:1219 Entering state: DHCP_STATE_SELECTINGI have searched this time and again over the last several months (I don't remember exactly when this issue started---it used to work perfectly) when I get a spare moment, but I have not found anything similar to the behavior I see.
I resigned myself to needing to restart the iwd.service everytime I take my laptop anywhere, thinking maybe there was an old config somewhere from my previous networking stack that I had failed to turn off.
But after a failed hard drive last week, and the "opportunity" to install fresh, iwd and openresolv are the only networking programs I have installed, and I have made sure all "systemd-network*" units are disabled.
Yet this behavior still persists.
I am using iwd with the following config:
[General]
EnableNetworkConfiguration=true
AddressRandomization=network
# AddressRandomizationRange=full (this is default)
[Network]
EnableIPv6=false
NameResolvingService=resolvconf
# RoutePriorityOffset=300
# [Scan]
# DisablePeriodicScan=true
# DisableRoamingScan=false
# note to self: [Settings] group in this file apparently does nothing
# [Settings]
# AutoConnect=true
# AlwaysRandomizeAddress=trueaccording to a forum post and a bug, I have this systemd override:
https://bbs.archlinux.org/viewtopic.php?id=258084
https://bugs.archlinux.org/task/67069
I have tried with and without RuntimeDirectory, and there is no discernible difference.
[Service]
ReadWritePaths=/etc/resolv.conf
ReadWritePaths=/etc/resolv.conf.bak
# RuntimeDirectory=resolvconfHere is what I have for my friend's wifi "ssid.psk":
[Security]
PreSharedKey=hash
Passphrase=passwd
SAE-PT-Group19=long_alpha_numeric
SAE-PT-Group20=longer_alpha_numeric
[Settings]
AutoConnect=true
AlwaysRandomizeAddress=trueI also use the same "[Settings]" section for all of my other network files, except for my home network.
home network:
[Security]
PreSharedKey=hash
Passphrase=my_wifi_passwd
SAE-PT-Group19=long_alpha_numeric
SAE-PT-Group20=longer_alpha_numeric
[Settings]
AutoConnect=true
AlwaysRandomizeAddress=falseI should add, this same behavior occurs when I go from one friend's house to the next.
In that case, the two "ssid.psk" files are the same regarding the [Settings] section, only differing in the hash, wifi_passwd, and alpha_numerics.
I want to try downgrading to an older iwd, to figure out if my configuration broke with a certain version change, but I wanted to verify something here first.
Because "iwd" depends on glibc, do I need to downgrade to a specific date to avoid breaking the whole system?
The other option is to just downgrade iwd and its dependencies alone.
If anyone can see right away how to get iwd properly roaming with "EnableNetworkConfiguration" I greatly appreciate the guidance.
Offline