vi /etc/sysconfig/network GATEWAY=192.168.0.254 OR vi /etc/sysconf/network-scripts/ifcfg-eth0 DEVICE=eth0 BOOTPROTO=static ONBOOT=yes IPADDR=192.168.0.? NETMASK=255.255.255.0 GATEWAY=192.168.0.254 service network restart Gateway defines the way to exit the packets. According to question System working as a router for two networks have IP Address 192.168.0.254 and 192.168.1.254.