>Number: 6567
>Category: i386
>Synopsis: wifi clients fail to reconnect to AP after sleep
>Confidential: yes
>Severity: serious
>Priority: medium
>Responsible: bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: unknown
>Arrival-Date: Sat Feb 19 21:30:01 GMT 2011
>Closed-Date:
>Last-Modified:
>Originator:
>Release:
>Organization:
>Environment:
System : OpenBSD 4.8
Details : OpenBSD 4.8-stable (NET4511) #1: Mon Jan 10 20:13:06 CET 2
011
Architecture: OpenBSD.i386
Machine : i386
>Description:
Soekris 4511 box with mini-PCI ath(4) card is running in hostap
mode. The clients can successfully connect and transmit data. If a
client goes to sleep (or is turned) off and then wakes up (or is
turned back on) it fails to reconnect.
This can be reproduced with 2 currently available clients - Apple
Powerbook running Mac OS X with built-in wifi card and whitebox PC
running Ubuntu Linux with PCI wifi card.
The config looks as follows:
# ifconfig ath0
ath0: flags=8922<BROADCAST,NOTRAILERS,PROMISC,SIMPLEX,MULTICAST> mtu 1500
lladdr 00:0b:6b:XXX
description: WiFi interface
priority: 4
groups: wlan
media: IEEE802.11 autoselect mode 11b hostap
status: no network
ieee80211: nwid XXX chan 8 bssid 00:0b:6b:XXX wpapsk XXX
wpaprotos wpa2 wpaakms psk wpaciphers tkip,ccmp wpagroupcipher tkip
inet6 fe80::20b:XXX%ath0 prefixlen 64 scopeid 0x1
Note: parts of the output were redacted.
the ath0 participates in bridge with both ethernet iterfaces:
bridge0: flags=41<UP,RUNNING>
groups: bridge
priority 32768 hellotime 2 fwddelay 15 maxage 20 holdcnt 6 proto rstp
ath0 flags=3<LEARNING,DISCOVER>
port 1 ifpriority 0 ifcost 0
sis1 flags=3<LEARNING,DISCOVER>
port 3 ifpriority 0 ifcost 0
sis0 flags=7<LEARNING,DISCOVER,BLOCKNONIP>
port 2 ifpriority 0 ifcost 0
This is a dump of failed reconnect:
# tcpdump -i ath0 -n -e -ttt -y IEEE802_11 | grep 43:09
tcpdump: listening on ath0, link-type IEEE802_11
Feb 19 17:18:06.597289 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:06.678465 00:25:00:XXX > 00:0b:6b:XXX, bssid
00:0b:6b:XXX: 802.11: authentication request
Feb 19 17:18:06.990389 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:07.010720 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:07.032489 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:07.052939 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:07.413927 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:07.434275 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:11.870340 00:25:00:XXX > 00:0b:6b:XXX, bssid
00:0b:6b:XXX: 802.11: authentication request
^C
156 packets received by filter
0 packets dropped by kernel
Successful reconnect looks like this:
# tcpdump -i ath0 -n -e -ttt -y IEEE802_11 | grep 43:09
tcpdump: listening on ath0, link-type IEEE802_11
tcpdump: WARNING: compensating for unaligned libpcap packets
tcpdump: WARNING: compensating for unaligned libpcap packets
Feb 19 17:18:59.865680 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:59.865975 00:0b:6b:XXX > 00:25:00:XXX, bssid
00:0b:6b:XXX: 802.11: probe response, ssid (XXX), rates, ds, rsn
Feb 19 17:18:59.885937 00:25:00:XXX > ff:ff:ff:ff:ff:ff, bssid
ff:ff:ff:ff:ff:ff: 802.11: probe request
Feb 19 17:18:59.886144 00:0b:6b:XXX > 00:25:00:XXX, bssid
00:0b:6b:XXX: 802.11: probe response, ssid (XXX), rates, ds, rsn
Feb 19 17:18:59.947266 00:25:00:XXX > 00:0b:6b:XXX, bssid
00:0b:6b:XXX: 802.11: authentication request
Feb 19 17:18:59.947364 00:0b:6b:XXX > 00:25:00:XXX, bssid
00:0b:6b:XXX: 802.11: authentication response
Feb 19 17:18:59.949544 00:25:00:XXX > 00:0b:6b:XXX, bssid
00:0b:6b:XXX: 802.11: association request
Feb 19 17:18:59.949750 00:0b:6b:XXX > 00:25:00:XXX, bssid
00:0b:6b:XXX: 802.11: association response
Feb 19 17:18:59.949964 00:0b:6b:XXX > 00:25:00:XXX, bssid
00:0b:6b:XXX, DS >: 802.11: data: sap aa ui/C len=96
Feb 19 17:18:59.954878 00:25:00:XXX > 00:0b:6b:XXX, bssid
00:0b:6b:XXX, > DS: 802.11: data: sap aa ui/C len=118
Feb 19 17:18:59.957826 00:0b:6b:XXX > 00:25:00:XXX, bssid
00:0b:6b:XXX, DS >: 802.11: data: sap aa ui/C len=176
Feb 19 17:18:59.964057 00:25:00:XXX > 00:0b:6b:XXX, bssid
00:0b:6b:XXX, > DS: 802.11: data: sap aa ui/C len=96
Feb 19 17:18:59.971411 00:25:00:XXX > 00:02:cf:b0:86:02, bssid
00:0b:6b:XXX, > DS: 802.11: data: arp who-has 192.168.1.1 tell
192.168.1.35 ()
Feb 19 17:18:59.971927 00:25:00:XXX > 00:0c:42:35:bc:23, bssid
00:0b:6b:XXX, > DS: 802.11: data: arp who-has 192.168.1.1 tell
192.168.1.33 ()
I found that the workaround is to do:
ifconfig ath0 down
ifconfig ath0 up
when the clients cannot reconnect.
Also, the client is not present in the output of 'ifconfig ath0 scan'
when the reconnect is failing. (I don't know of any other way how to
dump wifi client table)
>How-To-Repeat:
Put the client to sleep or turn if off and then wake it up or
power on and try reconnecting.
>Fix:
No that I know of.
dmesg:
OpenBSD 4.8-stable (NET4511) #1: Mon Jan 10 20:13:06 CET 2011
root@greenbox:/usr/src/sys/arch/i386/compile/NET4511
cpu0: AMD Am486DX4 W/B or Am5x86 W/B 150 ("AuthenticAMD" 486-class)
cpu0: FPU
real mem = 33124352 (31MB)
avail mem = 25935872 (24MB)
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 20/80/03, BIOS32 rev. 0 @ 0xf7840
pcibios0 at bios0: rev 2.0 @ 0xf0000/0x10000
pcibios0: pcibios_get_intr_routing - function not supported
pcibios0: PCI IRQ Routing information unavailable.
pcibios0: PCI bus #1 is the last bus
cpu0 at mainbus0: (uniprocessor)
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
elansc0 at pci0 dev 0 function 0 "AMD ElanSC520 PCI" rev 0x00: product
0 stepping 1.1, CPU clock 100MHz, reset 0
gpio0 at elansc0: 32 pins
cbb0 at pci0 dev 9 function 0 "TI PCI1410 CardBus" rev 0x02: irq 10
ath0 at pci0 dev 16 function 0 "Atheros AR5212" rev 0x01: irq 11
ath0: AR5213A 5.9 phy 4.3 rf5112a 3.6, FCC2A*, address 00:0b:6b:XXX
sis0 at pci0 dev 18 function 0 "NS DP83815 10/100" rev 0x00, DP83815D:
irq 5, address 00:00:24:c0:61:24
nsphyter0 at sis0 phy 0: DP83815 10/100 PHY, rev. 1
sis1 at pci0 dev 19 function 0 "NS DP83815 10/100" rev 0x00, DP83815D:
irq 9, address 00:00:24:c0:61:25
nsphyter1 at sis1 phy 0: DP83815 10/100 PHY, rev. 1
cardslot0 at cbb0 slot 0 flags 0
cardbus0 at cardslot0: bus 1 device 0 cacheline 0x10, lattimer 0x3f
pcmcia0 at cardslot0
isa0 at mainbus0
isadma0 at isa0
com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
com0: console
com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
wdc0 at isa0 port 0x1f0/8 irq 14
wd0 at wdc0 channel 0 drive 0: <SanDisk SDCFH-1024>
wd0: 4-sector PIO, LBA, 977MB, 2001888 sectors
wd0(wdc0:0:0): using BIOS timings
npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
biomask f5c7 netmask ffe7 ttymask ffff
rd0: fixed, 7480 blocks
root on rd0a swap on rd0b dump on rd0b
>Release-Note:
>Audit-Trail:
>Unformatted: