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

CX11x, CX31x, CX710 (Earlier Than V6.03), and CX91x Series Switch Modules V100R001C10 Configuration Guide 12

The documents describe the configuration of various services supported by the CX11x&CX31x&CX91x series switch modules The description covers configuration examples and function configurations.
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).
Configuring GRE

Configuring GRE

This section describes the procedures for configuring GRE functions.

Configuring a GRE Tunnel

This section describes how to configure a GRE tunnel on an IPv4 network.

Pre-configuration Tasks
Before configuring a GRE tunnel, complete the following task:
Configuring a Tunnel Interface

Context

A GRE tunnel is established between two tunnel interfaces; therefore, you need to configure tunnel interfaces on devices at both ends of a tunnel. Set the protocol type to GRE, specify the tunnel source address (or interface) and tunnel destination address, and specify IP addresses for tunnel interfaces.

Switch Module_1 in Figure 9-9 is used as an example to illustrate configurations on a tunnel interface.
  • Tunnel source address (or interface): indicates the source address or interface used for packet transmission. The tunnel source interface is the physical interface from which encapsulated packets are sent, that is, VLANIF100 on Switch Module_1. The tunnel source address is the IP address of the physical interface from which encapsulated packets are sent, that is, the IP address of VLANIF100 on Switch Module_1.

  • Tunnel destination address: indicates the destination address for packet transmission. The tunnel destination address is the IP address of the physical interface to which encapsulated packets are sent, that is, the IP address of VLANIF100 on Switch Module_2.

  • IP address of the tunnel interface: indicates an IP address assigned to the tunnel interface. A dynamic or static routing protocol uses this IP address to advertise the tunnel interface. The IP address of the tunnel interface may be a public network address or not. It can also be an IP address borrowed from another interface to save IP addresses. When the tunnel interface borrows an IP address from another interface, you cannot enable a dynamic routing protocol on the tunnel interface because it does not have an IP address of its own. You must configure a static route to ensure connectivity between the devices.

NOTE:

The same tunnel mode must be configured on both ends of the tunnel.

The switch does not support multilayer GRE encapsulation or decapsulation.

GRE tunnels consume internal forwarding resources of VLANs. Therefore, the number of VLANs that can be created on the switch will decrease after GRE is configured. That is, less than 4093 VLANs can be created.

Figure 9-9 Networking for GRE tunnel setup

Procedure

  1. Run:

    system-view

    The system view is displayed.

  2. Run:

    interface eth-trunk trunk-id

    The Eth-Trunk interface view is displayed.

  3. Run:

    service type tunnel

    The interface is specified as a service loopback interface.

  4. Run:

    quit

    Return to the system view.

  5. Run:

    interface interface-type interface-number

    The interface view is displayed.

    The interface must be idle. That is, the interface does not transmit services.

  6. Run:

    eth-trunk trunk-id

    The interface is added to an Eth-Trunk.

  7. Run:

    quit

    Return to the system view.

  8. Run:

    interface tunnel interface-number

    A tunnel interface is created and the tunnel interface view is displayed.

  9. Run:

    tunnel-protocol gre

    The protocol type of the tunnel interface is set to GRE.

  10. Run:

    binding interface eth-trunk trunk-id

    The tunnel interface is bound to the Eth-Trunk.

  11. Run:

    source { source-ip-address | interface-type interface-number }

    A source address or source interface is specified for the tunnel.

  12. Run:

    destination dest-ip-address

    A destination address is specified for the tunnel.

  13. (Optional) Run:

    mtu mtu

    An MTU value is configured for the tunnel interface.

    By default, the MTU of a tunnel interface is 1500 bytes.

    NOTE:

    To change the MTU of a tunnel interface, run the shutdown command and then the undo shutdown command on the interface to make the new MTU effective.

  14. (Optional) Run:

    description text

    An interface description is provided.

    By default, no description is provided for the tunnel interface.

  15. Run either of the following commands to specify an IP address for the tunnel interface.

    • Specify an IP address.

      • Specify an IPv4 address for the tunnel interface when IPv4 networks communicate using the GRE tunnel.

        Run:

        ip address ip-address { mask | mask-length } [ sub ]

        An IPv4 address is specified for the tunnel interface.

      • Specify an IPv6 address for the tunnel interface when IPv6 networks communicate using the GRE tunnel.

        1. Run:

          ipv6 enable

          The IPv6 function is enabled on the interface.

        2. Run:

          ipv6 address { ipv6-address prefix-length | ipv6-address/prefix-length }

          An IPv6 address is specified for the tunnel interface.

    • Borrow an IP address.

      Run:

      ip address unnumbered interface interface-type interface-number

      The tunnel interface is configured to borrow an IP address.

      NOTE:

      A tunnel interface cannot borrow an IPv6 address.

  16. Run:

    commit

    The configuration is committed.

