Using Ndiswrapper
From MEPIS Documentation Wiki
Contents |
Introduction
Ndiswrapper is an open source software driver "wrapper" that enables the use of Microsoft Windows drivers for wireless network devices in Linux. MEPIS comes with Ndiswrapper pre-installed, however you can download newer Ndiswrapper version from the project download page.
Note that you MUST use a Windows 32-bit driver if you have Mepis 32-bit edition and you MUST use a Windows 64-bit driver if you have Mepis 64-bit edition. In general, Windows-XP drivers work much better than Vista drivers, so try the Windows-XP driver first.
Installation
- First, make sure your wireless device is recognized by opening a terminal and typing:
lspci -nn
to look for your device.
- Then, check if your card is already supported in Ndiswrapper, by a Mepis pre-loaded Windows driver:
ndiswrapper -l
If 'hardware present' or 'device present' shows up, you can jump to the next section!
- If not, obtain the Windows driver, either from the CD that comes with the wireless card or download it from the Internet. Check this list first. In general, drivers for Windows XP should work well unless your system is very old.
- Copy the entire driver directory to a folder in the Linux partition.
- It is a good idea now to remove all the other drivers before installing the one you want to use. Type as root:
ndiswrapper -e drivername
Remove each driver one at a time until all the drivers have been removed. Even if you see a driver in ndiswrapper that is the same name or the same as the one ndiswrapper will build for you it may not work so it is a good idea to remove them all.
- (A little shortcut is to type the command ndiswrapper -e into konsole and hit enter. It won't do anything without a driver name, but by pressing the up arrow key you can scroll through the commands you have typed in until ndiswrapper -e shows up, then just add the drivername and hit enter. It speeds things up a bit.)
- Then unload the ndiswrapper module by typing as root:
modprobe -r ndiswrapper
If you want to check, type lsmod | grep ndiswrapper and you should get nothing in return.
- Change directory to that folder with the Windows drivers (you can open it with Konqueror and then press F4)
- Run as root:
ndiswrapper -i <.inf file>
where <.inf file> is the name of the driver file that has the .inf extension
- An example of the above command would be
ndiswrapper -i 8185.inf
- Now, check that Ndiswrapper has bound to a specific installed Windows driver. If 'hardware present' or 'device present' shows up next to your installed Windows driver, it is!
ndiswrapper -l
- Now reload the module back into the kernel:
modprobe ndiswrapper
- and create the 'wlan0' alias:
ndiswrapper -m
- Lastly, we need to create a 'blacklist' entry into the file '/etc/modprobe.d/blacklist', to instruct the system to NOT use the 'alternate' (native) driver. The 'alternate-driver' name should be listed on the 'device ... present' line from 'ndiswrapper -l' cmd. For example, the blacklist-entry for alternate 'ath_pci' driver will be appended into that file with cmd:
echo 'blacklist ath_pci' >>/etc/modprobe.d/blacklist
- Now reboot the machine.
Wireless setup
GUI method
- Follow these directions to reconfigure the WiFi connection from MEPIS utilities (6.0), or MEPIS Network Assistant (mnetwork). Please note: you must enter an SSID on the WiFi/Wireless tab of MEPIS Utilities or Network Assistant, even if your router is set to broadcast the SSID (ESSID)!
- Reboot and you should be connected.
CLI method
- Type as root:
iwconfig
to see what your wireless interface is. Let's pretend it is wlan0, though the name might be different depending on your hardware.
- Now you need to provide the name of your network by typing as root:
iwconfig wlan0 "NetworkName"
- Now when you reboot, you should be connected.
Connecting to a specific network
MEPIS Network Assistant does not have a scan function, and will simply hook up with the strongest network it finds. You can install a graphical wireless front end application that does have scanning (such as Wicd), and connect to the network you want. Or open a terminal, become root, and type:
iwlist wlan0 scan
Then to connect to the network you wish by using using this command again:
iwconfig wlan0 "NetworkName"
Links
- Archived-list of cards known to work
- Detailed wireless directions
- Graphical guide to the MEPIS Network Assistant

