귀하의 경험을 개선할 수 있도록 도와주십시오.

귀하의 의견을 알려주십시오.

2분이 소요되는 설문 조사에 시간을 내주시겠습니까?

close
keyboard_arrow_left
list Table of Contents
keyboard_arrow_right

이 기계 번역이 도움이 되었습니까?

starstarstarstarstar
Go to English page
면책 조항:

이 페이지는 타사 기계 번역 소프트웨어를 사용해 번역됩니다. 주니퍼 네트웍스에서는 우수한 품질의 번역을 제공하기 위한 합리적인 수준의 노력을 기울이지만 해당 컨텐츠의 정확성을 보장할 수 없습니다. 본 번역에 포함된 정보의 정확성과 관련해 의문이 있는 경우 영문 버전을 참조하시기 바랍니다. 다운로드 가능한 PDF는 영어로만 제공됩니다.

예: 라우팅 정책에서의 커뮤니티 구성

date_range 19-Jan-25

커뮤니티는 유사한 속성을 가진 경로를 관리상 그룹화하기 위해 BGP에서 사용하는 경로 속성입니다.

요구 사항

이 예를 구성하기 전에 디바이스 초기화를 제외한 특별한 구성은 필요하지 않습니다.

  • Junos OS 릴리스 21.1R1에서 vMX를 사용하여 업데이트 및 재검증되었습니다.

개요

커뮤니티 속성의 주요 역할 중 하나는 경로를 함께 연결하는 데 사용되는 관리 태그 값입니다. 일반적으로 이러한 경로는 몇 가지 공통적인 속성을 공유하지만 필수적인 것은 아닙니다. 커뮤니티는 BGP 내의 유연한 도구입니다. 개별 커뮤니티 값을 단일 경로 또는 여러 경로에 할당할 수 있습니다. 경로에는 단일 커뮤니티 값 또는 여러 값을 할당할 수 있습니다. 네트워크는 커뮤니티 속성을 사용하여 관리 라우팅 정책 구현을 지원합니다. 경로에 할당된 값은 네트워크에서 수락하거나 네트워크에서 거부하거나 속성을 수정할 수 있습니다.

그림 1에는 자율 시스템(AS) 64510의 내부 BGP(IBGP) 피어로서 디바이스 R1, 디바이스 R2 및 디바이스 R3이 나와 있습니다. 디바이스 R4는 AS 64511에서 주소 공간 172.16.0.0/21을 표시하고 있습니다.

토폴로지

그림 1: 일반 BGP 커뮤니티의 토폴로지일반 BGP 커뮤니티의 토폴로지

디바이스 R1이 디바이스 R4로부터 수신한 특정 경로는 다음과 같습니다.

content_copy zoom_out_map
user@R1> show route receive-protocol bgp 10.0.0.13

inet.0: 24 destinations, 28 routes (24 active, 0 holddown, 0 hidden)
  Prefix                  Nexthop              MED     Lclpref    AS path
* 172.16.0.0/24           10.0.0.13                               64511 I
* 172.16.1.0/24           10.0.0.13                               64511 I
* 172.16.2.0/24           10.0.0.13                               64511 I
* 172.16.3.0/24           10.0.0.13                               64511 I
  172.16.4.0/24           10.0.0.13                               64511 I
  172.16.5.0/24           10.0.0.13                               64511 I
  172.16.6.0/24           10.0.0.13                               64511 I
  172.16.7.0/24           10.0.0.13                               64511 I

AS 64511의 관리자는 디바이스 R1으로부터 특정 사용자 트래픽을 수신하고 디바이스 R3로부터 다른 사용자 트래픽을 수신하고자 합니다. 이 관리 목표를 달성하기 위해 디바이스 R4는 일부 전송 경로에 커뮤니티 값 64511:1을 연결하고 다른 전송 경로에 커뮤니티 값 64511:3을 연결합니다. AS 64510 내의 라우팅 정책은 커뮤니티 일치 기준을 사용하여 구성된 것으로 수신된 경로의 로컬 기본 설정을 BGP 경로 선택 알고리즘을 변경하는 새 값으로 변경합니다. 로컬 기본 설정 값이 가장 높은 경로가 선호됩니다.

