No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

CLI-based Configuration Guide - VPN

AR100, AR120, AR150, AR160, AR200, AR1200, AR2200, AR3200, and AR3600 V200R010

This document describes VPN features on the device and provides configuration procedures and configuration examples.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Example for Configuring an MCE IPv6 Device

Example for Configuring an MCE IPv6 Device

Networking Requirements

The headquarters and branch of a company need to communicate through MPLS VPN, and two IPv6 services of the company must be isolated. To reduce hardware costs, the company wants the branch to connect to the PE device through one CE device with high capability.

As shown in Figure 8-3, the networking requirements are as follows:

  • CE1 and CE2 connect to the headquarters. CE1 belongs to vpna, and CE2 belongs to vpnb.
  • The MCE device connects to vpna and vpnb of the branch through CE3 and CE4.
This implements communication within the same VPN and service isolation between different VPNs.
NOTE:

CE1, CE2, CE3 and CE4 are huawei Ethernet Switches S5700.

PE1 and PE2 are huawei Ethernet Switches S9700.

Figure 8-3  MCE IPv6 networking

Configuration Roadmap

The configuration roadmap is as follows:

  1. Configure OSPF between PE devices to implement interworking between them and configure MP-IBGP to exchange VPN routing information.
  2. Enable basic MPLS capabilities and MPLS LDP on the PE devices to set up LDP LSPs.
  3. Create VPN instances vpna and vpnb on the MCE and PE devices to isolate services.
  4. Set up EBGP peer relationships between PE1 and local CE devices to exchange VPN routes.
  5. Configure routing between MCE and sites and between MCE and PE2 to exchange VPN routes.

