RedHat. AS4.0 最小化安装.
Eth0 内网
eth1 外网1
eth2 外网2
/etc/.sysctl.conf 健康
把net.ipv4..ip_forword=0 改为服务器
net.ipv4.ip_.forward=1域名
/e.tc/rc.d/rc.local电影
脚本如下:
#!/bin/sh
#
# This scr.ipt will be exe.cuted *after * all the other init scripts<性病>
#You can put your ow.n initialization stuff in here if you don`.t域名
#w.ant to do t.he full sys v styls init stuff.
touch /var/lo.ck/.subsys/local 健康
/sbin/modprobe ip_.tables 电子
/sbin/modprob.e ip_nat_ftp健康
/s.bin/modprobe ip._conntrack_ftp.
/sbin/iptables .–F<性病>
/sbin/.iptables –F –t nat教育
/sbin/ip.tables –X( 游戏 )
/sbin/iptabl.es –Z健康
/.sbin/i.ptables –P INPUT ACCEPT.
/sbin/iptables –P FOR.WAR.D ACCEPT(广告)
/sbin/iptables –P. OUTPUT ACCEP.T 建材
echo 1 > /proc/sys/net/ip.v4/ip_forwar.d.
/sbin/iptables -t nat -A POST.ROUTING -o eth1. -j MASQUERADE 杀毒
/s.bin/iptables -t nat -A POSTROUTING -o e.th2 -j MASQUERADE.
ip rul.e add to 60.0..0.0/13 table 1.
ip .rule add to 60.8.0.0/15 table 1. 汽车
ip. rule add to 60.10.0.0/.16 table 1 女人
..........
arp –f
ip route add 0./0 via. 218.28.x.x 杀毒
ip route add 0/0. via 219.147.x.x. table 1.
请问为何ip route 要加在ip rule 后面.才能.实现双线根据路由表转发? 鲜花