Private in-house domain
Tech Writer
TechWtr at handspun.com
Wed May 16 00:04:28 EDT 2007
Andrew and Stephen,
Thanks for the tips! Your combined suggestions seemed to do the trick. I
edited my rc.local file and added the lines:
echo "Set up IP alias interfaces"
/sbin/ifconfig eth0:0 192.168.1.30
echo "Set up routes"
/sbin/route add -host 127.0.0.0 dev eth0
/sbin/route add -host 192.168.1.1 dev eth0
/sbin/route add default gw 192.168.1.1
Now eth0 has the IP address 10.25.1.10 that I assigned, and also has an
alias of the IP address 192.168.1.30 that my Linksys wants to talk to. The
routing table uses the IP address of my Linksys router, and I can now
successfully get nslookup responses outside my private mini-domain and my
web browser can see the rest of the world, too.
Peg
----- Original Message -----
From: "Andrew Gaunt" <fishfryah at gmail.com>
To: <stephen at sryanfamily.info>; <gnhlug-discuss at mail.gnhlug.org>
Sent: Tuesday, May 15, 2007 9:03 PM
Subject: Re: Private in-house domain
> Ok, I admit I didn't really read all this stuff, I just took a cursory
> scan. So, if I'm totally
> off on this just ignore me.... Anyway, How about using secondary IP's
> on the NICs so
> you can have one set of addresses you don't control (and get outside
> etc.) and another
> set you do control and are part of your mini-domain?
>
> e.g. eth0 is dhcp,
> then something does this: ifconfig eth0:1 10.x.x.x yadda...
>
> hat makes sense.
>>
>> Yes, it does; you'll have to go the "create an additional route" method,
>> then.
>>
>> If you don't need to access the rest of the surrounding network, a
>> static route just to the gateway will do; something like this:
>>
>> $ sudo route add -host 192.168.1.1 dev eth0
>>
>> If you do need to access the rest of the local network, too, then you'll
>> need a network route, like this:
>>
>> $ sudo route add -net 192.168.1.0 netmask 255.255.255.0 dev eth0
>>
>> Normally, there is a script that automatically runs these commands,
>> filling in the values from ifcfg-eth0.txt, but they are only set up for
>> simple networks; you'll need to find someplace to put the "route
>> add ..." command to have it run automatically on boot.
>>
>> Either way, this gives the network stack information about where to send
>> packets destined for your gateway.
>>
>> > >> ... I'm not familiar with
>> > >> CentOS, so I don't know if there's an easy way to do that.
>> > >>
>> >
>> > btw... CentOS is just Red Hat Enterprise Linux, with a different logo.
>>
>> Thanks; I was aware of that, but I'm not familiar with RHEL, either.
>> I've got 10 years of Debian in my fingers, and 1 month of RHEL. If it
>> was a Debian-based system, I'd tell you to put the extra route commands
>> in /etc/network/interfaces as a 'post-up' option. As it is, somebody
>> with more RedHat-fu will have to answer that part.
>>
>> _______________________________________________
>> gnhlug-discuss mailing list
>> gnhlug-discuss at mail.gnhlug.org
>> http://mail.gnhlug.org/mailman/listinfo/gnhlug-discuss/
>>
>
>
> --
> --
> _______________________________________________
> gnhlug-discuss mailing list
> gnhlug-discuss at mail.gnhlug.org
> http://mail.gnhlug.org/mailman/listinfo/gnhlug-discuss/
More information about the gnhlug-discuss
mailing list