Ok here is the deal I am fairly new to Linux but have found Debian to be a great OS to use.
Im in college and right now Im using Debian in a Lab environment as a server, with about 7 other groups using different server OSes including Win 2003 server and Win 2000 server, and we are setting up a mini internet in the lab.
We got routing to work on the Debian Server using static routes in the lab using the route add command, but everyday we come into the lab to get the routing table back up we have to do the following commands to get the routing table up and running agian between the networks.
Code:
route add -net 192.168.1.0 netmask 255.255.255.0 gw 10.9.64.101
route add -net 192.168.3.0 netmask 255.255.255.0 gw 10.9.64.103
route add -net 192.168.4.0 netmask 255.255.255.0 gw 10.9.64.104
route add -net 192.168.5.0 netmask 255.255.255.0 gw 10.9.64.105
route add -net 192.168.6.0 netmask 255.255.255.0 gw 10.9.64.160
route add -net 192.168.7.0 netmask 255.255.255.0 gw 10.9.64.107
route add -net 192.168.8.0 netmask 255.255.255.0 gw 10.9.64.108
and we get the following Routing Table
Code:
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.7.0 10.9.64.107 255.255.255.0 UG 0 0 0 eth0
192.168.6.0 10.9.64.160 255.255.255.0 UG 0 0 0 eth0
192.168.5.0 10.9.64.105 255.255.255.0 UG 0 0 0 eth0
192.168.4.0 10.9.64.104 255.255.255.0 UG 0 0 0 eth0
192.168.3.0 10.9.64.103 255.255.255.0 UG 0 0 0 eth0
192.168.2.0 * 255.255.255.0 U 0 0 0 eth1
192.168.1.0 10.9.64.101 255.255.255.0 UG 0 0 0 eth0
192.168.8.0 10.9.64.108 255.255.255.0 UG 0 0 0 eth0
10.9.64.0 * 255.255.252.0 U 0 0 0 eth0
default 10.9.64.1 0.0.0.0 UG 0 0 0 eth0
Im wanting to write and implement a start up script that will input the route commands into the kernel on boot up instead of us having to do it everytime we reboot the server. Can anyone help me out with this?