Procedure

  1. Configure OSPF on PE1 and PE2 to implement interworking between them.

    # Configure PE1. The configuration on PE2 is similar to the configuration on PE1 and is not mentioned here.

    <Huawei> system-view
    [Huawei] sysname PE1
    [PE1] ospf
    [PE1-ospf-1] area 0
    [PE1-ospf-1-area-0.0.0.0] network 1.1.1.9 0.0.0.0
    [PE1-ospf-1-area-0.0.0.0] network 172.1.1.0 0.0.0.255
    [PE1-ospf-1-area-0.0.0.0] quit
    [PE1-ospf-1] quit
    

    Take the display on PE2 as an example:

    [PE2] display ip routing-table
    Route Flags:
    R - relay, D - download to fib
    ------------------------------------------------------------------------------
    Routing Tables: Public
             Destinations : 9        Routes : 9
    
      Destination/Mask  Proto  Pre  Cost       Flags  NextHop         Interface
    
            1.1.1.9/32  OSPF   10   2              D  172.1.1.1        Vlanif30
            2.2.2.9/32  Direct 0    0              D  127.0.0.1        LoopBack1
          127.0.0.0/8   Direct 0    0              D  127.0.0.1        InLoopBack0
          127.0.0.1/32  Direct 0    0              D  127.0.0.1        InLoopBack0
    127.255.255.255/32  Direct 0    0              D  127.0.0.1        InLoopBack0 
          172.1.1.0/24  Direct 0    0              D  172.1.1.2        Vlanif30
          172.1.1.2/32  Direct 0    0              D  172.1.1.1        Vlanif30
        172.1.1.255/32  Direct 0    0              D  127.0.0.1        Vlanif30
    255.255.255.255/32  Direct 0    0              D  127.0.0.1        InLoopBack0 

  2. Enable basic MPLS capabilities and MPLS LDP on the PE devices to set up LDP LSPs between them.

    # Configure PE1. The configuration on PE2 is similar to the configuration on PE1 and is not mentioned here.
    [PE1] mpls lsr-id 1.1.1.9
    [PE1] mpls
    [PE1-mpls] quit
    [PE1] mpls ldp
    [PE1-mpls-ldp] quit
    [PE1] interface vlanif 30
    [PE1-Vlanif30] mpls
    [PE1-Vlanif30] mpls ldp
    [PE1-Vlanif30] quit

    After the configuration is complete, run the display mpls ldp session command on the PE devices. You can see that the MPLS LDP session between the PE devices is in Operational state.

    Take the display on PE2 as an example:

    [PE2] display mpls ldp session
    
     LDP Session(s) in Public Network
     Codes: LAM(Label Advertisement Mode), SsnAge Unit(DDDD:HH:MM)
     A '*' before a session means the session is being deleted.
    ------------------------------------------------------------------------------
    Peer-ID            Status      LAM  SsnRole  SsnAge      KA-Sent/Rcv
    ------------------------------------------------------------------------------ 
    1.1.1.9:0          Operational DU   Active   0000:00:04  17/17
    ------------------------------------------------------------------------------
     TOTAL: 1 session(s) Found.
    

  3. Enable IPv6. Configure VPN instances on the PE devices. On PE1, bind the VPN instances to the interfaces connected to CE1 and CE2 respectively. On PE2, bind the VPN instances to the interfaces connected to the MCE device.

    # Configure PE1.

    [PE1] ipv6
    [PE1] vlan batch 10 20
    [PE1] interface gigabitethernet 1/0/0
    [PE1-GigabitEthernet1/0/0] port hybrid pvid vlan 10
    [PE1-GigabitEthernet1/0/0] port hybrid untagged vlan 10
    [PE1-GigabitEthernet1/0/0] quit
    [PE1] interface gigabitethernet 2/0/0
    [PE1-GigabitEthernet2/0/0] port hybrid pvid vlan 20
    [PE1-GigabitEthernet2/0/0] port hybrid untagged vlan 20
    [PE1-GigabitEthernet2/0/0] quit
    [PE1] ip vpn-instance vpna
    [PE1-vpn-instance-vpna] ipv6-family
    [PE1-vpn-instance-vpna-af-ipv6] route-distinguisher 100:1
    [PE1-vpn-instance-vpna-af-ipv6] vpn-target 111:1 both
    [PE1-vpn-instance-vpna-af-ipv6] quit
    [PE1-vpn-instance-vpna] quit
    [PE1] ip vpn-instance vpnb
    [PE1-vpn-instance-vpnb] ipv6-family
    [PE1-vpn-instance-vpnb-af-ipv6] route-distinguisher 100:2
    [PE1-vpn-instance-vpnb-af-ipv6] vpn-target 222:2 both
    [PE1-vpn-instance-vpnb-af-ipv6] quit
    [PE1-vpn-instance-vpnb] quit
    [PE1] interface vlanif 10
    [PE1-Vlanif10] ip binding vpn-instance vpna
    [PE1-Vlanif10] ipv6 enable
    [PE1-Vlanif10] ipv6 address 2001::1 64
    [PE1-Vlanif10] quit
    [PE1] interface vlanif 20
    [PE1-Vlanif20] ip binding vpn-instance vpnb
    [PE1-Vlanif20] ipv6 enable
    [PE1-Vlanif20] ipv6 address 2002::1 64
    [PE1-Vlanif20] quit

    # Configure PE2.

    [PE2] ipv6
    [PE2] vlan batch 100 200
    [PE2] interface gigabitethernet 2/0/0
    [PE2-GigabitEthernet2/0/0] port link-type trunk
    [PE2-GigabitEthernet2/0/0] port trunk allow-pass vlan 100 200
    [PE2-GigabitEthernet2/0/0] quit
    [PE2] ip vpn-instance vpna
    [PE2-vpn-instance-vpna] ipv6-family
    [PE2-vpn-instance-vpna-af-ipv6] route-distinguisher 200:1
    [PE2-vpn-instance-vpna-af-ipv6] vpn-target 111:1 both
    [PE2-vpn-instance-vpna-af-ipv6] quit
    [PE2-vpn-instance-vpna] quit
    [PE2] ip vpn-instance vpnb
    [PE2-vpn-instance-vpnb] ipv6-family
    [PE2-vpn-instance-vpnb-af-ipv6] route-distinguisher 200:2
    [PE2-vpn-instance-vpnb-af-ipv6] vpn-target 222:2 both
    [PE2-vpn-instance-vpnb-af-ipv6] quit
    [PE2-vpn-instance-vpnb] quit
    [PE2] interface vlanif 60
    [PE2-Vlanif60] ip binding vpn-instance vpna
    [PE2-Vlanif60] ipv6 enable
    [PE2-Vlanif60] ipv6 address 2007::1 64
    [PE2-Vlanif60] quit
    [PE2] interface vlanif 70
    [PE2-Vlnaif70] ip binding vpn-instance vpnb
    [PE2-Vlnaif70] ipv6 enable
    [PE2-Vlnaif70] ipv6 address 2008::1 64
    [PE2-Vlnaif70] quit

  4. Enable IPv6 and configure VPN instances on the MCE device. Bind the vpn instances to the interfaces connected to CE3 and CE4 respectively.

    <Huawei> system-view
    [Huawei] sysname MCE
    [MCE] ipv6
    [MCE] ip vpn-instance vpna
    [MCE-vpn-instance-vpna] ipv6-family
    [MCE-vpn-instance-vpna-af-ipv6] route-distinguisher 100:1
    [MCE-vpn-instance-vpna-af-ipv6] quit
    [MCE-vpn-instance-vpna] quit
    [MCE] ip vpn-instance vpnb
    [MCE-vpn-instance-vpnb] ipv6-family
    [MCE-vpn-instance-vpnb-af-ipv6] route-distinguisher 200:2
    [MCE-vpn-instance-vpnb-af-ipv6] quit
    [MCE-vpn-instance-vpnb] quit
    [MCE] interface gigabitethernet 1/0/0.1
    [MCE-GigabitEthernet1/0/0.1] ip binding vpn-instance vpna
    [MCE-GigabitEthernet1/0/0.1] dot1q termination vid 100
    [MCE-GigabitEthernet1/0/0.1] ipv6 enable
    [MCE-GigabitEthernet1/0/0.1] ipv6 address 2007::2 64
    [MCE-GigabitEthernet1/0/0.1] ipv6 nd ns multicast-enable
    [MCE-GigabitEthernet1/0/0.1] quit
    [MCE] interface gigabitethernet 1/0/0.2
    [MCE-GigabitEthernet1/0/0.2] ip binding vpn-instance vpnb
    [MCE-GigabitEthernet1/0/0.2] dot1q termination vid 200
    [MCE-GigabitEthernet1/0/0.2] ipv6 enable
    [MCE-GigabitEthernet1/0/0.2] ipv6 address 2008::2 64
    [MCE-GigabitEthernet1/0/0.2] ipv6 nd ns multicast-enable
    [MCE-GigabitEthernet1/0/0.2] quit
    [MCE] interface gigabitethernet 3/0/0
    [MCE-GigabitEthernet3/0/0] ip binding vpn-instance vpna
    [MCE-GigabitEthernet3/0/0] ipv6 enable
    [MCE-GigabitEthernet3/0/0] ipv6 address FC03::2 64
    [MCE-GigabitEthernet3/0/0] quit
    [MCE] interface gigabitethernet 4/0/0
    [MCE-GigabitEthernet4/0/0] ip binding vpn-instance vpnb
    [MCE-GigabitEthernet4/0/0] ipv6 enable
    [MCE-GigabitEthernet4/0/0] ipv6 address FC04::1 64
    [MCE-GigabitEthernet4/0/0] quit

  5. Set up an MP-IBGP peer relationship between PE1 and PE2. Set up an EBGP peer relationship between PE1 and CE1, and between PE1 and CE2.

    # Configure PE1 to set up an MP-IBGP peer relationship between PE1 and PE2.

    [PE1] bgp 100
    [PE1-bgp] peer 2.2.2.9 as-number 100
    [PE1-bgp] peer 2.2.2.9 connect-interface loopback 1
    [PE1-bgp] ipv6-family vpnv6
    [PE1-bgp-af-vpnv6] peer 2.2.2.9 enable
    [PE1-bgp-af-vpnv6] quit

    The configuration of PE2 is the same as the configuration of PE1.

    # Configure PE1 to set up an EBGP peer relationship between PE1 and CE1, and between PE1 and CE2.

    [PE1] bgp 100
    [PE1-bgp] ipv6-family vpn-instance vpna
    [PE1-bgp6-vpna] peer 2001::2 as-number 65410
    [PE1-bgp6-vpna] quit
    [PE1-bgp] ipv6-family vpn-instance vpnb
    [PE1-bgp6-vpnb] peer 2002::2 as-number 65420
    [PE1-bgp6-vpnb] quit
    [PE1-bgp] quit

    # Configure CE1.

    [CE1] bgp 65410
    [CE1-bgp] peer 2001::1 as-number 100
    [CE1-bgp] ipv6-family unicast
    [CE1-bgp-af-ipv6] peer 2001::1 enable
    [CE1-bgp-af-ipv6] import-route direct
    [CE1-bgp-af-ipv6] quit
    [CE1-bgp] quit

    The configuration of CE2 is the same as the configuration of CE1.

    After the configuration is complete, run the display bgp vpnv6 all peer command on PE1. The command output shows that the PE1 has set up an IBGP peer relationship with PE2 and EBGP peer relationships with CE1 and CE2. All the peer relationships are in Established state.

    [PE1] display bgp vpnv6 all peer
    
     BGP local router ID : 1.1.1.9
     Local AS number : 100
     Total number of peers : 1                 Peers in established state : 1
    
      Peer            V    AS  MsgRcvd  MsgSent  OutQ  Up/Down       State PrefRcv
    
      2.2.2.9         4   100      288      287     0 01:19:16 Established       6
    
      Peer of vpn instance :
      vpn instance vpna :
      2001::2       4 65410        9       11       0 00:04:14 Established       2
      vpn instance vpnb :
      2002::2       4 65420        9       12       0 00:04:09 Established       2
    

  6. Configure routing between the MCE device and VPN sites.

    The MCE device directly connects to vpna, and no routing protocol is used in vpna. Configure IPv6 static routes to implement communication between the MCE device and vpna.
    • # Configure CE3.

      Assign IPv6 address FC05::1/64 to the interface connected to vpna.

      <Huawei> system-view
      [Huawei] sysname CE3
      [CE3] ipv6
      [CE3] vlan batch 60 80
      [CE3] interface gigabitethernet 1/0/0
      [CE3-GigabitEthernet1/0/0] port link-type trunk
      [CE3-GigabitEthernet1/0/0] port trunk allow-pass vlan 60
      [CE3-GigabitEthernet1/0/0] port trunk pvid vlan 60
      [CE3-GigabitEthernet1/0/0] quit
      [CE3]interface vlanif 60
      [CE3-Vlanif60]ipv6 enable
      [CE3-Vlanif60]ipv6 address FC03::3 64
      [CE3-Vlanif60] quit
      [CE3] interface gigabitethernet 2/0/0
      [CE3-GigabitEthernet2/0/0] port link-type trunk
      [CE3-GigabitEthernet2/0/0] port trunk allow-pass vlan 80
      [CE3-GigabitEthernet2/0/0] quit
      [CE3]interface vlanif 80
      [CE3-Vlanif80]ipv6 enable
      [CE3-Vlanif80]ipv6 address FC05::1 64
      [CE3-Vlanif80] quit
      [CE3]ipv6 route-static 0::0 0 FC03::2
    • # Configure the MCE device.

      [MCE] ipv6 route-static vpn-instance vpna FC05:: 64 FC03::3
    • # Check the IPv6 routes of vpna on the MCE device.
      [MCE]display ipv6 routing-table vpn-instance vpna
      Routing Table : vpna                                                            
              Destinations : 6        Routes : 6                                      
                                                                                      
       Destination  : FC03::                          PrefixLength : 64               
       NextHop      : FC03::2                         Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet3/0/0            Flags        : D                
                                                                                      
       Destination  : FC03::2                         PrefixLength : 128              
       NextHop      : ::1                             Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet3/0/0            Flags        : D                
                                                                                      
       Destination  : FC05::                          PrefixLength : 64               
       NextHop      : FC03::3                         Preference   : 60               
       Cost         : 0                               Protocol     : Static           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet3/0/0            Flags        : RD               
                                                                                      
       Destination  : 2007::                          PrefixLength : 64               
       NextHop      : 2007::2                         Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet1/0/0.1          Flags        : D                
                                                                                      
       Destination  : 2007::2                         PrefixLength : 128              
       NextHop      : ::1                             Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet1/0/0.1          Flags        : D                
                                                                                      
       Destination  : FE80::                          PrefixLength : 10               
       NextHop      : ::                              Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : NULL0                           Flags        : D                
                                                                                      
      The preceding information shows that the MCE device has a static route to vpna.

    The RIPng protocol runs in vpnb. Configure RIPng process 200 on the MCE device and bind it to vpnb so that routes learned by RIPng are added to the IPv6 routing table of vpnb.

    • # Configure the MCE device.
      [MCE] ripng 200 vpn-instance vpnb
      [MCE-ripng-200] import-route ospfv3 200
      [MCE-ripng-200] quit
      [MCE] interface gigabitethernet 4/0/0
      [MCE-GigabitEthernet4/0/0] ripng 200 enable
      [MCE-GigabitEthernet4/0/0] quit
    • # Configure CE4.

      Assign IP address FC06::1/64 to the interface connected to vpnb.

      <Huawei> system-view
      [Huawei] sysname CE4
      [CE4] ipv6
      [CE4] vlan batch 70 80
      [CE4] interface gigabitethernet 1/0/0
      [CE4-GigabitEthernet1/0/0] port link-type trunk
      [CE4-GigabitEthernet1/0/0] port trunk allow-pass vlan 70
      [CE4-GigabitEthernet1/0/0] port trunk pvid vlan 70
      [CE4-GigabitEthernet1/0/0] quit
      [CE4] interface vlanif 70
      [CE4-Vlanif70] ipv6 enable
      [CE4-Vlanif70] ipv6 address FC04::3 64
      [CE4-Vlanif70] quit
      [CE4] interface gigabitethernet 2/0/0
      [CE4-GigabitEthernet2/0/0] port link-type trunk
      [CE4-GigabitEthernet2/0/0] port trunk allow-pass vlan 80
      [CE4-GigabitEthernet2/0/0] quit
      [CE4] interface vlanif 80
      [CE4-Vlanif80] ipv6 enable
      [CE4-Vlanif80] ipv6 address FC06::1 64
      [CE4-Vlanif80] quit
      [CE4] ripng 200
      [CE4-ripng-200] quit
      [CE4] interface vlanif 70
      [CE4-Vlanif70] ripng 200 enable
      [CE4-Vlanif70] quit
      [CE4] interface vlanif 80
      [CE4-Vlanif80] ripng 200 enable
      [CE4-Vlanif80] quit
    • # Check the routes of vpnb on the MCE device.
      [MCE] display ipv6 routing-table vpn-instance vpnb                     
      Routing Table : vpnb                                                            
              Destinations : 6        Routes : 6                                      
                                                                                      
       Destination  : FC04::                          PrefixLength : 64               
       NextHop      : FC04::2                         Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet4/0/0            Flags        : D                
                                                                                      
       Destination  : FC04::2                         PrefixLength : 128              
       NextHop      : ::1                             Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet4/0/0            Flags        : D                
                                                                                      
       Destination  : FC06::                          PrefixLength : 64               
       NextHop      : FE80::5689:98FF:FE28:8442       Preference   : 100              
       Cost         : 0                               Protocol     : RIPng            
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet4/0/0            Flags        : D                
                                                                                      
       Destination  : 2008::                          PrefixLength : 64               
       NextHop      : 2008::2                         Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet1/0/0.2          Flags        : D                
                                                                                      
       Destination  : 2008::2                         PrefixLength : 128              
       NextHop      : ::1                             Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : GigabitEthernet1/0/0.2          Flags        : D                
                                                                                      
       Destination  : FE80::                          PrefixLength : 10               
       NextHop      : ::                              Preference   : 0                
       Cost         : 0                               Protocol     : Direct           
       RelayNextHop : ::                              TunnelID     : 0x0              
       Interface    : NULL0                           Flags        : D                
                                                                                      
      The preceding information shows that the MCE device has learned the route to vpnb through RIPng. The route to vpnb and the route to vpna (FC05::/64) are maintained in different VPN routing tables so that users in the two VPNs are isolated from each other.

  7. Configure OSPFv3 multi-instance between the MCE device and PE2.

    # Configure PE2.
    NOTE:
    To configure OSPFv3 multi-instance between the MCE device and PE2, complete the following tasks on PE2:
    • In the OSPFv3 view, import BGP routes and advertise VPN routes of PE1 to the MCE device.
    • In the BGP view, import routes of the OSPFv3 processes and advertise the VPN routes of the MCE device to PE1.
    [PE2] ospfv3 100 vpn-instance vpna
    [PE2-ospfv3-100] import-route bgp
    [PE2-ospf-100] quit
    [PE2] ospfv3 200 vpn-instance vpnb
    [PE2-ospfv3-200] import-route bgp
    [PE2-ospf-200] quit
    [PE2] bgp 100
    [PE2-bgp] ipv6-family vpn-instance vpna
    [PE2-bgp-vpna] import-route ospfv3 100
    [PE2-bgp-vpna] quit
    [PE2-bgp] ipv6-family vpn-instance vpnb
    [PE2-bgp-vpnb] import-route ospfv3 200
    [PE2-bgp-vpnb] quit
    [PE2] interface vlanif 100
    [PE2-Vlanif100] ospfv3 100 area 0
    [PE2-Vlanif100] quit
    [PE2] interface vlanif 200
    [PE2-Vlnaif200] ospfv3 200 area 0
    [PE2-Vlnaif200] quit
    # Configure the MCE device.
    NOTE:

    Import VPN routes to the OSPFv3 processes.

    [MCE] ospfv3 100 vpn-instance vpna
    [MCE-ospfv3-100] router-id 1.1.1.1
    [MCE-ospfv3-100] import-route static
    [MCE-ospfv3-100] vpn-instance-capability simple
    [MCE-ospfv3-100] quit
    [MCE] ospfv3 200 vpn-instance vpnb
    [MCE-ospfv3-200] router-id 2.2.2.2
    [MCE-ospfv3-200] import-route ripng 200
    [MCE-ospfv3-200] vpn-instance-capability simple
    [MCE-ospfv3-200] quit
    [MCE] interface gigabitethernet 1/0/0.1
    [MCE-GigabitEthernet1/0/0.1] ospfv3 100 area 0
    [MCE-GigabitEthernet1/0/0.1] quit
    [MCE] interface gigabitethernet 1/0/0.2
    [MCE-GigabitEthernet1/0/0.2] ospfv3 200 area 0
    [MCE-GigabitEthernet1/0/0.2] quit

  8. Verify the configuration.

    # After the configuration is complete, run the display ipv6 routing-table vpn-instance command on the MCE device to view the routes to the remote CE devices.

    # Take the routing table of vpna as an example:

    [MCE] display ipv6 routing-table vpn-instance vpna
    Routing Table : vpna                                                            
            Destinations : 7        Routes : 7                                      
                                                                                    
     Destination  : 2001::                          PrefixLength : 64               
     NextHop      : FE80::5689:98FF:FE28:8472       Preference   : 150              
     Cost         : 0                               Protocol     : OSPFv3ASE         
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : GigabitEthernet1/0/0.1          Flags        : D                
                                                                                    
     Destination  : FC03::                          PrefixLength : 64               
     NextHop      : FC03::2                         Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : GigabitEthernet3/0/0            Flags        : D                
                                                                                    
     Destination  : FC03::2                         PrefixLength : 128              
     NextHop      : ::1                             Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : GigabitEthernet3/0/0            Flags        : D                
                                                                                    
     Destination  : FC05::                          PrefixLength : 64               
     NextHop      : FC03::3                         Preference   : 60               
     Cost         : 0                               Protocol     : Static           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : GigabitEthernet3/0/0            Flags        : RD               
                                                                                    
     Destination  : 2007::                          PrefixLength : 64               
     NextHop      : 2007::2                         Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : GigabitEthernet1/0/0.1          Flags        : D                
                                                                                    
     Destination  : 2007::2                         PrefixLength : 128              
     NextHop      : ::1                             Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : GigabitEthernet1/0/0.1          Flags        : D                
                                                                                    
     Destination  : FE80::                          PrefixLength : 10               
     NextHop      : ::                              Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : NULL0                           Flags        : D                
                                                                                    

    # Run the display ipv6 routing-table vpn-instance command on the PE devices to view the routes to the remote CE devices.

    # Take the VPN routing table of vpna on PE as an example:

    [PE1] display ipv6 routing-table vpn-instance vpna
    Routing Table : vpna                                                            
            Destinations : 6        Routes : 6                                      
                                                                                    
     Destination  : 2001::                          PrefixLength : 64               
     NextHop      : 2001::1                         Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : Vlanif30                        Flags        : D                
                                                                                    
     Destination  : 2001::1                         PrefixLength : 128              
     NextHop      : ::1                             Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : Vlanif30                        Flags        : D                
                                                                                    
     Destination  : FC03::                          PrefixLength : 64               
     NextHop      : ::FFFF:2.2.2.9                  Preference   : 255              
     Cost         : 0                               Protocol     : BGP              
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : Vlanif30                        Flags        : RD               
                                                                                    
     Destination  : FC05::                          PrefixLength : 64               
     NextHop      : ::FFFF:2.2.2.9                  Preference   : 255              
     Cost         : 0                               Protocol     : BGP              
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : Vlanif30                        Flags        : RD               
                                                                                    
     Destination  : 2007::                          PrefixLength : 64               
     NextHop      : ::FFFF:2.2.2.9                  Preference   : 255              
     Cost         : 0                               Protocol     : BGP              
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : Vlanif30                        Flags        : RD               
                                                                                    
     Destination  : FE80::                          PrefixLength : 10               
     NextHop      : ::                              Preference   : 0                
     Cost         : 0                               Protocol     : Direct           
     RelayNextHop : ::                              TunnelID     : 0x0              
     Interface    : NULL0                           Flags        : D                
                                                                                    
    

    # CE1 and CE3 can communicate with each other. CE2 and CE4 can communicate with each other.

    # CE1 cannot ping CE2 or CE4. CE3 cannot ping CE2 or CE4.

