VectorLinux

Please login or register.

Login with username, password and session length
Advanced search  

News:

Visit our home page for VL info. For support and documentation, visit the Vector Linux Knowledge Center or search the Knowledge Center and this Forum using the search box above.

Author Topic: Start network on bootup (solved)  (Read 2926 times)

InTheWoods

  • Vectorite
  • ***
  • Posts: 302
Start network on bootup (solved)
« on: June 14, 2007, 02:17:58 pm »

I recently had to reinstall Vec 5.8 Standard and cannot remember how to enable automatic network startup on system start. The network is working, I'm using ndiswrapper for the wireless card and wep encryption.

I had this problem solved before but that post is presently missing.

« Last Edit: June 14, 2007, 03:17:41 pm by InTheWoods »
Logged

easuter

  • Global Moderator
  • Vectorian
  • *****
  • Posts: 2160
Re: Start network on bootup
« Reply #1 on: June 14, 2007, 02:25:01 pm »

Yeah, there are lots of useful posts missing atm.
Anyway, all you have to do is add the commands you would normally use to connect to your network to the end of /etc/rc.d/rc.local
For example, this is what I have in my rc.local to autoconnect to my network:

Code: [Select]
echoc "Attempting to start wireless network for 20 seconds..." green
iwconfig wlan0 key 31652f254b
iwconfig wlan0 ap Auto

#Give enough time to let iwconfig autodetect the wireless AP
sleep 1

dhcpcd -d wlan0 -t 20

HTH  :)
Logged

InTheWoods

  • Vectorite
  • ***
  • Posts: 302
Re: Start network on bootup
« Reply #2 on: June 14, 2007, 03:17:20 pm »


Got it!

Thanks!
Logged

vlinco

  • Member
  • *
  • Posts: 12
Re: Start network on bootup (solved)
« Reply #3 on: March 28, 2010, 12:08:25 pm »

I just installed VL 6.0 Light, and found that the wireless network would not start automatically at boot. I also found that in my case the code from easuter wouldn't work without a few changes. For anyone else who might be in the same shoes, here's the code that worked for me:

#-- Auto connect to wireless network
echo "Attempting to start wireless network for 20 seconds..." green
iwconfig wlan0 essid MyRouterName key XXXXXXXXXX mode Managed ap auto

#Give enough time to let iwconfig autodetect the wireless AP
sleep 1

#Get ip address from DHCP server
dhcpcd -d wlan0 -t 20

#Start up connection
ifconfig wlan0 up



Note - The essid & key are fictitious fillers. Fill in your essid and key.
Logged

brampieke

  • Member
  • *
  • Posts: 34
Re: Start network on bootup (solved)
« Reply #4 on: June 06, 2010, 02:02:15 am »

I'm also using VL 6.0 light.
Do I need to fill this in ~/.icewm/startup ??
Logged

nightflier

  • Administrator
  • Vectorian
  • *****
  • Posts: 4133
Re: Start network on bootup (solved)
« Reply #5 on: June 06, 2010, 05:54:28 am »

These commands need to be run as root, so the Icewm startup script won't do. Put them in /etc/rc.d/rc.local.

For a GUI app that a normal user can control, install and use wicd.
Logged