# Wireless / ndiswrapper -  [ SOLVED ]

## HeXiLeD

I was trying  to set up  my wireless mobo builtin card using ndiswrapper but i am having some problems

wireless is all new to me so i will explain the problem and if anyone knows anything  that can help me  i would be very thankfull.

mboard :

http://usa.asus.com/products/mb/socket775/p5ad2-e-p/overview.htm

lspci : 

0000:01:00.0 Ethernet controller: Marvell Technology Group Ltd. 88W8310 and 88W8000G [Libertas] 802.11g client chipset (rev 07)

net-wireless/wireless-tools installed

net-wireless/ndiswrapper : 1.2 installed

lsmod :

Module                  Size  Used by

ndiswrapper           184176  0

# ndiswrapper -l

Installed ndis drivers:

mrv8ka51        driver present, hardware present

I installed the drivers from asus

manual  that i was reading : http://ndiswrapper.sourceforge.net/mediawiki/index.php/Main_Page

and for some reason  i cant bring the wireless card up .

Any ideas ? maybe another driver to try to use ?

----------

## Havin_it

Hi,

To have ndiswrapper create an interface for the card, you also need to do

```
ndiswrapper -m
```

to add the line "alias wlan0 ndiswrapper" to /etc/modules.conf.  You also have to add configuration directives to either /etc/conf.d/net or /etc/conf.d/wireless - have you done this?

----------

## HeXiLeD

Well.. the only thing  missing is /etc/conf.d/wireless .

but how can i do that if 

# iwconfig

lo        no wireless extensions.

sit0      no wireless extensions.

ip6tnl0   no wireless extensions.

eth0      no wireless extensions.

eth1      no wireless extensions.

eth2      no wireless extensions.

vmnet1    no wireless extensions.

vmnet8    no wireless extensions.

 ....i should have  the wireless nic here . none of these is the wireless one.

----------

## Havin_it

Blimey - well you are not short of NICs!

First, you have three ethernet NICs there - is this correct, or might one of them be the wireless card?

If you're not sure, you can check how the system identifies them with

```
dmesg | grep eth0

#repeat for eth1, eth2
```

If one of these turns out to be the wireless card, you'll need to alter /etc/modules.conf accordingly.  Open it in your favourite editor as root, find the line 'alias wlan0 ndiswrapper' and substitute eth0 or whichever is the wireless NIC.

You'll also want to add configuration info for your network to the file /etc/conf.d/wireless and/or /etc/conf.d/net - for instructions on how to compose these files, look at net.example and wireless.example in /etc/conf.d.

You might also want to make the wireless network come up at boot.  In this case you need two things: add the line 'ndiswrapper' [no quotes] to /etc/modules.autoload.d/kernel-2.6 and ensure there is a symlink to /etc/init.d/net.lo from /etc/init.d/net.eth0 (or whichever interface it is)

You can start the interface by running 

```
/etc/init.d/net.eth0 start

#...and if it works, to make it start at boot...#

rc-update add net.eth0 default
```

When you reboot it should then try to come up automatically.  Just ask if you have questions about any of these steps!

----------

## HeXiLeD

Well... i know what  you are saying ...

But the problem  is the only thing missing  is the wireless card being "detected"

All those nics are wired  i have 2 builtin GB nics  and a pci 100mb nic too.

As for the the vmnet one they are from vmware ( they are virtual )

the rest its how the system is.

Now  the only .conf  missing is /etc/conf.d/wireless

All the other confs are done as you mentioned

/etc/modules.conf

# Internal Aliases - Do not edit

# ------------------------------

alias wlan0 ndiswrapper

/etc/modules.autoload.d/kernel-2.6

#wireless

ndiswrapper

as for  /etc/init.d/net.eth0, i want it to use the wirered nic.

i want to be able to have the wired and wirelss working at the same time

as for : /etc/conf.d/wireless , this is  the only thing i havent done yet because if the wireless nic is not detected how can i make its conf ?

----------

## Havin_it

