LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Start wirless at boot (https://www.linuxquestions.org/questions/slackware-14/start-wirless-at-boot-372012/)

linux_or_bust 10-11-2005 03:42 PM

Start wirless at boot
 
So, I installed Slackware 10.2 on a IBM TP 600e after being very pleased w/10.1. Everything is working including my Linksys wpc11 ver. 4. Installed the card using ndiswrapper, and it works perfectly. The only thing wrong is everytime I boot, dhcp does not start. So basically, once I boot up I have to open a console & type # dhcpcd wlan0, to get wireless to work. I have put the following in /etc/rc.d/rc.local:

/etc/rc.d/rc.wireless wlan0
/sbin/dhcpcd wlan0

& put all my wireless info in /etc/rc.d/rc.wireless.conf.

When I did this in 10.1 wireless would start when i booted up, but for some reason 10.2 will not let me do this...

thanks in advance for any help...this has got me stumped

rnicolson 10-11-2005 03:56 PM

If you type iwconfig does it show the wireless nic as wlan0 or eth0? I have not had to use the ndis wrapper before so am not sure about that. If iwconfig gives eth0 then change your script from wlan0 to eth0.

linux_or_bust 10-11-2005 03:59 PM

It is definitely wlan0 in iwconfig...iwconfig gives all the correct info for me to connect to the internet, but everytime I have to boot up or restart, I have to dhcpcd wlan0 to get the internet working

rnicolson 10-11-2005 04:16 PM

I just added a script for wireless to my rc.local to test it out. worked fine for me using.

this script was called work
#!/bin/bash
iwconfig eth1 essid XXXXXXX key XXXXXXXXXXXXXXXXXXXXXXXXX
dhcpcd eth1

in rc.local just added

/etc/rc.d/work

just make sure script is executable


This worked for me. I also tested rc.local was running by adding
echo "can I see this?"

to the rc.local script. On boot you can verify it is running this way by looking for this in the boot up messages.

Alien Bob 10-11-2005 04:33 PM

Re: Start wirless at boot
 
Quote:

Originally posted by linux_or_bust
So, I installed Slackware 10.2 on a IBM TP 600e after being very pleased w/10.1. Everything is working including my Linksys wpc11 ver. 4. Installed the card using ndiswrapper, and it works perfectly. The only thing wrong is everytime I boot, dhcp does not start. So basically, once I boot up I have to open a console & type # dhcpcd wlan0, to get wireless to work. I have put the following in /etc/rc.d/rc.local:

/etc/rc.d/rc.wireless wlan0
/sbin/dhcpcd wlan0

& put all my wireless info in /etc/rc.d/rc.wireless.conf.

When I did this in 10.1 wireless would start when i booted up, but for some reason 10.2 will not let me do this...

thanks in advance for any help...this has got me stumped

In Slackware 10.2, the rc.wireless can no longer run on it's own. It was convenient that you could do that before, but rc.wireless is started inside rc.inet1 and starting with Slackware 10.2, rc.wireless needs the variables that rc.inet1 initializes.

So, your solution would be to add this to /etc/rc.d/rc.inet1.conf:
Code:

IFNAME[4]="wlan0"
IPADDR[4]=""
NETMASK[4]=""
USE_DHCP[4]="yes"

And the card will be configured on boot, on the condition that you did
Code:

/sbin/modprobe ndiswrapper
somewhere in your scripts.

If you don't want to reboot and find out, you can run
Code:

/etc/rc.d/rc.inet1 wlan0_restart
or maybe just
Code:

/etc/rc.d/rc.inet1 wlan0_start
Eric

linux_or_bust 10-11-2005 06:25 PM

Awesome guys!!! it worked, thanks to the both of you for your great tips.

Eric, you were absolutely correct, once I uncommented the lines in /etc/rc.d/rc.inet1.conf & put in some of my iwconfig settings, I restarted, and everything worked!!!

thanks again to both of you!!!

salviadud 11-13-2005 05:39 AM

I want to do that too. My sister doesn't know a thing about linux, but since she's the owner of the computer i gotta do it.

My problem is, I have not done bash scripting yet. My question is, do I add this line of code to an exinsting file
Code:

/sbin/ndiswrapper
?
or do i need it to have a script of its own?

I also took a look at rc.inet1, theres a lot of code, do i add those lines at the end, anywhere?

salviadud 11-13-2005 05:40 AM

oops
i meant
Code:

/sbin/modprobe ndiswrapper
hehe :)

Alien Bob 11-13-2005 08:24 AM

Quote:

Originally posted by salviadud
oops
i meant
Code:

/sbin/modprobe ndiswrapper
hehe :)

Add that line at the end of the file
Code:

/etc/rc.d/rc.modules
! No more, no less. The rc.modules file is where you load your kernel modules.

Eric

salviadud 11-13-2005 07:19 PM

YEAH!
 
Slackware rocks!!!

I think I finally understand why some files have green color in them... (in terminal).

I preferred the rc.local aproach. I can add just about anything over there.

thanx a lot guys!


All times are GMT -5. The time now is 11:12 PM.