17c7a [Solved] ifconfig wlan0 scan does not show any results. - The FreeBSD Forums
The FreeBSD Forums  

Go Back   The FreeBSD Forums > Server & Networking > Networking

Networking Network related discussions (including general TCP/IP stuff, routing, etc).

Reply
 
Thread Tools Display Modes
  #1  
Old March 3rd, 2011, 20:21
bhargava's Avatar
bhargava bhargava is offline
Junior Member
 
Join Date: May 2009
Location: California
Posts: 32
Thanks: 2
Thanked 1 Time in 1 Post
Default ifconfig wlan0 scan does not show any results.

Hi,

I just now did a fresh install of FreeBSD.
Code:
$ uname -a
FreeBSD mybox.hsd1.ca.comcast.net. 8.2-RELEASE FreeBSD 8.2-RELEASE #0: Fri Feb 18 02:24:46 UTC 2011     root@almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386
Code:
$ pciconf -lv
...
 vendor     = 'Broadcom Corporation'
    device     = 'Broadcom Corporation Dell Wireless 1390 WLAN Mini-PCI Card (BCM4311)'
    class      = network
I installed the bwn firmware from the ports net/bwn-firmware-kmod.

But when I try to scan for the available networks:
Code:
ifconfig wlan0 up scan
, but it just returns empty results. Does not show any available networks. I tried installing wpa_gui also but does not work. Below are the files and their contents that I think might be useful. Please let me know if any other information is needed.

Here is the /etc/rc.conf file:
Code:
$ cat /etc/rc.conf 

# -- sysinstall generated deltas -- # Thu Mar  3 06:55:32 2011
# Created: Thu Mar  3 06:55:32 2011
# Enable network daemons for user convenience.
# Please make all changes to this file, not to /etc/defaults/rc.conf.
# This file now contains just the overrides from /etc/defaults/rc.conf.
hostname="mybox.hsd1.ca.comcast.net."
ifconfig_nfe0="DHCP"
inetd_enable="NO"
ipv6_enable="YES"
keymap="us.iso"
moused_enable="YES"
saver="fire"
hald_enable="YES"
dbus_enable="YES"
gdm_enable="YES"
wlans_bwn0="wlan0"
ifconfig_wlan0="WPA DHCP"
Here is the /boot/loader.conf file:
Code:
$ cat /boot/loader.conf 
nvidia_load="YES"
if_bwn_load="YES"
bwn_u4_ucode_load="YES"
wlan_scan_ap_load="YES"
wlan_scan_sta_load="YES"
wlan_wep_load="YES"
wlan_ccmp_load="YES"
wlan_tkip_load="YES"
Here is the /etc/wpa_supplicant.conf
Code:
$ cat /etc/wpa_supplicant.conf 
network={
	ssid="Espresso"
	psk="************"
}

ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=wheel
How do I fix this and connect to a network?

Thank you.
__________________
--
Bhargava

Last edited by bhargava; March 4th, 2011 at 03:12. Reason: Thread marked solved.
Reply With Quote
  #2  
Old March 3rd, 2011, 22:39
wblock@'s Avatar
wblock@ wblock@ is offline
Moderator
 
Join Date: Sep 2009
Location: Milky Way galaxy
Posts: 7,701
Thanks: 429
Thanked 1,757 Times in 1,456 Posts
Default

First, use
# ifconfig wlan0 up list scan

bwn(4) requires installing net/bwn-firmware-kmod and loading the firmware before use. If you've already done that, please show the output of
% ifconfig

You may want to change the PSK, now that you've shown it to the world.
Reply With Quote
  #3  
Old March 3rd, 2011, 23:26
bhargava's Avatar
bhargava bhargava is offline
Junior Member
 
Join Date: May 2009
Location: California
Posts: 32
Thanks: 2
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by wblock View Post
First, use
# ifconfig wlan0 up list scan

bwn(4) requires installing net/bwn-firmware-kmod and loading the firmware before use. If you've already done that, please show the output of
% ifconfig
I already installed it. Here is the output:
Code:
$ ifconfig 
fwe0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=8<VLAN_MTU>
	ether 02:24:1b:33:40:00
	ch 1 dma -1
fwip0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
	lladdr 0.24.1b.0.95.33.40.0.a.2.ff.fe.0.0.0.0
