07-Layer 3—IP Services Command Reference

HomeSupportRoutersMSR5600 Series(Comware V7)Reference GuidesCommand ReferencesH3C MSR 5600 Routers Command Reference(V7)-R6728-6W10007-Layer 3—IP Services Command Reference
19-GRE commands
Title Size Download
19-GRE commands 111.70 KB

GRE commands

display gre p2mp tunnel-table interface tunnel

Use display gre p2mp tunnel-table interface tunnel to display dynamic tunnel entry information for a GRE P2MP tunnel interface.

Syntax

display gre p2mp tunnel-table interface tunnel number [ ipv4 | ipv6 ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

number: Specifies an existing GRE P2MP tunnel interface by its interface number.

ipv4: Specifies dynamic IPv4 tunnel entries.

ipv6: Specifies dynamic IPv6 tunnel entries.

Usage guidelines

If you do not specify the ipv4 keyword or the ipv6 keyword, this command displays all dynamic tunnel entries for a GRE P2MP tunnel interface.

Examples

# Display all dynamic tunnel entries for GRE P2MP tunnel interface Tunnel 0.

<Sysname> display gre p2mp tunnel-table interface tunnel 0

Total number:2

Dest Addr               Mask/Prefix Len Tunnel Dest Addr        Gre Key   Aging

10.0.0.1                255.255.255.255 20.0.0.1                          10

10::1                   64              20.0.0.2                          5

# Display dynamic IPv4 tunnel entries for GRE P2MP tunnel interface Tunnel 0.

<Sysname> display gre p2mp tunnel-table interface tunnel 0 ipv4

Total number:1

Dest Addr               Mask/Prefix Len Tunnel Dest Addr        Gre Key   Aging

100.0.0.1               255.255.255.255  20.0.0.1                         9

# Display dynamic IPv6 tunnel entries for GRE P2MP tunnel interface Tunnel 0.

<Sysname> display gre p2mp tunnel-table interface tunnel 0 ipv6

Total number:1

Dest Addr             Mask/Prefix Len Tunnel Dest Addr        Gre Key   Aging

100::1                128                    20::2                      3

Table 1 Command output

Field

Description

Total number

Total number of GRE P2MP dynamic tunnel entries.

Dest Addr

Network address of the branch network.

Mask/Prefix Len

Address mask or prefix length of the branch network.

Tunnel Dest Addr

Destination address of the tunnel.

Gre Key

GRE key, which indicates the priority of the dynamic tunnel entry. This field does not display anything if the tunnel destination end does not have a GRE key.

Aging

Remaining lifetime of the entry, in seconds.

 

display gre p2mp tunnel-table statistics

Use display gre p2mp tunnel-table statistics to display packet statistics of static tunnel entries for a GRE P2MP tunnel interface.

Syntax

display gre p2mp tunnel-table statistics interface tunnel number [ vpn-instance vpn-instance-name ] [ branch-network-address branch-network-address { mask | mask-length } ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

interface tunnel number: Specifies an existing GRE P2MP tunnel interface by its interface number.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name. The vpn-instance-name argument is a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays packet statistics of static tunnel entries on the public network for the specified GRE P2MP tunnel interface.

branch-network-address branch-network-address: Specifies an IPv4 branch network address. If you do not specify this option, the command displays packets statistics of static tunnel entries for all IPv4 branch networks of the specified scope.

mask: Specifies the mask of the branch network address, in dotted decimal notation.

mask-length: Specifies the mask length of the branch network address, in the range of 0 to 32.

Usage guidelines

If you do not specify any parameters, this command displays packet statistics of all static tunnel entries on the public network for the specified GRE P2MP tunnel interface.

Examples

# Display packet statistics of all static tunnel entries on the public network for GRE P2MP tunnel interface Tunnel 1.

<Sysname> display gre p2mp tunnel-table statistics interface tunnel 1

 

VPN-instance name: -       Map entries: 2

 

Branch network address    : 192.168.11.1/32

Tunnel destination address: 11.1.1.1

Checksum value            : 192.168.20.1

  Input:

    0 packets, 0 bytes, 0 drops

  Output:

    0 packets, 0 bytes, 0 drops

 

Branch network address    : 192.168.12.1/32

Tunnel destination address: 11.1.1.1

Checksum value            : 192.168.20.2

  Input:

    0 packets, 0 bytes, 0 drops

  Output:

    0 packets, 0 bytes, 0 drops

Table 2 Command output

Field

Description

VPN-instance name

VPN instance of the branch networks.

If the branch networks belong to the public network, this field displays a hyphen (-).

Map entries

Total number of GRE P2MP tunnel mapping entries.

Branch network address

IPv4 address and mask of a branch network.

Tunnel destination address

A destination address of the tunnel.

Checksum value

Value to fill in the checksum field.

The system does not display the Checksum value field if no value is specified to fill in the checksum field.

Input:

0 packets, 0 bytes, 0 drops

Incoming traffic statistics:

·     Number of incoming packets.

·     Number of incoming bytes.

·     Number of dropped packets.

Output:

0 packets, 0 bytes, 0 drops

Outgoing traffic statistics:

·     Number of outgoing packets.

·     Number of outgoing bytes.

·     Number of dropped packets.

 

eogre carry

Use eogre carry to configure EoGRE packets to carry GRE extended fields.

Use undo eogre carry to restore the default.

Syntax

eogre carry network-policy-id id-value mac-address { bridge | bssid }

undo eogre carry

The following compatibility matrix shows the support of hardware platforms for this command:

 

Hardware platform

MPU model

Command compatibility

MSR5620

MPU-60

Yes

MSR 56-60

MSR 56-80

MPU-100

Yes

MPU-100-X1

Yes

MPU-100-G

No

Default

EoGRE packets do not carry GRE extended fields.

Views

EoGRE tunnel interface view

Predefined user roles

network-admin

Parameters

network-policy-id id-value: Specifies the Network Policy ID field value, in the range of 1 to 65535. This value is the policy ID used by the peer server to identify its access device.

mac-address bridge: Specifies the bridge MAC address of the local device as the value of the AP MAC field.

mac-address bssid: Specifies the BSSID of the local device as the value of the AP MAC field.

Usage guidelines

If the EoGRE packets sent by an EoGRE tunnel interface need to carry the GRE extended fields, execute this command to configure the fields as needed.

Examples

# In EoGRE tunnel interface view, configure EoGRE packets to carry the Network Policy ID and AP MAC fields. Set the Network Policy ID to 20 and the AP MAC field value as the local bridge MAC address.

<Sysname> system-view

[Sysname] interface tunnel 0 mode eogre

[Sysname-Tunnel0] eogre carry network-policy-id 20 mac-address bridge

gre checksum

Use gre checksum to enable GRE checksum.

Use undo gre checksum to disable GRE checksum.

Syntax

gre checksum

undo gre checksum

Default

GRE checksum is disabled.

Views

Tunnel interface view

Predefined user roles

network-admin

Usage guidelines

GRE checksum verifies packet integrity.

You can enable or disable GRE checksum at each end of a tunnel as needed. After GRE checksum is enabled, the sender does the following:

·     Calculates the checksum for the GRE header and the payload.

·     Sends the packet containing the checksum information to the peer.

The receiver calculates the checksum for the received packet and compares it with that carried in the packet. If the checksums are the same, the receiver processes the packet. If the checksums are different, the receiver discards the packet.

If a packet carries a GRE checksum, the receiver checks the checksum whether or not the receiver is enabled with GRE checksum.

Examples

# Enable GRE checksum.

<Sysname> system-view

[Sysname] interface tunnel 2 mode gre

[Sysname-Tunnel2] gre checksum

gre key

Use gre key to configure a key for a GRE tunnel interface.

Use undo gre key to restore the default.

Syntax

gre key key

undo gre key

Default

No key is configured for a GRE tunnel interface.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

key: Specifies the key for the GRE tunnel interface, in the range of 0 to 4294967295.

Usage guidelines

Both ends of a GRE point-to-point tunnel must have the same key or no key.

Do not configure any GRE key on a GRE P2MP tunnel interface. You can configure GRE keys on the point-to-point tunnel interfaces in the branch networks. The GRE keys not only check for the validity of packets received on the tunnel interfaces but also indicate the priorities of dynamic tunnels. The GRE P2MP tunnel end prefers the branch tunnel that has the highest priority to forward traffic.

Examples

# Configure the GRE key as 123 for the GRE tunnel interface Tunnel 2.

<Sysname> system-view

[Sysname] interface tunnel 2 mode gre

[Sysname-Tunnel2] gre key 123

gre p2mp aging-time

Use gre p2mp aging-time to specify an aging timer for dynamic tunnel entries of a GRE P2MP tunnel interface.

Use undo gre p2mp aging-time to restore the default.

Syntax

gre p2mp aging-time aging-time

undo gre p2mp aging-time

Default

The aging timer is 5 seconds.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

aging-time: Specifies an aging timer in the range of 1 to 86400 seconds.

Usage guidelines

This command is applicable only to GRE P2MP tunnel interfaces.

If the headquarters gateway does not receive any packets from a branch when the aging timer expires, it deletes the dynamic tunnel entry of that branch.

Set an appropriate aging timer depending on the network condition. A shorter timer might cause forwarding failure to an actual reachable network. A longer timer cannot quickly update dynamic tunnel entries.

Examples

# Set the aging timer to 10 seconds for dynamic tunnel entry on GRE P2MP tunnel interface Tunnel 0.

<Sysname> system-view

[Sysname] interface tunnel 0 mode gre-p2mp

[Sysname-Tunnel0] gre p2mp aging-time 10

gre p2mp backup-interface

Use gre p2mp backup-interface to specify a backup interface for a GRE P2MP tunnel interface.

Use undo gre p2mp backup-interface to restore the default.

Syntax

gre p2mp backup-interface tunnel number

undo gre p2mp backup-interface

Default

No backup interface is configured for a GRE P2MP tunnel interface.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

tunnel number: Specifies a tunnel interface by its interface number. The tunnel interface must exist on the device and must be a GRE/IPv4 or GRE/IPv6 tunnel interface.

Usage guidelines

This command is applicable only to GRE P2MP tunnel interfaces.

When the device cannot find a matching GRE P2MP dynamic tunnel entry to forward traffic, it forwards the traffic to the backup gateway through the backup interface. Services (for example, NetStream and NAT) on the backup interface do not take effect on the traffic. The service configuration on the primary GRE P2MP tunnel interface is used for the traffic.

Examples

# Specify tunnel interface Tunnel 100 as the backup interface of GRE P2MP tunnel interface Tunnel 0.

<Sysname> system-view

[Sysname] interface tunnel 0 mode gre-p2mp

[Sysname-Tunnel0] gre p2mp backup-interface tunnel 100

gre p2mp branch-network-mask

Use gre p2mp branch-network-mask to specify the network mask or mask length for IPv4 branch networks or specify the prefix length for IPv6 branch networks on a GRE P2MP tunnel interface.

Use undo gre p2mp branch-network-mask to restore the default.

Syntax

gre p2mp branch-network-mask { mask | mask-length | ipv6 prefix-length }

undo gre p2mp branch-network-mask [ ipv6 ]

Default

The IPv4 address mask is 255.255.255.255 (the mask length is 32) and the IPv6 address prefix length is 128 for branch networks.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

mask: Specifies the IPv4 address mask, in dotted decimal notation.

mask-length: Specifies the IPv4 address mask length, in the range of 0 to 32.

ipv6 prefix-length: Specifies the IPv6 address prefix length, in the range of 0 to 128.

Usage guidelines

This command is applicable only to GRE P2MP tunnel interfaces.

This command enables a GRE P2MP tunnel interface to use the same network mask or prefix length to create dynamic tunnel entries for branch networks. One branch has only one dynamic tunnel entry.

To ensure successful packet forwarding, make sure all branch networks have the same network mask or prefix length, which is the same as that specified by this command.

Examples

# Specify the IPv4 branch network mask as 255.255.255.0 for GRE P2MP dynamic tunnel entries on tunnel interface Tunnel 0.

<Sysname> system-view

[Sysname] interface tunnel 0 mode gre-p2mp

[Sysname-Tunnel0] gre p2mp branch-network-mask 255.255.255.0

gre p2mp nexthop-learning

Use gre p2mp nexthop-learning to enable next hop host route learning.

Use undo gre p2mp nexthop-learning to disable next hop host route learning.

Syntax

gre p2mp nexthop-learning

undo gre p2mp nexthop-learning

Default

Next hop host route learning is disabled.

Views

Tunnel interface view.

Predefined user roles

network-admin

Usage guidelines

This command is supported only on GRE/IPv4 P2MP tunnel interfaces.

The headquarters gateway uses the same branch network mask to create tunnel entries for all branch networks. If some branch network addresses are in the same subnet, the headquarters gateway will learn the same destination address for these branch networks in the tunnel entries. In this case, the headquarters cannot establish BGP neighbors with these branches.

To resolve this issue, enable next hop host route learning on the headquarters gateway. This feature enables the gateway to learn destination addresses with the 32-bit mask when it establishes a BGP neighbor relationship with peers that are in the same subnet.

Examples

# Enable next hop host route learning on GRE/IPv4 P2MP tunnel interface Tunnel 0.

<Sysname> system-view

[Sysname] interface tunnel 0 mode gre-p2mp

[Sysname-Tunnel0] gre p2mp nexthop-learning

Related commands

gre p2mp branch-network-mask

gre p2mp-template (system view)

Use gre p2mp-template to create a GRE P2MP tunnel template and enter its view, or enter the view of an existing GRE P2MP tunnel template.

Use undo gre p2mp-template to delete a GRE P2MP tunnel template.

Syntax

gre p2mp-template template-name

undo gre p2mp-template template-name

Default

No GRE P2MP tunnel templates exist.

Views

System view

Predefined user roles

network-admin

Parameters

template-name: Specifies a name for the GRE P2MP tunnel template, a case-sensitive string of 1 to 31 characters.

Examples

# Create a GRE P2MP tunnel template named aa and enter its view.

<Sysname> system-view

[Sysname] gre p2mp-template aa

[Sysname-p2mp-template-aa]

Related commands

map

gre p2mp-template (tunnel interface view)

Use gre p2mp-template to apply a GRE P2MP tunnel template to a GRE P2MP tunnel interface.

Use undo gre p2mp-template to restore the default.

Syntax

gre p2mp-template template-name

undo gre p2mp-template

Default

No GRE P2MP tunnel template is applied to a GRE P2MP tunnel interface.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

template-name: Specifies a GRE P2MP tunnel template by its name, a case-sensitive string of 1 to 31 characters.

Usage guidelines

A GRE P2MP tunnel interface can use only one GRE P2MP tunnel template. If you execute this command multiple times, the most recent configuration takes effect.

Examples

# Apply GRE P2MP tunnel template aa to GRE P2MP tunnel interface Tunnel 1.

<Sysname> system-view

[Sysname] interface tunnel 1 mode gre-p2mp

[Sysname-Tunnel1] gre p2mp-template aa

Related commands

gre p2mp-template (system view)

keepalive

Use keepalive to enable GRE and EoGRE keepalive and set the keepalive interval and the keepalive number.

Use undo keepalive to disable GRE and EoGRE keepalive.

Syntax

keepalive [ interval [ times ] ]

undo keepalive

Default

GRE and EoGRE keepalive is disabled.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

interval: Specifies the keepalive interval, in the range of 1 to 32767 seconds. The default value is 10.

times: Specifies the keepalive number, in the range of 1 to 255. The default value is 3.

Usage guidelines

This command enables the tunnel interface to send keepalive packets at the specified interval. If the device receives no response from the peer within the timeout time, it shuts down the local tunnel interface. The device brings the local tunnel interface up if it receives a keepalive acknowledgment packet from the peer. The timeout time is the result of multiplying the keepalive interval by the keepalive number.

The device always acknowledges the keepalive packets it receives whether or not keepalive is enabled.

EoGRE keepalive relies on NQA. Make sure NQA client is enabled on the device.

GRE/IPv6 mode tunnel interfaces do not support this command.

Examples

# Enable GRE and EoGRE keepalive, set the keepalive interval to 20 seconds, and set the keepalive number to 5.

<Sysname> system-view

[Sysname] interface tunnel 2 mode gre

[Sysname-Tunnel2] keepalive 20 5

Related commands

nqa agent enable (Network Management and Monitoring Command Reference)

map

Use map to configure a tunnel mapping entry in a GRE P2MP tunnel template.

Use undo map to delete a tunnel mapping entry from a GRE P2MP tunnel template.

Syntax

map [ vpn-instance vpn-instance-name ] branch-network-address branch-network-address { mask | mask-length } tunnel-destination tunnel-dest-address [ checksum-fill checksum-value ]

undo map [ vpn-instance vpn-instance-name ] branch-network-address branch-network-address { mask | mask-length } [ tunnel-destination tunnel-dest-address ]

Default

No tunnel mapping entries are configured in a GRE P2MP tunnel template.

Views

GRE P2MP tunnel template view

Predefined user roles

network-admin

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name. The vpn-instance-name argument is a case-sensitive string of 1 to 31 characters. If the branch network address belongs to a private network, you must specify this option. If the branch network address belongs to the public network, do not specify this option.

branch-network-address branch-network-address: Specifies an IPv4 branch network address.

mask: Specifies the mask of the branch network IPv4 address, in dotted decimal notation.

mask-length: Specifies the mask length of the branch network IPv4 address, in the range of 0 to 32.

tunnel-destination tunnel-dest-address: Specifies the tunnel destination IPv4 address.

checksum-fill checksum-value: Specifies an IPv4 address to fill in the checksum field of the GRE header. The IPv4 address is in dotted decimal notation. If you do not specify this option, the device does not fill in the checksum field of the GRE header.

Usage guidelines

The tunnel mapping entries in the tunnel template are static tunnel entries.

You can repeat this command to configure multiple tunnel mapping entries for a GRE P2MP tunnel template. Each entry defines a mapping between a branch network address and a tunnel destination address. One branch network address can be mapped to only one tunnel destination address.

If a branch network contains VMs that have multiple users, fill the IPv4 address of the destination VM to the checksum field for correct forwarding of a GRE packet. Specify the checksum-fill checksum-value option depending on your network. Incorrect usage of the option will cause GRE checksum failures.

Examples

# In GRE P2MP tunnel template aa, configure a tunnel mapping entry. The branch network address is 192.168.0.11 and the mask length is 32, the tunnel destination address is 10.108.113.71, and the IPv4 address to fill in the checksum field is 192.168.20.1.

<Sysname> system-view

[Sysname] gre p2mp-template aa

[Sysname-p2mp-template-aa] map branch-network-address 192.168.0.11 32 tunnel-destination 10.108.113.71 checksum-fill 192.168.20.1

Related commands

gre p2mp-template (system view)

map bridge

Use map bridge to map a Layer 2 VEB interface to an EoGRE tunnel interface or a Layer 3 physical interface.

Use undo map bridge to remove the mapping.

Syntax

map bridge { ve-bridge number | ve-bridge name }

undo map bridge

The following compatibility matrix shows the support of hardware platforms for this command:

 

Hardware platform

MPU model

Command compatibility

MSR5620

MPU-60

Yes

MSR 56-60

MSR 56-80

MPU-100

Yes

MPU-100-X1

Yes

MPU-100-G

No

Default

No VEB interface is mapped to an EoGRE tunnel interface or a Layer 3 physical interface.

Views

EoGRE tunnel interface view

Layer 3 physical interface view

Predefined user roles

network-admin

Parameters

ve-bridge number: Specifies an existing Layer 2 VEB interface by its number.

ve-bridge name: Specifies an existing Layer 2 VEB interface by its name.

Usage guidelines

To forward Layer 2 packets on a Layer 3 physical interface, perform the following tasks:

·     Bind the Layer 3 physical interface to a Layer 2 VEB interface.

·     Map the Layer 2 VEB interface to an EoGRE tunnel interface.

The Layer 2 VEB interface mapped to the Layer 3 physical interface encapsulates Layer 2 packets and passes the packets to the mapped EoGRE tunnel interface for encapsulation and forwarding.

To ensure successful mapping, a Layer 2 VEB interface mapped to a Layer 3 physical interface cannot be bound to other services (such as ATM).

To ensure successful mapping, a Layer 2 VEB interface mapped to an EoGRE tunnel interface cannot be bound to other services (such as ATM).

Examples

# Enter Layer 3 physical interface view and map Layer 2 VEB interface VE-Bridge 1/0/1 to the Layer 3 physical interface.

<Sysname> system-view

[Sysname] interface gigabitethernet 1/0/1

[Sysname-GigabitEthernet1/0/1] map bridge ve-bridge 1/0/1

# Create EoGRE-mode tunnel interface Tunnel 0, enter tunnel interface view, and map VE-Bridge 1/0/1 to Tunnel 0.

<Sysname> system-view

[Sysname] interface tunnel 0 mode eogre

[Sysname-Tunnel0] map bridge ve-bridge 1/0/1

reset gre p2mp tunnel-table

Use reset gre p2mp tunnel-table to clear dynamic tunnel entry information for a GRE P2MP tunnel interface.

Syntax

reset gre p2mp tunnel-table interface tunnel number [ destination { dest-address | ipv6 dest-ipv6-address } tunnel-destination { tunnel-dest-address | ipv6 tunnel-dest-address } ]

Views

User view

Predefined user roles

network-admin

Parameters

interface tunnel number: Specifies a GRE P2MP tunnel interface by its interface number.

destination { dest-address | ipv6 dest-ipv6-address }: Specifies an IPv4 or IPv6 branch network address of the specified GRE P2MP tunnel interface.

tunnel-destination { tunnel-dest-address | ipv6 tunnel-dest-address }: Specifies a tunnel destination IPv4 or IPv6 address.

Usage guidelines

If you do not specify a branch network address or a tunnel destination address, this command clears all dynamic tunnel entries for the specified GRE P2MP tunnel interface.

Examples

# Clear all dynamic tunnel entries for GRE P2MP tunnel interface Tunnel 0.

<Sysname> reset gre p2mp tunnel-table interface tunnel 0

# Clear a dynamic tunnel entry of which the branch network is 10.0.0.1 and the tunnel destination is 20.0.0.1 on GRE P2MP tunnel interface Tunnel 0.

<Sysname> reset gre p2mp tunnel-table interface tunnel 0 destination 10.0.0.1 tunnel-destination 20.0.0.1

Related commands

display gre p2mp tunnel-table interface tunnel

reset gre p2mp tunnel-table statistics

Use reset gre p2mp tunnel-table statistics to clear packet statistics of static tunnel entries for a GRE P2MP tunnel interface.

Syntax

reset gre p2mp tunnel-table statistics interface tunnel number [ vpn-instance vpn-instance-name ] [ branch-network-address branch-network-address { mask | mask-length } ]

Views

User view

Predefined user roles

network-admin

Parameters

interface tunnel number: Specifies an existing GRE P2MP tunnel interface by its interface number.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name. The vpn-instance-name argument is a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command clears packet statistics of static tunnel entries on the public network for the specified GRE P2MP tunnel interface.

branch-network-address branch-network-address: Specifies a branch network IPv4 address. If you do not specify this option, the command clears packet statistics of static tunnel entries for all IPv4 branch networks of the specified scope.

mask: Specifies the mask of the branch network address, in dotted decimal notation.

mask-length: Specifies the mask length of the branch network address, in the range of 0 to 32.

Usage guidelines

If you do not specify any parameters, this command clears packet statistics of all static tunnel entries on the public network for the specified GRE P2MP tunnel interface.

Examples

# Clear packet statistics of all static tunnel entries on the public network for GRE P2MP tunnel interface Tunnel 1.

<Sysname> reset gre p2mp tunnel-table statistics interface tunnel 1

Related commands

display gre p2mp tunnel-table statistics

service-class

Use service-class to specify a service class value for a GRE tunnel interface.

Use undo service-class to restore the default.

Syntax

service-class service-class-value

undo service-class

Default

No service class value is specified for a GRE tunnel interface.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

service-class-value: Specifies a service class value in the range of 0 to 7. The lower the service class value, the lower the forwarding priority for a tunnel. If no service class value is specified for a tunnel, the tunnel is considered to have the lowest forwarding priority.

Usage guidelines

Use this command only on a GRE tunnel interface.

The device selects a tunnel to forward a packet in the following order:

1.     The tunnel that has the same service class value as the packet.

2.     If multiple tunnels have the same service class value as the packet, the device randomly selects one of the tunnels to forward the packet.

3.     If no tunnel has the same service class value as the packet, the device randomly selects a tunnel from all tunnels that have the lowest forwarding priority.

To set a service class value for packets, use the remark service-class command in traffic behavior view. For information about the remark service-class command, see QoS commands in ACL and QoS Command Reference.

Examples

# Set the service class value of Tunnel 0 to 5.

<Sysname> system-view

[Sysname] interface tunnel 0 mode gre

[Sysname-Tunnel0] service-class 5

tunnel route-static

Use tunnel route-static to configure the preference of static routes for a GRE P2MP tunnel interface.

Use undo tunnel route-static to restore the default.

Syntax

tunnel route-static [ preference preference-value ]

undo tunnel route-static

Default

The preference of static routes is 60 for a GRE P2MP tunnel interface.

Views

Tunnel interface view

Predefined user roles

network-admin

Parameters

preference preference-value: Specifies a preference value in the range of 1 to 255. The default value is 60, which is not affected by the ip route-static default-preference command.

Usage guidelines

A GRE P2MP tunnel interface automatically issues reachable static routes according to the tunnel mapping entries configured in the GRE P2MP tunnel template applied to the interface. This command takes effect on these static routes.

Examples

# Set the preference of static routes to 3 for GRE P2MP tunnel interface Tunnel 1.

<Sysname> system-view

[Sysname] interface tunnel 1 mode gre-p2mp

[Sysname-Tunnel1] tunnel route-static preference 3

Related commands

display ip routing-table protocol (Layer 3—IP Routing Command Reference)

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become a Partner
  • Partner Resources
  • Partner Business Management
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网