Image via Wikipedia
The Hardware
In despair my wife and I ran out to the local Circuit City store hunting for an all in one solution to provide portable networking capabilities. After looking over the D-Links, Linksys, Netgear, and Belkin networking devices we both went for the Belkin Wireless G USB Network Adapter. The Adapter easily connects your USB-equipped desktop or notebook computer to your wireless network for Internet and file sharing. Desktop users can now join the network with the ease of a USB plug-in, without opening their PC cases; laptop users can enjoy the benefits of staying mobile-while connected to the Internet.The Systems -- The main operating systems I'll be using includes; Ubuntu Breezy Badger (5.10), Windows XP, and Debian Sarge (Stable). For the sakes of simplicity I will not include instructions for Windows XP and will concentrate on my Ubuntu laptop setup with a few side notes for Debian Base users.
Ubuntu Breezy Configuration
Ubuntu users are lucky enough to have just about everything they need already configured in the kernel by the default installation. Due to Belkin being a Windows device the use of a NDIS Wrapper is required.The Network Driver Interface Specification (NDIS) is an application programming interface (API) for network interface cards (NICs). It was jointly developed by Microsoft and 3Com Corporation, and is mostly used in Microsoft Windows on Intel-based computers, but the open-source ndiswrapper project allows many NDIS-compliant NICs to be used with Linux.
Sounds complicated, eh? Do not fret, Ubuntu (as mentioned above) is stocked and ready for this use. ndiswrapper, wireless-tools, and the kernel modules are already installed. Simply download and installed the ndiswrapper-utils via terminal like so;
sudo aptitude -P install ndiswrapper-utils
This package contains the userspace tools. The default Ubuntu kernel already provides the required modules. If you use a custom kernel, you might also need the kernel module package.
The next step is to install the drivers for the Belkin USB network interface. Insert the driver's CD and browse to your *.inf driver (be sure your CD-Rom is mounted);
cd /media/cdrom0/drivers/
Then I would suggest that you plug in your Belkin network adapter and time to install the drivers via;
sudo ndiswrapper -i rt2500usb.inf
You will receive a conformation if everything is successfully installed and detected. To recofirm you can simply type;
sudo ndiswrapper -l
You will (should) be displayed with;
rt2500usb driver present, hardware present. To have this module loaded on boot you will want to;
sudo ndiswrapper -m
sudo ndiswrapper -hotplugYou will see something on the lines of; alias wlan0 ndiswrapper. Now you MUST include this new interface in your /etc/network/interfaces file;
sudo vi /etc/network/interfaces
Arrow the whole way to the bottom and start a new line by pressing the letter O. For simplicity sake add the following;
iface wlan0 inet dhcp
auto wlan0press the Esc key, then
:wq to Write and Quit the file. If all has gone well you are ready to use the USB adapter. To bring your new interface on line try the following near or around your wireless router (fingers crossed);
sudo ifup wlan0
Unplug the messy Ethernet cable and go-go wifi access. You will see the Belkin blink green as data is transferred.
For other people's methods on doing the basic same thing might I suggest;
- http://ndiswrapper.sourceforge.net/mediawiki/index.php/Ubuntu
- http://lxer.com/module/newswire/view/46385/
In summary, I highly recommend the Belkin G USB Network Adapter as both a Linux and Windows interface.
Troubleshooting
How can I remove the driver?
You should be able to remove the ndiswrapper (man ndiswrapper) driver by using;
sudo ndiswrapper -e rt2500usb
See the list for your exact driver's name if you are using a different network adapter.
sudo ndiswrapper -l
What if /media/cdrom* doesn't exist?
Sounds like you are missing a symbolic link (man ln) to /dev/hdc.
sudo ln -s /dev/hdc /media/cdrom; sudo ln -s /dev/hdc /media/cdrom0
I am having problems setting this up with WPA. I am using wpa_supplicant and I can see the AP, but it is not accepting the key?
You are going to want to enable AP Broadcast on your Wifi router. Also, verify your /etc/default/wpasupplicant;
# ATTEMPT BELKIN 54G WPA ENABLED
ENABLED=1
OPTIONS="-i wlan0 -D ndiswrapper -c /etc/wpa_supplicant.conf -w"Feedback
Thanks for all the great feedback!hhh writes: Awesome, thank you so much. This should be stickied in the Networking forum as well.
nijinsky writes: I followed this guide. Absolutely great and everythig ran perfectly. [...] Took me days without success using other methods. This method took 10 minutes
bootsie writes: Thank You! I'm a newbie to linux and was quickly becoming frusterated with my lack of success after hours of reading ideas and trying to download and install drivers and tweak my network settings to get my belkin wireless adapter going on my desktop. Following your steps got me up and running in minutes!
Also See
- Easy Peasy Mount NTFS w/ Ubuntu (Linux) - This brief blog entry will note the steps required to properly mount a local NTFS hard-drive within Ubuntu Linux.
- Easy Peasy Ubuntu Linux NFS File Sharing - In this brief blog entry I will note the steps it took for me to use the Network File System (NFS) protocol to share files between another Linux computer.
- See the UbuntuForums.org topic for other comments



