rt61pci in master mode? (using hostapd)

Live forum: http://rt2x00.serialmonkey.com/viewtopic.php?t=6172

leadpumper

14-08-2011 15:44:21

Hello everyone,

This is driving me nuts... In the past, I had my rt61pci card set up as an access point. Now I can't seem to get it configured again that way. Can someone help?

I use dnsmasq 2.55 and hostapd 0.6.10. I'm running kernel 2.6.35.14 on Debian.

This is my /etc/network/interfaces
[code1e8gdf9t]auto wlan0
iface wlan0 inet static
address 192.168.24.1
netmask 255.255.255.0
network 192.168.24.0
post-up /bin/echo 1 > /proc/sys/net/ipv4/ip_forward
post-up /sbin/iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
pre-down /sbin/iptables -t nat -D POSTROUTING -o eth1 -j MASQUERADE[/code1e8gdf9t]

This is my hostapd.conf
[code1e8gdf9t]interface=wlan0
driver=nl80211
logger_syslog=-1
logger_syslog_level=0
logger_stdout=-1
logger_stdout_level=0
dump_file=/tmp/hostapd.dump
ctrl_interface=/var/run/hostapd
ctrl_interface_group=0
ssid=rt61pci
country_code=NL
hw_mode=g
channel=11
beacon_int=100
dtim_period=2
max_num_sta=255
rts_threshold=2347
fragm_threshold=2346
macaddr_acl=0
auth_algs=1
ignore_broadcast_ssid=0
wmm_enabled=1
wmm_ac_bk_cwmin=4
wmm_ac_bk_cwmax=10
wmm_ac_bk_aifs=7
wmm_ac_bk_txop_limit=0
wmm_ac_bk_acm=0
wmm_ac_be_aifs=3
wmm_ac_be_cwmin=4
wmm_ac_be_cwmax=10
wmm_ac_be_txop_limit=0
wmm_ac_be_acm=0
wmm_ac_vi_aifs=2
wmm_ac_vi_cwmin=3
wmm_ac_vi_cwmax=4
wmm_ac_vi_txop_limit=94
wmm_ac_vi_acm=0
wmm_ac_vo_aifs=2
wmm_ac_vo_cwmin=2
wmm_ac_vo_cwmax=3
wmm_ac_vo_txop_limit=47
wmm_ac_vo_acm=0
eapol_key_index_workaround=0
eap_server=0
own_ip_addr=127.0.0.1
wpa=2
wpa_passphrase=mypassword
wpa_pairwise=TKIP CCMP
rsn_pairwise=CCMP[/code1e8gdf9t]

