Network Services

Wednesday, March 7, 2012

دمج خطين من موقع الشركة بطريقة pcc

اولا 
نقوم بتعديل اسماء الكروت 
LAN
ISP1
ISP2
ثانيا نقوم بتغيير ايبى الروتر الاول 
 10.111.0.1= ISP1


 10.112.0.1= ISP2


192.168.0.1 = LAN




بعد ذلك نقم بوضع هذا الاسكربت فى النيو ترمنال 



2 Line Adsl Pcc By Mikrotik

/ip firewall mangle add chain=prerouting action=mark-connection \new-connection-mark=1st_conn per-connection-classifier=src-address-and-port:3/0/ip firewall mangle add chain=prerouting action=mark-connection \new-connection-mark=2nd_conn per-connection-classifier=src-address-and-port:3/1/ip firewall mangle add chain=prerouting action=mark-connection \new-connection-mark=3rd_conn per-connection-classifier=src-address-and-port:3/2
/ ip address add address=192.168.0.1/24 network=192.168.0.0 broadcast=192.168.0.255 interface=LANadd address=10.111.0.2/24 network=10.111.0.0 broadcast=10.111.0.255 interface=ISP1add address=10.112.0.2/24 network=10.112.0.0 broadcast=10.112.0.255 interface=ISP2

/ ip firewall mangleadd chain=prerouting dst-address=10.111.0.0/24 action=accept in-interface=LANadd chain=prerouting dst-address=10.112.0.0/24 action=accept in-interface=LAN

add chain=prerouting in-interface=ISP1 connection-mark=no-mark action=mark-connection \new-connection-mark=ISP1_connadd chain=prerouting in-interface=ISP2 connection-mark=no-mark action=mark-connection \ new-connection-mark=ISP2_conn

add chain=prerouting in-interface=LAN connection-mark=no-mark dst-address-type=!local \per-connection-classifier=both-addresses:2/0 action=mark-connection new-connection-mark=ISP1_conn add chain=prerouting in-interface=LAN connection-mark=no-mark dst-address-type=!local \ per-connection-classifier=both-addresses:2/1 action=mark-connection new-connection-mark=ISP2_conn

add chain=prerouting connection-mark=ISP1_conn in-interface=LAN action=mark-routing \ new-routing-mark=to_ISP1add chain=prerouting connection-mark=ISP2_conn in-interface=LAN action=mark-routing \new-routing-mark=to_ISP2add chain=output connection-mark=ISP1_conn action=mark-routing new-routing-mark=to_ISP1 add chain=output connection-mark=ISP2_conn action=mark-routing new-routing-mark=to_ISP2

/ ip routeadd dst-address=0.0.0.0/0 gateway=10.111.0.1 routing-mark=to_ISP1 check-gateway=pingadd dst-address=0.0.0.0/0 gateway=10.112.0.1 routing-mark=to_ISP2 check-gateway=ping

add dst-address=0.0.0.0/0 gateway=10.111.0.1 distance=1 check-gateway=pingadd dst-address=0.0.0.0/0 gateway=10.112.0.1 distance=2 check-gateway=ping




وبكدا  انتهينا من الشرح والتطبيق 


مع تحيات 


http://mikrotik-network.blogspot.com/ 

24 hours 7 days 



0 comments:

Post a Comment