LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-21-2008, 02:19 PM   #16
Ilgar
Senior Member
 
Registered: Jan 2005
Location: Istanbul, Turkey
Distribution: Slackware64 15.0, Slackwarearm 14.2
Posts: 1,157

Original Poster
Rep: Reputation: 237Reputation: 237Reputation: 237

Here they are. First, the console output:
Code:
   
root@kutu:~# /etc/rc.d/rc.inet1 wlan0_start
Error for wireless request "Set Nickname" (8B1C) :
    SET failed on device wlan0 ; Operation not supported.
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Polling for DHCP server on interface wlan0:
dhcpcd: MAC address = 00:1a:73:66:6b:b9
And the logs:

Code:
Apr 21 22:00:13 kutu logger: /etc/rc.d/rc.inet1:  List of interfaces: 'eth0 eth1 eth2 eth3 wlan0 eth5'
Apr 21 22:00:16 kutu logger: /etc/rc.d/rc.inet1:  /sbin/iwconfig wlan0 nick kutu
Apr 21 22:00:16 kutu logger: /etc/rc.d/rc.inet1:  /sbin/iwconfig wlan0 essid "AIRTIES_RT-205"
Apr 21 22:00:17 kutu logger: /etc/rc.d/rc.inet1:  wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -Dwext -iwlan0
Apr 21 22:00:22 kutu logger: /etc/rc.d/rc.inet1:  /sbin/dhcpcd -d -t 30  wlan0
This is the part coming after the console command above. I didn't edit out the key, it doesn't appear to be there. Here is the conf file I used:

Code:
DEBUG_ETH_UP="yes"

IFNAME[4]="wlan0"
IPADDR[4]=""
NETMASK[4]=""
USE_DHCP[4]="yes"
WLAN_ESSID[4]=AIRTIES_RT-205
WLAN_KEY[4]="edited"
WLAN_WPA[4]="wpa_supplicant"
WLAN_WPADRIVER[4]="wext"
WLAN_WPAWAIT[4]=30
Interestingly, if I run the commands in the logs manually, I get the following in the console:

Code:
root@kutu:~# killall dhcpcd
root@kutu:~# killall wpa_supplicant 
root@kutu:~# /sbin/iwconfig wlan0 nick kutu
Error for wireless request "Set Nickname" (8B1C) :
    SET failed on device wlan0 ; Operation not supported.
root@kutu:~# /sbin/iwconfig wlan0 essid "AIRTIES_RT-205"
root@kutu:~# wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -Dwext -iwlan0
root@kutu:~# /sbin/dhcpcd -d -t 30  wlan0
dhcpcd: MAC address = 00:1a:73:66:6b:b9
dhcpcd: your IP address = 192.168.2.6
So it works. By the way, the commands return immediately, so the wpa wait time should be fine. Also, as I pointed out earlier, that nickname setting error goes away if I uncomment the relevant line in rc.wireless, but otherwise the problem persists.
 
Old 04-21-2008, 02:41 PM   #17
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Is there anything else in your logs (messages, syslog, debug) around "Apr 21 22:00:22" that shows what's happening? It must be a timing issue of some kind.

Eric
 
Old 04-21-2008, 02:51 PM   #18
Ilgar
Senior Member
 
Registered: Jan 2005
Location: Istanbul, Turkey
Distribution: Slackware64 15.0, Slackwarearm 14.2
Posts: 1,157

Original Poster
Rep: Reputation: 237Reputation: 237Reputation: 237
Here are the logs. The ones prior to the time you gave are from my earlier tries. The bold lines are the first entries after the command was run.

