- 論壇徽章:
- 0
|
用route增加的路由,為什么重啟后就沒(méi)有了!?
usr/share/doc/initscripts-<version>;/sysconfig.txt可以找到static-routes的說(shuō)明:
/etc/sysconfig/static-routes:
Contains lines of the form:
<device>; host|net <arguments to route command>;
<device>; may be a device name to have the route brought up and
down with the device, or "any" to have the correct devices calculated
at run time.
For example:
eth0 host 192.168.2.2 eth0
adds a host route through eth0 to 192.168.2.2, while
any net 192.168.2.0 netmask 255.255.255.0 ppp0
adds a network route to the 192.168.2.0 network through ppp0.
在這個(gè)文件里加路由,重啟也不會(huì)丟
(我個(gè)人喜歡在rc.local最后加路由) |
|