nfe0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=82008<VLAN_MTU,WOL_MAGIC,LINKSTATE>
	ether 00:1b:24:74:c6:1c
	inet6 fe80::21b:24ff:fe74:c61c%nfe0 prefixlen 64 scopeid 0x3 
	inet 192.168.1.101 netmask 0xffffff00 broadcast 192.168.1.255
	nd6 options=3<PERFORMNUD,ACCEPT_RTADV>
	media: Ethernet autoselect (100baseTX <full-duplex>)
	status: active
bwn0: flags=8803<UP,BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 2290
	ether 00:1a:73:98:8c:94
	media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
	status: no carrier
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
	options=3<RXCSUM,TXCSUM>
	inet 127.0.0.1 netmask 0xff000000 
	inet6 ::1 prefixlen 128 
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x5 
	nd6 options=3<PERFORMNUD,ACCEPT_RTADV>
wlan0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
	ether 00:1a:73:98:8c:94
	inet6 fe80::21a:73ff:fe98:8c94%wlan0 prefixlen 64 scopeid 0x6 
	inet 208.68.139.38 netmask 0xffffff00 broadcast 208.68.139.255
	nd6 options=3<PERFORMNUD,ACCEPT_RTADV>
	media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
	status: no carrier
	ssid "" channel 1 (2412 MHz 11b)
	country US authmode WPA1+WPA2/802.11i privacy OFF txpower 30 bmiss 7
	scanvalid 60 bgscan bgscanintvl 300 bgscanidle 250 roam:rssi 7
	roam:rate 1 wme bintval 0
Quote:
Originally Posted by wblock View Post
You may want to change the PSK, now that you've shown it to the world.
I forgot to change this when I posted this. Thanks for letting me know.

Thank you.
__________________
--
Bhargava
Reply With Quote
  #4  
Old March 4th, 2011, 00:15
cheme cheme is offline
Junior Member
 
Join Date: Jan 2011
Posts: 16
Thanks: 2
Thanked 2 Times in 2 Posts
Default

Hello,

Try rearranging your /etc/wpa_supplicant.conf. Change it to match mine and give it a try.

Code:
#cat /etc/wpa_supplicant.conf
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=wheel
network={
        ssid="yourssid"
        psk="yourkey"
        }
Notice how the "Global Parameters" are before the "Network Block" and that there are no uncommented spaces between a line of the file. Check out the wpa_supplicant.conf man page. http://www.FreeBSD.org/cgi/man.cgi?q...conf&sektion=5
Reply With Quote
  #5  
Old March 4th, 2011, 02:12
bhargava's Avatar
bhargava bhargava is offline
Junior Member
 
Join Date: May 2009
Location: California
Posts: 32
Thanks: 2
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by cheme View Post
Hello,

Try rearranging your /etc/wpa_supplicant.conf. Change it to match mine and give it a try.

Code:
#cat /etc/wpa_supplicant.conf
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=wheel
network={
        ssid="yourssid"
        psk="yourkey"
        }
I tried everything it does not scan at all.

I tried using the following command
Code:
# wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
ioctl[SIOCS80211, op 103, len 128]: Device not configured
Failed to initiate AP scan.
^CCTRL-EVENT-TERMINATING - signal 2 received
ioctl[SIOCS80211, op 26, arg 0x0]: Operation not supported
Failed to disable WPA in the driver.
ELOOP: remaining socket: sock=4 eloop_data=0x28406140 user_data=0x2840d040 handler=0x8069f90
It continues the output till use C-c. Anyone who see what the problem is?

Thank you.
__________________
--
Bhargava
Reply With Quote
  #6  
Old March 4th, 2011, 01:58
wblock@'s Avatar
wblock@ wblock@ is offline
Moderator
 
Join Date: Sep 2009
Location: Milky Way galaxy
Posts: 7,701
Thanks: 429
Thanked 1,757 Times in 1,456 Posts
Default

The wlan_* modules are included in the GENERIC kernel. It's not necessary to load them unless you have a custom kernel without them.

Access point scanning does not use wpa_supplicant(8). Does "list scan" show different results than just "scan"?

All I've ever used in wpa_supplicant.conf is a network block for each network with SSID and PSK (or a bit more for open networks). But you only need that to connect to those networks, not scan for SSIDs.
Reply With Quote
  #7  
Old March 4th, 2011, 02:16
bhargava's Avatar
bhargava bhargava is offline
Junior Member
 
Join Date: May 2009
Location: California
Posts: 32
Thanks: 2
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by wblock View Post
The wlan_* modules are included in the GENERIC kernel. It's not necessary to load them unless you have a custom kernel without them.