디바이스 R1에서 커뮤니티 값이 64511:1인 경로에는 로컬 기본 설정 200이 할당되고 커뮤니티 값이 64511:3인 경로에는 로컬 기본 설정 50이 할당됩니다. 디바이스 R3에서는 반대로 커뮤니티 값이 64511:3인 경로에 로컬 기본 설정 200이 할당되고 커뮤니티 값이 64511:1인 경로에 로컬 기본 설정 50이 할당됩니다. 그런 다음 이 정보는 디바이스 R1 및 디바이스 R3에 의해 IBGP를 통해 디바이스 R2로 전달됩니다.

CLI 빠른 구성은(는) 그림 1 내 모든 디바이스의 구성을 보여줍니다.

단계별 구성 섹션에서는 디바이스 R1 및 R4의 구성 단계에 대해 설명합니다.

구성

CLI 빠른 구성

이 예를 빠르게 구성하려면, 아래 명령을 복사하여 텍스트 파일로 붙여 넣은 다음 모든 라인브레이크를 제거하고, 네트워크 구성을 일치하는 데 필요한 세부 사항을 바꾸고 [edit] 계층 수준에서 명령을 CLI로 복사해 붙여 넣습니다.

디바이스 R1

content_copy zoom_out_map
set interfaces ge-0/0/0 unit 0 family inet address 10.0.0.1/30
set interfaces ge-0/0/1 unit 0 family inet address 10.1.0.5/30
set interfaces ge-0/0/2 unit 0 family inet address 10.0.0.14/30
set interfaces lo0 unit 0 family inet address 192.168.0.1/32
set policy-options policy-statement change-local-preference term find-R1-routes from community R1_PREFERRED
set policy-options policy-statement change-local-preference term find-R1-routes then local-preference 200
set policy-options policy-statement change-local-preference term find-R3-routes from community R3_PREFERRED
set policy-options policy-statement change-local-preference term find-R3-routes then local-preference 50
set policy-options policy-statement send-direct term 1 from protocol direct
set policy-options policy-statement send-direct term 1 from route-filter 10.0.0.12/30 exact
set policy-options policy-statement send-direct term 1 then accept
set policy-options community R3_PREFERRED members 64511:3
set policy-options community R1_PREFERRED members 64511:1
set protocols bgp group int type internal
set protocols bgp group int local-address 192.168.0.1
set protocols bgp group int export send-direct
set protocols bgp group int neighbor 192.168.0.2
set protocols bgp group int neighbor 192.168.0.3
set protocols bgp group ext type external
set protocols bgp group ext import change-local-preference
set protocols bgp group ext peer-as 64511
set protocols bgp group ext neighbor 10.0.0.13
set protocols ospf area 0.0.0.0 interface ge-0/0/0.0
set protocols ospf area 0.0.0.0 interface ge-0/0/1.0
set protocols ospf area 0.0.0.0 interface lo0.0 passive
set routing-options router-id 192.168.0.1
set routing-options autonomous-system 64510

디바이스 R2

content_copy zoom_out_map
set interfaces ge-0/0/0 unit 0 family inet address 10.0.0.2/30
set interfaces ge-0/0/1 unit 0 family inet address 10.1.0.1/30
set interfaces lo0 unit 0 family inet address 192.168.0.2/32
set protocols bgp group int type internal
set protocols bgp group int local-address 192.168.0.2
set protocols bgp group int neighbor 192.168.0.1
set protocols bgp group int neighbor 192.168.0.3
set protocols ospf area 0.0.0.0 interface ge-0/0/0.0
set protocols ospf area 0.0.0.0 interface ge-0/0/1.0
set protocols ospf area 0.0.0.0 interface lo0.0 passive
set routing-options router-id 192.168.0.2
set routing-options autonomous-system 64510

