[SOLVED] Problems with wpa_supplicant and rc.inet1 on Slackware x86_64 -current
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Starting the network interfaces...
Successfully initialized wpa_supplicant
wlan1: polling for DHCP server
wlan1: waiting for carrier
wlan1: carrier acquired
wlan1: connected to Access Point `MyNetworkAP'
DUID 00:04:35:30:45:35:34:39:33:35:32:30:42:43:ff:ff:ff:ff
wlan1: IAID d5:fd:dc:b6
wlan1: soliciting a DHCP lease
wlan1: offered 192.168.1.185 from 192.168.1.1
wlan1: probing address 192.168.1.185/24
timed out
dhcpcd exited
The /var/log/messages says:
Code:
Mar 21 21:33:07 darkstar rc.inet1[14024]: wlan1: configuring interface
Mar 21 21:33:11 darkstar root: /etc/rc.d/rc.inet1: wpa_supplicant -B -c/etc/wpa_supplicant.conf -Dnl80211 -iwlan1
Mar 21 21:33:19 darkstar kernel: wlan1: authenticate with 1c:3b:f3:86:be:99
Mar 21 21:33:19 darkstar kernel: wlan1: send auth to 1c:3b:f3:86:be:99 (try 1/3)
Mar 21 21:33:19 darkstar kernel: wlan1: authenticated
Mar 21 21:33:19 darkstar kernel: wlan1: associate with 1c:3b:f3:86:be:99 (try 1/3)
Mar 21 21:33:19 darkstar kernel: wlan1: associate with 1c:3b:f3:86:be:99 (try 2/3)
Mar 21 21:33:19 darkstar kernel: wlan1: RX AssocResp from 1c:3b:f3:86:be:99 (capab=0x411 status=0 aid=2)
Mar 21 21:33:19 darkstar kernel: wlan1: associated
Mar 21 21:33:19 darkstar kernel: IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready
Mar 21 21:33:19 darkstar kernel: wlan1: deauthenticating from 1c:3b:f3:86:be:99 by local choice (Reason: 3=DEAUTH_LEAVING)
Mar 21 21:33:24 darkstar rc.inet1[14024]: wlan1: starting dhcpcd
Mar 21 21:33:24 darkstar dhcpcd[14191]: wlan1: waiting for carrier
Mar 21 21:33:31 darkstar kernel: wlan1: authenticate with 1c:3b:f3:86:b1:01
Mar 21 21:33:32 darkstar kernel: wlan1: send auth to 1c:3b:f3:86:b1:01 (try 1/3)
Mar 21 21:33:32 darkstar kernel: wlan1: authenticated
Mar 21 21:33:32 darkstar kernel: wlan1: associate with 1c:3b:f3:86:b1:01 (try 1/3)
Mar 21 21:33:32 darkstar kernel: wlan1: associate with 1c:3b:f3:86:b1:01 (try 2/3)
Mar 21 21:33:32 darkstar kernel: wlan1: RX AssocResp from 1c:3b:f3:86:b1:01 (capab=0x411 status=0 aid=3)
Mar 21 21:33:32 darkstar kernel: wlan1: associated
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: carrier acquired
Mar 21 21:33:32 darkstar kernel: IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: connected to Access Point `MyNetworkAP'
Mar 21 21:33:32 darkstar dhcpcd[14191]: DUID 00:04:35:30:45:35:34:39:33:35:32:30:42:43:ff:ff:ff:ff
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: IAID d5:fd:dc:b6
Mar 21 21:33:33 darkstar dhcpcd[14191]: wlan1: soliciting a DHCP lease
Mar 21 21:33:37 darkstar dhcpcd[14191]: wlan1: offered 192.168.1.185 from 192.168.1.1
Mar 21 21:33:37 darkstar dhcpcd[14191]: wlan1: probing address 192.168.1.185/24
Mar 21 21:33:39 darkstar dhcpcd[14191]: dhcpcd exited
Mar 21 21:33:39 darkstar rc.inet1[14024]: wlan1: failed to obtain DHCP lease
Mar 21 21:33:38 darkstar kernel: wlan1: deauthenticating from 1c:3b:f3:86:b1:01 by local choice (Reason: 3=DEAUTH_LEAVING)
The odd part is that if I just open a terminal and call wpa_supplicant with the exact command as rc.inet1 uses and then call dhclient wlan1 or dhcpcd everything just works...
How are you running dhcpcd or dhclient? Are you giving them a timeout option? From what you posted it looks like it is timing out when trying to get a dhcp lease.
I don't think this changed with the update, and the default should be 15 seconds, but maybe it needs more time.
I think the default timeout interval for dhcpcd is 30 seconds, and 60 seconds for dhclient.
If this doesn't work try setting:
DHCP_DEBUG[4]="yes"
and maybe
DEBUG_ETH_UP="yes"
to see if that helps give more information.
Starting the network interfaces...
Successfully initialized wpa_supplicant
wlan1: polling for DHCP server
wlan1: waiting for carrier
wlan1: carrier acquired
wlan1: connected to Access Point `MyNetworkAP'
DUID 00:04:35:30:45:35:34:39:33:35:32:30:42:43:ff:ff:ff:ff
wlan1: IAID d5:fd:dc:b6
wlan1: soliciting a DHCP lease
wlan1: offered 192.168.1.185 from 192.168.1.1
wlan1: probing address 192.168.1.185/24
timed out
dhcpcd exited
The /var/log/messages says:
Code:
Mar 21 21:33:07 darkstar rc.inet1[14024]: wlan1: configuring interface
Mar 21 21:33:11 darkstar root: /etc/rc.d/rc.inet1: wpa_supplicant -B -c/etc/wpa_supplicant.conf -Dnl80211 -iwlan1
Mar 21 21:33:19 darkstar kernel: wlan1: authenticate with 1c:3b:f3:86:be:99
Mar 21 21:33:19 darkstar kernel: wlan1: send auth to 1c:3b:f3:86:be:99 (try 1/3)
Mar 21 21:33:19 darkstar kernel: wlan1: authenticated
Mar 21 21:33:19 darkstar kernel: wlan1: associate with 1c:3b:f3:86:be:99 (try 1/3)
Mar 21 21:33:19 darkstar kernel: wlan1: associate with 1c:3b:f3:86:be:99 (try 2/3)
Mar 21 21:33:19 darkstar kernel: wlan1: RX AssocResp from 1c:3b:f3:86:be:99 (capab=0x411 status=0 aid=2)
Mar 21 21:33:19 darkstar kernel: wlan1: associated
Mar 21 21:33:19 darkstar kernel: IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready
Mar 21 21:33:19 darkstar kernel: wlan1: deauthenticating from 1c:3b:f3:86:be:99 by local choice (Reason: 3=DEAUTH_LEAVING)
Mar 21 21:33:24 darkstar rc.inet1[14024]: wlan1: starting dhcpcd
Mar 21 21:33:24 darkstar dhcpcd[14191]: wlan1: waiting for carrier
Mar 21 21:33:31 darkstar kernel: wlan1: authenticate with 1c:3b:f3:86:b1:01
Mar 21 21:33:32 darkstar kernel: wlan1: send auth to 1c:3b:f3:86:b1:01 (try 1/3)
Mar 21 21:33:32 darkstar kernel: wlan1: authenticated
Mar 21 21:33:32 darkstar kernel: wlan1: associate with 1c:3b:f3:86:b1:01 (try 1/3)
Mar 21 21:33:32 darkstar kernel: wlan1: associate with 1c:3b:f3:86:b1:01 (try 2/3)
Mar 21 21:33:32 darkstar kernel: wlan1: RX AssocResp from 1c:3b:f3:86:b1:01 (capab=0x411 status=0 aid=3)
Mar 21 21:33:32 darkstar kernel: wlan1: associated
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: carrier acquired
Mar 21 21:33:32 darkstar kernel: IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: connected to Access Point `MyNetworkAP'
Mar 21 21:33:32 darkstar dhcpcd[14191]: DUID 00:04:35:30:45:35:34:39:33:35:32:30:42:43:ff:ff:ff:ff
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: IAID d5:fd:dc:b6
Mar 21 21:33:33 darkstar dhcpcd[14191]: wlan1: soliciting a DHCP lease
Mar 21 21:33:37 darkstar dhcpcd[14191]: wlan1: offered 192.168.1.185 from 192.168.1.1
Mar 21 21:33:37 darkstar dhcpcd[14191]: wlan1: probing address 192.168.1.185/24
Mar 21 21:33:39 darkstar dhcpcd[14191]: dhcpcd exited
Mar 21 21:33:39 darkstar rc.inet1[14024]: wlan1: failed to obtain DHCP lease
Mar 21 21:33:38 darkstar kernel: wlan1: deauthenticating from 1c:3b:f3:86:b1:01 by local choice (Reason: 3=DEAUTH_LEAVING)
The odd part is that if I just open a terminal and call wpa_supplicant with the exact command as rc.inet1 uses and then call dhclient wlan1 or dhcpcd everything just works...
I'd appreciate any suggestion about this.
Thanks!
I had the same problem after the update that modified rc.inet1.conf. I checked the diff between the old and the new rc.inet1.conf and ensured it didn't remove any of my settings which it didn't. Not long after that update I lost my connection. So I ran
Code:
/etc/rc.d/rc.inet1 wlan0_restart
and it timed out. I double checked rc.inet1.conf and also checked wpa_supplicant.conf and none of my settings had been overwritten. So I ran it again and this time it worked. I rebooted just to make sure it would stick which it did and it's been fine ever since.
This seems fine; though, as suggested by others, you could try increasing the DHCP timeout, for example:
Code:
DHCP_TIMEOUT[4]="120"
Quote:
Originally Posted by pakcjo
Code:
<snip>
wlan1: probing address 192.168.1.185/24
timed out
dhcpcd exited
and
Quote:
Originally Posted by pakcjo
Code:
<snip>
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: connected to Access Point `MyNetworkAP'
Mar 21 21:33:32 darkstar dhcpcd[14191]: DUID 00:04:35:30:45:35:34:39:33:35:32:30:42:43:ff:ff:ff:ff
Mar 21 21:33:32 darkstar dhcpcd[14191]: wlan1: IAID d5:fd:dc:b6
Mar 21 21:33:33 darkstar dhcpcd[14191]: wlan1: soliciting a DHCP lease
Mar 21 21:33:37 darkstar dhcpcd[14191]: wlan1: offered 192.168.1.185 from 192.168.1.1
Mar 21 21:33:37 darkstar dhcpcd[14191]: wlan1: probing address 192.168.1.185/24
Mar 21 21:33:39 darkstar dhcpcd[14191]: dhcpcd exited
Mar 21 21:33:39 darkstar rc.inet1[14024]: wlan1: failed to obtain DHCP lease
Mar 21 21:33:38 darkstar kernel: wlan1: deauthenticating from 1c:3b:f3:86:b1:01 by local choice (Reason: 3=DEAUTH_LEAVING)
both suggest that it is a DHCP timeout causing the failure, rather than rc.inet1 - wpa_supplicant has authenticated to the access point, and DHCP started successfully. dhcpcd then does the IP config, which is where it fails on the second phase of the configuration where it asks the DHCP server to authorise the lease of the IP address offered to it.
Quote:
Originally Posted by pakcjo
The odd part is that if I just open a terminal and call wpa_supplicant with the exact command as rc.inet1 uses and then call dhclient wlan1 or dhcpcd everything just works...
This could indicate that the DHCP server isn't serving the lease fast enough for dhcpcd to obtain it.
The DHCP_TIMEOUT command I suggested above should help with that.
I wouldn't recommend using dhclient as that's not supported by rc.inet1 - dhcpcd is the standard util to configure DHCP on Slackware.
I don't think this changed with the update, and the default should be 15 seconds, but maybe it needs more time.
No, nothing changed with the configuration of wlan interfaces or DHCP changed with the most recent update, so I'm unsure what is causing pakjo's problens...
Quote:
Originally Posted by kaott
I think the default timeout interval for dhcpcd is 30 seconds
The default timeout is overridden by rc.inet1 and set to 15 seconds by default; but can be increased if the DHCP server is a bit slow; which is what I believe is happening here.
Quote:
Originally Posted by kaott
If this doesn't work try setting:
DHCP_DEBUG[4]="yes"
and maybe
DEBUG_ETH_UP="yes"
to see if that helps give more information.
Good suggestion. With DEBUG_ETH_UP set, EVERY command that is run is output to the log, so you'll be able to see exactly how rc.inet1 configured the interface, and what failed where.
Hello, increasing the timeout of the dhcp as Tadgy suggested seems to have solved the issue. I changed both the WLAN_WPAWAIT[4] and DHCP_TIMEOUT[4] to 60.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.