no wired or wireless internet connection available -> BCM4318 [AirForce One 54g] 802.11g Wireless LAN Controller [14e4:4318] (rev 02) not working reliably using ndiswrapper+wmp54gs driver on home-built pc in Ubuntu 9.04 - wireless PCI card is a Linksys WMP54GS

Asked by alleycatuk

Hi, I'm new to Ubuntu and am having wireless problems.
I managed to get ndiswrapper to work with my windows drivers and have configured wpa_supplicant for WPA2 but it won't work on startup.
In fact, wpa_supplicant only seems to work when started from a terminal window. It does find the router and says that the key is accepted.
I start it in terminal 1 then do a dhclient wlan0 in terminal window 2 BUT it only seems to show DHCKACK once every few tries. When it doesn't work, I have to kill wpa_supplicant, star everything up again and try again. After a few goes, it works and gets an ip address. It seems to start working if I swap windows i.e. if wpa_supplicant was running in terminal 1 and I was trying dhclient in terminal 2, kill wpa_supplicant and run it in terminal 2 then try dhclient in terminal 1. Not sure if it's just my imagination but it seems to work more often just after I swapped terminal windows.

I've tried reading loads of how-to's but they didn't solve it, despite trying.... and even posted a question on ubuntoforums but don't get any reply.

Please help - I really want to get it working but if I can't get the network to be reliable, I'll have to go back to XP.

Thanks in advance

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu gnome-nettool Edit question
Assignee:
No assignee Edit question
Solved by:
Mark Rijckenberg
Solved:
Last query:
Last reply:
Revision history for this message
Mark Rijckenberg (markrijckenberg) said :
#1

Hi,

Please first connect your network card to the wireless router using an ethernet cable (also known as a LAN cable).

In order to gather essential troubleshooting information about your wireless card, please follow this procedure:

Step 1: Open Terminal from "Applications->Accessories->Terminal"

Step 2: Run the following command. The command STARTS with the word sudo and ENDS with the word restart. So please copy-paste the ENTIRE command below into a Terminal, press enter, then enter password when sudo asks for password, then press enter again.

sudo lshw -C network; sudo iwlist scanning; cat /etc/network/interfaces; cat /etc/lsb-release; lspci -nn; lsusb; uname -a; dmesg | grep ound; dmesg | grep b43; dmesg | grep iwl; iwconfig; sudo /etc/init.d/networking restart

Step 3: Please post results (copy/paste terminal output) on this thread

Step 4: Please also specify the exact model and make of your PC (if known) on this thread

Regards,

Mark

Revision history for this message
alleycatuk (alleycat-uk) said :
#2

Mark,

thank you for the reply! I can't use a wired connection as the PC has no ethernet card. I do have one somewhere but I can't find it! I was looking for it the other day but have no idea where it is. As I mentioned, just from trying resets over and over again, I can get the wireless working so I hope the output of your 'script' is ok on that basis? I ran it before doing multiple resets of wpa_supplicant and dhcp that have allowed me eventually to get online. If it needs a fixed cable, please do let me know. Anyway, the output is below.

Thanks again.

The PC is really a home build so no make and model as such. It's based on an Abit motherboard with an Intel P4 if that helps. As you'll probably see from the output, wireless card is a Linksys WMP54GS. I'm basically trying to get an old PC running as a LAMP server for some testing. The set up of everything went better than I could have dreamt until I hit the problem of connecting to the network.

If I run wpa_supplicant in daemon mode, I get an error
wpa_supplicant: /sbin/wpa_supplicant daemon failed to start
run-parts: /etc/network/if-pre-up.d/wpasupplicant exited with return code 1

