How do I save my network config so it comes up at boot?

Booting, installing, newbie
Post Reply
Message
Author
ray

How do I save my network config so it comes up at boot?

#1 Post by ray »

dear all, I want to ask that after I finish to set the ip, netmask,gateway(not DHCP)....How to save it,I want that after reboot the computer and I do not set it again.
I am using version 1.0.3
thanks all :(

User avatar
rarsa
Posts: 3053
Joined: Sun 29 May 2005, 20:30
Location: Kitchener, Ontario, Canada
Contact:

#2 Post by rarsa »

You add the necessary commands to the /etc/rc.d/rc.local file.

For example, in my case, I want to assign an IP of 192.168.1.98 to my computer, using a netmask of 255.255.255.0 and my router's address is 192.168.1.1

I add the following commands to rc.local

Code: Select all

ifconfig eth1 192.168.1.98 netmask 255.255.255.0 broadcast 192.168.1.255 up
route add -net default gw 192.168.1.1
You can find the commands specific to your set-up under /etc. The file is called <device>mode, where <device> is your network device. For example: eth0mode or eth1mode or wlan0mode, etc.

Guest

#3 Post by Guest »

it is ok now
thanks so much :!:

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#4 Post by Flash »

What did you do that made it work? :?

User avatar
rarsa
Posts: 3053
Joined: Sun 29 May 2005, 20:30
Location: Kitchener, Ontario, Canada
Contact:

#5 Post by rarsa »

My guess is that he did as I suggested. I don't think it requires more explanation.

Post Reply