Excellent ! it works also
Excellent ! it works also with usr805422 (us robitics) - Thank you very much for this page
any ideas --rt73
i have the same card but the driver files are rt73,and this info does not work with my ubuntu 5.10, some ideas please.
sudo ndiswrapper -hotplug does not seem a valid command
I'm new to Ubuntu and linux in general. I tried following this walk through with dapper but I think it goes wrong at the "sudo ndiswrapper -hotplug" step as it just regurgitates a list of valid commands like -e and -i but not -hotplug.
"driver present, hardware
"driver present, hardware not present"
This is where it goes wrong, it cant find my nic, thats really strange cause he founded my
usb external hard disk immidiatelly.
Can anyone help me with this ?
RT73
I compiled the ralinktech module for the RT73 series of USB adapters. My vender card is D-Link WUA-1340 compiling is not hard to do, its keeping it working that seems to be the issue. I will stay connected for about a minute, then it will lose its connection.
Ubuntu 6.06
I am trying to connect using WPA-PSK with TKIP encryption, but it seems to work for only about a minute, then it dies, and configuring it on the system just freezes the system. I had better luck with Mandriva 2006 at least it doesn't freeze the system.
Help!
Hi,
thanks for the guide, but I am having problems at the end - I run;
"sudo ifup wlan0"
And I get;
"/etcnetwork/interfaces:8: unknown method
ifup: couldn't read interfaces file "/etc/network/interfaces""
Any Ideas???
Thanks! Almost there....
Thanks for these clear and simple steps to get wifi up and running with the device. It works for me fine but I can not boot the machine (or reboot) without needing to remove the d-link from my machine first, then plugging it in after I've fully booted onto my desktop. I can't simply leave it in there.
I followed your steps with my Ubuntu 6.10 PC.
Is there a step I missed?
Thanks,
Midia
Sooooo close I can taste it!!!
Please can someone help me on this.
The ndiswrapper -i has worked, and a -l says "driver present, hardware present"
I've added the neccessary lines to /etc/network/interfaces, but an ifup wlan0 doesn't work.
I get the following error:
Internet Systems Consortium DHCP Client V3.0.4Copyright 2004-2006 Internet Systems Consortium.
All rights reserved.
For info, please visit http://www.isc.org/sw/dhcp/
SIOCSIFADDR: No such device
wlan0: ERROR while getting interface flags: No such device
wlan0: ERROR while getting interface flags: No such device
Bind socket to interface: No such device
Failed to bring up wlan0.
Can anyone shed any light on this?
Thanks.
Re: Sooooo close I can taste it!!!
Hi,
Just a thought, but maybe your driver uses a different interface (i.e. not wlan0). My rt73 driver uses the 'rausb0' interface instead. What does the '/sbin/ifconfig' command show?
Colin
Soooo close I can taste it!! - Mark II
In the same dilemma as Toby, after nearly three days of trying to get this USB wireless dongle to work.
Have ended up installing lots of packages (e.g.
locales_2.3.22_all.deb, linux-libc-dev_2.6.17.1-11.35_i386.deb, libc6-dev_2.4-1ubuntu12_i386.deb, libc6_2.4-1ubuntu12_i386.deb, python_2.4.2-0ubuntu3_all.deb, python-glade2_2.8.6-0ubuntu1_all.deb, python-glade2_2.8.6-0ubuntu1_all.deb, python-gtk2_2.8.6-0ubuntu1_all.deb, ndiswrapper_1.8, ndiswrapper-utils-1.8_1.18-1ubuntu2_i386.deb) and run dozens of configuration commands.However when I issue the command "sudo ifup wlan0" I get the same error message
Internet Systems Consortium DHCP Client V3.0.4Copyright 2004-2006 Internet Systems Consortium.
All rights reserved.
For info, please visit http://www.isc.org/sw/dhcp/
SIOCSIFADDR: No such device
wlan0: ERROR while getting interface flags: No such device
wlan0: ERROR while getting interface flags: No such device
Bind socket to interface: No such device
Failed to bring up wlan0.
Ubuntu is my first adventure
Ubuntu is my first adventure into linux and I only installed it yesterday so I know nothing about anything!
But I hope these comments may help someone since this post was SO useful to me in getting my belkin USB adapter working.
My adapter is a version 2 and I used the rt2500usb.inf driver from the supplied disk.
I agree with the comment above that ndiswrapper -hotplug is not a valid command in the ndiswrapper supplied with Ubuntu 6.06.
In my setup when editing the interface file (iface wlan0; inet dhcp auto wlan0) I had to change wlan0 to rausb0. The device then shows as active in system - admin - network but if I input the details of my router into the connection when I click OK it freezes. This seems to be a common problem and one I am looking in to.
I found installing wlassistant (wireless assistant in the install menu) useful for showing that the wireless device was working - one can see networks with SSID broadcast enabled but I cannot connect using this app because when it runs it nags me about having insufficient permissions (I am working on this).
The way I did get it working was from terminal to use the commands iwconfig rausb0 essid "youressidhere" and iwconfig rausb0 key WEPkeyvalue. After inputting these the connection works fine! However the connection is not persistent on reboot.
I think the answer to both the wlassistant permissions and persistent connection are found in this thread
http://www.linuxquestions.org/linux/blog/w322/2006-09-09/Auto_connect_to...
which I am going to try tonight.
cannot connect
I did much the same, but with xubuntu instead (old computer). I was able to get the "hardware present, driver present" and when I executed the
iwconfigcommand I noted that it saidLink Quality: 0/0.The Network panel recognizes my router and I entered the same ESSID and password as I use on my wireless mac (and wife's wireless XP machine). Still it doesn't work. Any ideas?
Oh dear
Followed the guide but, i think I messed up..i do everything..and when i try the ifup wlan0...i get a message saying suplicate interfaces..cannot read....etc/network/interfaces
Help anyone?
No such drive or folder exists
When I put in the code for where my *.inf file is (cd /media/cdrom0/drivers/) I get a message saying no such drive or folder exists even though my cd is properly mounted. Is it possible to copy the drivers file into the computer then acces it from withon and if so what would the command look like. Cheers
WICD!
I have the WUA-1340 D-Link wireless adapter... took me a day and a half of searching, and just about the time i was about to give up (after fiddling for hours with ndiswrapper), I found WICD!
WICD is a network manager, and it takes the place of the "Network-manager" package that comes with ubuntu.
edit: I'm a noob like you, so don't expect me to know whats up if you run into problems with the way that I did this... (but I would like to know if you did)
I simply:
--uninstalled the Network-manager package (using System>Administration>synaptic package manager)
--installed the WICD package
(if you're accessing the internet from a windows computer, just download from sourceforge: [url]http://downloads.sourceforge.net/wicd/wicd_1.3.1-all.deb?modtime=1184023948&big_mirror=0[/url] )
--ran the WICD package, and it saw my router, and i clicked 'connect' and POOF! wireless internet!
I'm talking to you about 5 minutes after i got it working (I'm spreading the word.)
edit: I'm not sure if uninstalling network manager will disconnect your ubuntu system if you are currently accessing the internet from it (through wired connection, and trying to get wireless to work). So you might want to make sure you have the necessary file (the WICD .deb) downloaded before uninstalling network manager.
trying to set up an Ad-Hoc wireless network connection
Hi, Im trying to connect 2 laptops using an Ad-Hoc wireless connection using only Linux code. Im pretty new to Linux and Im trying to understand the coding but so far I have been pretty unsuccesfull about it. does anyone have an idea or can give me an idea what will be the steps or the coding that I need for this? thank you
Fantastic!
Hi - tried for days to get Ubuntu to recognise my Netgear WG311v3 including installing Wicd. Found your site, followed your instructions, removed Wicd, reinstalled network manager and "hey presto!" the wireless network registered my system and 4 others in the neighbourhood. So I'm wireless and ever so grateful.