/var/log/messages:
Code:
Apr 21 21:58:19 kutu kernel: b43-phy0: Loading firmware version 410.2160 (2007-05-26 15:32:10)
Apr 21 21:59:34 kutu logger: /etc/rc.d/rc.inet1:  List of interfaces: 'eth0 eth1 eth2 eth3 wlan0 eth5'
Apr 21 21:59:34 kutu logger: /etc/rc.d/rc.inet1:  /sbin/dhcpcd -k -d wlan0
Apr 21 22:00:13 kutu logger: /etc/rc.d/rc.inet1:  List of interfaces: 'eth0 eth1 eth2 eth3 wlan0 eth5'
Apr 21 22:00:13 kutu kernel: b43-phy0: Loading firmware version 410.2160 (2007-05-26 15:32:10)
Apr 21 22:00:16 kutu logger: /etc/rc.d/rc.inet1:  /sbin/iwconfig wlan0 nick kutu
Apr 21 22:00:16 kutu logger: /etc/rc.d/rc.inet1:  /sbin/iwconfig wlan0 essid "AIRTIES_RT-205"
Apr 21 22:00:17 kutu logger: /etc/rc.d/rc.inet1:  wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -Dwext -iwlan0
Apr 21 22:00:17 kutu kernel: b43-phy0: Loading firmware version 410.2160 (2007-05-26 15:32:10)
Apr 21 22:00:22 kutu logger: /etc/rc.d/rc.inet1:  /sbin/dhcpcd -d -t 30  wlan0
Apr 21 22:00:22 kutu kernel: b43-phy0: Loading firmware version 410.2160 (2007-05-26 15:32:10)
Apr 21 22:07:35 kutu kernel: b43-phy0: Loading firmware version 410.2160 (2007-05-26 15:32:10)
/var/log/syslog. This one shows a DHCP server timeout:
Code:
Apr 21 21:57:42 kutu dhcpcd[24715]: timed out waiting for a valid DHCP server response 
Apr 21 21:58:49 kutu dhcpcd[24890]: timed out waiting for a valid DHCP server response 
Apr 21 22:00:52 kutu dhcpcd[25025]: timed out waiting for a valid DHCP server response 
Apr 21 22:07:56 kutu dhcpcd[25145]: terminating on signal 2 
Apr 21 22:09:50 kutu dhcpcd[24604]: terminating on signal 15
/var/log/debug

