Can i use a wireless USB adapter to make pfsense a access point ?
-
To See what you get on the console / system logs or with dmesg
ugen4.2: <ralink>at usbus4 run0: <1.0> on usbus4 run0: MAC/BBP RT3070 (rev 0x0201), RF RT3020 (MIMO 1T1R), address c8:3a:35:ce:10:4a run0: firmware RT2870 loaded</ralink>
-
@ptt:
To See what you get on the console / system logs or with dmesg
ugen4.2: <ralink>at usbus4 run0: <1.0> on usbus4 run0: MAC/BBP RT3070 (rev 0x0201), RF RT3020 (MIMO 1T1R), address c8:3a:35:ce:10:4a run0: firmware RT2870 loaded</ralink>
When i do that pfsense immediatly crash .
-
Check to see what revision it is. If it's C1 then it should work and we can try to work out why it's not. If it's some other revision it may not be worth the effort.
Even if it crashes there should be some clue on the console. What makes you think it has 'crashed'?
Steve
-
What makes you think it has 'crashed'?
Steve
Because after i have installed a interface for my device pfsense freezes and if i unplug my device all thing go back and pfsense tells me that has detected a crash report or something like that.
Ok i will post my device-related syslog .
-
Crash report begins. Anonymous machine information:
i386
8.1-RELEASE-p6
FreeBSD 8.1-RELEASE-p6 #1: Mon Dec 12 18:18:02 EST 2011 root@FreeBSD_8.0_pfSense_2.0-snaps.pfsense.org:/usr/obj./usr/pfSensesrc/src/sys/pfSense.8Crash report details:
Filename: /var/crash/bounds
1Filename: /var/crash/info.0
Dump header from device /dev/ad0s1b
Architecture: i386
Architecture Version: 1
Dump Length: 122880B (0 MB)
Blocksize: 512
Dumptime: Mon May 13 16:58:29 2013
Hostname: pfsense.localdomain
Magic: FreeBSD Text Dump
Version String: FreeBSD 8.1-RELEASE-p6 #1: Mon Dec 12 18:18:02 EST 2011
root@FreeBSD_8.0_pfSense_2.0-snaps.pfsense.org:/usr/obj./usr/pfSensesrc/src/sys/pfSense.8
Panic String:
Dump Parity: 2435037477
Bounds: 0
Dump Status: goodFilename: /var/crash/textdump.tar.0
ddb.txt���������������������������������������������������������������������������������������������0600����0�������0�������140000������12144170605� 7072� �����������������������������������������������������������������������������������������������������ustar���root����������������������������wheel������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������db:0:kdb.enter.default> run lockinfo
db:1:lockinfo> show locks
No such command
db:1:locks> show alllocks
No such command
db:1:alllocks> show lockedvnods
Locked vnodes
db:0:kdb.enter.default> show pcpu
cpuid = 0
dynamic pcpu = 0x51f880
curthread = 0xc783c280: pid 0 "rum0 taskq"
curpcb = 0xed5f2d90
fpcurthread = none
idlethread = 0xc498f780: pid 11 "idle: cpu0"
APIC ID = 0
currentldt = 0x50
db:0:kdb.enter.default> bt
Tracing pid 0 tid 64269 td 0xc783c280
ieee80211_chan2mode(ffff,0,c5987cc4,0,18,…) at ieee80211_chan2mode+0xa
rum_start(c4b25800,ffffffff,d25b1900,6083c67,c52ea000,...) at rum_start+0x220
if_transmit(c4b25800,c5987c00,c5987c00,0,c66ce000,...) at if_transmit+0xcb
ieee80211_start(c496c800,5,ffffffff,c4ddac54,ed5f2c9c,...) at ieee80211_start+0x5a8
ieee80211_newstate_cb(c54f3000,7,0,c12ce3fc,0,...) at ieee80211_newstate_cb+0x285
taskqueue_run(c74b4ac0,c74b4ad8,0,c0edc643,0,...) at taskqueue_run+0x89
taskqueue_thread_loop(c66ce074,ed5f2d38,0,281d0a31,281aa1c0,...) at taskqueue_thread_loop+0x45
fork_exit(c0a77de0,c66ce074,ed5f2d38) at fork_exit+0x88
fork_trampoline() at fork_trampoline+0x8
--- trap 0, eip = 0, esp = 0xed5f2d70, ebp = 0 ---
db:0:kdb.enter.default> ps
pid ppid pgrp uid state wmesg wchan cmd
39421 62134 45237 0 S nanslp 0xc133c224 sleep
62134 1 45237 0 S wait 0xc7b75aa0 sh
59970 1 59970 0 Ss select 0xc539bbe4 apinger
57580 1 57260 65534 S select 0xc4dee6a4 dnsmasq
53225 34672 25 0 S nanslp 0xc133c224 sleep
1401 1 1401 0 Ss select 0xc54475a4 syslogd
38532 1 38532 0 Ss (threaded) sshlockout_pf
64268 S nanslp 0xc133c224 sshlockout_pf
64138 S uwait 0xc4ded900 initial thread
4645 29350 28795 62 S sbwait 0xc70c00b8 initial thread
4441 29350 28795 62 S sbwait 0xc6f4da60 initial thread
4313 29350 28795 62 S sbwait 0xc4f4a0b8 initial thread
3989 29350 28795 62 S sbwait 0xc60d0a60 initial thread
3898 29350 28795 62 S sbwait 0xc6f4dd98 initial thread
30283 29350 28795 62 S piperd 0xc6c537a8 unlinkd
29350 28795 28795 62 S kqread 0xc68db400 initial thread
28795 1 28795 0 Ss wait 0xc5fb4d48 squid
9413 1 9413 0 Ss nanslp 0xc133c224 cron
9740 1 9740 0 Ss select 0xc54484e4 ntpd
7616 1 257 123 S select 0xc5447324 ntpd
55023 1 55023 0 Ss select 0xc5447d64 openvpn
15395 45237 45237 0 S accept 0xc53896ae php
37454 45237 45237 0 S nanslp 0xc133c224 php
28935 1 28935 0 Ss (threaded) mpd5
64160 S select 0xc5447aa4 mpd5
40093 38525 40093 0 S+ ttyin 0xc4a21470 sh
38525 38212 38525 0 S+ wait 0xc5495aa0 sh
38281 1 38281 0 Ss (threaded) sshlockout_pf
64150 S nanslp 0xc133c224 sshlockout_pf
64097 S uwait 0xc4beb700 initial thread
38212 1 38212 0 Ss+ wait 0xc4e74550 login
36320 1 36320 0 Ss nanslp 0xc133c224 minicron
36048 1 36048 0 Ss nanslp 0xc133c224 minicron
35636 1 35636 0 Ss nanslp 0xc133c224 minicron
34672 1 25 0 S+ wait 0xc4f27aa0 sh
45237 42787 45237 0 Ss wait 0xc4e4daa0 initial thread
44194 43043 43043 0 S accept 0xc4f4b376 php
44096 43043 43043 0 S accept 0xc4f4b376 php
43043 42787 43043 0 Ss wait 0xc4e757f8 initial thread
42787 1 42752 0 S kqread 0xc52fd300 lighttpd
28466 1 28466 0 Ss select 0xc4c0be64 inetd
18714 1 25 0 S+ piperd 0xc4e6bab8 logger
18461 1 25 0 S+ bpf 0xc4e4f100 tcpdump
11580 1 11580 0 Ss select 0xc4ded124 sshd
270 1 270 0 Ss select 0xc4defe64 devd
259 257 257 0 S kqread 0xc4e3b580 check_reload_status
257 1 257 0 Ss kqread 0xc4bf1d80 check_reload_status
40 0 0 0 SL mdwait 0xc4dbb000 [md0]
24 0 0 0 SL sdflush 0xc136ac60 [softdepflush]
23 0 0 0 SL syncer 0xc134fd94 [syncer]
22 0 0 0 SL vlruwt 0xc4a18d48 [vnlru]
21 0 0 0 SL psleep 0xc134fac8 [bufdaemon]
20 0 0 0 SL pollid 0xc133b77c [idlepoll]
19 0 0 0 SL pgzero 0xc136b914 [pagezero]
18 0 0 0 SL psleep 0xc136b53c [vmdaemon]
17 0 0 0 SL psleep 0xc136b504 [pagedaemon]
16 0 0 0 SL ccb_scan 0xc1306454 [xpt_thrd]
9 0 0 0 SL pftm 0xc04f6d80 [pfpurge]
8 0 0 0 SL waiting_ 0xc13571d8 [sctp_iterator]
7 0 0 0 SL - 0xc4b2043c [fdc0]
15 0 0 0 SL (threaded) usb
64056 D - 0xc4bc2d0c [usbus5]
64055 D - 0xc4bc2cdc [usbus5]
64054 D - 0xc4bc2cac [usbus5]
64053 D - 0xc4bc2c7c [usbus5]
64052 D - 0xc4bb0dac [usbus4]
64051 D - 0xc4bb0d7c [usbus4]
64050 D - 0xc4bb0d4c [usbus4]
64049 D - 0xc4bb0d1c [usbus4]
64048 D - 0xc4b95dac [usbus3]
64047 D - 0xc4b95d7c [usbus3]
64046 D - 0xc4b95d4c [usbus3]
64045 D - 0xc4b95d1c [usbus3]
64044 D - 0xc4b78d0c [usbus2]
64043 D - 0xc4b78cdc [usbus2]
64042 D - 0xc4b78cac [usbus2]
64041 D - 0xc4b78c7c [usbus2]
64039 D - 0xc4b63dac [usbus1]
64038 D - 0xc4b63d7c [usbus1]
64037 D - 0xc4b63d4c [usbus1]
64036 D - 0xc4b63d1c [usbus1]
64034 D - 0xc4b51dac [usbus0]
64033 D - 0xc4b51d7c [usbus0]
64032 D - 0xc4b51d4c [usbus0]
64031 D - 0xc4b51d1c [usbus0]
14 0 0 0 SL - 0xc133c084 [yarrow]
6 0 0 0 SL crypto_r 0xc136a28c [crypto returns]
5 0 0 0 SL crypto_w 0xc136a268 [crypto]
4 0 0 0 SL - 0xc1339924 [g_down]
3 0 0 0 SL - 0xc1339920 [g_up]
2 0 0 0 SL - 0xc1339918 [g_event]
13 0 0 0 SL (threaded) ng_queue
64011 D sleep 0xc12dcae0 [ng_queue1]
64010 D sleep 0xc12dcae0 [ng_queue0]
12 0 0 0 RL (threaded) intr
64061 I [swi0: uart]
64060 I [irq7: ppc0]
64059 I [irq1: atkbd0]
64058 I [irq15: ata1]
64057 I [irq14: ata0]
64040 I [irq22: ehci0]
64035 I [irq21: rl1 uhci1+]
64030 I [irq20: rl0 uhci0++]
64028 I [irq9: acpi0]
64024 I [swi6: task queue]
64023 I [swi6: Giant taskq]
64021 I [swi5: +]
64019 I [swi2: cambio]
64009 I [swi4: clock]
64008 Run CPU 1 [swi4: clock]
64007 I [swi1: netisr 0]
64006 I [swi3: vm]
11 0 0 0 RL (threaded) idle
64005 CanRun [idle: cpu0]
64004 CanRun [idle: cpu1]
1 0 1 0 SLs wait 0xc498dd48 [init]
10 0 0 0 SL audit_wo 0xc136a600 [audit]
0 0 0 0 RLs (threaded) kernel
64269 Run CPU 0 [rum0 taskq]
64029 D - 0xc4b35500 [em0 taskq]
64027 D - 0xc4adf380 [acpi_task_2]
64026 D - 0xc4adf380 [acpi_task_1]
64025 D - 0xc4adf380 [acpi_task_0]
64022 D - 0xc4adf4c0 -
I suggest you try a pfSense 2.1 snapshot build. It is based on FreeBSD 8.3 which has newer device drivers than pfSense 2.0.x which is based on FreeBSD 8.1.
-
Any an idea ?
-
So the crash happens as soon as you plug the usb stick in?
It seems like it doesn't have the revision written on it (or if it does you're just not saying! ;)). The only way to determine which it is is to look at the reported USB vendor and product values:
http://wikidevi.com/wiki/D-Link_DWL-G122_rev_C1Perhaps plug it into a different box to get them.
Steve
-
So the crash happens as soon as you plug the usb stick in?
No it happen when enabling wireless's interface .
-
Ah, OK. Then run 'usbconfig dump_device_desc' before you enable the interface and post the results.
Steve
-
Ah, OK. Then run 'usbconfig dump_device_desc' before you enable the interface and post the results.
Steve
Hi…i'm sorry for my late replay .
So do you want me to plugin my device and execute your command then enable wireless interface ?
-
Just plug it in then run that command and paste the output here. Then we will know what hardware you're dealing with.
Steve
-
Just plug it in then run that command and paste the output here. Then we will know what hardware you're dealing with.
Steve
Here :
usbconfig dump_device_desc ugen0.1: <uhci root="" hub="" intel="">at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0100 bDeviceClass = 0x0009 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x0000 idProduct = 0x0000 bcdDevice = 0x0100 iManufacturer = 0x0001 <intel>iProduct = 0x0002 <uhci root="" hub="">iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001 ugen1.1: <uhci root="" hub="" intel="">at usbus1, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0100 bDeviceClass = 0x0009 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x0000 idProduct = 0x0000 bcdDevice = 0x0100 iManufacturer = 0x0001 <intel>iProduct = 0x0002 <uhci root="" hub="">iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001 ugen2.1: <ehci root="" hub="" intel="">at usbus2, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0200 bDeviceClass = 0x0009 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0001 bMaxPacketSize0 = 0x0040 idVendor = 0x0000 idProduct = 0x0000 bcdDevice = 0x0100 iManufacturer = 0x0001 <intel>iProduct = 0x0002 <ehci root="" hub="">iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001 ugen3.1: <uhci root="" hub="" intel="">at usbus3, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0100 bDeviceClass = 0x0009 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x0000 idProduct = 0x0000 bcdDevice = 0x0100 iManufacturer = 0x0001 <intel>iProduct = 0x0002 <uhci root="" hub="">iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001 ugen4.1: <uhci root="" hub="" intel="">at usbus4, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0100 bDeviceClass = 0x0009 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x0000 idProduct = 0x0000 bcdDevice = 0x0100 iManufacturer = 0x0001 <intel>iProduct = 0x0002 <uhci root="" hub="">iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001 ugen5.1: <ehci root="" hub="" intel="">at usbus5, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0200 bDeviceClass = 0x0009 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0001 bMaxPacketSize0 = 0x0040 idVendor = 0x0000 idProduct = 0x0000 bcdDevice = 0x0100 iManufacturer = 0x0001 <intel>iProduct = 0x0002 <ehci root="" hub="">iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001 ugen5.2: <802.11 bg WLAN Ralink> at usbus5, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0200 bDeviceClass = 0x0000 bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0040 idVendor = 0x07d1 idProduct = 0x3c03 bcdDevice = 0x0001 iManufacturer = 0x0001 <ralink>iProduct = 0x0002 <802.11 bg WLAN> iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001</no></ralink></no></ehci></intel></ehci></no></uhci></intel></uhci></no></uhci></intel></uhci></no></ehci></intel></ehci></no></uhci></intel></uhci></no></uhci></intel></uhci>
-
OK
ugen5.2: <802.11 bg WLAN Ralink> at usbus5, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON
bLength = 0x0012
bDescriptorType = 0x0001
bcdUSB = 0x0200
bDeviceClass = 0x0000
bDeviceSubClass = 0x0000
bDeviceProtocol = 0x0000
bMaxPacketSize0 = 0x0040
idVendor = 0x07d1
idProduct = 0x3c03
bcdDevice = 0x0001
iManufacturer = 0x0001 <ralink>iProduct = 0x0002 <802.11 bg WLAN>
iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001</no></ralink>So this shows you have the rev C1 hardware according to the WikiDevi page.
This should be supported by the rum(4) driver.To make the driver load at boot add the line:
if_rum_load="YES"
To the file /boot/loader.conf.local. You may have to create that file if it doesn't exist.
So now the question is why is it not working.
What do you see in the logs after it's first plugged in (before you attempt to assign the interface)?What settings are you attempting to apply when you assign the interface?
Steve
-
A quick search here for dwl-g122 shows up some worrying threads such as this:
http://forum.pfsense.org/index.php/topic,44491.0.html
And this much older comment:
http://forum.pfsense.org/index.php/topic,27519.msg143349.html#msg143349
Did it ever get fixed for 2.0?You might just try 2.1 to get the most recent driver.
Steve
-
OK
ugen5.2: <802.11 bg WLAN Ralink> at usbus5, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON
bLength = 0x0012
bDescriptorType = 0x0001
bcdUSB = 0x0200
bDeviceClass = 0x0000
bDeviceSubClass = 0x0000
bDeviceProtocol = 0x0000
bMaxPacketSize0 = 0x0040
idVendor = 0x07d1
idProduct = 0x3c03
bcdDevice = 0x0001
iManufacturer = 0x0001 <ralink>iProduct = 0x0002 <802.11 bg WLAN>
iSerialNumber = 0x0000 <no string="">bNumConfigurations = 0x0001</no></ralink>So this shows you have the rev C1 hardware according to the WikiDevi page.
This should be supported by the rum(4) driver.To make the driver load at boot add the line:
if_rum_load="YES"
To the file /boot/loader.conf.local. You may have to create that file if it doesn't exist.
So now the question is why is it not working.
What do you see in the logs after it's first plugged in (before you attempt to assign the interface)?What settings are you attempting to apply when you assign the interface?
Steve
Wait how can i do that ? (creating file or writing to a file ?)
-
You can do both with the following command:
echo 'if_rum_load="yes"' >> /boot/loader.conf.local
Steve
-
If I recall correctly, the rum driver has been in pfSense since at least pfSense 1.2.3.
Again, if I recall correctly I saw system crashes on enabling rum devices in pfSense 2.0.
Yesterday I tried enabling a rum device on a pSense 2.1 RC0 build and saw lost of messages like
May 25 13:03:00 pfsense2 kernel: rum0: could not multi read MAC register: USB_ERR_TIMEOUT
May 25 13:03:13 pfsense2 kernel: rum0: could not multi read MAC register: USB_ERR_TIMEOUT
May 25 13:03:17 pfsense2 kernel: stray irq7
May 25 13:03:26 pfsense2 kernel: rum0: could not multi write MAC register: USB_ERR_TIMEOUTand the system seemed to lock up when I issued the shell command```
usbconfig show_ifdrvI suspect the driver is infected with bit rot and it is unlikely there will be anyone interested in fixing in in either FreeBSD 8.1 or 8.3. I have successfully used Ralink RT3070 based devices as Access Points in pfSense 2.0.x and pfSense 2.1 snapshot builds but unfortunately the devices I used seem to have disappeared from local retail outlets. A search for RT3070 on eBay should show some likely sources and a search in the pfSense wireless forum should also turn up some likely sources. At prices of these devices I suspect it is not worth your while trying to get your existing device working. It may well work quite well under Windows or Linux.
-
You can do both with the following command:
echo 'if_rum_load="yes"' >> /boot/loader.conf.local
Steve
Okay i have done that and ?
-
Having done that the driver should load at boot allowing the interface to start when the box boots.
However if what Wallabybob suggested is true then it may instead actually prevent the box booting! :(
Did you try 2.1 with the newest drivers?
Steve