부울 조건을 사용하여 인터페이스 페일오버로 IP 모니터링 구성
인터페이스 페일오버와 함께 IP 모니터링을 사용하면 모니터링되는 IP 주소에 대한 AND 및 OR 조건을 통합할 수 있습니다. 프로브가 실패하려면 지정된 프로브를 구성하는 각 테스트가 실패해야 합니다(AND 논리). 지정된 IP 모니터링 정책에 대해 지정된 프로브 중 하나라도 실패하면 IP 모니터링 작업(OR 논리)이 트리거됩니다. 다음 예는 rpm 프로브 및 IP 모니터링을 사용하여 AND 및 OR 조합을 구현하는 방법을 보여줍니다. IP 주소 11.1.1.1 및 11.1.1.2에 모두 연결할 수 없을 때 백업 인터페이스를 불러오고 IP 주소 12.1.1.1에 연결할 수 없을 때 백업 인터페이스도 불러오려는 경우 이 시나리오는 "If (11.1.1.1 is unreachable AND 11.1.1.2 is unreachable) OR (12.1.1.1 is unreachable) then enable the backup interface"와 같은 부울 문으로 표현할 수 있습니다.
아래 구성은 시나리오에 필요한 논리를 구현합니다. 다음 명령은 위의 명령문에서 Junos 기능을 로 대체하고 구성에 매핑하는 방법을 보여줍니다. Probe1 및 probe2는 아래 구성 예에서 정의됩니다. Probe1은 부울 AND 조건과 함께 연결된 두 개의 테스트로 구성됩니다. (probe1이 실패하거나 probe2가 실패하면) 백업 인터페이스를 활성화합니다.
set services rpm probe probe1 test paysvr1 target address 11.1.1.1 set services rpm probe probe1 test paysvr1 probe-count 5 set services rpm probe probe1 test paysvr1 probe-interval 5 set services rpm probe probe1 test paysvr1 test-interval 3 set services rpm probe probe1 test paysvr1 thresholds successive-loss 5 set services rpm probe probe1 test paysvr1 destination-interface fe-0/0/1.0 set services rpm probe probe1 test paysvr1 hardware-timestamp set services rpm probe probe1 test paysvr1 next-hop 1.1.1.2 set services rpm probe probe1 test paysvr2 target address 11.1.1.2 set services rpm probe probe1 test paysvr2 probe-count 5 set services rpm probe probe1 test paysvr2 probe-interval 5 set services rpm probe probe1 test paysvr2 test-interval 3 set services rpm probe probe1 test paysvr2 thresholds successive-loss 5 set services rpm probe probe1 test paysvr2 destination-interface fe-0/0/1.0 set services rpm probe probe1 test paysvr2 hardware-timestamp set services rpm probe probe1 test paysvr2 next-hop 1.1.1.2 set services rpm probe probe2 test paysvr1 target address 12.1.1.1 set services rpm probe probe2 test paysvr1 probe-count 5 set services rpm probe probe2 test paysvr1 probe-interval 5 set services rpm probe probe2 test paysvr1 test-interval 3 set services rpm probe probe2 test paysvr1 thresholds successive-loss 5 set services rpm probe probe2 test paysvr1 destination-interface fe-0/0/1.0 set services rpm probe probe2 test paysvr1 hardware-timestamp set services rpm probe probe2 test paysvr1 next-hop 1.1.1.2 set services ip-monitoring policy enable_backup match rpm-probe probe1 set services ip-monitoring policy enable_backup match rpm-probe probe2 set services ip-monitoring policy enable_backup then interface fe-0/0/2 enable