wireless card to load on boot?Forum: Networking Topic: wireless card to load on boot? started by: invisble1 Posted by invisble1 on Mar. 27 2007,06:38
is it possible to have my wireless card load on boot, through NDISWRAPPER, when DSL starts, instead of me having to mainuall load the driver every time?
Posted by ^thehatsrule^ on Mar. 27 2007,16:46
Use the startup script /opt/bootlocal.sh
Posted by rothmail on Mar. 27 2007,16:47
Yes, I had the same problem myself and this is how I solved it. After DSL is installed, as many of you have noticed, if you do a ifconfig, there is no wlan0 present. For this to work, don't use ndiswrapper on the command line, go to DSLpanel on the desktop and select "Ndiswrapper". Fill it out according to where you have your windows driver for the wireless card located and the name of your network and wep key. Click OK, and wait for a couple of minutes and it should come back with a message that the connection has been made. Go to ATerminal and type in: ifconfig and you should see wlan0 now listed with your DHCP assigned IP address after "net addr" in the wlan0 entry. OK, what you have done now, is established the wlan0 device for your system and its working. Now, look in /opt and notice the myndis.sh which should contain a call to the /usr/local/bin/ndiswrapper.sh script and passing the data you provided from the DSLpanel ndiswrapper. (I know what some of you are thinking, why do I need to use DSLpanel, can't I just do the ndiswrapper stuff myself, well, yes and no. If you have not established the wlan0 device, you need the DSLpanel to create it. That is, unless you have some other method that works for you using 'pump', for example.) Edit /opt/bootlocal.sh and add this to the last line: /opt/myndis.sh Reboot DSL. When you come back up, return to the ATerminal and do this: ping yahoo.com You should see something like this: PING yahoo.com (66.66.94.234.13) 56 data bytes 64 bytes from ... time 93.1 ms then after a few repeating lines, hit control-c to stop it. This means you have a working connection to the Internet! As an option, I have written a small script called checklan.sh I have placed in /opt which is after "/opt/myndis.sh", that checks to inform me the LAN and the Internet is working: #!/bin/sh # Check for LAN if ping -c 1 192.168.1.1 1>/dev/null 2>/dev/null then echo -e "LAN is working! \c" else echo "Unable to reach LAN." fi # Check for Internet if ping -c 1 yahoo.com 1>/dev/null 2>/dev/null then echo "Internet is working!" else echo "Unable to reach Internet." fi # Using ifconfig to display the IP address # for the wireless card assigned by DHCP. IPADDR=`/sbin/ifconfig wlan0 | grep "inet addr" | awk '{ print $2}' | awk 'BEGIN{FS=":"}{ print $2}'` echo -e "Your IP address is \c"; echo $IPADDR; When this is run at boot after myndis.sh has done it's job, checklan.sh should display: LAN is working! Internet is working! Your IP address is 192.168.1.103 Then you get your login prompt, knowing that your wireless card is up and running, the LAN is working, and the Internet, so you can proceed without having to test to see if you have a connection each time. I hope this helps! Posted by invisble1 on Mar. 29 2007,03:26
okay, so the /opt/myndis.sh line is in my bootlocal.sh but it doesn't work.ideas? no errors, just no luck. Posted by rothmail on Mar. 29 2007,03:31
Sorry you are still having a problem. After you boot with /opt/myndish.sh in your /opt/bootlocal.sh, what does your 'ifconfig' output look like? Does it show device wlan0? Is it assigned an IP address from inet addr? Also, do a 'ps' and see if 'pump' is running. I'm not sure my DSL system right now, but I recall seeing 'pump' running on mine. Posted by invisble1 on Mar. 29 2007,03:37
there we go. had to reboot twice for some reason! thank you much! |