Configuring a User-defined VRF


The VRF configuration process is in the following steps:

  1. Enable IP routing function before using VRF function.
  2. Create a VRF for the tenant.
  3. Bind one or more L3 interfaces (VLAN interfaces, loopback interfaces, routed interfaces or sub-interfaces) to the VRF.
  4. Configure static routes or OSPF routing protocol into the VRF table.

Procedure

Step1         Enable IP routing function before using VRF function.

                   set ip routing enable <true | false>

Step2         Create a VRF for the tenant.

                   set ip vrf <vrf-name> [description <string>]

Step3        Bind one or more L3 interfaces to the VRF.

  • Bind one or more VLAN interfaces to the VRF. 

    a)      Configure VLAN ID.

    set vlans vlan-id <vlan-id>

    b)     Configure the interface to a VLAN.

    set interface gigabit-ethernet <port> family ethernet-switching native-vlan-id <vlan-id>

    c)      Configure the IP address of the Layer 3 interface.

    set l3-interface vlan-interface <interface-name> address <address> prefix-length <number>

    d)     Associate a Layer 3 interface with a VLAN.

    set vlans vlan-id <vlan-id> l3-interface <interface-name>

                    e)     Bind the Layer 3 VLAN interface to a VRF.

                   set l3-interface vlan-interface <interface-name> vrf <vrf-name>

  • Bind one or more routed interfaces/sub-interfaces to the VRF. 

     a)      Enable routed interface.

    set interface gigabit-ethernet <interface-name> routed-interface enable <true | false>

    set interface gigabit-ethernet <interface-name> routed-interface name <string>

    b)     Configure reserved-vlan for the routed interface.   

    set vlans reserved-vlan <reserved-vlan>

    c)      (Optional) Create the sub-interface and add it into a VLAN.

    set interface aggregate-ethernet <interface-name> routed-interface sub-interface <sub-interface-name> vlan-id <vlan-id>

    d)      Configure the IP address of the routed interface.

    set l3-interface routed-interface <interface-name> address <ip-address> prefix-length <prefix-number>

    e)     Bind the routed interface to a VRF.

                   set l3-interface routed-interface <interface-name> vrf <vrf-name>

  • Bind one or more loopback interfaces to the VRF. 

    a)      Create a loopback interface and configures its IP address.

    set l3-interface loopback <loopback-name> address <ip-address> prefix-length <int>

    b)     Bind the loopback interface to a VRF.              

                   set l3-interface loopback <interface-name> vrf <vrf-name>

Step4         (Optional) Configure a static route entry into the VRF.

   set protocols static [vrf <vrf-name>] route <ip-address> next-hop <nexthop-address>

Step5         (Optional) Configure static ARP entries.

                   set protocols arp interface <interface-name> address <ip-address> mac-address <mac-address>

                   The ARP entries are associated with the VRF by binding the Layer 3 VLAN interface to the VRF.




Copyright © 2024 Pica8 Inc. All Rights Reserved.