Dnsmasq is set up to listen on wlan0 and serve range 192.168.24.100 to 192.168.24.150 with leases of 12h. (But I don't feel dnsmasq is the problem here - I suspect that the problem is before the dhcp request.)

My iwconfig reports everything ok
[code1e8gdf9t]wlan0 IEEE 802.11bg Mode:Master Frequency:2.462 GHz Tx-Power=20 dBm
Retry long limit:7 RTS thr=2347 B Fragment thr=2346 B
Power Management:off

mon.wlan0 IEEE 802.11bg Mode:Monitor Tx-Power=20 dBm
Retry long limit:7 RTS thr=2347 B Fragment thr=2346 B
Power Management:off[/code1e8gdf9t]

I run hostapd in a console, like so hostapd -K -dd /etc/hostapd/hostapd.conf. It gives me
[code1e8gdf9t]Configuration file: /etc/hostapd/hostapd.conf
ctrl_interface_group=0
Opening raw packet socket for ifindex -1216208954
BSS count 1, BSSID mask ff:ff:ff:ff:ff:ff (0 bits)
SIOCGIWRANGE: WE(compiled)=22 WE(source)=21 enc_capa=0xf
nl80211: Added 802.11b mode based on 802.11g information
Allowed channel: mode=1 chan=1 freq=2412 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=2 freq=2417 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=3 freq=2422 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=4 freq=2427 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=5 freq=2432 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=6 freq=2437 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=7 freq=2442 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=8 freq=2447 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=9 freq=2452 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=10 freq=2457 MHz max_tx_power=20 dBm
Allowed channel: mode=1 chan=11 freq=2462 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=1 freq=2412 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=2 freq=2417 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=3 freq=2422 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=4 freq=2427 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=5 freq=2432 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=6 freq=2437 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=7 freq=2442 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=8 freq=2447 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=9 freq=2452 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=10 freq=2457 MHz max_tx_power=20 dBm
Allowed channel: mode=0 chan=11 freq=2462 MHz max_tx_power=20 dBm
RATE[0] rate=10 flags=0x2
RATE[1] rate=20 flags=0x6
RATE[2] rate=55 flags=0x6
RATE[3] rate=110 flags=0x6
RATE[4] rate=60 flags=0x0
RATE[5] rate=90 flags=0x0
RATE[6] rate=120 flags=0x0
RATE[7] rate=180 flags=0x0
RATE[8] rate=240 flags=0x0
RATE[9] rate=360 flags=0x0
RATE[10] rate=480 flags=0x0
RATE[11] rate=540 flags=0x0
Passive scanning not supported
Mode: IEEE 802.11g Channel: 11 Frequency: 2462 MHz
Flushing old station entries
Deauthenticate all stations
Using interface wlan0 with hwaddr bc:ae:c5:c6:df:45 and ssid 'rt61pci'
SSID - hexdump_ascii(len=7):
72 74 36 31 70 63 69 rt61pci
PSK (ASCII passphrase) - hexdump_ascii(len=10):
6d 79 70 61 73 73 77 6f 72 64 mypassword
PSK (from passphrase) - hexdump(len=32): 19 ac 70 50 05 22 a0 9b 47 d6 71 78 b7 9b dd 80 1b 75 2d 7c 67 2f a0 d2 ca 2b bb 7b 89 a9 1c 11
WPA: group state machine entering state GTK_INIT (VLAN-ID 0)
GMK - hexdump(len=32): 28 18 b8 17 25 70 d1 0e c3 3a af 28 23 4a 21 f4 6d 30 51 ba 2c a4 77 3e 70 09 8a 7b a4 fc 42 c7
GTK - hexdump(len=16): 91 88 db d7 dc 5f 22 4d be 3a e9 5c 78 49 cc 19
WPA: group state machine entering state SETKEYSDONE (VLAN-ID 0)
wlan0: Setup of interface done.[/code1e8gdf9t]

My laptop (running Ubuntu) should now be able to connect to my access point. It does see the access point! But it can not connect to it... S

This is what tail -f /var/log/kern.log gives me
[code1e8gdf9t]Aug 14 17:33:44 argon kernel: [ 1064.896206] bridge-eth0: up
Aug 14 17:33:44 argon kernel: [ 1064.896215] bridge-eth0: attached
Aug 14 17:33:47 argon kernel: [ 1068.525500] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 1/3)
Aug 14 17:33:47 argon kernel: [ 1068.728055] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 2/3)
Aug 14 17:33:48 argon kernel: [ 1068.928085] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 3/3)
Aug 14 17:33:48 argon kernel: [ 1069.132143] wlan0: direct probe to bc:ae:c5:c6:df:45 timed out
Aug 14 17:34:01 argon kernel: [ 1082.119233] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 1/3)
Aug 14 17:34:01 argon kernel: [ 1082.316065] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 2/3)
Aug 14 17:34:01 argon kernel: [ 1082.516698] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 3/3)
Aug 14 17:34:01 argon kernel: [ 1082.716037] wlan0: direct probe to bc:ae:c5:c6:df:45 timed out
Aug 14 17:34:14 argon kernel: [ 1095.710458] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 1/3)
Aug 14 17:34:15 argon kernel: [ 1095.908079] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 2/3)
Aug 14 17:34:15 argon kernel: [ 1096.108094] wlan0: direct probe to bc:ae:c5:c6:df:45 (try 3/3)
Aug 14 17:34:15 argon kernel: [ 1096.308047] wlan0: direct probe to bc:ae:c5:c6:df:45 timed out[/code1e8gdf9t]

What is this?? Hostapd doesn't show any output. That's why I post here - I suspect the driver. Can anybody help me? It's driving me nuts, because I know it should work... It did before!