Configuration Files

  • CE1 configuration file

    #
     sysname CE1
    #
     vlan batch 10
    #
    ipv6
    #
    interface Vlanif10
     ipv6 enable
     ipv6 address 2001::2/64
    #
    interface GigabitEthernet1/0/0
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    bgp 65410
     peer 2001::1 as-number 100
     #
     ipv6-family unicast
      undo synchronization
      import-route direct
      peer 2001::1 enable
    #
    return
  • CE2 configuration file

    #
     sysname CE2
    #
    ipv6
    #
     vlan batch 20
    #
    interface Vlanif20
     ipv6 enable
     ipv6 address 2002::2/64
    #
    interface GigabitEthernet1/0/0
     port hybrid pvid vlan 20
     port hybrid untagged vlan 20
    #
    bgp 65420
     peer 2002::1 as-number 100
     #
     ipv6-family unicast
      undo synchronization
      import-route direct
      peer 2002::1 enable
    #
    return
  • PE1 configuration file

    #
     sysname PE1
    #
    ipv6
    #
     vlan batch 10 20 30
    #
    ip vpn-instance vpna
     ipv6-family
      route-distinguisher 100:1
      vpn-target 111:1 export-extcommunity
      vpn-target 111:1 import-extcommunity
    #
    ip vpn-instance vpnb
     ipv6-family
      route-distinguisher 100:2
      vpn-target 222:2 export-extcommunity
      vpn-target 222:2 import-extcommunity
    #
    mpls lsr-id 1.1.1.9
    mpls
    #
    mpls ldp
    #
    interface Vlanif10
     ip binding vpn-instance vpna
     ipv6 enable
     ipv6 address 2001::1/64
    #
    interface Vlanif20
     ip binding vpn-instance vpnb
     ipv6 enable
     ipv6 address 2002::1/64
    #
    interface Vlanif30
     ip address 172.1.1.1 255.255.255.0
     mpls
     mpls ldp
    #
    interface GigabitEthernet1/0/0
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet2/0/0
     port hybrid pvid vlan 20
     port hybrid untagged vlan 20
    #
    interface GigabitEthernet3/0/0
     port hybrid pvid vlan 30
     port hybrid untagged vlan 30
    #
    
    interface LoopBack1
     ip address 1.1.1.9 255.255.255.255
    #
    bgp 100
     peer 2.2.2.9 as-number 100
     peer 2.2.2.9 connect-interface LoopBack1
     #
     ipv4-family unicast
      undo synchronization
      peer 2.2.2.9 enable
     #
     ipv6-family vpnv6
      policy vpn-target
      peer 2.2.2.9 enable
     #
     ipv6-family vpn-instance vpna
      peer 2001::2 as-number 65410
      import-route direct
    #
     ipv6-family vpn-instance vpnb
      peer 2002::2 as-number 65420
      import-route direct
    #
    ospf 1
     area 0.0.0.0
      network 1.1.1.9 0.0.0.0
      network 172.1.1.0 0.0.0.255
    #
    return
  • PE2 configuration file

    #
     sysname PE2
    #
    ipv6
    #
     vlan batch 30 100 200
    #
    ip vpn-instance vpna
     ipv6-family
      route-distinguisher 200:1
      vpn-target 111:1 export-extcommunity
      vpn-target 111:1 import-extcommunity
    #
    ip vpn-instance vpnb
     ipv6-family 
      route-distinguisher 200:2
      vpn-target 222:2 export-extcommunity
      vpn-target 222:2 import-extcommunity
    #
    mpls lsr-id 2.2.2.9
    mpls
    #
    mpls ldp
    #
    ospfv3 100 vpn-instance vpna
     router-id 3.3.3.3
     import-route bgp
    #
    ospfv3 200 vpn-instance vpnb
     router-id 4.4.4.4
     import-route bgp
    #
    interface vlanif30
     ip address 172.1.1.2 255.255.255.0
     mpls
     mpls ldp
    #
    interface Vlanif100
     ip binding vpn-instance vpna
     ipv6 enable
     ipv6 address 2007::1/64
     ospfv3 100 area 0.0.0.0
    #
    interface Vlanif200
     ip binding vpn-instance vpnb
     ipv6 enable
     ipv6 address 2008::1/64
     ospfv3 200 area 0.0.0.0
    #
    interface LoopBack1
     ip address 2.2.2.9 255.255.255.255
    #
    interface GigabitEthernet1/0/0
     port hybrid pvid vlan 30
     port hybrid untagged vlan 30
    #
    interface GigabitEthernet2/0/0
     port link-type trunk
     port trunk allow-pass vlan 100 200
    #
    bgp 100
     peer 1.1.1.9 as-number 100
     peer 1.1.1.9 connect-interface LoopBack1
     #
     ipv4-family unicast
      undo synchronization
      peer 1.1.1.9 enable
     #
     ipv6-family vpnv6
      policy vpn-target
      peer 1.1.1.9 enable
     #
     ipv6-family vpn-instance vpna
      import-route ospfv3 100
     #
     ipv6-family vpn-instance vpnb
      import-route ospfv3 200
    #
    ospf 1
     area 0.0.0.0
      network 2.2.2.9 0.0.0.0
      network 172.1.1.0 0.0.0.255
    #
    return
  • MCE configuration file

    #
     sysname MCE
    #
    ipv6
    #
    ip vpn-instance vpna
     ipv6-family
      route-distinguisher 100:1
    #
    ip vpn-instance vpnb
     ipv6-family
      route-distinguisher 200:2
    #
    ospfv3 100 vpn-instance vpna
     router-id 1.1.1.1
     import-route static
     vpn-instance-capability simple
    #
    ospfv3 200 vpn-instance vpnb
     router-id 2.2.2.2
     import-route ripng 200
     vpn-instance-capability simple
    #
    ripng 200 vpn-instance vpnb
     import-route ospfv3 200
    #
    interface GigabitEthernet1/0/0.1
     dot1q termination vid 100
     ip binding vpn-instance vpna
     ipv6 enable
     ipv6 address 2007::2/64
     ipv6 nd ns multicast-enable
     ospfv3 100 area 0.0.0.0
    #
    interface GigabitEthernet1/0/0.2
     dot1q termination vid 200
     ip binding vpn-instance vpnb
     ipv6 enable
     ipv6 address 2008::2/64
     ipv6 nd ns multicast-enable
     ospfv3 200 area 0.0.0.0
    #
    interface GigabitEthernet3/0/0
     ip binding vpn-instance vpna
     ipv6 enable
     ipv6 address FC03::2/64
    #
    interface GigabitEthernet4/0/0
     ip binding vpn-instance vpnb
     ipv6 enable
     ipv6 address FC04::1/64
     ripng 200 enable
    #
    ipv6 route-static vpn-instance vpna FC05:: 64 FC03::3
    #
    return
  • CE3 configuration file

    #
     sysname CE3
    #
    ipv6
    #
     vlan batch 60 80
    #
    interface vlanif60
     ipv6 enable
     ipv6 address FC03::3/64
    #
    interface vlanif80
     ipv6 enable
     ipv6 address FC05::1/64
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 60
     port trunk pvid vlan 60
    #
    interface GigabitEthernet2/0/0
     port link-type trunk
     port trunk allow-pass vlan 80
    #
    ipv6 route-static :: 0 FC03::2
    #
    return
  • CE4 configuration file

    #
     sysname CE4
    #
    ipv6
    #
     vlan batch 70 80
    #
    ripng 200
    #
    interface vlanif70
     ipv6 enable
     ipv6 address FC04::2/64
     ripng 200 enable
    #
    interface vlanif80
     ipv6 enable
     ipv6 address FC06::1/64
     ripng 200 enable
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 70
     port trunk pvid vlan 70
    #
    interface GigabitEthernet2/0/0
     port link-type trunk
     port trunk allow-pass vlan 80
    #
    return
Translation
Download
Updated: 2019-08-07

Document ID: EDOC1100033725

Views: 153469

Downloads: 372

Average rating:
This Document Applies to these Products
Related Version
Related Documents
Share
Previous Next