(E-Mail Removed) wrote:
> Thanks for the quick reply Allen. I did figure out that using
> 10.9.81.193 as my default gateway was bad, and that having 2 gateways
> was also bad.
2 gateways isn't bad unless both are default gateways.
> So, I removed that entry, and I think my default gateway
> is now automagically set to that which I get from DHCP.
Looks like it, based on the routing table you appended.
> Soo... I made a perl script to parse my /etc/hosts file and get the
> IP's of the machines on the isolated network I need access to. For each
> of these $ip addresses I have the script execute:
> /sbin/route -v add -host $ip eth0
One host at a time is a bit ugly, but if it works...
Are you sure all those hosts are directly connected to the network
attached to eth0 and hence do not need a gateway? (Maybe something is
proxy ARPing for them??) Did you try pinging or otherwise contacting
all of them? If you can contact them directly without a gateway, this
doesn't match the original netmask you gave us.
>
> Now I have access to all of the machines I need on the isolated
> network, and public internet works too. So, I seem to have what i
> wanted. Is this really the correct or proper way to do this? One
> question I have, is why didn't it need me to tell it that the gateway
> for those routes on eth0 was 10.9.81.193?
Depends on whether they are directly connected or not. See previous
comment.
> I also need to figure out how
> to make those route commands persist, or run the script after bootup,
> which isn't a big deal..
You can make the commands persist, but the details depend on the
distribution you are using. In your shoes I would probably find the GUI
tool for adding static routes, add one, figure out what file was
changed, and then run the awk script.
> Here is a snippet of output of route -n. I've snipped out a bunch of
> lines that are similar to the first 2, and are the IP's of the other 30
> or so systems on the isolated network. Does anything here look like it
> will cause me any problems?
You seem to have snipped out the entry for the network attached to eth0
(169.254.0.0 doesn't count).
> Kernel IP routing table
> Destination Gateway Genmask Flags Metric Ref Use Iface
> 10.9.71.196 0.0.0.0 255.255.255.255 UH 0 0 0 eth0
> 10.9.69.196 0.0.0.0 255.255.255.255 UH 0 0 0 eth0
> 10.9.16.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
> 169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0
> 127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo
> 0.0.0.0 10.9.16.1 0.0.0.0 UG 0 0 0 eth1