Evil_TTL> show | s

Juniper ip monitoring

Category:Juniper -> Routing and Switching

Two ISP scenario:

1. ISP#1 - Primary
2. ISP#2 - Secondary

Routing configuration:

set routing-options static route 0.0.0.0/0 next-hop 10.0.0.2 //ISP#1 


Monitoring configuration:

set services rpm probe ISP1 test Gateway probe-type http-get
set services rpm probe ISP1 test Gateway target url http
://google.com
set services rpm probe ISP1 test Gateway probe-count 1
set services rpm probe ISP1 test Gateway probe
-interval 5
set services rpm probe ISP1 test Gateway thresholds successive
-loss 2
set services rpm probe ISP1 test Gateway next
-hop 10.0.0.2 

 
This configuration performs a HTTP GET to the monitoring address (HTTP GET is used for demonstration purposes only and requires DNS resolution). Can be replaced by ICMP probe. It probes every 5 seconds, and if 2 probes fail in succession, the probe is considered a failure. This gives a failover time of approximately 10 seconds. The next hop address configured overrides the routing table for that probe, and ensures that the test uses the correct ISP.

Once the probe is working - configure actions to occur when the probe fails. This is done with via IP monitoring:

set services ip-monitoring policy PrimaryISP no-preempt 
set services ip
-monitoring policy PrimaryISP match rpm-probe ISP1
set services ip
-monitoring policy PrimaryISP then preferred-route route 0.0.0.0/0 next-hop 10.0.0.6  //ISP#2 

This will override the static route config replacing the route to the Internet via ISP#1 with route via ISP#2. If there is a second probe, the match condition on the probe name is a logical OR, so failure of either will cause to trigger failover. Preempt is turned off, this will manage the process to failback manually.

By privilege15