I've also seen posts that say use the -Bw switch for daemon but mine says that the w isn't a recognised command (it's v0.6.6)

If you need any more info, please do let me know as I'm very grateful for your help.

Regards
Alastair

  *-network
       description: Wireless interface
       product: BCM4318 [AirForce One 54g] 802.11g Wireless LAN Controller
       vendor: Broadcom Corporation
       physical id: 2
       bus info: pci@0000:02:02.0
       logical name: wlan0
       version: 02
       serial: 00:16:b6:9e:ab:5a
       width: 32 bits
       clock: 33MHz
       capabilities: bus_master ethernet physical wireless
       configuration: broadcast=yes driver=ndiswrapper+wmp54gs driverversion=1.53+Linksys,12/22/2004, 3.100.4 latency=32 link=yes module=ndiswrapper multicast=yes wireless=IEEE 802.11g
  *-network DISABLED
       description: Ethernet interface
       physical id: 1
       logical name: pan0
       serial: 8e:19:cd:3e:50:a3
       capabilities: ethernet physical
       configuration: broadcast=yes driver=bridge driverversion=2.3 firmware=N/A link=yes multicast=yes
lo Interface doesn't support scanning.

wlan0 Scan completed :
          Cell 01 - Address: 00:16:B6:C9:05:32
                    ESSID:"alleycatwlan"
                    Protocol:IEEE 802.11g
                    Mode:Managed
                    Frequency:2.462 GHz (Channel 11)
                    Quality:46/100 Signal level:-66 dBm Noise level:-96 dBm
                    Encryption key:on
                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 6 Mb/s; 9 Mb/s
                              11 Mb/s; 12 Mb/s; 18 Mb/s; 24 Mb/s; 36 Mb/s
                              48 Mb/s; 54 Mb/s
                    Extra:bcn_int=100
                    Extra:atim=0
                    IE: IEEE 802.11i/WPA2 Version 1
                        Group Cipher : CCMP
                        Pairwise Ciphers (1) : CCMP
                        Authentication Suites (1) : PSK

pan0 Interface doesn't support scanning.

auto lo
iface lo inet loopback
auto wlan0
iface wlan0 inet dhcp
wpa-ap-scan 1
pre-up sudo /sbin/wpa_supplicant -B -Dwext -iwlan0 -c/etc/wpa_supplicant.conf
pre-up sleep 5
post-down sudo killall -q wpa_supplicant

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=9.04
DISTRIB_CODENAME=jaunty
DISTRIB_DESCRIPTION="Ubuntu 9.04"
00:00.0 Host bridge [0600]: Intel Corporation 82850 850 (Tehama) Chipset Host Bridge (MCH) [8086:2530] (rev 02)
00:01.0 PCI bridge [0604]: Intel Corporation 82850 850 (Tehama) Chipset AGP Bridge [8086:2532] (rev 02)
00:1e.0 PCI bridge [0604]: Intel Corporation 82801 PCI Bridge [8086:244e] (rev 04)
00:1f.0 ISA bridge [0601]: Intel Corporation 82801BA ISA Bridge (LPC) [8086:2440] (rev 04)
00:1f.1 IDE interface [0101]: Intel Corporation 82801BA IDE U100 Controller [8086:244b] (rev 04)
00:1f.2 USB Controller [0c03]: Intel Corporation 82801BA/BAM USB Controller #1 [8086:2442] (rev 04)
00:1f.3 SMBus [0c05]: Intel Corporation 82801BA/BAM SMBus Controller [8086:2443] (rev 04)
00:1f.4 USB Controller [0c03]: Intel Corporation 82801BA/BAM USB Controller #1 [8086:2444] (rev 04)
00:1f.5 Multimedia audio controller [0401]: Intel Corporation 82801BA/BAM AC'97 Audio Controller [8086:2445] (rev 04)
01:00.0 VGA compatible controller [0300]: ATI Technologies Inc Radeon RV200 QW [Radeon 7500] [1002:5157]
02:00.0 FireWire (IEEE 1394) [0c00]: Agere Systems FW323 [11c1:5811] (rev 04)
02:01.0 USB Controller [0c03]: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller [1106:3038] (rev 61)
02:01.1 USB Controller [0c03]: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller [1106:3038] (rev 61)
02:01.2 USB Controller [0c03]: VIA Technologies, Inc. USB 2.0 [1106:3104] (rev 63)
02:02.0 Network controller [0280]: Broadcom Corporation BCM4318 [AirForce One 54g] 802.11g Wireless LAN Controller [14e4:4318] (rev 02)
02:03.0 Multimedia audio controller [0401]: Ensoniq 5880B [AudioPCI] [1274:5880] (rev 02)
02:04.0 Communication controller [0780]: ESS Technology ES2898 Modem [125d:2898] (rev 03)
Bus 003 Device 002: ID 1241:1177 Belkin F8E842-DL Mouse
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Linux alleyserver 2.6.28-15-generic #48-Ubuntu SMP Wed Jul 29 08:54:56 UTC 2009 i686 GNU/Linux
[ 0.000000] found SMP MP-table at [c00f5570] 000f5570
[ 0.853829] ACPI: No dock devices found.
[ 0.895445] pnp: PnP ACPI: found 15 devices
[ 2.464460] isapnp: No Plug & Play device found
[ 3.212222] hub 1-0:1.0: USB hub found
[ 3.212947] hub 2-0:1.0: USB hub found
[ 3.213489] hub 3-0:1.0: USB hub found
[ 3.214047] hub 4-0:1.0: USB hub found
[ 3.214612] hub 5-0:1.0: USB hub found
[ 3.216500] device-mapper: multipath round-robin: version 1.0.0 loaded
[ 3.220283] BIOS EDD facility v0.16 2004-Jun-25, 0 devices found
[ 14.507613] Control name 'Sigmatel Surround Phase Inversion Playback Switch' truncated to 'Sigmatel Surround Phase Inversion Playback '
lo no wireless extensions.

wlan0 IEEE 802.11g ESSID:"alleycatwlan"
          Mode:Managed Frequency:2.462 GHz Access Point: 00:16:B6:C9:05:32
          Bit Rate=54 Mb/s Tx-Power:25 dBm
          RTS thr:2347 B Fragment thr:2346 B
          Power Management:off
          Link Quality:43/100 Signal level:-68 dBm Noise level:-96 dBm
          Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
          Tx excessive retries:0 Invalid misc:0 Missed beacon:0

pan0 no wireless extensions.

 * Reconfiguring network interfaces... * Stopping the Firestarter firewall...
   ...done.
 * Starting the Firestarter firewall...
   ...fail!
run-parts: /etc/network/if-down.d/50firestarter exited with return code 2
RTNETLINK answers: No such process
Internet Systems Consortium DHCP Client V3.1.1
Copyright 2004-2008 Internet Systems Consortium.
All rights reserved.
For info, please visit http://www.isc.org/sw/dhcp/

Listening on LPF/wlan0/00:16:b6:9e:ab:5a
Sending on LPF/wlan0/00:16:b6:9e:ab:5a
Sending on Socket/fallback
DHCPRELEASE on wlan0 to 192.168.1.1 port 67
send_packet: Network is unreachable
send_packet: please consult README file regarding broadcast address.
 * Reloading /etc/samba/smb.conf smbd only
   ...done.

Revision history for this message
alleycatuk (alleycat-uk) said :
#3

I forgot to say, before getting your reply, I saw another post that recommended wpa_gui for being able to see what's happening.
When I bring up wpa_supplicant manually, wpa_gui is showing that a network has been added and that the and says STATUS Completed and that the authentication is complete - it also shows my ssid and the router's MAC, which it can obviously see. The only thing missing is the IP address.
This is what dhclient seems to struggle to resolve. I've tried with the /etc/interfaces/ file set to a static ip address but that still didn't connect.
Does anything in the dhcp conf file need to be changed?

Thanks again

Alastair

Revision history for this message
Best Mark Rijckenberg (markrijckenberg) said :
#4

Hi,

First of all, you absolutely need a wired internet connection to be able to easily install the right firmware for the BCM4318 chipset. It can be done without a wired or wireless internet connection, but it is too complicated.

Secondly, you should be using the b43-pci-bridge driver instead of the ndiswrapper driver, as you can see in the solution procedures below for the BCM4318 chipset:

https://answers.launchpad.net/~markrijckenberg/+questions?field.search_text=BCM4318&field.sort=NEWEST_FIRST&field.sort-empty-marker=1&field.actions.search=Search&field.language=en&field.language-empty-marker=1&field.status=SOLVED&field.status-empty-marker=1

You will also need the wired ethernet cable to connect your pc to the wireless router, so that you can temporarily disable encryption on the router itself, enable SSID broadcasting and also make sure that DHCP is enabled on the wireless router.

So please try this procedure:

First connect your network card to the wireless router using an ethernet cable (also known as a LAN cable).

Step 1: Open Terminal from "Applications->Accessories->
Terminal"

Step 2: Run the following commands AFTER you have successfully obtained a working, wired internet connection (copy-paste each line below to the Terminal then hit <enter> after each line)

sudo aptitude update
sudo aptitude dist-upgrade
sudo aptitude install b43-fwcutter

Step 3: Please post output of commands on this thread.

Step 4: Open a terminal and enter the following command:

gksudo gedit /etc/modprobe.d/blacklist.conf

# Add the following line at the end of the blacklist.conf file:

blacklist ndiswrapper

Step 5: Open a terminal and enter the following command:

gksudo gedit /etc/network/interfaces

# Make sure the /etc/network/interfaces file only contains the following 2 lines:

auto lo
iface lo inet loopback

# Save the above changes

Step 6: Reboot and retest wireless

Regards,

Mark

Revision history for this message
alleycatuk (alleycat-uk) said :
#5

Mark,
THANK YOU!!!!!!!

I was pulling what's left of my hair out with this and being new to Ubuntu I'd just followed the recommendations I'd found without knowing what's what. I think I've learnt a lot in the last 10 days but before your advice, I was about to give up.

I now have a wireless connection that is going from the moment of boot up and works very nicely!

Thanks again. I'd buy you a beer if it were possible but hopefully you'll accept a 'virtual' one?

Cheers

Alastair

Revision history for this message
alleycatuk (alleycat-uk) said :
#6

Thanks Mark Rijckenberg, that solved my question.

Revision history for this message
Mark Rijckenberg (markrijckenberg) said :
#7

Hi,

I accept your virtual beer, as long as it is not Heineken ;-)

I live in Belgium, so I know what good beer is like :-p

Happy to see your wireless issue is solved.

Kind regards,

Mark

Revision history for this message
alleycatuk (alleycat-uk) said :
#8

Mark I would never dream of offering a friend Heineken!!
I'd definitely get you a Leffe.... Blond or Brun, whichever is your preference! :)