mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
177 lines
5.3 KiB
Plaintext
177 lines
5.3 KiB
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * networking/metallb/metallb-troubleshoot-support.adoc
|
|
|
|
:_mod-docs-content-type: PROCEDURE
|
|
[id="nw-metallb-troubleshoot-bgp_{context}"]
|
|
= Troubleshooting BGP issues
|
|
|
|
[role="_abstract"]
|
|
To diagnose and resolve BGP configuration issues, execute commands directly within the FRR container. By accessing the container, you can verify routing states and identify connectivity errors.
|
|
|
|
.Prerequisites
|
|
|
|
* You have access to the cluster as a user with the `cluster-admin` role.
|
|
* You have installed the {oc-first}.
|
|
|
|
.Procedure
|
|
|
|
. Display the names of the `frr-k8s` pods by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc -n metallb-system get pods -l component=frr-k8s
|
|
----
|
|
+
|
|
.Example output
|
|
[source,text]
|
|
----
|
|
NAME READY STATUS RESTARTS AGE
|
|
frr-k8s-thsmw 6/6 Running 0 109m
|
|
----
|
|
|
|
. Display the running configuration for FRR by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc exec -n metallb-system frr-k8s-thsmw -c frr -- vtysh -c "show running-config"
|
|
----
|
|
+
|
|
.Example output
|
|
----
|
|
Building configuration...
|
|
|
|
Current configuration:
|
|
!
|
|
frr version 8.5.3
|
|
frr defaults traditional
|
|
hostname some-hostname
|
|
log file /etc/frr/frr.log informational
|
|
log timestamp precision 3
|
|
no ip forwarding
|
|
no ipv6 forwarding
|
|
service integrated-vtysh-config
|
|
!
|
|
router bgp 64500
|
|
bgp router-id 10.0.1.2
|
|
no bgp ebgp-requires-policy
|
|
no bgp default ipv4-unicast
|
|
no bgp network import-check
|
|
neighbor 10.0.2.3 remote-as 64500
|
|
neighbor 10.0.2.3 bfd profile doc-example-bfd-profile-full
|
|
neighbor 10.0.2.3 timers 5 15
|
|
neighbor 10.0.2.4 remote-as 64500
|
|
neighbor 10.0.2.4 bfd profile doc-example-bfd-profile-full
|
|
neighbor 10.0.2.4 timers 5 15
|
|
!
|
|
address-family ipv4 unicast
|
|
network 203.0.113.200/30
|
|
neighbor 10.0.2.3 activate
|
|
neighbor 10.0.2.3 route-map 10.0.2.3-in in
|
|
neighbor 10.0.2.4 activate
|
|
neighbor 10.0.2.4 route-map 10.0.2.4-in in
|
|
exit-address-family
|
|
!
|
|
address-family ipv6 unicast
|
|
network fc00:f853:ccd:e799::/124
|
|
neighbor 10.0.2.3 activate
|
|
neighbor 10.0.2.3 route-map 10.0.2.3-in in
|
|
neighbor 10.0.2.4 activate
|
|
neighbor 10.0.2.4 route-map 10.0.2.4-in in
|
|
exit-address-family
|
|
!
|
|
route-map 10.0.2.3-in deny 20
|
|
!
|
|
route-map 10.0.2.4-in deny 20
|
|
!
|
|
ip nht resolve-via-default
|
|
!
|
|
ipv6 nht resolve-via-default
|
|
!
|
|
line vty
|
|
!
|
|
bfd
|
|
profile doc-example-bfd-profile-full
|
|
transmit-interval 35
|
|
receive-interval 35
|
|
passive-mode
|
|
echo-mode
|
|
echo-interval 35
|
|
minimum-ttl 10
|
|
!
|
|
!
|
|
end
|
|
----
|
|
+
|
|
where:
|
|
+
|
|
`router bgp 64500`:: Specifies the `router bgp` that indicates the ASN for MetalLB.
|
|
`neighbor 10.0.2.3 remote-as 64500`:: Specifies that a `neighbor <ip-address> remote-as <peer-ASN>` line exists for each BGP peer custom resource that you added.
|
|
`bfd profile doc-example-bfd-profile-full`:: Specifies that the BFD profile is associated with the correct BGP peer and that the BFD profile shows in the command output.
|
|
`network 203.0.113.200/30`:: Specifies that the `network <ip-address-range>` lines match the IP address ranges that you specified in address pool custom resources
|
|
|
|
. Display the BGP summary by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc exec -n metallb-system frr-k8s-thsmw -c frr -- vtysh -c "show bgp summary"
|
|
----
|
|
+
|
|
.Example output
|
|
----
|
|
IPv4 Unicast Summary:
|
|
BGP router identifier 10.0.1.2, local AS number 64500 vrf-id 0
|
|
BGP table version 1
|
|
RIB entries 1, using 192 bytes of memory
|
|
Peers 2, using 29 KiB of memory
|
|
|
|
Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd PfxSnt
|
|
10.0.2.3 4 64500 387 389 0 0 0 00:32:02 0 1
|
|
10.0.2.4 4 64500 0 0 0 0 0 never Active 0
|
|
|
|
Total number of neighbors 2
|
|
|
|
IPv6 Unicast Summary:
|
|
BGP router identifier 10.0.1.2, local AS number 64500 vrf-id 0
|
|
BGP table version 1
|
|
RIB entries 1, using 192 bytes of memory
|
|
Peers 2, using 29 KiB of memory
|
|
|
|
Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd PfxSnt
|
|
10.0.2.3 4 64500 387 389 0 0 0 00:32:02 NoNeg
|
|
10.0.2.4 4 64500 0 0 0 0 0 never Active 0
|
|
|
|
Total number of neighbors 2
|
|
----
|
|
+
|
|
where:
|
|
+
|
|
`10.0.2.3`:: Specifies that the output includes a line for each BGP peer custom resource that you added.
|
|
`10.0.2.4`:: Specifies that the output shows `0` messages received and `0` messages sent, which indicates a BGP peer that does not have a BGP session. Check network connectivity and the BGP configuration of the BGP peer.
|
|
|
|
. Display the BGP peers that received an address pool by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc exec -n metallb-system frr-k8s-thsmw -c frr -- vtysh -c "show bgp ipv4 unicast 203.0.113.200/30"
|
|
----
|
|
+
|
|
Replace `ipv4` with `ipv6` to display the BGP peers that received an IPv6 address pool.
|
|
Replace `203.0.113.200/30` with an IPv4 or IPv6 IP address range from an address pool.
|
|
+
|
|
.Example output
|
|
----
|
|
BGP routing table entry for 203.0.113.200/30
|
|
Paths: (1 available, best #1, table default)
|
|
Advertised to non peer-group peers:
|
|
10.0.2.3
|
|
Local
|
|
0.0.0.0 from 0.0.0.0 (10.0.1.2)
|
|
Origin IGP, metric 0, weight 32768, valid, sourced, local, best (First path received)
|
|
Last update: Mon Jan 10 19:49:07 2022
|
|
----
|
|
+
|
|
where:
|
|
+
|
|
`10.0.2.3`:: Specifies that the output includes an IP address for a BGP peer.
|