Friday, February 12, 2010

Make Windows XP drivers work under Linux through ndiswrapper

Ndiswrapper is a wrapper that can be used to wrap windows drivers enabling them to use under Linux environment. This is available for drivers of wireless network devices. The supported devices can be found here.

Here, I will tell you how to configure D-Link DWA-120 wireless USB adapter to work under Linux. I did this in Ubuntu 9.10. As I've seen this should work for D-Link DWA-110 adapter as well.

  1. Plug the device
  2. Enter following commands in the terminal.
sudo su
-Perform following in root.
apt-get update
apt-cache search ndiswrapper
-In it you can find ndiswrapper-common, ndiswrapper-utils-1.9 packages. Install them by,
apt-get install ndiswrapper-common
apt-get install ndiswrapper-utils-1.9
-Change the folder to where the windows XP drivers for your network device is.
ndiswrapper -i filename.inf
-Give the name of .inf file for the driver. For DWA-120 it is netA5AGU.inf
ndiswrapper -m
modprobe ndiswrapper
Add the line "ndiswrapper" (without quotes) at the end of the file /etc/modules using command "sudo gedit /etc/modules" to load the driver every time the system loads. If you do not want to load the driver automatically, do not edit this file. Instead, enter following command at terminal to turn on the adapter.
sudo modprobe ndiswrapper
3. reboot the machine

All done. You can check whether your device working by typing "iwconfig".


This is how I enabled my wi-fi adapter to connect to wi-fi network. Does this helped you to as well? Any particular issues you encountered? Let us know in the comments.

13 comments:

  1. It worked perfectly for me, thanks!

    ReplyDelete
  2. newbie to linux:
    ubuntu 11.04 shows the wireless network but does not start DLINK-DWA-120.sudo lsusb just hangs the terminal. more config required i think.

    ReplyDelete
  3. Make sure you used the file name netA5AGU.inf, at the step
    ndiswrapper -i filename.inf

    This file must be in your current working directory.

    ReplyDelete
  4. Hi I've just installed ubuntu 11.10
    Everything you pointed out in your tutorial worked perfectly, until i installed the updates for Ubuntu.
    Once you start up , and log in to Ubuntu. then type "modprobe ndiswrapper" - everything crashes. My pc goes crazy and i cannot do anything except reboot. If you have any information to help i would be really thankful.
    - Giles

    ReplyDelete
  5. It worked for me, thank you!
    (Ubuntu 10.04)

    ReplyDelete
  6. I have a 64-bit Ubuntu 11.10, as I can run this Blast?? I find the driver for 64-bit?

    ReplyDelete
  7. sudo modprobe ndiswrapper
    fatal ndiswrapper not found
    (BackTrack 5) HELP!!

    ReplyDelete
  8. sudo modprobe ndiswrapper
    fatal ndiswrapper not found
    (BackTrack) HELP!!

    ReplyDelete
  9. video explanation would be better as am a fresh meat

    ReplyDelete
  10. hey i am completly a newbie and i have kali linux and i dnt knw what to do to configure my dlink dwa 120 as it can not be detected please help

    ReplyDelete
  11. Hi, what would I need to do to get the DWA-120 to work on Debian 64bit, or am I just out off luck?

    ReplyDelete