EBGP Configuration on Huawei Router

Here is sample tutorial on how to configure External Border Gateway Protocol (EBGP) between Huawei Router and another router. I will focus on the configuration of the Huawei router (RouterA).

Fig.1.1

Procedure:
1. Configure the Loopback IP address

a. Enter system view
command: system-view

<RouterA>system-view
Enter system view, return user view with return command.

<RouterA>interface LoopBack0
<RouterA>description RouterA Loopback0
<RouterA>ip address 172.16.1.1 255.255.255.255
<RouterA>quit

Verify:
<RouterA>display current-configuration interface LoopBack 0

2. Configure the P2P(point to point) IP, we will assume that the connectivity between the 2 routers are in 100GigaEthernet interface and configured in Bundle via LACP

a. Configure the physical interface

<RouterA>interface 100GE6/0/0
<RouterA>description Connection to Peer
<RouterA>undo shutdown
<RouterA>damp-interface enable
<RouterA>eth-trunk 8
<RouterA>undo lldp enable
<RouterA>undo dcn

b. Configure the Eth-Trunk

<RouterA>interface Eth-Trunk8
<RouterA>description Eth-Trunk to Peer
<RouterA>set flow-stat interval 10
<RouterA>ip address 192.168.10.2 255.255.255.252
<RouterA>trust upstream default
<RouterA>mode lacp-static
<RouterA>lacp timeout fast

Verify:

<RouterA>display current-configuration interface 100GE6/0/0
<RouterA>display current-configuration interface Eth-Trunk8
<RouterA>display interface Eth-Trunk8
<RouterA>display lacp statistics Eth-Trunk8

Ping the P2P IP to verify connectivity:

<RouterA>ping 192.168.10.1
PING 192.168.10.1: 56 data bytes, press CTRL_C to break
Reply from 192.168.10.1: bytes=56 Sequence=1 ttl=255 time=4 ms
Reply from 192.168.10.1: bytes=56 Sequence=2 ttl=255 time=1 ms
Reply from 192.168.10.1: bytes=56 Sequence=3 ttl=255 time=1 ms
Reply from 192.168.10.1: bytes=56 Sequence=4 ttl=255 time=1 ms
Reply from 192.168.10.1: bytes=56 Sequence=5 ttl=255 time=1 ms

— 192.168.10.1 ping statistics —
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 1/1/4 ms

3. Configure the Incoming Policy
Assuming you one to allow default route from the neighbor

a. Create prefix list to allow default route

<RouterA>ip ip-prefix DEFAULT-PREFIX index 10 permit 0.0.0.0 0

b. Create the route policy to match the prefix, then explicitly add the default deny

<RouterA>route-policy DEFAULTv4 permit node 10
  if-match ip-prefix DEFAULT-PREFIX
route-policy DEFAULTv4 deny node 10000

 

4. Configure the Outgoing Policy

a. Create prefix list to allow the prefix you want to advertise

<RouterA>ip ip-prefix OUTPREFIX index 10 permit 172.16.1.1 32

b. Create the route policy to match the prefix, then explicitly add the default deny

<RouterA>route-policy OUTPOLICY permit node 10
   if-match ip-prefix OUTPREFIX
route-policy OUTPOLICY deny node 10000

 

5.Configure the eBGP
Assuming the agreed MD5 password between peers is bGP@p455w0rd

<RouterA>bgp 65555
 router-id 172.16.1.1
 graceful-restart
 peer 192.168.10.1 as-number 65577
 peer 192.168.10.1 description Peer BGP IPv4
 peer 192.168.10.1 password cipher bGP@p455w0rd

ipv4-family unicast
 undo synchronization
 import-route unr
 peer 192.168.10.1 enable
 peer 192.168.10.1 route-policy DEFAULTv4 import
 peer 192.168.10.1 route-policy OUTPOLICY export

6.Verification:

<RouterA>display bgp all summary
<RouterA>display bgp peer
<RouterA>display bgp routing-table
<RouterA>display bgp routing-table peer 192.168.10.1 advertised-routes
<RouterA>display bgp routing-table peer 192.168.10.1 received-routes
<RouterA>display bgp routing-table peer 192.168.10.1 accepted-routes
<RouterA>display bgp routing-table peer 192.168.10.1 not-accepted-routes

where:
accepted-routes Routes accepted by routing policy
advertised-routes Routes advertised to the remote peer
not-accepted-routes Routes not accepted by routing policy
received-routes Routes received from the remote peer

Sample Output:

<RouterA>display bgp peer

BGP local router ID : 172.16.1.1
Local AS number : 65555
Total number of peers : 1 Peers in established state : 1

Peer           V  AS      MsgRcvd MsgSent OutQ Up/Down  State          PrefRcv
192.168.10.1   4 65577 10359        10065 0         0071h55m  Established 1

It can be observed that the eBGP IPv4 neighbor relationship is “Established” and receiving 1 prefix from AS65577 for peering 192.168.10.1

Be First to Comment

Leave a Reply

Your email address will not be published.