디바이스 R3

content_copy zoom_out_map
set interfaces ge-0/0/0 unit 0 family inet address 10.1.0.6/30
set interfaces ge-0/0/1 unit 0 family inet address 10.1.0.2/30
set interfaces ge-0/0/2 unit 0 family inet address 10.0.0.10/30
set interfaces lo0 unit 0 family inet address 192.168.0.3/32
set policy-options policy-statement change-local-preference term find-R3-routes from community R3_PREFERRED
set policy-options policy-statement change-local-preference term find-R3-routes then local-preference 200
set policy-options policy-statement change-local-preference term find-R1-routes from community R1_PREFERRED
set policy-options policy-statement change-local-preference term find-R1-routes then local-preference 50
set policy-options policy-statement send-direct term 1 from protocol direct
set policy-options policy-statement send-direct term 1 from route-filter 10.0.0.8/30 exact
set policy-options policy-statement send-direct term 1 then accept
set policy-options community R1_PREFERRED members 64511:1
set policy-options community R3_PREFERRED members 64511:3
set protocols bgp group int type internal
set protocols bgp group int local-address 192.168.0.3
set protocols bgp group int export send-direct
set protocols bgp group int neighbor 192.168.0.1
set protocols bgp group int neighbor 192.168.0.2
set protocols bgp group ext type external
set protocols bgp group ext import change-local-preference
set protocols bgp group ext peer-as 64511
set protocols bgp group ext neighbor 10.0.0.9
set protocols ospf area 0.0.0.0 interface ge-0/0/1.0
set protocols ospf area 0.0.0.0 interface ge-0/0/0.0
set protocols ospf area 0.0.0.0 interface lo0.0 passive
set routing-options router-id 192.168.0.3
set routing-options autonomous-system 64510

디바이스 R4

content_copy zoom_out_map
set interfaces ge-0/0/0 unit 0 family inet address 10.0.0.13/30
set interfaces ge-0/0/1 unit 0 family inet address 10.0.0.9/30
set interfaces lo0 unit 0 family inet address 192.168.0.4/32
set policy-options policy-statement send-static term 1 from protocol static
set policy-options policy-statement send-static term 1 from route-filter 172.16.0.0/24 exact
set policy-options policy-statement send-static term 1 from route-filter 172.16.1.0/24 exact
set policy-options policy-statement send-static term 1 from route-filter 172.16.2.0/24 exact
set policy-options policy-statement send-static term 1 from route-filter 172.16.3.0/24 exact
set policy-options policy-statement send-static term 1 then community add R1_PREFERRED
set policy-options policy-statement send-static term 1 then accept
set policy-options policy-statement send-static term 2 from protocol static
set policy-options policy-statement send-static term 2 from route-filter 172.16.4.0/24 exact
set policy-options policy-statement send-static term 2 from route-filter 172.16.5.0/24 exact
set policy-options policy-statement send-static term 2 from route-filter 172.16.6.0/24 exact
set policy-options policy-statement send-static term 2 from route-filter 172.16.7.0/24 exact
set policy-options policy-statement send-static term 2 then community add R3_PREFERRED
set policy-options policy-statement send-static term 2 then accept
set policy-options policy-statement send-static term 3 then reject
set policy-options community R3_PREFERRED members 64511:3
set policy-options community R1_PREFERRED members 64511:1
set protocols bgp group to-R1 type external
set protocols bgp group to-R1 export send-static
set protocols bgp group to-R1 peer-as 64510
set protocols bgp group to-R1 neighbor 10.0.0.14
set protocols bgp group to-R3 type external
set protocols bgp group to-R3 export send-static
set protocols bgp group to-R3 peer-as 64510
set protocols bgp group to-R3 neighbor 10.0.0.10
set routing-options router-id 192.168.0.4
set routing-options autonomous-system 64511
set routing-options static route 172.16.0.0/24 reject
set routing-options static route 172.16.1.0/24 reject
set routing-options static route 172.16.2.0/24 reject
set routing-options static route 172.16.3.0/24 reject
set routing-options static route 172.16.4.0/24 reject
set routing-options static route 172.16.5.0/24 reject
set routing-options static route 172.16.6.0/24 reject
set routing-options static route 172.16.7.0/24 reject

