Skip to main content
● networkDual-WAN PCC (2/0 & 2/1) + ROS v7 Failover

MikroTik Dual-WAN (2 ISP) PCC Load Balancing & Failover Script for RouterOS v7

Production-ready MikroTik RouterOS v7 2-WAN PCC Load Balancing script with FIB routing tables, mangle rules, and recursive gateway failover.

⚡ Instant Calculated Answer
Dual-WAN PCC (2/0 & 2/1) + ROS v7 Failover
⚡Open Full Interactive Calculator (mikrotik-pcc-calculator) →

📊Reference Table & Engineering Specs

Parameter / MetricSpecification Value
WAN Uplinks2 ISP (ISP-1 + ISP-2)
PCC Classifier Modeboth-addresses-and-ports (Aman untuk Mobile Banking & HTTPS)
PCC Hash Buckets2/0 (ke ISP-1) dan 2/1 (ke ISP-2)
Target RouterOS VersionRouterOS v7.x (/routing table add fib)
Failover Mechanismcheck-gateway=ping (Distance 1 & 2)

📖Technical Explanation & Methodology

Dual-WAN PCC distributes LAN connections across two ISPs using `both-addresses-and-ports` so HTTPS, banking, and gaming sessions maintain sticky public IP affinity.

💻 Ready-to-Deploy CLI Snippet:
/routing table
add name=to-isp1 fib
add name=to-isp2 fib
/ip firewall mangle
add chain=prerouting in-interface=bridge-lan dst-address-type=!local per-connection-classifier=both-addresses-and-ports:2/0 action=mark-connection new-connection-mark=isp1_conn passthrough=yes
add chain=prerouting in-interface=bridge-lan dst-address-type=!local per-connection-classifier=both-addresses-and-ports:2/1 action=mark-connection new-connection-mark=isp2_conn passthrough=yes

❓Frequently Asked Questions (FAQ)

Why use both-addresses-and-ports in MikroTik PCC?

It keeps each client connection bound to a consistent WAN IP, preventing broken SSL/banking sessions.