H3C Technologies H3C SecPath F1000-E User Manual

Page 25

Advertising
background image

13

# Create a tunnel interface Tunnel0.

[RouterB] interface tunnel 0

# Configure an IP address for interface Tunnel0.

[RouterB-Tunnel0] ip address 10.1.2.2 255.255.255.0

# Configure the tunnel encapsulation mode as GRE over IPv4.

[RouterB-Tunnel0] tunnel-protocol gre

# Configure the source address of interface Tunnel0 to be the IP address of interface

GigabitEthernet 0/2.

[RouterB-Tunnel0] source 2.2.2.2

# Configure the destination address of interface Tunnel0 to be the IP address of interface
GigabitEthernet 0/2 on Router A.

[RouterB-Tunnel0] destination 1.1.1.1

[RouterB-Tunnel0] quit

# Configure a static route from Router B through interface Tunnel0 to Group 1.

[RouterB] ip route-static 10.1.1.0 255.255.255.0 tunnel 0

3.

Verify the configuration:
# Display the tunnel interface status on Router A and Router B.

[RouterA] display interface tunnel 0

Tunnel0 current state: UP

Line protocol current state: UP

Description: Tunnel0 Interface

The Maximum Transmit Unit is 1476

Internet Address is 10.1.2.1/24 Primary

Encapsulation is TUNNEL, service-loopback-group ID not set.

Tunnel source 1.1.1.1, destination 2.2.2.2

Tunnel keepalive disabled

Tunnel protocol/transport GRE/IP

GRE key disabled

Checksumming of GRE packets disabled

Output queue : (Urgent queuing : Size/Length/Discards) 0/100/0

Output queue : (Protocol queuing : Size/Length/Discards) 0/500/0

Output queue : (FIFO queuing : Size/Length/Discards) 0/75/0

Last clearing of counters: Never

Last 300 seconds input: 0 bytes/sec, 0 packets/sec

Last 300 seconds output: 0 bytes/sec, 0 packets/sec

10 packets input, 840 bytes

0 input error

10 packets output, 840 bytes

0 output error

[RouterB] display interface tunnel 0

Tunnel0 current state: UP

Line protocol current state: UP

Description: Tunnel0 Interface

The Maximum Transmit Unit is 1476

Internet Address is 10.1.2.2/24 Primary

Encapsulation is TUNNEL, service-loopback-group ID not set.

Tunnel source 2.2.2.2, destination 1.1.1.1

Advertising