Click to See Complete Forum and Search --> : How to automate ndiswrapper install with WEP key?
Mr.Newbie
06-04-2004, 09:34 AM
Hello people,
I setup my Broadcom BCM94306 module for wireless networking using the ndiswrapper on my laptop. The good news is that it worked.
The bad news is that when I restart my computer it does not work anymore. The INSTALL file gives me some instructions to automate the install process for my wireless module but I dont think it works if I use WEP key on my network.
Can anybody help me figure out how to automate the ndiswrapper WITH WEP KEY so that I don't have to reinstall it everytime I restart my computer?
Icarus
06-04-2004, 09:44 AM
What distro are you using?
Gentoo uses an init script to start the networking in /etc/init.d/net and the WAP key can be entered there
Also there is /etc/pcmcia/wireless.opts that is more common and the WAP key can be entered there
Mr.Newbie
06-04-2004, 09:53 AM
Originally posted by Icarus
What distro are you using?
Gentoo uses an init script to start the networking in /etc/init.d/net and the WAP key can be entered there
I am using Mandrake 10.0
Originally posted by Icarus
Also there is /etc/pcmcia/wireless.opts that is more common and the WAP key can be entered there
I am using WEP Key, will changing wireless.opts to enter WEP key work?
Icarus
06-04-2004, 10:28 AM
Whoops, I meant WEP...WAP is the access point! :p
Look at the wireless.opts file, It's well documented (comments galore!)
JayMan8081
06-04-2004, 11:20 AM
Try checking if you have /etc/sysconfig/network-scripts/ifcfg-wlan0. Depending on how your wireless is setup that wlan0 maybe something different. In my installation that is what starts up my wireless connection everytime I boot up. Mine looks something like this:
DEVICE=wlan0
CHANNEL=10
KEY=s:asciiwepkey
ESSID=The\ Realm
BOOTPROTO=dhcp
ONBOOT=yes
JayMan8081
06-04-2004, 11:24 AM
Also what version of the ndiswrapper are you trying to use?
Mr.Newbie
06-04-2004, 11:55 AM
I am using NDISwrapper version 0.4 because I read somewhere that NDISwrapper versions 0.5 through 0.7 do NOT work with my bcm94306
JayMan8081
06-04-2004, 12:41 PM
I don't currently have my Laptop with me, but when I get home this evening I will look at my configuration. I'm pretty sure I am using ndiswrapper version 0.5 or 0.6 and I have a built-in wireless card base on the bcm94306 chipset. I think it works better in Linux than it does under Windows. For ndiswrapper 0.4 you can check my How-I-Did-It post here. (http://www.justlinux.com/forum/showthread.php?s=&threadid=124190&highlight=ndiswrapper+mandrake) Just change the part where it talks about /etc/modules.conf to /etc/modprobe.conf since you are using a 2.6.X kernel with Mandrake 10. The installation for version 0.5 and 0.6 is a little more automated than it was for version 0.4, that' why I asked which version you were using.
JayMan8081
06-04-2004, 10:11 PM
Currently I am running ndiswrapper 0.6 with a 2.6.3 Mandrake build of the kernel. The install for 0.6 was considerably easier than the 0.4 installation was. Hope this helps you out.
Mr.Newbie
06-05-2004, 11:19 AM
Originally posted by Icarus
Whoops, I meant WEP...WAP is the access point! :p
Look at the wireless.opts file, It's well documented (comments galore!)
Well I tried using this file but it didn't work. I made following changes to the wireless.opts file:
# Generic example (decribe all possible settings)*,*,*,*)
ESSID="MyNetwork"
NWID=""
MODE="Managed"
FREQ=""
CHANNEL="10"
SENS=""
RATE=""
KEY="XXXXXXXXXXXXXXXXXXXXXXXX" < My WEP key
RTS=""
FRAG=""
IWCONFIG=""
IWSPY=""
IWPRIV=""
Following is what I have to do in konsole every time I restart my computer:
# modprobe ndiswrapper
# /usr/sbin/loadndisdriver 1234 5678 /lib/windrivers/bcmwl5.sys /lib/windrivers/bcmwl5.inf
# iwconfig wlan0 mode Managed
# iwconfig wlan0 key restricted XXXXXXXXXXXXXXXXXXXXXXXX
# iwconfig wlan0 essid MyNetwork
# ifconfig wlan0 up
Mr.Newbie
06-05-2004, 11:30 AM
Originally posted by JayMan8081
Currently I am running ndiswrapper 0.6 with a 2.6.3 Mandrake build of the kernel. The install for 0.6 was considerably easier than the 0.4 installation was. Hope this helps you out.
Ok I tried what you asked me to do. The ifcfg-wlan0 file already existed. I went in and made the following changes:
DEVICE=wlan0
CHANNEL=10
KEY=s:XXXXXXXXXXXXXXXXXXXXXXXX
ESSID=MyNetwork
BOOTPROTO=dhcp
ONBOOT=yes
But these changes did not fix the problem. I also followed the thread you asked me to look at. Well i have already done everything it says. I can establish a wireless connection BUT my settings still get lost when I restart.
Also, I dont know yet how to uninstall the old version of ndiswrapper so I wont attempt to install the newer version, unless you think that the newer version fill fix my problem.
Following is what I have to do in konsole every time I restart my computer:
# modprobe ndiswrapper
# /usr/sbin/loadndisdriver 1234 5678 /lib/windrivers/bcmwl5.sys /lib/windrivers/bcmwl5.inf
# iwconfig wlan0 mode Managed
# iwconfig wlan0 key restricted XXXXXXXXXXXXXXXXXXXXXXXX
# iwconfig wlan0 essid MyNetwork
# ifconfig wlan0 up
JayMan8081
06-05-2004, 11:51 AM
I think that the newer releases of ndiswrapper might solve your problem. At least the 0.6 one I really think it will. To remove the current driver try doing a make clean inside the ndiswrapper directory. I'm not 100% sure but I think that will remove all of the old code and modules. Then download ndiswrapper 0.6 and follow the INSTALL file. As I said before, it is a little more automated and I haven't run into any problems using it.
Mr.Newbie
06-07-2004, 09:26 PM
Originally posted by JayMan8081
I think that the newer releases of ndiswrapper might solve your problem. At least the 0.6 one I really think it will. To remove the current driver try doing a make clean inside the ndiswrapper directory. I'm not 100% sure but I think that will remove all of the old code and modules. Then download ndiswrapper 0.6 and follow the INSTALL file. As I said before, it is a little more automated and I haven't run into any problems using it.
Ok, I tried the version 6 of ndiswrapper (i know version 8 is also available but that didnt work for me either) and after following the INSTALL file, this is what I ended up with:
[root@localhost ndiswrapper-0.6]# ndiswrapper -l
ls: /etc/ndiswrapper: No such file or directory
No drivers installed
[root@localhost ndiswrapper-0.6]# ndiswrapper -i bcmwl5.inf
ls: /etc/ndiswrapper: No such file or directory
Installing bcmwl5
cp: cannot stat `bcmwl5.inf': No such file or directory
[root@localhost ndiswrapper-0.6]# ndiswrapper -l
Installed ndis drivers:
bcmwl5
[root@localhost ndiswrapper-0.6]# modprobe ndiswrapper
[root@localhost ndiswrapper-0.6]# dmesg
...
ndiswrapper: no version for "struct_module" found: kernel tainted.
ndiswrapper version 0.6 loaded
[root@localhost ndiswrapper-0.6]# iwconfig
lo no wireless extensions.
sit0 no wireless extensions.
eth0 no wireless extensions.
NO WLAN0. I can't continue further after this. v8 does the same thing. I also noticed that v6 and up dont ask for bcmwl5.sys file.
Any Ideas?
JayMan8081
06-08-2004, 09:21 AM
Right now I have final exams at school so I won't get a chance to look at my setup again until tomorrow night. I'll look then at my setup and see if I can find anything else that might help you out. Until then maybe somebody else has some ideas.
Mr.Newbie
06-10-2004, 09:13 AM
Does anybody have any clues on how to get bcm94306 to work with Mandrake 10.0????
JayMan8081
06-10-2004, 09:43 PM
Sorry it too me so long to get back to you about this.
First off make sure that you have the kernel sources installed for you kernel, which should be 2.6.3-mdk I think. Before you start to try and reinstall the driver again issue an updatedb at the command prompt as root. Then issue the following commands: locate ndiswrapper and then locate loadndisdriver. Delete all instances of loadnsiddriver that are listed by the locate command and also all instances of ndiswrapper that are not the uncompressed source from the tar.gz file. Then go to the ndiswrapper-0.6 directory. Do an su and enter the root password. Next type:[root@localhost ndiswrapper-0.6]# make install When you do that make sure to take note if there are any error messages displayed. If the make install finished correctly then issue the command ndiswrapper -i /path/to/inffile.inf which in my case was ndiswrapper -i /home/jhorsman/bcmwl5.inf Post any error messages that this command might give you as well. If you don't have any errors to this point then issue the command ndiswrapper -l as root still. The output should look like this:Installed ndis drivers:
bcmwl5 present Now you should be able to type modprobe ndiswrapper and have that return no messages, just go back to a command prompt. The next thing to do is type dmesg and towards the last couple of lines you should see something mentioning ndiswrapper. Next use iwconfig to setup all of your wireless settings and then try it out. If you get to this point, then issue the command ndiswrapper -m and reboot to see if the settings were maintained. You can use dmesg again after reboot to look for message pertaining to ndiswrapper to verify that the module is still loading. For a little while the ndiswrapper module would load for me, but wouldn't get the proper settings each time to get an IP from my DHCP router. Post any error messages that you get so maybe those can give an idea of where to look next.
Mr.Newbie
06-11-2004, 10:31 AM
Originally posted by JayMan8081
Sorry it too me so long to get back to you about this.
First off make sure that you have the kernel sources installed for you kernel, which should be 2.6.3-mdk I think. Before you start to try and reinstall the driver again issue an updatedb at the command prompt as root.
Then issue the following commands: locate ndiswrapper and then locate loadndisdriver. Delete all instances of loadnsiddriver that are listed by the locate command and also all instances of ndiswrapper that are not the uncompressed source from the tar.gz file. Then go to the ndiswrapper-0.6 directory. Do an su and enter the root password.
Hay Man, thanks for taking the time to help me out. Ok, here is what happens:
I tried running updateb. It doesn't recognize the command (I found out that its either not in my path or not installed, I will fix it when I get home). I ran a file search utility and removed any occurance of ndiswrapper stuff from my linux.
Then I downloaded the v6 of ndiswrapper and proceeded to install it. Here is what I end up with:
[root@localhost ndiswrapper-0.6]# ndiswrapper -i bcmwl5.inf
ls: /etc/ndiswrapper: No such file or directory <------------ Bothers Me
Installing bcmwl5
cp: cannot stat `bcmwl5.inf': No such file or directory
[root@localhost ndiswrapper-0.6]# ndiswrapper -l
Installed ndis drivers:
bcmwl5 <------------- Doesn't say present
After this its basically the same story that I explained two or three threads before.
Next type:[root@localhost ndiswrapper-0.6]# make install When you do that make sure to take note if there are any error messages displayed. If the make install finished correctly then issue the command ndiswrapper -i /path/to/inffile.inf which in my case was ndiswrapper -i /home/jhorsman/bcmwl5.inf Post any error messages that this command might give you as well. If you don't have any errors to this point then issue the command ndiswrapper -l as root still. The output should look like this:Installed ndis drivers:
bcmwl5 present Now you should be able to type modprobe ndiswrapper and have that return no messages, just go back to a command prompt. The next thing to do is type dmesg and towards the last couple of lines you should see something mentioning ndiswrapper. Next use iwconfig to setup all of your wireless settings and then try it out. If you get to this point, then issue the command ndiswrapper -m and reboot to see if the settings were maintained. You can use dmesg again after reboot to look for message pertaining to ndiswrapper to verify that the module is still loading. For a little while the ndiswrapper module would load for me, but wouldn't get the proper settings each time to get an IP from my DHCP router. Post any error messages that you get so maybe those can give an idea of where to look next. [/B]
JayMan8081
06-11-2004, 10:40 AM
Ok, I will check and see if I have an /etc/ndiswrapper and when you do ndiswrapper -i bcmwl5.inf try giving the absolute path for the bcmwl5.inf file and see if that can get rid of the cp: cannot stat `bcmwl5.inf': No such file or directory message.
Mr.Newbie
06-11-2004, 12:09 PM
Originally posted by JayMan8081
Ok, I will check and see if I have an /etc/ndiswrapper and when you do ndiswrapper -i bcmwl5.inf try giving the absolute path for the bcmwl5.inf file and see if that can get rid of the message.
I have already checked this. When I gave the command ndiswrapper -i bcmwl5.inf, it copied the bcmwl5.inf file into /etc/ndiswrapper/bcmwl5/ directory that IT created.
I have also tried giving it the full path and that did not work. So, I moved the driver to ndiswrapper-0.6 directory to avoid giving it the path.
JayMan8081
06-11-2004, 02:15 PM
Okay, sorry but I am out of ideas on what might be going wrong here. Hopefully someone else will be able to offer some advice or tips that I haven't thought of. Anyone else here using ndiswrapper that could try and give Mr. Newbie a hand?
justlinux.com
Copyright 2007 Jupitermedia Corporation All Rights Reserved.