display bgp [ vpnv4 vpn-instance vpn-instance-name ] peer [ { group-name | ipv4-address } log-info | [ ipv4-address ] verbose ]
display bgp vpnv4 all peer [ [ ipv4-address ] verbose ]
display bgp vpls peer [ [ ipv4-address ] verbose ] (supported only by the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731S-H, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730S-H, and S6730-H)
display bgp ipv6 peer [ verbose ]
display bgp ipv6 peer ipv6-address { log-info | verbose }
display bgp ipv6 peer ipv4-address verbose
display bgp vpnv6 all peer [ [ ipv4-address ] verbose ] (supported only by the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731S-H, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730S-H, and S6730-H)
display bgp vpnv6 vpn-instance vpn-instance-name peer [ { group-name | ipv6-address } log-info | [ ipv6-address ] verbose ] (supported only by the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731S-H, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730S-H, and S6730-H)
display bgp l2vpn-ad peer [ [ ipv4-address ] verbose ] (supported only by the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731S-H, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730S-H, and S6730-H)
display bgp l2vpn peer [ [ ipv4-address ] verbose ] (supported only by the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731S-H, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730S-H, and S6730-H)
Parameter | Description | Value |
---|---|---|
vpn-instance vpn-instance-name | Specifies the name of a VPN instance. | The value must be an existing VPN instance name. |
ipv4-address | Specifies the IPv4 address of a peer to be displayed. | It is in dotted decimal notation. |
group-name | Specifies the name of a peer group. | The name is a string of 1 to 47 case-sensitive characters, with spaces not supported. When double quotation marks are used around the string, spaces are allowed in the string. |
log-info | Indicates to display log information of the specified peer. | - |
verbose | Indicates to display detailed peer information. | - |
vpnv4 | Indicates to display information about peers in a VPNv4 instance. | - |
all | Indicates to display information about peers in all VPNv4 or VPNv6 instances. | - |
vpls | Displays information about peers in the BGP-VPLS view. | - |
ipv6-address | Specifies the IPv6 address of a peer to be displayed. | The value is a 32-digit hexadecimal number, in the format of X:X:X:X:X:X:X:X. |
vpnv6 | Indicates to display BGP VPNv6 peer information. | - |
l2vpn-ad | Displays information about peers in the BGP L2VPN-AD view. | - |
l2vpn | Displays information about peers in the BGP L2VPN view. | - |
Usage Scenario
Precautions
BGP has multiple address families. By default, the display bgp peer command displays information about BGP peers in IPv4 unicast address family only. If you want to view information about BGP peers in another address family, you need to specify its address family parameter.
To view detailed information about a BGP peer, such as information about BGP timers, the number of sent and received routes, capacities supported, the number of sent and received BGP messages, and enabled functions, specify verbose in the command.
If log-info is specified in the command, log information about a BGP peer is displayed, including information about BGP peer flapping.
# Display peer information.
<HUAWEI> display bgp peer BGP Local router ID : 10.2.3.4 local AS number : 10 Total number of peers : 2 Peers in established state : 1 Peer V AS MsgRcvd MsgSent OutQ Up/Down State PrefRcv 10.1.1.1 4 100 0 0 0 00:00:07 Idle 0 10.2.5.6 4 200 32 35 0 00:17:49 Established 0
Item |
Description |
---|---|
BGP Local router ID |
Indicates the ID of the BGP local router.
NOTE:
If two ends have the same BGP local router ID, no BGP peer relationship can be established between them. In this situation, run the router id command in the BGP view on either end to change the BGP local router ID. Changing it to the IP address of a loopback interface is recommended. |
local AS number |
Indicates the local AS number. |
Total number of peers |
Indicates the number of peers. |
Peers in established state |
Indicates the number of peers in established state. |
Peer |
Indicates the IP address of the peer. |
V |
Indicates the BGP version used on the peer. |
AS |
Indicates the AS number. |
MsgRcvd |
Indicates the number of received messages. |
MsgSent |
Indicates the number of sent messages. |
OutQ |
Indicates the message to be sent to the specified peer. |
Up/Down |
Indicates the period of time during which a BGP session keeps the current state. |
State |
Status of the peer:
|
PrefRcv |
Indicates the number of route prefixes sent from the peer. |
# Display detailed information about the peer 10.2.2.9.
<HUAWEI> display bgp peer 10.2.2.9 verbose BGP Peer is 10.2.2.9, remote AS 100 Type: IBGP link BGP version 4, Remote router ID 10.1.1.1 Update-group ID: 1 BGP current state: Established, Up for 00h57m53s BGP current event: RecvKeepalive BGP last state: Established BGP Peer Up count: 1 Received total routes: 0 Received active routes total: 0 Received mac routes: 0 Advertised total routes: 2 Port: Local - 42796 Remote - 179 Configured: Connect-retry Time: 32 sec Configured: Min Hold Time: 0 sec Configured: Active Hold Time: 180 sec Keepalive Time:60 sec Received : Active Hold Time: 180 sec Negotiated: Active Hold Time: 180 sec Keepalive Time:60 sec Peer optional capabilities: Peer supports bgp multi-protocol extension Peer supports bgp route refresh capability Peer supports bgp 4-byte-as capability Address family IPv4 Unicast: advertised and received Received: Total messages 60 Update messages 1 Open messages 1 KeepAlive messages 58 Notification messages 0 Refresh messages 0 Sent: Total messages 61 Update messages 2 Open messages 1 KeepAlive messages 58 Notification messages 0 Refresh messages 0 Authentication type configured: None Last keepalive received: 2012/03/06 19:17:37 Last keepalive sent : 2012/03/06 19:17:37 Last update received: 2012/03/06 19:17:43 Last update sent : 2012/03/06 19:17:37 Minimum route advertisement interval is 15 seconds Optional capabilities: Route refresh capability has been enabled 4-byte-as capability has been enabled Listen-only has been configured Peer's BFD has been enabled Peer Preferred Value: 0 Routing policy configured: No routing policy is configured
Item |
Description |
---|---|
Type |
Indicates the BGP link type, which can be IBGP or EBGP. |
BGP version |
Indicates the BGP version. |
remote router ID |
Indicates the router ID of the peer. |
Update-group ID |
Indicates the ID of the update-group to which the peer belongs. |
BGP current state |
Current state of BGP:
|
BGP current event |
Indicates the current BGP event. |
BGP last state |
Indicates the last BGP status, which may be Idle, Connect, Active, OpenSent, OpenConfirm, or Established. |
BGP Peer Up count |
Indicates the flapping count of a BGP peer in a specified period of time. |
Received total routes |
Indicates the number of received route prefixes. |
Received active routes total |
Indicates the number of received active route prefixes. |
Received mac routes |
Number of MAC routes received. |
Advertised total routes |
Indicates the number of sent route prefixes. |
Port |
Indicates the port number.
|
Configured |
Indicates locally configured timers.
|
Received : Active Hold Time |
Indicates the hold time on the peer. |
Negotiated : Active Hold Time |
Indicates the hold time agreed between the BGP peers after capability negotiation. |
Address family IPv4 Unicast |
Indicates the IPv4 unicast address family. |
Received |
Indicates the number of packets received from a peer.
|
Sent |
Indicates the number of messages sent to a peer.
|
Authentication type configured |
Indicates the authentication type configured. |
Last keepalive received |
Indicates the time when the Keepalive packet is received
last time. It can be in the following formats:
|
Last keepalive sent |
Indicates the time when the Keepalive packet is sent last
time. It can be in the following formats:
|
Last update received |
Indicates the time when the Update packet is received last
time. It can be in the following formats:
|
Last update sent |
Indicates the time when the Update packet is sent last time.
It can be in the following formats:
|
Minimum route advertisement interval is 15 seconds |
Indicates the minimum interval between route advertisements.
|
Optional capabilities |
(Optional) Indicates the peer-supported capabilities. |
Route refresh capability has been enabled |
Indicates that route refreshing has been enabled. |
4-byte-as capability has been enabled |
Indicates that the 4-byte AS number capability is enabled. |
Listen-only has been configured |
Indicates that only connection requests are snooped and no connections will be initiated proactively. |
Peer Preferred Value |
Indicates the preferred value of the peer. |
Routing policy configured |
Indicates the configured routing policy. |
Peer's BFD has been enabled |
Indicates that BFP has been enabled on the peer. |
<HUAWEI> display bgp peer 10.1.1.2 log-info
Peer : 10.1.1.2
Date/Time : 2011/13/06 11:53:21
State : Up
Date/Time : 2011/13/06 11:53:09
State : Down
Error Code : 6(CEASE)
Error Subcode : 4(Administrative Reset)
Notification : Receive Notification
Date/Time : 2011/13/06 10:34:05
State : Up
Item |
Description |
---|---|
Error Code |
Error code. |
Error Subcode |
Error subcode. |
Notification |
Notification packet sent or received by a peer. |
# Display information about the BGP peer of the VPN instance vrf1.
<HUAWEI> display bgp vpnv4 vpn-instance vrf1 peer BGP local router ID : 10.1.1.9 Local AS number : 100 VPN-Instance vrf1, router ID 10.1.1.1: Total number of peers : 1 Peers in established state : 1 Peer V AS MsgRcvd MsgSent OutQ Up/Down State PrefRcv 10.1.1.1 4 65410 207 192 0 02:59:49 Established 1
# Display detailed information about the BGP peer of the VPN instance vpna.
<HUAWEI> display bgp vpnv4 vpn-instance vpna peer verbose BGP Peer is 10.1.1.1, remote AS 200 Type: EBGP link BGP version 4, remote router ID 10.1.1.1 Update-group ID: 1 BGP current state: Established, Up for 03h01m22s BGP current event: RecvKeepalive BGP last state: OpenConfirm BGP Peer Up count: 1 Received total routes: 0 Received active routes total: 0 Received mac routes: 0 Advertised total routes: 3 Port: Local - 3722 Remote - 179 Configured: Connect-retry Time: 32 sec Configured: Min Hold Time: 0 sec Configured: Active Hold Time: 180 sec Keepalive Time:60 sec Received : Active Hold Time: 180 sec Negotiated: Active Hold Time: 180 sec Peer optional capabilities: Peer supports bgp multi-protocol extension Peer supports bgp route refresh capability Peer supports bgp 4-byte-as capability Address family IPv4 Unicast: advertised and received Received: Total 76 messages Update messages 0 Open messages 5 KeepAlive messages 71 Notification messages 0 Refresh messages 0 Sent: Total 91 messages Update messages 0 Open messages 10 KeepAlive messages 77 Notification messages 4 Refresh messages 0 Authentication type configured: None Last keepalive received: 2012/03/06 19:17:37 Last keepalive sent : 2012/03/06 19:17:37 Last update received: 2012/03/06 19:17:43 Last update sent : 2012/03/06 19:17:37 Maximum allowed prefix number: 150000 Threshold: 75% Minimum route advertisement interval is 30 seconds Optional capabilities: Route refresh capability has been enabled 4-byte-as capability has been enabled Peer Preferred Value: 0 Routing policy configured: No routing policy is configured
# Display information about IPv6 peers.
<HUAWEI> display bgp ipv6 peer
BGP Local router ID : 10.0.0.1
local AS number : 100
Total number of peers : 1 Peers in established state : 1
Peer V AS MsgRcvd MsgSent OutQ Up/Down State PrefRcv
FC00:0:0:20::21 4 200 17 19 0 00:09:59 Established 3
# Display information about IPv6 peers.
<HUAWEI> display bgp ipv6 peer fc00:0:0:2001::1 verbose BGP Peer is FC00:0:0:2001::1, remote AS 1 Type: EBGP link BGP version 4, remote router ID 10.1.1.1 Update-group ID: 1 BGP current state: Established, Up for 00h00m59s BGP current event: RecvKeepalive BGP last state: OpenConfirm BGP Peer Up count: 2 Received total routes: 0 Received active routes total: 0 Received mac routes: 0 Advertised total routes: 0 Port: Local - 179 Remote - 49153 Configured: Connect-retry Time: 32 sec Configured: Min Hold Time: 0 sec Configured: Active Hold Time: 180 sec Keepalive Time:60 sec Received : Active Hold Time: 180 sec Negotiated: Active Hold Time: 180 sec Keepalive Time:60 sec Peer optional capabilities: Peer supports bgp multi-protocol extension Peer supports bgp route refresh capability Peer supports bgp 4-byte-as capability Address family IPv6 Unicast: advertised and received Received: Total 76 messages Update messages 0 Open messages 5 KeepAlive messages 71 Notification messages 0 Refresh messages 0 Sent: Total 91 messages Update messages 0 Open messages 10 KeepAlive messages 77 Notification messages 4 Refresh messages 0 Authentication type configured: None Last keepalive received: 2012/03/06 19:17:37 Last keepalive sent : 2012/03/06 19:17:37 Last update received: 2012/03/06 19:17:43 Last update sent : 2012/03/06 19:17:37 Minimum route advertisement interval is 30 seconds Optional capabilities: Route refresh capability has been enabled 4-byte-as capability has been enabled listen-only has been configured Peer Preferred Value: 0 Routing policy configured: No routing policy is configured
# Display brief information about a VPNv6 peer.
<HUAWEI> display bgp vpnv6 all peer
BGP local router ID : 10.1.1.1
Local AS number : 100
Total number of peers : 2 Peers in established state : 2
Peer V AS MsgRcvd MsgSent OutQ Up/Down State PrefRcv
10.2.2.2 4 100 210 220 0 02:42:55 Established 1
Peer of IPv6-family for vpn instance :
VPN-Instance vpn1, Router ID 10.4.4.4 :
FC00:0:0:200::2 4 65410 205 178 0 02:42:53 Established 0
# Display detailed information about the VPNv6 peer whose IPv4 address is 10.2.2.2.
<HUAWEI> display bgp vpnv6 all peer 10.2.2.2 verbose BGP Peer is 10.2.2.2, remote AS 200, Type: IBGP link BGP version 4, remote router ID 10.2.2.2 Group ID : 0 Peer Local Interface Name: Vlanif10 Local Ifnet Tunnel: 0xb0010000 BGP current state: Established, Up for 02h43m52s BGP current event: RecvKeepalive BGP last state: OpenConfirm BGP Peer Up count: 2 Received total routes: 0 Received active routes total: 0 Received mac routes: 0 Advertised total routes: 0 Port: Local - 53308 Remote - 179 Configured: Connect-retry Time: 32 sec Configured: Min Hold Time: 0 sec Configured: Active Hold Time: 180 sec Keepalive Time:60 sec Received : Active Hold Time: 180 sec Negotiated: Active Hold Time: 180 sec Keepalive Time:60 sec Peer optional capabilities: Peer supports bgp multi-protocol extension Peer supports bgp route refresh capability Peer supports bgp 4-byte-as capability Address family IPv4 Unicast: advertised and received Address family VPNv6: advertised and received Received: Total 76 messages Update messages 0 Open messages 5 KeepAlive messages 71 Notification messages 0 Refresh messages 0 Sent: Total 91 messages Update messages 0 Open messages 10 KeepAlive messages 77 Notification messages 4 Refresh messages 0 Last keepalive received: 2009-09-30 09:52:41 Minimum route advertisement interval is 15 seconds Optional capabilities: Route refresh capability has been enabled 4-byte-as capability has been enabled Connect-interface has been configured Peer Preferred Value: 0 Routing policy configured: No routing policy is configured
# Display detailed information about the BGP peer of an IPv6 address family-enabled VPN instance whose IPv6 address is FC00:0:0:2000::2.
<HUAWEI> display bgp vpnv6 vpn-instance vpn1 peer fc00:0:0:2000::2 verbose BGP Peer is FC00:0:0:2000::2, remote AS 65410, Type: EBGP link BGP version 4, remote router ID 10.1.1.1 Group ID : 0 Peer Local Interface Name: Vlanif10 Local Ifnet Tunnel: 0xb0010000 BGP current state: Established, Up for 02h39m36s BGP current event: KATimerExpired BGP last state: OpenConfirm BGP Peer Up count: 2 Received total routes: 0 Received active routes total: 0 Received mac routes: 0 Advertised total routes: 0 Port: Local - 49177 Remote - 179 Configured: Connect-retry Time: 32 sec Configured: Min Hold Time: 0 sec Configured: Active Hold Time: 180 sec Keepalive Time:60 sec Received : Active Hold Time: 180 sec Negotiated: Active Hold Time: 180 sec Keepalive Time:60 sec Peer optional capabilities: Peer supports bgp multi-protocol extension Peer supports bgp route refresh capability Peer supports bgp 4-byte-as capability Address family IPv6 Unicast: advertised and received Received: Total 76 messages Update messages 0 Open messages 5 KeepAlive messages 71 Notification messages 0 Refresh messages 0 Sent: Total 91 messages Update messages 0 Open messages 10 KeepAlive messages 77 Notification messages 4 Refresh messages 0 Last keepalive received: 2009-09-30 09:51:52 Minimum route advertisement interval is 30 seconds Optional capabilities: Route refresh capability has been enabled 4-byte-as capability has been enabled Peer Preferred Value: 0 Routing policy configured: No routing policy is configured