Code:
Apr 21 21:59:35 kutu kernel: wlan0: deauthenticate(reason=3)
Apr 21 22:00:14 kutu kernel: b43-phy0 debug: Chip initialized
Apr 21 22:00:14 kutu kernel: b43-phy0 debug: 64-bit DMA initialized
Apr 21 22:00:14 kutu kernel: b43-phy0 debug: Wireless interface started
Apr 21 22:00:14 kutu kernel: b43-phy0 debug: Adding Interface type 2
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: Removing Interface type 2
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: Wireless interface stopped
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: DMA-64 0x0200 (RX) max used slots: 1/64
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: DMA-64 0x0340 (TX) max used slots: 0/128
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: DMA-64 0x0300 (TX) max used slots: 0/128
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: DMA-64 0x02C0 (TX) max used slots: 0/128
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: DMA-64 0x0280 (TX) max used slots: 0/128
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: DMA-64 0x0240 (TX) max used slots: 2/128
Apr 21 22:00:16 kutu kernel: b43-phy0 debug: DMA-64 0x0200 (TX) max used slots: 0/128
Apr 21 22:00:19 kutu kernel: b43-phy0 debug: Chip initialized
Apr 21 22:00:19 kutu kernel: b43-phy0 debug: 64-bit DMA initialized
Apr 21 22:00:19 kutu kernel: b43-phy0 debug: Wireless interface started
Apr 21 22:00:19 kutu kernel: b43-phy0 debug: Adding Interface type 2
Apr 21 22:00:19 kutu kernel: wlan0: Initial auth_alg=0
Apr 21 22:00:19 kutu kernel: wlan0: authenticate with AP 00:1a:2a:a6:b3:31
Apr 21 22:00:19 kutu kernel: wlan0: RX authentication from 00:1a:2a:a6:b3:31 (alg=0 transaction=2 status=0)
Apr 21 22:00:19 kutu kernel: wlan0: authenticated
Apr 21 22:00:19 kutu kernel: wlan0: associate with AP 00:1a:2a:a6:b3:31
Apr 21 22:00:19 kutu kernel: wlan0: RX AssocResp from 00:1a:2a:a6:b3:31 (capab=0x471 status=0 aid=1)
Apr 21 22:00:19 kutu kernel: wlan0: associated
Apr 21 22:00:19 kutu kernel: wlan0: switched to short barker preamble (BSSID=00:1a:2a:a6:b3:31)
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: Removing Interface type 2
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: Wireless interface stopped
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: DMA-64 0x0200 (RX) max used slots: 1/64
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: DMA-64 0x0340 (TX) max used slots: 0/128
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: DMA-64 0x0300 (TX) max used slots: 0/128
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: DMA-64 0x02C0 (TX) max used slots: 0/128
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: DMA-64 0x0280 (TX) max used slots: 0/128
Apr 21 22:00:22 kutu kernel: b43-phy0 debug: DMA-64 0x0240 (TX) max used slots: 2/128
Apr 21 22:00:23 kutu kernel: b43-phy0 debug: Chip initialized
Apr 21 22:00:23 kutu kernel: b43-phy0 debug: 64-bit DMA initialized
Apr 21 22:00:23 kutu kernel: b43-phy0 debug: Wireless interface started
Apr 21 22:00:23 kutu kernel: b43-phy0 debug: Adding Interface type 2
Apr 21 22:00:23 kutu dhcpcd[25025]: broadcasting DHCP_DISCOVER 
Apr 21 22:00:24 kutu kernel: wlan0: switched to short barker preamble (BSSID=00:1a:2a:a6:b3:31)
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: Removing Interface type 2
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: Wireless interface stopped
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: DMA-64 0x0200 (RX) max used slots: 1/64
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: DMA-64 0x0340 (TX) max used slots: 0/128
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: DMA-64 0x0300 (TX) max used slots: 0/128
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: DMA-64 0x02C0 (TX) max used slots: 0/128
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: DMA-64 0x0280 (TX) max used slots: 0/128
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: DMA-64 0x0240 (TX) max used slots: 0/128
Apr 21 22:00:52 kutu kernel: b43-phy0 debug: DMA-64 0x0200 (TX) max used slots: 0/128
Apr 21 22:07:36 kutu kernel: b43-phy0 debug: Chip initialized
Apr 21 22:07:36 kutu kernel: b43-phy0 debug: 64-bit DMA initialized
Edit: My first post also has the dmesg logs of a successful and unsuccessful connection attempt.

Last edited by Ilgar; 04-21-2008 at 02:53 PM.
 
Old 04-21-2008, 03:00 PM   #19
Ilgar
Senior Member
 
Registered: Jan 2005
Location: Istanbul, Turkey
Distribution: Slackware64 15.0, Slackwarearm 14.2
Posts: 1,157

Original Poster
Rep: Reputation: 237Reputation: 237Reputation: 237
One more thing: If I do

Code:
root@kutu:~# /sbin/iwconfig wlan0 nick kutu ; /sbin/iwconfig wlan0 essid "AIRTIES_RT-205" ; wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -Dwext -iwlan0 ; /sbin/dhcpcd -d -t 30  wlan0
Error for wireless request "Set Nickname" (8B1C) :
    SET failed on device wlan0 ; Operation not supported.
dhcpcd: MAC address = 00:1a:73:66:6b:b9
dhcpcd: your IP address = 192.168.2.6
then as you see I can get an address, but unlike when running the commands one by one, the last line (with the IP address) appears about 4-5 seconds after the MAC address. When I run them one by one the IP is displayed immediately.
 
Old 04-28-2008, 04:23 AM   #20
Ilgar
Senior Member
 
Registered: Jan 2005
Location: Istanbul, Turkey
Distribution: Slackware64 15.0, Slackwarearm 14.2
Posts: 1,157

