Re: help with static ip on lan aaronl wrote:
>I need a static ip for my box. I've made sure I am trying to
>use an address not being passed out from my Linksys WRT54G router, so not
>1, nor 102 thru 110. I've read the related section in the Slackbook on the
>install cd's (5.3.3 /etc/rc.d/rc.inet1.conf). I've tried making this work
>two ways and each fails. The second way that failed was to use
>'netconfig' which seem to produce the same config I did manually. Here--
>the first way that failed--are some of the different options I have
>tried putting in the rc.inet1.conf file:
>
>
>
>
Give something like this a try:
# Config information for eth0:
IPADDR[0]="192.168.1.10"
NETMASK[0]="255.255.255.0"
USE_DHCP[0]=""
DHCP_HOSTNAME[0]=""
...
# Default gateway IP address:
GATEWAY="192.168.1.1"
That sets your machine address to 192.168.1.10 (I have three machines,
all static, with addresses 192.168.1.10, 192.168.1.20, 192.168.1.30 and
a non-static H-P printer that connects as 192.168.1.100). All that works
just fine with a Linksys router (a BEFSR41, but what the heck).
On this machine, /etc/hosts looks like:
# For loopbacking.
127.0.0.1 localhost
192.168.1.10 fubar.com fubar
192.168.1.20 snafu.com snafu
...
and /etc/resolv.conf contains the address of the nameserver specified by
my ISP like this:
search com
nameserver nnn.nnn.nnn.nnn
(where nnn.nnn.nnn.nnn is the address).
In the Linksys the Setup screen has the default values
192.168.1.1 (Device IP Address)
255.255.255.0 (Subnet Mask)
and my ISP uses PPPoE. My login name and password are entered in the
User Name and Password fields.
Hope this helps. |