Mainos / Advertisement:
Ero sivun ”RouterOS Load Balancing” versioiden välillä
Siirry navigaatioon
Siirry hakuun
(Ak: Uusi sivu: Tässä ohjeessa tehdään kahden WAN portin kuormantasaus. Käytössämme on RB951-2HnD reititin ja kaksi WAN yhteyttä. wan1: 192.168.10.1 wan2: 192.168.20.1 bridge-local...) |
|||
Rivi 26: | Rivi 26: | ||
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/0 action=mark connection new-connection-mark=wan1-con passthrough=yes | add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/0 action=mark connection new-connection-mark=wan1-con passthrough=yes | ||
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/1 action=mark-connection new-connection-mark=wan2-con passthrough=yes | add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/1 action=mark-connection new-connection-mark=wan2-con passthrough=yes | ||
− | + | ||
− | |||
add chain=prerouting connection-mark=wan1-con in-interface=Local action=mark-routing new-routing-mark=to_WAN1 | add chain=prerouting connection-mark=wan1-con in-interface=Local action=mark-routing new-routing-mark=to_WAN1 | ||
add chain=prerouting connection-mark=wan2-con in-interface=Local action=mark-routing new-routing-mark=to_WAN2 | add chain=prerouting connection-mark=wan2-con in-interface=Local action=mark-routing new-routing-mark=to_WAN2 |
Versio 14. toukokuuta 2015 kello 10.26
Tässä ohjeessa tehdään kahden WAN portin kuormantasaus. Käytössämme on RB951-2HnD reititin ja kaksi WAN yhteyttä.
wan1: 192.168.10.1 wan2: 192.168.20.1 bridge-local: 192.168.88.1
bridge-local on verkkosilta.
Määritetään staattiset IP-osoitteet:
/ip address add address 192.168.88.1/24 interface=bridge-local add address 192.168.10.1/24 interface=wan1 add address 192.168.20.1/24 interface=wan2
Konfiguroidaan palomuuri
/ip firewall mangle add chain=input in-interface=wan1 action=mark-connection new-connection-mark=wan1-con add chain=input in-interface=wan2 action=mark-connection new-connection-mark=wan2-con add chain=output connection-mark=wan1-con action=mark-routing new-routing-mark=to-wan1 add chain=output connection-mark=wan2-con action=mark-routing new-routing-mark=to-wan2 add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/0 action=mark connection new-connection-mark=wan1-con passthrough=yes add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/1 action=mark-connection new-connection-mark=wan2-con passthrough=yes add chain=prerouting connection-mark=wan1-con in-interface=Local action=mark-routing new-routing-mark=to_WAN1 add chain=prerouting connection-mark=wan2-con in-interface=Local action=mark-routing new-routing-mark=to_WAN2
Konfiguroidaan reititys
/ip route add dst-address=0.0.0.0/0 gateway=192.168.10.1 routing-mark=to-wan1 check-gateway=ping add dst-address=0.0.0.0/0 gateway=192.168.20.1 routing-mark=to-wan2 check-gateway=ping
Konfigoroi NAT
/ip firewall nat add chain=srcnat out-interface=wan1 action=masquerade add chain=srcnat out-interface=wan2 action=masquerade
Mainos / Advertisement: