Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save adalenv/64cb5a66b2e7c7217d20a6e7ef6a552d to your computer and use it in GitHub Desktop.
Save adalenv/64cb5a66b2e7c7217d20a6e7ef6a552d to your computer and use it in GitHub Desktop.
mikrotik 2 gateways and separate clients
How to add 2 gateways and seperate clients by Chupaka
/ip firewall mangle add chain=prerouting src-address=198.54.15.0/24 action=mark-routing new-routing-mark=r_178
/ip firewall mangle add chain=prerouting src-address=192.168.10.0/24 action=mark-routing new-routing-mark=r_178
/ip firewall mangle add chain=prerouting src-address=192.168.11.0/24 action=mark-routing new-routing-mark=r_172
/ip firewall mangle add chain=prerouting src-address=192.168.12.0/24 action=mark-routing new-routing-mark=r_172
/ip route add gateway=178.242.0.200 routing-mark=r_178
/ip route add gateway=172.16.0.200 routing-mark=r_172
something like that. and if you need routing between those subnets, then you should add one more rule on the top with 'action=accept' and dst-address-list=my_local_subnets, then add all your four subnets to that address list
maybe the best one: http://habrahabr.ru/post/227913/
http://www.slideshare.net/Basellof/load-balancing-over-multiple-gateways-28422296
http://blog.butchevans.com/2008/09/mikrotik-policy-routing-implementation-example/
http://wiki.mikrotik.com/wiki/Load_Balancing_over_Multiple_Gateways
http://wiki.mikrotik.com/wiki/ECMP_load_balancing_with_masquerade
http://habrahabr.ru/post/244385/
http://vasilevkirill.com/?p=45
http://www.linuxshop.ru/articles/a1614589-vpn_tunel_mikrotik_to_mikrotik_na_primere_dvukh_ofisov_pptp_l2tp_ip2ip_ppoe_vlan_ipsec_gre
http://lanmarket.ua/stats/mikrotik-routeros-dva-provajdera-balansirovka-marshrutizaciya-firewall-%28bez%20skriptov%29
http://geektimes.ru/post/186284/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment