본문 바로가기
네트워크/VRF

VRF Leaking with Static and Policy Sample Configuration(Nokia 7750 SR)

by 최개미의 세계 2024. 6. 30.

1. VRF Leaking with Static and Policy Sample Configuration 구성도

  • 테스트 장비
    • 에뮬레이터 : EVE-NG
    • 라우터 : Nokia 7750 SR-12 TiMOS-C-21.10.R1
    • 스위치 : Cisco IOL I86BI_LINUXL2-ADVENTERPRISEK9-M, Version 15.1
  • 본 글에서는 BGP 사용 없이 VRF Leaking 하는 것이 목표
    • Static Route 및 Policy(PBR)를 사용하여 VRF Leaking
    • ① : VRF↔Global 간에 Policy를 사용하여 통신하는 것이 목표
    • ② : VRF↔Global 간에 Policy를 사용하여 통신하는 것이 목표
    • ③ : 서로 다른 VRF 간에 Static Route를 설정하여 통신하는 것이 목표
  • 본 글에서 진행하는 테스트는 BGP를 사용하지 않으므로 Route Target이 불필요
  • VPRN은 Nokia 용어이며 본 글에서는 VPRN이 VRF와 동일한 용어로 가정
  • Nokia는 Static Route를 이용한 VRF Leaking이 불가능하며 Policy를 이용한 VRF Leaking만 가능
  • 기본적인 VRF 설정은 'VRF Sample Configuration' 글 참고

 

 

2. VRF Leaking with Static and Policy Sample Configuration

1) Global Interface Configuration

  • Global에 해당하는 포트 및 인터페이스 설정
    • Nokia 7750 SR OS는 기본적으로 Ethernet Mode Network로 구성

 

  • SW 인터페이스에 IP Address를 설정하며 테스트를 위해 Default-Route를 설정
  • 모든 SW도 SW1의 구성과 비슷하게 설정

 

2) VRF Interface Configuration

  • VPRN(VRF)에 설정할 포트에 'ethernet mode access'로 설정

 

  • 'configure service vprn [service-id] name [service-name] customer [customer-id] create'를 지정하여 VPRN(VRF)를 생성
  • 각 VRF에 RD(Route Distinguisher)를 지정

 

  • 위에서 생성한 각 VRF의 Service-ID, Status, Customer-ID, Service-Name에 대한 정보 확인 가능

 

3) Global and VRF Interface Configuration Verification

  • 라우터에서 Global 및 VRF 별로 인터페이스에 적용된 IP Address, Status, Binding된 Port 등 정보 확인 가능

 

  • 위에서 설정한 Global, VRF10, VRF20에 대한 설정이 각 라우팅 테이블에 정상으로 올라온 것을 확인
  • Global 및 VRF가 다르면 라우팅 테이블이 분리되어 있음을 확인

 

  • 모든 장비에서 인접 장비까지 Ping Test 진행
  • 'ping router [service-id] [destination-ip]'를 입력하여 각 VRF에 해당하는 장비로 Ping Test 가능

 

4) ① VRF10→Global Leaking with Policy

  • VRF10→Global로 Leaking할 Network Address를 Policy를 이용하여 지정

 

  • 'export-grt'를 이용하여 VRF10→Global로 Leaking할 Policy(Network Address)를 적용

 

  • VRF10→Global로 Leaking된 것을 확인 

 

5) ① Global→VRF10 Leaking with Static

  • Global→VRF10으로 Leaking할 Network Address를 Policy를 이용하여 지정

 

  • 'config>router' Context에서 'leak-export'를 설정하여 특정 GRT Route가 VRF로 Leaking되도록 설정
  • 'import-grt'를 이용하여 Global→VRF10으로 Leaking할 Policy(Network Address)를 적용
  • Global→VRF로 Leaking할 수 있는 Policy 개수는 기본적으로 5개이며 'leak-export-limit'을 이용하여 적용 가능한 Policy 개수 변경 가능
  • 'import-grt'를 사용하여 Leaking될 수 있는 GRT Route Type
    • Direct Routes
    • Static Routes
    • RIP, OSPF, IS-IS Routes

 

  • Global→VRF10으로 Leaking된 것을 확인 

 

  • Global↔VRF10(SW1↔SW3) 간 통신 확인

 

6) ② VRF20→Global Leaking with Policy

  • 'grt-lookup enable-grt' 설정 시, VRF Table에서 Lookup할 정보가 없을 때 GRT(Global Route Table)에서 Route를 Lookup
  • Static-Route Option을 사용하지 않고 해당 명령어를 사용할 경우, GRT보다 Local VRF에서 Lookup이 선호
  • 'enable-grt' 옵션으로 'allow-local-management' 설정 시, ssh, telnet, snmp 등 사용 가능

 

  • VRF20에서 Global Network Address 정보가 없음을 확인

 

7) ② Global→VRF20 Leaking with Policy

  • VRF20→Global로 Leaking할 Network Address를 Policy를 이용하여 지정

 

  • 'export-grt'를 이용하여 VRF20→Global로 Leaking할 Policy(Network Address)를 적용

 

  • VRF20→Global로 Leaking된 것을 확인 

 

  • 'grt-lookup enable-grt'를 설정하여 VRF20 Routing Table에 없는 정보는 Global Routing Table에서 참조
  • Global↔VRF20(SW1↔SW5) 간 통신 확인

 

7) ③ VRF20→VRF10 Leaking with Static