R2511-HP MSR Router Series Layer 3 - IP Services Command Reference(V5)

245
Default
No key is configured for a GRE tunnel interface.
Views
Tunnel interface view
Default command level
2: System level
Parameters
key-number: Specifies the key for the GRE tunnel interface, in the range of 0 to 4294967295.
Usage guidelines
For a P2P GRE tunnel, both ends of the tunnel must be configured with the same GRE key. Otherwise,
packets cannot pass the GRE key verification and will be discarded. This weak security mechanism can
prevent packets from being received mistakenly.
GRE keys can also be used to differentiate GRE tunnels with the same source and destination addresses.
Examples
# Set the key for the GRE tunnel interfaces to 123 on Sysname1 and Sysname2.
// Set the GRE key to 123 for GRE tunnel interface 3 on router Sysname1.
<Sysname1> system-view
[Sysname1] interface tunnel 3
[Sysname1-Tunnel3] gre key 123
// Set the GRE key to 123 for GRE tunnel interface 2 on router Sysname2.
<Sysname2> system-view
[Sysname2] interface tunnel 2
[Sysname2-Tunnel2] gre key 123
Related commands
interface tunnel
display interface tunnel
gre recursion
Use gre recursion to specify a value for the Recursion Control field in the GRE header.
Use undo gre recursion to restore the default.
Syntax
gre recursion recursion-value
undo gre recursion
Default
The value of the Recursion Control field in the GRE header is 0, which means not to limit the number of
encapsulations.
Views
Tunnel interface view