配置网卡地址及子接口地址:
ifconfig hme0 192.168.0.1 netmask 255.255.255.0 up #hme0视网卡接口而定
ifconfig hme0:1 plumb
然后再用ifconfig hem0:1给它配上IP地址,如:
ifconfig hme0:1 192.168.1.1 netmask 255.255.255.0 up
路由查看:
netstat -rn
修改路由表:
route add net 192.168.11.0 192.168.11.254 1
route add default 192.168.11.254 1
增加静态路由:
vi /etc/defaultrouter
192.168.11.254 1
重新关闭/启动tcp/ip协议进程:
sh /etc/init.d/inetinit stop
sh /etc/init.d/inetinit start
ncrr 于 2007-03-06 08:50:49发表:
简单明了,通俗实用。学习了……