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

Configuration Guide - VPN

S7700 and S9700 V200R013C00

This document describes the configurations of VPN, including GRE, IPSec, BGP/MPLS IP VPN, BGP/MPLS IPv6 VPN, VLL, PWE3, VPLS, L2VPN Access to L3VPN.
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 a GRE Tunnel to Implement Interworking Between IPv6 Networks

Example for Configuring a GRE Tunnel to Implement Interworking Between IPv6 Networks

Networking Requirements

As shown in Figure 1-16, SwitchA and SwitchC on IPv6 networks connect to SwitchB on an IPv4 public network. PC1 and PC2 on the two IPv6 networks need to communicate with each other.

PC1 uses SwitchA and PC2 uses SwitchC as a default gateway.

Figure 1-16  Configuring a GRE tunnel to implement interworking between IPv6 networks

Configuration Roadmap

To allow PC1 and PC2 on IPv6 networks to communicate with each other across an IPv4 network, you can configure a direct link between SwitchA and SwitchC to set up a GRE tunnel and configure a static route to forward packets through tunnel interfaces to the peer.

The configuration roadmap is as follows:

  1. Configure IP addresses for physical interfaces and configure an IPv4 static route to implement interworking over the IPv4 network.

  2. Create tunnel interfaces on SwitchA and SwitchC to set up a GRE tunnel, and configure an IPv6 static route passing through tunnel interfaces on SwitchA and SwitchC, so that traffic between PC1 and PC2 can be transmitted over the GRE tunnel.

Procedure

  1. Configure an IP address for each physical interface.

    # Configure SwitchA.

    <HUAWEI> system-view
    [HUAWEI] sysname SwitchA
    [SwitchA] vlan batch 10 30
    [SwitchA] interface gigabitethernet 1/0/0
    [SwitchA-GigabitEthernet1/0/0] port link-type trunk
    [SwitchA-GigabitEthernet1/0/0] port trunk allow-pass vlan 10
    [SwitchA-GigabitEthernet1/0/0] quit
    [SwitchA] interface gigabitethernet 2/0/0
    [SwitchA-GigabitEthernet2/0/0] port link-type access
    [SwitchA-GigabitEthernet2/0/0] port default vlan 30
    [SwitchA-GigabitEthernet2/0/0] quit
    [SwitchA] interface vlanif 10
    [SwitchA-Vlanif10] ip address 20.1.1.1 24
    [SwitchA-Vlanif10] quit
    [SwitchA] ipv6
    [SwitchA] interface vlanif 30
    [SwitchA-Vlanif30] ipv6 enable
    [SwitchA-Vlanif30] ipv6 address fc00:1::1 64
    [SwitchA-Vlanif30] quit
    

    # Configure SwitchB.

    <HUAWEI> system-view
    [HUAWEI] sysname SwitchB
    [SwitchB] vlan batch 10 20
    [SwitchB] interface gigabitethernet 1/0/0
    [SwitchB-GigabitEthernet1/0/0] port link-type trunk
    [SwitchB-GigabitEthernet1/0/0] port trunk allow-pass vlan 10
    [SwitchB-GigabitEthernet1/0/0] quit
    [SwitchB] interface gigabitethernet 2/0/0
    [SwitchB-GigabitEthernet2/0/0] port link-type trunk
    [SwitchB-GigabitEthernet2/0/0] port trunk allow-pass vlan 20
    [SwitchB-GigabitEthernet2/0/0] quit
    [SwitchB] interface vlanif 10
    [SwitchB-Vlanif10] ip address 20.1.1.2 24
    [SwitchB-Vlanif10] quit
    [SwitchB] interface vlanif 20
    [SwitchB-Vlanif20] ip address 30.1.1.1 24
    [SwitchB-Vlanif20] quit

    # Configure SwitchC.

    <HUAWEI> system-view
    [HUAWEI] sysname SwitchC
    [SwitchC] vlan batch 20 30
    [SwitchC] interface gigabitethernet 1/0/0
    [SwitchC-GigabitEthernet1/0/0] port link-type trunk
    [SwitchC-GigabitEthernet1/0/0] port trunk allow-pass vlan 20
    [SwitchC-GigabitEthernet1/0/0] quit
    [SwitchC] interface gigabitethernet 2/0/0
    [SwitchC-GigabitEthernet2/0/0] port link-type access
    [SwitchC-GigabitEthernet2/0/0] port default vlan 30
    [SwitchC-GigabitEthernet2/0/0] quit
    [SwitchC] interface vlanif 20
    [SwitchC-Vlanif20] ip address 30.1.1.2 24
    [SwitchC-Vlanif20] quit
    [SwitchC] ipv6
    [SwitchC] interface vlanif 30
    [SwitchC-Vlanif30] ipv6 enable
    [SwitchC-Vlanif30] ipv6 address fc00:2::1 64
    [SwitchC-Vlanif30] quit

  2. Configure an IPv4 static route.

    # Configure SwitchA.

    [SwitchA] ip route-static 30.1.1.0 255.255.255.0 20.1.1.2

    # Configure SwitchC.

    [SwitchC] ip route-static 20.1.1.0 255.255.255.0 30.1.1.1

  3. Configure a tunnel interface.

    # Configure SwitchA.

    [SwitchA] interface tunnel 1
    [SwitchA-Tunnel1] tunnel-protocol gre
    [SwitchA-Tunnel1] ipv6 enable
    [SwitchA-Tunnel1] ipv6 address 3001::1 64
    [SwitchA-Tunnel1] source 20.1.1.1
    [SwitchA-Tunnel1] destination 30.1.1.2
    [SwitchA-Tunnel1] quit

    # Configure SwitchC.

    [SwitchC] interface tunnel 1
    [SwitchC-Tunnel1] tunnel-protocol gre
    [SwitchC-Tunnel1] ipv6 enable
    [SwitchC-Tunnel1] ipv6 address 3001::2 64
    [SwitchC-Tunnel1] source 30.1.1.2
    [SwitchC-Tunnel1] destination 20.1.1.1
    [SwitchC-Tunnel1] quit

  4. Configure a static tunnel route.

    # Configure SwitchA.

    [SwitchA] ipv6 route-static fc00:2:: 64 tunnel 1

    # Configure SwitchC.

    [SwitchC] ipv6 route-static fc00:1:: 64 tunnel 1

  5. Verify the configuration.

    # Ping the IPv4 address of SwitchA from SwitchC. SwitchC can receive a Reply packet from SwitchA.

    [SwitchC] ping 20.1.1.1
      PING 20.1.1.1: 56  data bytes, press CTRL_C to break
        Reply from 20.1.1.1: bytes=56 Sequence=1 ttl=254 time=84 ms
        Reply from 20.1.1.1: bytes=56 Sequence=2 ttl=254 time=27 ms
        Reply from 20.1.1.1: bytes=56 Sequence=3 ttl=254 time=25 ms
        Reply from 20.1.1.1: bytes=56 Sequence=4 ttl=254 time=3 ms
        Reply from 20.1.1.1: bytes=56 Sequence=5 ttl=254 time=24 ms
    
      --- 20.1.1.1 ping statistics ---
        5 packet(s) transmitted
        5 packet(s) received
        0.00% packet loss
        round-trip min/avg/max = 3/32/84 ms

    # Ping the IPv6 address of SwitchA from SwitchC. SwitchC can now receive a Reply packet from SwitchA.

    [SwitchC] ping ipv6 fc00:1::1
      PING fc00:1::1 : 56  data bytes, press CTRL_C to break
        Reply from FC00:1::1
        bytes=56 Sequence=1 hop limit=64  time = 28 ms
        Reply from FC00:1::1
        bytes=56 Sequence=2 hop limit=64  time = 27 ms
        Reply from FC00:1::1
        bytes=56 Sequence=3 hop limit=64  time = 26 ms
        Reply from FC00:1::1
        bytes=56 Sequence=4 hop limit=64  time = 27 ms
        Reply from FC00:1::1
        bytes=56 Sequence=5 hop limit=64  time = 26 ms
    
      --- fc00:1::1 ping statistics ---
        5 packet(s) transmitted
        5 packet(s) received
        0.00% packet loss
    round-trip min/avg/max = 26/26/28 ms