단계별 절차

다음 예는 구성 계층에서 다양한 수준의 탐색이 필요합니다. CLI 탐색에 대한 자세한 내용은 Junos OS CLI 사용자 가이드구성 모드에서 CLI 편집기 사용을(를) 참조하십시오.

디바이스 R1 구성

  1. 인터페이스를 구성합니다.

    content_copy zoom_out_map
    [edit interfaces]
    user@R1# set ge-0/0/0 unit 0 family inet address 10.0.0.1/30
    user@R1# set ge-0/0/1 unit 0 family inet address 10.1.0.5/30
    user@R1# set ge-0/0/2 unit 0 family inet address 10.0.0.14/30
    user@R1# set lo0 unit 0 family inet address 192.168.0.1/32
    
  2. 디바이스 R2 및 R3에 대한 내부 게이트웨이 프로토콜(IGP) 연결을 구성합니다.

    content_copy zoom_out_map
    [edit protocols ospf area 0.0.0.0]
    user@R1# set interface ge-0/0/0.0
    user@R1# set interface ge-0/0/1.0
    user@R1# set interface lo0.0 passive
    
  3. 디바이스 R2 및 R3에 대한 IBGP 연결을 구성합니다.

    content_copy zoom_out_map
    [edit protocols bgp group int]
    user@R1# set type internal
    user@R1# set local-address 192.168.0.1
    user@R1# set export send-direct
    user@R1# set neighbor 192.168.0.2
    user@R1# set neighbor 192.168.0.3
    
  4. 디바이스 R4에 대한 EBGP 연결을 구성합니다.

    content_copy zoom_out_map
    [edit protocols bgp group ext]
    user@R1# set type external
    user@R1# set import change-local-preference
    user@R1# set peer-as 64511
    user@R1# set neighbor 10.0.0.13
    
  5. 정책 send-direct을(를) 구성합니다.

    이 정책은 IBGP 구성에서 참조되며 디바이스 R2가 외부 연결성을 사용할 수 있도록 합니다. 대안은 디바이스 R1 및 디바이스 R3에서 next-hop self 정책을 구성하는 것입니다.

    content_copy zoom_out_map
    [edit policy-options policy-statement send-direct term 1]
    user@R1# set from protocol direct
    user@R1# set from route-filter 10.0.0.12/30 exact
    user@R1# set then accept
    
  6. 지정된 커뮤니티 태그가 있는 경로의 로컬 기본 설정을 변경하는 정책을 구성합니다.

    content_copy zoom_out_map
    [edit policy-options ]
    user@R1# set policy-statement change-local-preference term find-R1-routes from community R1_PREFERRED
    user@R1# set policy-statement change-local-preference term find-R1-routes then local-preference 200
    user@R1# set policy-statement change-local-preference term find-R3-routes from community R3_PREFERRED
    user@R1# set policy-statement change-local-preference term find-R3-routes then local-preference 50
    user@R1# set community R3_PREFERRED members 64511:3
    user@R1# set community R1_PREFERRED members 64511:1
    
  7. 자율 시스템(AS) 번호 및 라우터 ID를 구성합니다.

    content_copy zoom_out_map
    [edit routing-options]
    user@R1# set router-id 192.168.0.1
    user@R1# set autonomous-system 64510
    