Original Poster
Rep: Reputation: 237Reputation: 237Reputation: 237
Issue solved (but I don't understand why)

Hi all,

I was out of town, away from my computer recently. Today I managed to solve this problem by putting a DHCP_TIMEOUT value in rc.inet1.conf. A value as low as 2 does the job. So, obviously the problem is not an actual DHCP timeout issue (Slack tries with 10 seconds at least).

Setting an explicit timeout value makes a difference in this part of the rc.inet1 script:

Code:
        if [ "${DHCP_TIMEOUT[$i]}" = "" ]; then
          ifconfig ${1} up && sleep 1
          CONNSTATUS="$(cat /sys/class/net/${1}/carrier 2> /dev/null)"
         ifconfig ${1} down
         echo "CONNSTATUS= $CONNSTATUS"
          if [ "$CONNSTATUS" = "0" ]; then
            # The kernel has just told us the cable isn't even plugged in, but we will  
            # give any DHCP server a short chance to reply anyway:
            echo "No carrier detected on ${1}.  Reducing DHCP timeout to 10 seconds."
            DHCP_TIMEOUT[$i]=10
          fi
        fi
        # 30 seconds should be a reasonable default DHCP timeout.  60 was too much.  :-)
        echo "/etc/rc.d/rc.inet1:  /sbin/dhcpcd -d -t ${DHCP_TIMEOUT[$i]:-30} ${DHCP_OPTIONS} ${1}" | $LOGGER
        /sbin/dhcpcd -d -t ${DHCP_TIMEOUT[$i]:-30} ${DHCP_OPTIONS} ${1}
So, it's the if at the beginning that gets skipped if I set an explicit timeout.

Then I tried to simulate this in the console. I inserted ifconfig up/down commands before the dhcpcd call. The following one works:

Code:
root@kutu:/usr/src/linux# killall wpa_supplicant && killall dhcpcd
root@kutu:/usr/src/linux# /sbin/iwconfig wlan0 nick kutu ; /sbin/iwconfig wlan0 essid "AIRTIES_RT-205" ; wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -Dwext -iwlan0 ; ifconfig wlan0 up; ifconfig wlan0 down; /sbin/dhcpcd -d -t 30  wlan0
Error for wireless request "Set Nickname" (8B1C) :
    SET failed on device wlan0 ; Operation not supported.
dhcpcd: MAC address = 00:1a:73:66:6b:b9
dhcpcd: your IP address = 192.168.2.6
There is a delay of 3-4 seconds between the last two lines, but it works. However, this one doesn't work:

Code:
/sbin/iwconfig wlan0 nick kutu ; /sbin/iwconfig wlan0 essid "AIRTIES_RT-205" ; wpa_supplicant -Bw -c/etc/wpa_supplicant.conf -Dwext -iwlan0 ; ifconfig wlan0 up; sleep 1; ifconfig wlan0 down; /sbin/dhcpcd -d -t 30  wlan0
The only difference is that I added that "sleep 1" between the ifconfigs. There is a "sleep 1" there in the rc.inet1 script, so this is a better simulation of rc.inet1. A bigger sleep doesn't change anything. Adding another sleep before the dhcpcd call doesn't help either. Removing the "sleep 1" part in rc.inet1 also didn't help.

Earlier, I have tried adding/modifiying countless sleep calls here and there, trying to give the thing the extra time where I thought it choked, but I'm a bit surprised that the solution was to stay away from sleeps .

Edit: Btw, I'm aware of bstrik's "sleep 3" fix; but that didn't help me.

Last edited by Ilgar; 04-28-2008 at 04:54 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
slow startup because of rc.inet1 / wireless pmdkh Slackware 7 04-02-2008 06:20 PM
configuring rt61 wireless in rc.inet1 Widgeteye Slackware 2 09-26-2007 04:28 AM
How to configure wireless with rc.inet1.conf Murkhadh Linux - Wireless Networking 2 02-17-2007 10:28 AM
Slackware 9.1 Rc.inet1 help Psyman014 Slackware 3 10-03-2003 08:10 AM
rc.inet1 to start PFTPD on sys boot bripage Linux - Networking 0 04-01-2002 03:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:32 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration