LinuxQuestions.org
Review your favorite Linux distribution.
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 03-24-2006, 09:28 AM   #1
jb2006
LQ Newbie
 
Registered: Dec 2005
Location: England
Distribution: Slackware 10.2
Posts: 12

Rep: Reputation: 0
atheros madwifi wpa_supplicant troubles


ok this problem is really ticking me off now i've been trying to solve this for days but no luck. Ok im running windowmanager on slackware 10.2 with the default 2.4.x kernel.

I have an atheros wireless card and have installed wpa_supplicant and madwifi. I input the following in to the console:


sh-3.00# modprobe ath_pci
sh-3.00# wlanconfig ath0 create wlandev wifi0 wlanmode sta
ath0
sh-3.00# modprobe wlan_scan_sta
sh-3.00# ifconfig ath0 up
sh-3.00# iwconfig ath0
ath0 IEEE 802.11g ESSID:"" Nickname:""
Mode:Managed Frequency:2.462 GHz Access Point: 00:00:00:00:00:00
Bit Rate:0 kb/s Tx-Power:17 dBm Sensitivity=0/3
Retryff RTS thrff Fragment thrff
Encryption keyff
Power Managementff
Link Quality=0/94 Signal level=-95 dBm Noise level =-95 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0
sh-3.00# wlanconfig ath0 list scan
SSID BSSID CHAN RATE S:N INT CAPS
hell 00:11:50:39:af:f6 10 54M 56:0 100 EPSs WPA
sh-3.00# iwlist ath0 scan
ath0 Scan completed :
Cell 01 - Address: 00:11:50:39:AF:F6
ESSID:"hell"
Mode:Master
Frequency:2.457 GHz (Channel 10)
Quality=55/94 Signal level=-40 dBm Noise level=-95 dBm
Encryption keyn
Bit Rate:1 Mb/s
Bit Rate:2 Mb/s
Bit Rate:5.5 Mb/s
Bit Rate:6 Mb/s
Bit Rate:9 Mb/s
Bit Rate:11 Mb/s
Bit Rate:12 Mb/s
Bit Rate:18 Mb/s
Bit Rate:24 Mb/s
Bit Rate:36 Mb/s
Bit Rate:48 Mb/s
Bit Rate:54 Mb/s
Extra:bcn_int=100
Extra:wpa_ie=dsfy7s8 - long string cant bothered to type.

sh-3.00# iwconfig ath0 essid "hell"
sh-3.00# iwconfig ath0 ap 00:11:50:39:AF:F6
sh-3.00# pwd
/usr/src/wpa_supplicant-0.4.8
sh-3.00# cp defconfig .config

then i edited the following lines of .config in pico.

# Driver interface for madwifi driver
CONFIG_DRIVER_MADWIFI=y
# Change include directories to match with the local setup
CFLAGS += -I/usr/src/madwifi-ng
CONFIG_CTRL_IFACE=y

then i rebuilt wpa_supplicant because i built and installed it without those lines before.

sh-3.00# make clean
rm -f core *~ *.o *.d wpa_supplicant wpa_passphrase wpa_cli wpa_supplicant.exe wpa_cli.exe wpa_passphrase.exe win_if_list.exe
sh-3.00# make
- blah
- blah
- blah
- seems to build ok without errors.
sh-3.00# make install
mkdir -p /usr/local/sbin/
for i in wpa_supplicant wpa_passphrase wpa_cli; do cp $i /usr/local/sbin/$i; done
sh-3.00# wpa_passphrase "hell" "my wpa password" > /etc/wpa_supplicant.conf
sh-3.00# chmod 640 /etc/wpa_supplicant.conf

then inside the network={ } bit in the .conf file i appended this to it:

key_mgmt=WPA-PSK
proto=WPA
# proto=RSN

then i typed this:

sh-3.00# iwconfig ath0 nickname "James-Laptop"
sh-3.00# ifconfig ath0 up
sh-3.00# wpa_supplicant -dd -Dmadwifi -iath0 -c/etc/wpa_supplicant.conf

then it printed loads of stuff to the screen.

i cant copy and paste from console so i'll just type bits of it.

It prints

State: COMPLETED -> GROUP_HANDSHAKE
RTM_NEWLINK, IFLA_IFNAME: Interface 'ath0' added
Wireless even: cmd=0x8b19 len=12
Received 266 bytes of scan results (1 BSSes)
Selecting BSS from priority group 0
0: 00:11:50:39:af:f6 ssid='hell' wpa_ie_len=24 rsn_ie_len=0 caps=0x11
selected based on WPA IE
Already associated with the selected AP.

but i try pinging yahoo.co.uk and it doesn't do it.

i realised i havn't done dhclient thing but at first that said something about ath0 no such device or something so i did this command first:

bash-3.00# dhcpcd ath0
bash-3.00# dhclient ath0
Internet Systems Consortium DHCP Client V3.0.3
Copyright 2004-2005 Internet Systems Consortium.
All rights reserved.
For info, please visit ISC

Listening on Socket/ath0
Sending on Socket/ath0
DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 3
DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 6
DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 8
DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 8
DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 21
DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 13
DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 2
No DHCPOFFERS received.
No working leases in persistent database - sleeping.
bash-3.00#

ok so its still not working. im stumped. I have no idea what to do, i've been following tutorials on madwifi.org on WPA_PSK and madwifi setup.

i just typed again and it replied:

bash-3.00# dhclient ath0
-info
-info

ath0: not found

-info
bash-3.00#

any information appriciated thanks, please help me resolve this issue because its really getting on my nerves now, i can get on the internet on my laptop on windows (slackware + xp duel booting) and internet on slackware but i just have to plug my laptop in on slackware into the router with an ethernet cable.
 
Old 03-24-2006, 10:29 AM   #2
Bruce Hill
HCL Maintainer
 
Registered: Jun 2003
Location: McCalla, AL, USA
Distribution: Arch, Gentoo
Posts: 6,940

Rep: Reputation: 129Reputation: 129
Welcome to LQ!

I have some links. Start here:

Alien's Wiki and begin reading about the Slackware networking scripts.

After that you'll need to get to his Slackware section of the wiki, where you can find specific links for madwifi and wpa_supplicant.

No need for me to retype what this man has worked so diligently to put together. His stuff is what I use, including his SlackBuilds, especially for madwifi and wpa_supplicant, and They Just Work (TM).
 
Old 03-25-2006, 02:48 PM   #3
jb2006
LQ Newbie
 
Registered: Dec 2005
Location: England
Distribution: Slackware 10.2
Posts: 12

Original Poster
Rep: Reputation: 0
hey thanks i followed the instructions exactly and it still didn't work.

i typed this command :

wpa_supplicant -dw -c/etc/wpa_supplicant.conf -Dmadwifi -iath0

and it just came out with this:

Initializing interface 'ath0' conf '/etc/wpa_supplicant.conf' driver 'madwifi' ctrl_interface 'N/A'
Configuration file '/etc/wpa_supplicant.conf' -> '/etc/wpa_supplicant.conf'
Reading configuration file '/etc/wpa_supplicant.conf'
ctrl_interface='/usr/sbin/wpa_supplicant'
ctrl_interface_group=0
eapol_version=1
ap_scan=1
fast_reauth=1
Priority group 0
id=0 ssid='hell'
Initializing interface (2) 'ath0'
EAPOL: SUPP_PAE entering state DISCONNECTED
EAPOL: KEY_RX entering state NO_KEY_RECEIVE
EAPOL: SUPP_BE entering state INITIALIZE
EAP: EAP entering state DISABLED
EAPOL: External notification - portEnabled=0
EAPOL: External notification - portValid=0
SIOCGIWRANGE: too old (short) data - assuming WPA is not supported
Own MAC address: 00:11:f5:9b:b7:6e
wpa_driver_madwifi_del_key: keyidx=0
wpa_driver_madwifi_del_key: keyidx=1
wpa_driver_madwifi_del_key: keyidx=2
wpa_driver_madwifi_del_key: keyidx=3
wpa_driver_madwifi_set_countermeasures: enabled=0
wpa_driver_madwifi_set_drop_unencrypted: enabled=1
Setting scan request: 0 sec 100000 usec
Using existing control interface directory.
ctrl_iface exists, but does not allow connections - assuming it was leftover from forced program termination
Could not unlink existing ctrl_iface socket '/usr/sbin/wpa_supplicant/ath0'
Failed to initialize control interface '/usr/sbin/wpa_supplicant'.
You may have another wpa_supplicant process already running or the file was
left by an unclean termination of wpa_supplicant in which case you will need
to manually remove this file before starting wpa_supplicant again.
Failed to add interface ath0
State: DISCONNECTED -> DISCONNECTED
No keys have been configured - skip key clearing
EAPOL: External notification - portEnabled=0
EAPOL: External notification - portValid=0
wpa_driver_madwifi_set_drop_unencrypted: enabled=0
wpa_driver_madwifi_set_countermeasures: enabled=0
No keys have been configured - skip key clearing
Cancelling scan request
 
Old 03-27-2006, 02:33 PM   #4
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
Quote:
Originally Posted by jb2006
hey thanks i followed the instructions exactly and it still didn't work.

ctrl_interface='/usr/sbin/wpa_supplicant'
If you had read the instructions, and/or used the supplied package, your /etc/wpa_supplicant.conf file would have looked something like
Code:
  ctrl_interface=/var/run/wpa_supplicant
  ctrl_interface_group=0
  eapol_version=1
  ap_scan=1
  fast_reauth=1
  
  network={
        scan_ssid=0
        ssid="your_essid"
        proto=WPA
        key_mgmt=WPA-PSK
        pairwise=CCMP TKIP
        group=CCMP TKIP WEP104 WEP40
        psk=your_64_hex_characters_long_key
  }
(copied over from http://www.slackware.com/~alien/doku...wpa_encryption)

The debug output you posted shows your configuration wants to use
Code:
ctrl_interface='/usr/sbin/wpa_supplicant'
instead, which is the program binary itself. It might have sneaked into your configuration file by accidental copy/paste?

Eric
 
  


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
Atheros/madwifi on Suse OSS 10 novu5 Linux - Wireless Networking 11 05-20-2006 06:08 PM
FC4 + madwifi + wpa_supplicant. Authenticates, but cannot connect to network jspam Linux - Wireless Networking 0 11-05-2005 03:21 AM
2.6.14, Madwifi & wpa_supplicant on Slack 10.2... rkelsen Slackware 4 11-03-2005 05:59 AM
Madwifi / wpa_supplicant on Kanotix (debian3.1) mattshort Linux - Wireless Networking 2 09-05-2005 08:35 AM
Need help with Madwifi/Atheros on Slack10.1 d4m Linux - Wireless Networking 1 06-26-2005 10:01 AM

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

All times are GMT -5. The time now is 06:15 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