Access point scanning does not use wpa_supplicant(8). Does "list scan" show different results than just "scan"?
no. The results do not change. I mean it shows no results at all.
Code:
mybox# ifconfig wlan0 list scan 
mybox# 

mybox# ifconfig wlan0 scan
mybox#
Thank you.
__________________
--
Bhargava
Reply With Quote
  #8  
Old March 4th, 2011, 02:38
bhargava's Avatar
bhargava bhargava is offline
Junior Member
 
Join Date: May 2009
Location: California
Posts: 32
Thanks: 2
Thanked 1 Time in 1 Post
Default

Hi,

I found this line in the dmesg output.
Code:
bwn_v4_ucode13: could not load firmware image, error 2
....
bwn0: the fw file(bwn_v4_ucode13) not found
bwn-open_v4_ucode13: could not load firmware image, error 2
bwn0: the fw file(bwn-open_v4_ucode13) not found
here is my kldstat:
Code:
# kldstat 
Id Refs Address    Size     Name
 1   18 0xc0400000 bd97b4   kernel
 2    1 0xc0fda000 37228    if_bwn.ko
 3    2 0xc1012000 a1bc     siba_bwn.ko
 4    1 0xc101d000 a4c3e0   nvidia.ko
 5    2 0xc1a6a000 2d998    linux.ko

I have added bwn_u4_ucode in /boot/loader.conf
Code:
cat /boot/loader.conf 
nvidia_load="YES"
if_bwn_load="YES"
bwn_u4_ucode_load="YES"
wlan_scan_ap_load="YES"
wlan_scan_sta_load="YES"
wlan_wep_load="YES"
wlan_ccmp_load="YES"
wlan_tkip_load="YES"
But i guess it is looking for file/module named bwn-open_v4_ucode13

but in the /boot/modules I have:
Code:
# ls /boot/modules/
bwn_v4_lp_ucode.ko	cuse4bsd.ko		nvidia.ko
bwn_v4_ucode.ko		linker.hints
No bwn-open_v4_ucode13. I think this is the source of the problem (right ?). How do I fix this (if this is the problem). any suggestions.

Thanks.
__________________
--
Bhargava
Reply With Quote
  #9  
Old March 4th, 2011, 02:57
bhargava's Avatar
bhargava bhargava is offline
Junior Member
 
Join Date: May 2009
Location: California
Posts: 32
Thanks: 2
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by bhargava View Post
I have added bwn_u4_ucode in /boot/loader.conf
Code:
cat /boot/loader.conf 
nvidia_load="YES"
if_bwn_load="YES"
bwn_u4_ucode_load="YES"
wlan_scan_ap_load="YES"
wlan_scan_sta_load="YES"
wlan_wep_load="YES"
wlan_ccmp_load="YES"
wlan_tkip_load="YES"
I have a typo in there. I've now corrected it and will see if this will work. I'll post back in a minute after I reboot.
Thank you.
__________________
--
Bhargava
Reply With Quote
  #10  
Old March 4th, 2011, 02:58
wblock@'s Avatar
wblock@ wblock@ is offline
Moderator
 
Join Date: Sep 2009
Location: Milky Way galaxy
Posts: 7,701
Thanks: 429
Thanked 1,757 Times in 1,456 Posts
Default

You may also need to "up" the wlan0 interface the first time, which is why that's usually included in instructions:
# ifconfig wlan0 up list scan
Reply With Quote
  #11  
Old March 4th, 2011, 03:11
bhargava's Avatar
bhargava bhargava is offline
Junior Member
 
Join Date: May 2009
Location: California
Posts: 32
Thanks: 2
Thanked 1 Time in 1 Post
Default

Hi,

ifconfig wlan0 list scan is now working.

Thank you wblock and cheme for the answers and your time.
__________________
--
Bhargava
Reply With Quote
Reply

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
BSDA - why so long for the results da1 Off-Topic 2 October 13th, 2010 22:15
ifconfig doesnt show wpi0 Romanrp Mobile Computing 2 September 7th, 2010 15:15
ifconfig will not create wlan0 tl1000s77 Networking 3 April 21st, 2010 10:00
freebsd 8 ifconfig wlan0 get signal strength ! miniqq Mobile Computing 8 February 8th, 2010 13:50
Please post you results here Graaf_van_Vlaanderen General 10 October 15th, 2009 17:19


All times are GMT +1. The time now is 09:51.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.
The mark FreeBSD is a registered trademark of The FreeBSD Foundation and is used by The FreeBSD Project with the permission of The FreeBSD Foundation.
Web protection and acceleration provided by CloudFlare
0