route add -net 192.168.2.0 netmask 255.255.255.0 gw 192.168.1.2List routes:
netstat -rnDelete route:
route delete net 192.168.2.0Add static route:
nano /etc/network/interfaces
post-up route add -net 192.168.2.0/24 gw 192.168.1.2 dev eth1
pre-down route delete -net 192.168.2.0/16 gw 192.168.1.2Add/Change default gateway:
ip route add default via 192.168.1.254
No comments:
Post a Comment