디바이스 R4 구성

  1. 인터페이스를 구성합니다.

    content_copy zoom_out_map
    [edit interfaces]
    user@R4# set ge-0/0/0 unit 0 family inet address 10.0.0.13/30
    user@R4# set ge-0/0/1 unit 0 family inet address 10.0.0.9/30
    user@R4# set lo0 unit 0 family inet address 192.168.0.4/32
    
  2. 디바이스 R1 및 R3에 대한 EBGP 연결을 구성합니다.

    content_copy zoom_out_map
    [edit protocols bgp]
    user@R4# set group to-R1 type external
    user@R4# set group to-R1 export send-static
    user@R4# set group to-R1 peer-as 64510
    user@R4# set group to-R1 neighbor 10.0.0.14
    user@R4# set group to-R3 type external
    user@R4# set group to-R3 export send-static
    user@R4# set group to-R3 peer-as 64510
    user@R4# set group to-R3 neighbor 10.0.0.10
    
  3. 커뮤니티 태그를 구성합니다.

    content_copy zoom_out_map
    [edit policy-options ]
    user@R4# set community R3_PREFERRED members 64511:3
    user@R4# set community R1_PREFERRED members 64511:1
    
  4. 정책 send-static을(를) 구성합니다.

    이 정책은 디바이스 R1 및 디바이스 R3에 대한 EBGP 연결에서 참조됩니다. 이 정책은 64511:1(PREFERRED) 커뮤니티를 일부 경로에 연결하고 64511:3(NOT_PREFERRED) 커뮤니티를 다른 경로에 연결합니다.

    content_copy zoom_out_map
    [edit policy-options]
    user@R4# set policy-statement send-static term 1 from protocol static
    user@R4# set policy-statement send-static term 1 from route-filter 172.16.0.0/24 exact
    user@R4# set policy-statement send-static term 1 from route-filter 172.16.1.0/24 exact
    user@R4# set policy-statement send-static term 1 from route-filter 172.16.2.0/24 exact
    user@R4# set policy-statement send-static term 1 from route-filter 172.16.3.0/24 exact
    user@R4# set policy-statement send-static term 1 then community add R1_PREFERRED
    user@R4# set policy-statement send-static term 1 then accept
    user@R4# set policy-statement send-static term 2 from protocol static
    user@R4# set policy-statement send-static term 2 from route-filter 172.16.4.0/24 exact
    user@R4# set policy-statement send-static term 2 from route-filter 172.16.5.0/24 exact
    user@R4# set policy-statement send-static term 2 from route-filter 172.16.6.0/24 exact
    user@R4# set policy-statement send-static term 2 from route-filter 172.16.7.0/24 exact
    user@R4# set policy-statement send-static term 2 then community add R3_PREFERRED
    user@R4# set policy-statement send-static term 2 then accept
    user@R4# set policy-statement send-static term 3 then reject
    
  5. 고정 경로를 구성합니다.

    content_copy zoom_out_map
    [edit routing-options static]
    user@R4# set route 172.16.0.0/24 reject
    user@R4# set route 172.16.1.0/24 reject
    user@R4# set route 172.16.2.0/24 reject
    user@R4# set route 172.16.3.0/24 reject
    user@R4# set route 172.16.4.0/24 reject
    user@R4# set route 172.16.5.0/24 reject
    user@R4# set route 172.16.6.0/24 reject
    user@R4# set route 172.16.7.0/24 reject
    
  6. 자율 시스템(AS) 번호 및 라우터 ID를 구성합니다.

    content_copy zoom_out_map
    [edit routing-options]
    user@R4# set router-id 192.168.0.4
    user@R4# set autonomous-system 64511
    

결과

구성 모드에서 show interfaces, show protocols, show policy-optionsshow routing-options 명령을 입력하여 구성을 확인합니다. 출력 결과가 의도한 구성대로 표시되지 않으면 이 예의 지침을 반복하여 구성을 수정하십시오.

디바이스 R1