Configuring a Route on a Tunnel Interface

Context

GRE-encapsulated packets can be correctly forwarded only when a local and a remote device on the backbone network has a reachable route to each other and the route passes through the tunnel interfaces on the devices. The route can be a static route or a dynamic route.

Switch Module_1 in Figure 9-10 is used as an example to illustrate the configuration notes.
  • When configuring a static route, configure a route on both the local and the remote devices. Set the destination address of a static route to the original destination address of original packets (address of 10GE1/17/2 on Switch Module_2), and set the outbound interface to the tunnel interface on the local device (Tunnel1 on Switch Module_1).

  • When configuring a dynamic routing protocol, configure the protocol on both the tunnel interface and the interface connected to the network running the X protocol.

    As shown in Figure 9-10, you must configure the dynamic routing protocol on the tunnel interface and 10GE1/17/2 connected to the network running the X protocol. In the routing table, the outbound interface toward network segment 10.10.11.0 on Switch_2 is Tunnel1.

    In practice, you must configure different types of routing protocols or different processes of the same type of routing protocol to advertise routes for the tunnel interface and the backbone network. This ensures that user packets are forwarded by a physical interface rather than the tunnel interface.

    Figure 9-10 Networking for configuring a dynamic routing protocol for GRE

Procedure

  1. Run:

    system-view

    The system view is displayed.

  2. Choose either of the following methods to configure a route passing through a tunnel interface:

    • Run:

      ip route-static ip-address { mask | mask-length } { nexthop-address | tunnel interface-number [ nexthop-address ] } [ description text ]

      A static route is configured.

    • Configure a dynamic routing protocol. Dynamic routing can be implemented using IGP or External Gateway Protocol (EGP), such as OSPF and RIP. For details on how to configure a dynamic routing protocol, see CX11x&CX31x&CX91x Series Switch Modules Configuration Guide - IP Routing.

    NOTE:

    When IPv6 networks communicate with each other over the GRE tunnel, you must configure an IPv6 routing protocol on the tunnel interface and the physical interface connected to the network running IPv6.

  3. Run:

    commit

    The configuration is committed.

(Optional) Enabling the Keepalive Detection Function for GRE

Context

After the Keepalive detection function is enabled, the local device periodically sends Keepalive probes to the peer to check tunnel connectivity. If the peer is reachable, the local device receives a reply packet from the peer. Otherwise, the local device cannot receive a reply packet, and then disconnects the tunnel connection.

The Keepalive detection function takes effect on one end of the tunnel as long as this end is configured with the Keepalive detection function. The other end of the tunnel is not required to have the Keepalive detection function configured. To ensure that both ends of the tunnel can detect whether the peer is reachable, you are advised to enable the Keepalive detection function on both ends.

Procedure

  1. Run:

    system-view

    The system view is displayed.

  2. Run:

    interface tunnel interface-number

    The tunnel interface view is displayed.

  3. Run:

    keepalive [ period period [ retry-times retry-times ] ]

    The Keepalive detection function is enabled for GRE.

    By default, the Keepalive detection function of GRE is disabled.

  4. Run:

    commit

    The configuration is committed.

Checking the Configuration

Prerequisites

The configurations of a GRE tunnel are complete.

Procedure

  • Run the display interface tunnel [ interface-number ] command to view the status of the tunnel interface.
  • Run the display tunnel { tunnel-id | all | statistics } command to view tunnel information.
  • Run the display ip routing-table command to view the IPv4 routing table to check whether the outbound interface for a route to the specified destination address is a tunnel interface.
  • Run the display ipv6 routing-table command to view the IPv6 routing table to check whether the outbound interface for a route to the specified destination address is a tunnel interface.
  • Run the ping -a source-ip-address host command to check whether the local tunnel interface can ping the remote tunnel interface successfully.
  • After Keepalive detection is enabled, run the display keepalive packets count command in the tunnel interface view to view the number of Keepalive probes and Keepalive reply packets on the tunnel interface.

Configuring Priority Mapping on a Tunnel

You can configure priority mapping on a tunnel to enable the device to provide different QoS for different services based on their priorities.

Context

The enterprise campus network transmits voice, video, and data services. When different service flows of enterprise users enter a tunnel, devices on the campus network must assign priorities in descending order to the voice, video, and data services to provide differentiated services.

Priority mapping on a tunnel is similar to the IP QoS service. For the detailed configuration, see Priority Mapping Configuration.
NOTE:

When configuring priority mapping on a tunnel on the CX111&CX915 switch module GE switching plane , you can bind at most two DiffServ domains to an interface.

Translation
Download
Updated: 2019-08-09

Document ID: EDOC1000041694

Views: 59253

Downloads: 3623

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