
139
[PE1-vpn-instance-vpn1] tnl-policy policy1
[PE1-vpn-instance-vpn1] quit
[PE1] tunnel-policy policy1
[PE1-tunnel-policy-policy1] tunnel select-seq cr-lsp load-balance-number 1
[PE1-tunnel-policy-policy1] quit
[PE1] interface giabitethernet 2/1/1
[PE1-GigabitEthernet2/1/1] ip binding vpn-instance vpn1
[PE1-GigabitEthernet2/1/1] ip address 192.168.1.1 255.255.255.0
[PE1-GigabitEthernet2/1/1] quit
# Configure on CE 2.
<CE2> system-view
[CE2] interface giabitethernet 2/1/1
[CE2-GigabitEthernet2/1/1] ip address 192.168.2.2 255.255.255.0
[CE2-GigabitEthernet2/1/1] quit
# Configure the VPN instance on PE 2, and bind it with the interface connected to CE 2.
[PE2] ip vpn-instance vpn1
[PE2-vpn-instance-vpn1] route-distinguisher 100:2
[PE2-vpn-instance-vpn1] vpn-target 100:1 both
[PE2-vpn-instance-vpn1] quit
[PE2] interface giabitethernet 2/1/1
[PE2-GigabitEthernet2/1/1] ip binding vpn-instance vpn1
[PE2-GigabitEthernet2/1/1] ip address 192.168.2.1 255.255.255.0
[PE2-GigabitEthernet2/1/1] quit
Execute the
display ip vpn-instance
command on the PEs to view the configuration of the
VPN instance. Take PE 1 for example:
[PE1] display ip vpn-instance instance-name vpn1
VPN-Instance Name and ID : vpn1, 1
Create time : 2006/09/27 15:10:29
Up time : 0 days, 00 hours, 03 minutes and 09 seconds
Route Distinguisher : 100:1
Export VPN Targets : 100:1
Import VPN Targets : 100:1
Tunnel Policy : policy1
Interfaces : GigabitEthernet2/1/1
Ping connected CEs on PEs to test connectivity. For example, ping CE 1 on PE 1:
[PE1] ping -vpn-instance vpn1 192.168.1.2
PING 192.168.1.2: 56 data bytes, press CTRL_C to break
Reply from 192.168.1.2: bytes=56 Sequence=1 ttl=255 time=47 ms
Reply from 192.168.1.2: bytes=56 Sequence=2 ttl=255 time=26 ms
Reply from 192.168.1.2: bytes=56 Sequence=3 ttl=255 time=26 ms
Reply from 192.168.1.2: bytes=56 Sequence=4 ttl=255 time=26 ms
Reply from 192.168.1.2: bytes=56 Sequence=5 ttl=255 time=26 ms
--- 192.168.1.2 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 26/30/47 ms
The sample output shows that PE 1 can reach CE 1.