|
发表于 2005-4-28 21:21:20
|
显示全部楼层
客户机掩码用255.255.254.0就可以。而且两条线互备。/ ip address add address=192.168.0.254/24 network=192.168.0.0 broadcast=192.168.0.255 \ interface=LAN comment="added by setup" disabled=no add address=192.168.1.254/24 network=192.168.1.0 broadcast=192.168.1.255 \ interface=LAN1 comment="added by setup" disabled=no add address=XXX.XXX.220.116/27 network=XXX.XXX.220.96 broadcast=XXX.XXX.220.127 \ interface=WAN comment="" disabled=no add address=XXX.XXX.228.220/27 network=XXX.XXX.228.192 \ broadcast=XXX.XXX.228.223 interface=ADSL comment="" disabled=no/ ip policy-routing add name="table1" / ip policy-routing rule add src-address=0.0.0.0/0 dst-address=0.0.0.0/0 flow="" interface=LAN1\ action=lookup table=table1 comment="" disabled=no add src-address=0.0.0.0/0 dst-address=0.0.0.0/0 flow="" interface=all \ action=lookup table=main comment="" disabled=no / ip policy-routing table main add dst-address=0.0.0.0/0 gateway=XXX.XXX.220.97 preferred-source=0.0.0.0 \ comment="" disabled=no / ip policy-routing table table1 add dst-address=0.0.0.0/0 gateway=XXX.XXX.228.193 preferred-source=0.0.0.0 \ comment="" disabled=no/ system script add name="table1down" source="/ ip policy-routing table table1 \n\nset \[/ \ ip policy-routing table table1 find dst-address=0.0.0.0\] gateway \ XXX.XXX.220.97\n\n" policy=ftp,reboot,read,write,policy,test add name="table1up" source="/ ip policy-routing table table1 \n\nset \[/ ip \ policy-routing table table1 find dst-address=0.0.0.0\] gateway \ XXX.XXX.228.193\n\n" policy=ftp,reboot,read,write,policy,test add name="maindown" source="/ ip policy-routing table main \n\nset \[/ ip \ policy-routing table main find dst-address=0.0.0.0\] gateway \ XXX.XXX.228.193" policy=ftp,reboot,read,write,policy,test add name="mainup" source="/ ip policy-routing table main\n\n set \[/ ip \ policy-routing table main find dst-address=0.0.0.0\] gateway \ XXX.XXX.220.97" policy=ftp,reboot,read,write,policy,test / tool netwatch add host=XXX.XXX.220.97 timeout=2s interval=10s up-script=mainup \ down-script=maindown comment="" disabled=no add host=XXX.XXX.228.193 timeout=2s interval=15s up-script=table1up \ down-script=table1down comment="" disabled=no |
|