An AR Router Fails to Set Up a BGP Connection with a Non-Huawei Device

Publication Date:  2015-10-14 Views:  622 Downloads:  0
Issue Description
Version: V200R005C20SPC200

Networking: An AR161 connects to a non-Huawei device through a switch and needs to set up a BGP connection with the non-Huawei device.

Figure 1-1 An AR Router Fails to Set Up a BGP Connection with a Non-Huawei Device



AR161 configuration file:

ip vpn-instance MGMT
ipv4-family
ipv6-family
#
ip vpn-instance VPN1
ipv4-family
  route-distinguisher 64512:201
ipv6-family
#
interface Vlanif21
ip binding vpn-instance VPN1
ip address 172.16.1.1 255.255.255.0
dhcp select interface
dhcp server excluded-ip-address 172.16.1.2 172.16.1.25
dhcp server dns-list 193.150.193.150 83.255.245.11
#
interface GigabitEthernet0/0/0
shutdown
#
interface GigabitEthernet0/0/1
shutdown
#
interface GigabitEthernet0/0/2
port hybrid pvid vlan 21
port hybrid tagged vlan 22 to 25
port hybrid untagged vlan 21
undo lldp enable
#
interface GigabitEthernet0/0/3
shutdown
undo lldp enable
#
interface GigabitEthernet0/0/4
ip binding vpn-instance MGMT
ip address 172.16.49.50 255.255.255.224
combo-port auto
#
interface GigabitEthernet0/0/4.201
dot1q termination vid 201
ip binding vpn-instance VPN1
ip address 83.x.x.1 255.255.255.254
#
interface Cellular0/0/0
shutdown
#
bgp 64512
timer keepalive 10 hold 70
#
ipv4-family unicast
  undo synchronization
#
ipv4-family vpn-instance VPN1
  default-route imported
  import-route direct
  import-route static
  peer 83.x.x.0 as-number 39651
  peer 83.x.x.0 ebgp-max-hop 2
  peer 83.x.x.0 connect-interface GigabitEthernet0/0/4.201
  peer 83.x.x.0 password cipher @%@%k]7J;SbeIMzF>}B8O+}<wB4)@%@%
  peer 151.x.x.1 as-number 39651
  peer 151.x.x.1 ebgp-max-hop 2
  peer 151.x.x.1 connect-interface Virtual-Template3
  peer 151.x.x.1 password cipher @%@%f`IJGC%G<"j:aLBx2%&YwBEw@%@%
#
ip route-static vpn-instance MGMT 0.0.0.0 0.0.0.0 172.x.x.33 track nqa WAN WAN
ip route-static vpn-instance MGMT 172.16.111.0 255.255.255.0 172.16.49.33

Fault symptom: The AR161 fails to set up a BGP connection with the non-Huawei device after restarting.
Handling Process
Step 1 Check whether the AR router configuration is lost after the router restarts.

No problem is found after the BGP configuration is analyzed.

Step 2 Run the display diagnostic-information command in the diagnostic view to check device information.

The command output shows a socket error log: OutBuffer Not available. The error log has been confirmed as a known error, which will not affect the BGP connection setup and can be ignored.

Step 3 Check debugging information about the TCP and BGP modules during system startup to analyze the BGP startup process.

The AR161 can set up a TCP connection with the peer device, indicating that the link between them is working properly.

Step 4 Create a loopback interface on the AR161 and configure an IP address 192.168.1.2 for the loopback interface. After the interface has been created, the BGP connection can be set up, and the fault is rectified.

Compare session information generated before and after a BGP connection is set up. When the BGP connection fails to be set up, the BGP local router ID is 0.0.0.0. When the BGP connection is set up, the BGP local router ID is the loopback interface IP address 192.168.1.2, as shown in the following command output.

<Huawei> display bgp vpnv4 vpn-instance VPN1 peer
BGP local router ID : 192.168.1.2
Local AS number : 64512
VPN-Instance VPN1, router ID 192.168.1.2: 
Total number of peers : 1                 Peers in established state : 1
  Peer            V    AS  MsgRcvd  MsgSent  OutQ  Up/Down       State   PrefRcv
  83.255.231.1    4 39651      10      22     0   02:59:49  Established       1
Root Cause
The router ID 0.0.0.0 is invalid on a device. After the local CR timer expires, the AR161 does not initiate a TCP connection when detecting that the local router ID is 0. When the peer device finds that the router ID of the AR161 is 0, it terminates the BGP connection.
Solution
Perform either of the following operations on the AR161:
  • Run the router id router-id command to configure a global router ID.
  • Run the interface loopback loopback-number command to create a loopback interface and configure an IP address for the interface.
Suggestions
When configuring BGP, set the router ID first to prevent the situation that no interface IP address is available by default.

END