Static Route Reject and Discard Configuration(Juniper vMX)

2025. 2. 14. 23:57·Network/Switching, Routing Basic

1. Static Route Reject and Discard Configuration 구성도

1) Static Route Reject and Discard Configuration 구성도

  • Reject Option
    • 패킷을 Discard하고 S-IP에게 'ICMP Destination Unreachable'을 생성하여 전송
  • Discard Option
    • 패킷을 Discard만 하며 'ICMP Destination Unreachable'을 생성하지 않음

 

2) 테스트 장비

  • Emulator : EVE-NG
  • OS : Juniper vMX 18.2R1.9

 

 

2. Static Route Reject and Discard Configuration

1) Interface IP Address Configuration

더보기
< R1 : Interface IP 설정 >
set interfaces ge-0/0/1 unit 0 family inet address 1.1.2.1/24
set interfaces lo0 unit 0 family inet address 1.1.1.1/32
더보기
< R2 : Interface IP 설정 >
set interfaces ge-0/0/0 unit 0 family inet address 1.1.2.2/24
set interfaces ge-0/0/1 unit 0 family inet address 1.2.3.2/24
set interfaces lo0 unit 0 family inet address 2.2.2.2/32
더보기
< R3 : Interface IP 설정 >
set interfaces ge-0/0/0 unit 0 family inet address 1.2.3.3/24
set interfaces lo0 unit 0 family inet address 3.3.3.3/32

 

2) Static Route Configuration

< R1 : Static Route 설정 >
set routing-options static route 3.3.3.3/32 next-hop 1.1.2.2
root@R1> show route protocol static table inet.0  

inet.0: 4 destinations, 4 routes (4 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both

3.3.3.3/32         *[Static/5] 00:20:07
                    > to 1.1.2.2 via ge-0/0/1.0

 

3) Static Route Reject Configuration

< R2 : Static Route Reject Option 설정 >
set routing-options static route 3.3.3.3/32 reject
root@R2> show route protocol static table inet.0          

inet.0: 6 destinations, 6 routes (6 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both

3.3.3.3/32         *[Static/5] 00:13:37
                      Reject
  • Routing Table의 Next Hop이 'Reject'인 것을 확인

 

root@R2> show route forwarding-table matching 3.3.3.3 family inet table default    
Routing table: default.inet
Internet:
Enabled protocols: Bridging, 
Destination        Type RtRef Next hop           Type Index    NhRef Netif
3.3.3.3/32         user     0                    rjct       36     2
  • Forwarding Table의 Type이 'rjct'(Reject)인 것을 확인

 

root@R1> ping 3.3.3.3 count 2    
PING 3.3.3.3 (3.3.3.3): 56 data bytes
36 bytes from 1.1.2.2: Destination Net Unreachable
Vr HL TOS  Len   ID Flg  off TTL Pro  cks      Src      Dst
 4  5  00 0054 5e37   0 0000  40  01 136b 1.1.2.1  3.3.3.3 

36 bytes from 1.1.2.2: Destination Net Unreachable
Vr HL TOS  Len   ID Flg  off TTL Pro  cks      Src      Dst
 4  5  00 0054 5e50   0 0000  40  01 1352 1.1.2.1  3.3.3.3 


--- 3.3.3.3 ping statistics ---
2 packets transmitted, 0 packets received, 100% packet loss

  • ICMP Request 패킷이 R2의 Next-Hop이 Reject인 Entry와 Longest Match되어 해당 패킷을 Discard하며 S-IP로 ICMP Unreachable Message를 전송

 

4) Static Route Discard Configuration

< R2 : Static Route Discard Option 설정 >
set routing-options static route 3.3.3.3/32 discard
root@R2> show route protocol static table inet.0

inet.0: 6 destinations, 6 routes (6 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both

3.3.3.3/32         *[Static/5] 00:00:19
                      Discard
  • Routing Table의 Next Hop이 'Discard'인 것을 확인

 

root@R2> show route forwarding-table matching 3.3.3.3/32 family inet table default 
Routing table: default.inet
Internet:
Enabled protocols: Bridging, 
Destination        Type RtRef Next hop           Type Index    NhRef Netif
3.3.3.3/32         user     0                    dscd       34     2
  • Forwarding Table의 Type이 'dscd'(Discard)인 것을 확인

 

root@R1> ping 3.3.3.3 count 2    
PING 3.3.3.3 (3.3.3.3): 56 data bytes

--- 3.3.3.3 ping statistics ---
2 packets transmitted, 0 packets received, 100% packet loss

  • ICMP Request 패킷이 R2의 Next-Hop이 Discard인 Entry와 Longest Match되어 해당 패킷을 Discard

 

저작자표시 비영리 변경금지 (새창열림)

'Network > Switching, Routing Basic' 카테고리의 다른 글

Table 생성 과정  (0) 2025.02.22
Static Route with RPM and Event-option Configuration(Juniper vMX)  (0) 2025.02.20
Static Route Resolve Configuration(Juniper vMX)  (0) 2025.02.18
Static Route no-install Configuration(Juniper vMX)  (0) 2025.02.16
Static Route Metric and 'qualified-next-hop' Configuration(Juniper vMX)  (0) 2025.02.12
Static Route Preference and 'qualified-next-hop' Configuration(Juniper vMX)  (0) 2025.02.10
Static Route Basic Configuration(Juniper vMX)  (0) 2025.02.08
Static Route Next-Hop IP address vs Outgoing interface  (0) 2025.02.06
'Network/Switching, Routing Basic' 카테고리의 다른 글
  • Static Route Resolve Configuration(Juniper vMX)
  • Static Route no-install Configuration(Juniper vMX)
  • Static Route Metric and 'qualified-next-hop' Configuration(Juniper vMX)
  • Static Route Preference and 'qualified-next-hop' Configuration(Juniper vMX)
ant-choi의 네트워크
ant-choi의 네트워크
안녕하세요. 네트워크 엔지니어로 근무하고 있는 직장인 입니다. 2024.08.26부터 새로운 버전으로 블로그를 개설하였습니다. 제가 스터디한 내용이나 회사에서 업무 진행 시, 필요한 내용들을 정리하여 업로드 하는 것을 목표로 하고 있습니다. 오류가 있거나 피드백이 있으신 분들은 댓글 남겨주시면 감사하겟습니다.
  • ant-choi의 네트워크
    ant-choi의 네트워크
    ant-choi의 네트워크
  • 전체
    오늘
    어제
    • 분류 전체보기 (133) N
      • Network (116) N
        • Juniper Software (0)
        • Juniper Basic (7)
        • Emulator (24)
        • Network Basic (11)
        • ARP, ICMP (14)
        • VLAN (22)
        • STP (0)
        • VRRP (11)
        • Link Aggregation (10)
        • MC-LAG (0)
        • Switching, Routing Basic (15)
        • DHCP (2) N
        • OSPF (0)
        • BGP (0)
        • Routing Instance (0)
        • Issue (0)
      • Office (5)
        • Office 공통 (1)
        • Excel (1)
        • Power Point (1)
        • Word (2)
        • Outlook (0)
      • 기타 (12)
        • Windows (1)
        • Browser (4)
        • Tistory (7)
        • Notion (0)
        • Application (0)
  • 블로그 메뉴

    • hELLO· Designed By정상우.v4.10.3
    ant-choi의 네트워크
    Static Route Reject and Discard Configuration(Juniper vMX)
    상단으로

    티스토리툴바