net.eth0 was just an example based on the possibility of eth0 being found to be the wireless card (which it's not).

You should in that case issue the following (as root)

```
cd /etc/init.d

ln -s net.lo net.wlan0

rc-update add net.wlan0 default
```

As for /etc/conf.d/wireless, there are detailed instructions in /etc/conf.d/wireless.example - if you don't have this file at all, let me know and I'll post an example config.  It only gets complex if you have a series of APs to configure.

PS - You should have a look at dmesg | grep ndiswrapper to see what the driver is doing.

----------

## HeXiLeD

i belive this is the problem :

# dmesg | grep ndiswrapper

ndiswrapper version 1.2 loaded (preempt=no,smp=yes)

ndiswrapper (check_nt_hdr:152): Windows driver is not 64-bit; bad magic: 010B

ndiswrapper (load_sys_files:520): unable to prepare driver 'mrv8ka51'

<ffffffff883e11cb>{:ndiswrapper:unload_ndis_driver+137}

Modules linked in: ndiswrapper nvidia

RIP: 0010:[<ffffffff883e11cb>] <ffffffff883e11cb>{:ndiswrapper:unload_ndis_driver+137}

Call Trace:<ffffffff883e2348>{:ndiswrapper:wrapper_ioctl+4426}

RIP <ffffffff883e11cb>{:ndiswrapper:unload_ndis_driver+137} RSP <ffff81003b901dd8>

 <3>ndiswrapper (ndiswrapper_load_driver:93): loadndiswrapper failed (9); check system log for messages from 'loadndisdriver'

and i just downloaded the latest asus 64bit drivers ..  :Sad: 

==================================

eheh new drivers . wlan0 is up ! later i will check things ....

----------

## frenkel

You need to select wireless support in the kernel first, before you can use ndiswrapper...

----------

## HeXiLeD

okay... lets double check this 

kernel wireless settings are :

<*> 802.1d Ethernet Bridging                                                           

<*> 802.1Q VLAN Support       

my wireless windows driver is :

Version   	  V2.7.1.2   	  2005/02/16 update

OS 	           WinXP / Win2003

Description 	Marvell WiFi Driver V2.7.1.2 beta client for windows 64bit XP/2003.

File Size 	   2.25 (MBytes)

from : http://dlsvr03.asus.com/pub/ASUS/lan/wifi-g/WIFI_V2712_64bit.zip

#  iwconfig

lo        no wireless extensions.

sit0      no wireless extensions.

ip6tnl0   no wireless extensions.

eth0      no wireless extensions.

eth1      no wireless extensions.

eth2      no wireless extensions.

vmnet1    no wireless extensions.

vmnet8    no wireless extensions.

Warning: Driver for device wlan0 recommend version 18 of Wireless Extension,

but has been compiled with version 17, therefore some driver features

may not be available...

wlan0     IEEE 802.11FH  ESSID:off/any

          Mode:Managed  Channel:0  Access Point: 00:00:00:00:00:00

          Bit Rate=54 Mb/s   Sensitivity=-200 dBm

          RTS thr:off   Fragment thr:off

          Encryption key:off

          Power Management:off

          Link Quality:100  Signal level:0  Noise level:0

          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0

          Tx excessive retries:0  Invalid misc:2   Missed beacon:0

ifconfig gives me :

wlan0  Link encap:Ethernet  HWaddr 00:11:D8:2A:53:FE

          inet6 addr: fe80::211:d8ff:fe2a:53fe/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

          Memory:caca0000-cacaffff

# lsmod

Module                  Size         Used by

ndiswrapper           184176    0

# ndiswrapper -l

Installed ndis drivers:

mrv8knt driver present, hardware present

# dmesg | grep ndiswrapper

ndiswrapper (wrapper_worker_proc:1095): wlan0 is being reset

# /etc/init.d/net.wlan0 restart

 * Starting wlan0

 *   Configuring wireless network for wlan0

 *     no access points found

 *   Couldn't find any access points on wlan0

 *   Failed to configure wireless for wlan0   

The only thing  i am missing now is one .conf

this : /etc/conf.d/wireless

I have  /etc/conf.d/wireless.example but i would like to see one simple working conf from anyone if possible.

If everything  is ok and all   i am missing now is to do  /etc/conf.d/wireless conf; let me know.

There is also one other detail about my wireless nic. it can work as a wireless router too, but right now i just want  to client to work.

mobo : http://www.asus.com/products/mb/socket775/p5ad2-e-p/overview.htm

----------

## TWO515TY

Yay, another P5AD2-E Premium user. Getting some of my hardware (mainly the network stuff) to work with this mobo was a mofo, but in the end, I got it going.

Basically, to get the wireless working, you need to use ndiswrapper-1.0, not 1.2. Go to the ndiswrapper website, download and compile ndiswrapper-1.0 (I think you can emerge it, but I'm not sure). Install the necessary drivers, then do 

```
modprobe ndiswrapper
```

and you should be able to use the wireless-tools to get it going from there. 

Do note though that although this process worked for, me, I was using a 32 bit-install, and 32-bit drivers. It may be different if you're on a 64-bit install and using 64-bit drivers.

----------

## HeXiLeD

Yes i am 64bit. I will try your solution later if nothing else works.

----------

## frenkel

 *Blue-Steel wrote:*   

> okay... lets double check this 
> 
> kernel wireless settings are :
> 
> <*> 802.1d Ethernet Bridging                                                           
> ...

 

copy /etc/conf.d/wireless.example to /etc/conf.d/wireless and configure it to your needs, if you don' t understand how, give me some info about your accesspoint, are you using WEP, WPA, nothing...

----------

## Havin_it

Here's an example config for a static-IP connection to a router with WEP authentication.

```

config_wlan0=( "192.168.0.2 netmask 255.255.255.0" )

routes_wlan0=( "default gw 192.168.0.1" )

essid_wlan0="myAPname"

mode_wlan0="managed"

key_wlan0="AAAAAAAAAAAAAAAAAAAA"
```

If your AP uses WPA authentication, you need to use wpa_supplicant instead of the normal wireless-tools.  You can read about how to use it HERE.

----------

## HeXiLeD

I was finally able to use my wireless for a simple test.

I can say that this problem had a solution and it is now solved.

Gentoo detected and got connected to a wireless router.

There are some details about  the wireless .confs  but they are not a big issue for now since i still use wired connection most of the time.

The important is that the Marvell Technology Group Ltd. 88W8310 and 88W8000G [Libertas] 802.11g client chipset (rev 07)  works on gentoo with ndiswrapper.

Thank  you

----------