Configuration Files

  • SwitchA configuration file

    #
    sysname SwitchA
    #    
    ipv6      
    #  
    vlan batch 10 30
    #
    interface Vlanif10
     ip address 20.1.1.1 255.255.255.0
    #
    interface Vlanif30
     ipv6 enable
     ipv6 address FC00:1::1/64
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 10
    #
    interface GigabitEthernet2/0/0
     port link-type access
     port default vlan 30
    #
    interface Tunnel1
     ipv6 enable
     ipv6 address 3001::1/64
     tunnel-protocol gre
     source 20.1.1.1
     destination 30.1.1.2
    #
    ip route-static 30.1.1.0 255.255.255.0 20.1.1.2
    #                                                                               
    ipv6 route-static FC00:2:: 64 Tunnel1 
    #
    return
  • SwitchB configuration file

    #
    sysname SwitchB
    #
    vlan batch 10 20
    #
    interface Vlanif10
     ip address 20.1.1.2 255.255.255.0
    #
    interface Vlanif20
     ip address 30.1.1.1 255.255.255.0
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 10
    #
    interface GigabitEthernet2/0/0
     port link-type trunk
     port trunk allow-pass vlan 20
    #
    return
  • SwitchC configuration file

    #
    sysname SwitchC
    #    
    ipv6     
    #
    vlan batch 20 30
    #
    interface Vlanif20
     ip address 30.1.1.2 255.255.255.0
    #
    interface Vlanif30
     ipv6 enable
     ipv6 address FC00:2::1/64
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 20
    #
    interface GigabitEthernet2/0/0
     port link-type access
     port default vlan 30
    #
    interface Tunnel1
     ipv6 enable
     ipv6 address 3001::2/64
     tunnel-protocol gre
     source 30.1.1.2
     destination 20.1.1.1
    #
    ip route-static 20.1.1.0 255.255.255.0 30.1.1.1
    #                                                                               
    ipv6 route-static FC00:1:: 64 Tunnel1 
    #
    return
Translation
Download
Updated: 2019-04-08

Document ID: EDOC1100065751

Views: 39563

Downloads: 50

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