content_copy zoom_out_map
user@R1# show interfaces
ge-0/0/0 {
    unit 0 {
        family inet {
            address 10.0.0.1/30;
        }
    }
}
ge-0/0/1 {
    unit 0 {
        family inet {
            address 10.1.0.5/30;
        }
    }
}
ge-0/0/2 {
    unit 0 {
        family inet {
            address 10.0.0.14/30;
        }
    }
}
lo0 {
    unit 0 {
        family inet {
            address 192.168.0.1/32;
        }
    }
}
content_copy zoom_out_map
user@R1# show protocols
bgp {
    group int {
        type internal;
        local-address 192.168.0.1;
        export send-direct;
        neighbor 192.168.0.2;
        neighbor 192.168.0.3;
    }
    group ext {
        type external;
        import change-local-preference;
        peer-as 64511;
        neighbor 10.0.0.13;
    }
}
ospf {
    area 0.0.0.0 {
        interface ge-0/0/0.0;
        interface ge-0/0/1.0;
        interface lo0.0 {
            passive;
        }
    }
}
content_copy zoom_out_map
user@R1# show policy-options
policy-statement change-local-preference {
    term find-R1-routes {
        from community R1_PREFERRED;
        then {
            local-preference 200;
        }
    }
    term find-R3-routes {
        from community R3_PREFERRED;
        then {
            local-preference 50;
        }
    }
}
policy-statement send-direct {
    term 1 {
        from {
            protocol direct;
            route-filter 10.0.0.12/30 exact;
        }
        then accept;
    }
}
community R3_PREFERRED members 64511:3;
community R1_PREFERRED members 64511:1;
content_copy zoom_out_map
user@R1# show routing-options
router-id 192.168.0.1;
autonomous-system 64510;

디바이스 R4

content_copy zoom_out_map
user@R4# show interfaces
ge-0/0/0 {
    unit 0 {
        family inet {
            address 10.0.0.13/30;
        }
    }
}
ge-0/0/1 {
    unit 0 {
        family inet {
            address 10.0.0.9/30;
        }
    }
}
lo0 {
    unit 0 {
        family inet {
            address 192.168.0.4/32;
        }
    }
}
content_copy zoom_out_map
user@R4# show protocols
bgp {
    group to-R1 {
        type external;
        export send-static;
        peer-as 64510;
        neighbor 10.0.0.14;
    }
    group to-R3 {
        type external;
        export send-static;
        peer-as 64510;
        neighbor 10.0.0.10;
    }
}
content_copy zoom_out_map
user@R4# show policy-options
policy-statement send-static {
    term 1 {
        from {
            protocol static;
            route-filter 172.16.0.0/24 exact;
            route-filter 172.16.1.0/24 exact;
            route-filter 172.16.2.0/24 exact;
            route-filter 172.16.3.0/24 exact;
        }
        then {
            community add R1_PREFERRED;
            accept;
        }
    }
    term 2 {
        from {
            protocol static;
            route-filter 172.16.4.0/24 exact;
            route-filter 172.16.5.0/24 exact;
            route-filter 172.16.6.0/24 exact;
            route-filter 172.16.7.0/24 exact;
        }
        then {
            community add R3_PREFERRED;
            accept;
        }
    }
    term 3 {
        then reject;
    }
}
community R3_PREFERRED members 64511:3;
community R1_PREFERRED members 64511:1;
content_copy zoom_out_map
user@R4# show routing-options
router-id 192.168.0.4;
autonomous-system 64511;
static {
    route 172.16.0.0/24 reject;
    route 172.16.1.0/24 reject;
    route 172.16.2.0/24 reject;
    route 172.16.3.0/24 reject;
    route 172.16.4.0/24 reject;
    route 172.16.5.0/24 reject;
    route 172.16.6.0/24 reject;
    route 172.16.7.0/24 reject;
}

디바이스 구성이 완료되면 구성모드에서 commit을(를) 입력합니다.

검증

구성이 올바르게 작동하고 있는지 확인합니다.

디바이스 R4에서 전송된 경로 확인

목적

디바이스 R4에서, 디바이스 R1 및 디바이스 R3으로 전송된 경로를 확인합니다.

작업

content_copy zoom_out_map
user@R4> show route advertising-protocol bgp 10.0.0.14 extensive

inet.0: 13 destinations, 13 routes (13 active, 0 holddown, 0 hidden)
* 172.16.0.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.1.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.2.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.3.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.4.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

* 172.16.5.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

* 172.16.6.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

* 172.16.7.0/24 (1 entry, 1 announced)
 BGP group to-R1 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

content_copy zoom_out_map
user@R4> show route advertising-protocol bgp 10.0.0.10 extensive

inet.0: 13 destinations, 13 routes (13 active, 0 holddown, 0 hidden)
* 172.16.0.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.1.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.2.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.3.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:1

* 172.16.4.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

* 172.16.5.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

* 172.16.6.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

* 172.16.7.0/24 (1 entry, 1 announced)
 BGP group to-R3 type External
     Nexthop: Self
     AS path: [64511] I
     Communities: 64511:3

의미

디바이스 R4는 커뮤니티 64511:1 및 64511:3을 가진 경로에 태그를 지정하고 디바이스 R1 및 R3으로 전송했습니다.

디바이스 R2에서 수신된 경로 확인

목적

디바이스 R2에서, 디바이스 R1 및 디바이스 R3에서 수신한 경로를 확인합니다.

작업

content_copy zoom_out_map
user@R2> show route receive-protocol bgp 192.168.0.1

inet.0: 25 destinations, 25 routes (25 active, 0 holddown, 0 hidden)
  Prefix                  Nexthop              MED     Lclpref    AS path
* 10.0.0.12/30            192.168.0.1                  100        I
* 172.16.0.0/24           10.0.0.13                    200        64511 I
* 172.16.1.0/24           10.0.0.13                    200        64511 I
* 172.16.2.0/24           10.0.0.13                    200        64511 I
* 172.16.3.0/24           10.0.0.13                    200        64511 I
content_copy zoom_out_map
user@R2> show route receive-protocol bgp 192.168.0.3

inet.0: 25 destinations, 25 routes (25 active, 0 holddown, 0 hidden)
  Prefix                  Nexthop              MED     Lclpref    AS path
* 10.0.0.8/30             192.168.0.3                  100        I
* 172.16.4.0/24           10.0.0.9                     200        64511 I
* 172.16.5.0/24           10.0.0.9                     200        64511 I
* 172.16.6.0/24           10.0.0.9                     200        64511 I
* 172.16.7.0/24           10.0.0.9                     200        64511 I
content_copy zoom_out_map
user@R2> show route match-prefix 172.16.*

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

172.16.0.0/24      *[BGP/170] 1w3d 00:02:11, localpref 200, from 192.168.0.1
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.0.0.1 via ge-0/0/0.0
172.16.1.0/24      *[BGP/170] 1w3d 00:02:11, localpref 200, from 192.168.0.1
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.0.0.1 via ge-0/0/0.0
172.16.2.0/24      *[BGP/170] 1w3d 00:02:11, localpref 200, from 192.168.0.1
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.0.0.1 via ge-0/0/0.0
172.16.3.0/24      *[BGP/170] 1w3d 00:02:11, localpref 200, from 192.168.0.1
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.0.0.1 via ge-0/0/0.0
172.16.4.0/24      *[BGP/170] 1w3d 00:01:50, localpref 200, from 192.168.0.3
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.1.0.2 via ge-0/0/1.0
172.16.5.0/24      *[BGP/170] 1w3d 00:01:50, localpref 200, from 192.168.0.3
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.1.0.2 via ge-0/0/1.0
172.16.6.0/24      *[BGP/170] 1w3d 00:01:50, localpref 200, from 192.168.0.3
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.1.0.2 via ge-0/0/1.0
172.16.7.0/24      *[BGP/170] 1w3d 00:01:50, localpref 200, from 192.168.0.3
                      AS path: 64511 I, validation-state: unverified
                    >  to 10.1.0.2 via ge-0/0/1.0

의미

디바이스 R2에는 별표(*)로 표시된 것처럼 예상 로컬 기본 설정과 예상 활성 경로가 있는 경로가 있습니다.

예: BGP 커뮤니티 수를 기반으로 라우팅 정책 구성
external-footer-nav