sonic-net / sonic-buildimage

Scripts which perform an installable binary image build for SONiC
Other
735 stars 1.42k forks source link

Defining a SAG setup on an ISP connected route/switch breaks Uplink BGP peer settings #13676

Open delandtj opened 1 year ago

delandtj commented 1 year ago

Description

When following a SAG setup from EdgeCore, https://support.edge-core.com/hc/en-us/articles/6840823990169--Edgecore-SONiC-SAG-static-anycast-gateway- , the procedure installs a route-map

route-map RM_SET_SRC permit 10
set src 10.0.0.1
exit
!
ip protocol bgp route-map RM_SET_SRC

that source ip also gets set on the interface to the ISP peer , which breaks connectivity to the Upstream

SoNiC-02-PROD# show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP,
O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP,
T - Table, v - VNC, V - VNC-Direct, A - Babel, F - PBR,
f - OpenFabric,
> - selected route, * - FIB route, q - queued, r - rejected, b - backup
t - trapped, o - offload failure

B   0.0.0.0/0 [20/0] via 123.234.66.154, Ethernet1 inactive, weight 1, 00:53:36
B   10.0.0.1/32 [200/0] via fe80::9a19:2cff:fe3f:8f58, Vlan3 inactive, weight 1, 00:53:17
C>* 10.0.0.2/32 is directly connected, Loopback0, 00:54:10
C>* 123.234.66.152/30 is directly connected, Ethernet1, 00:53:37
C>* 192.168.255.0/24 is directly connected, Vlan2, 00:53:17

this yields a default routing table:

default via 123.234.66.154 dev Ethernet1 proto bgp src 10.0.0.2 metric 20
10.0.0.1 via 169.254.0.1 dev Vlan3 proto bgp src 10.0.0.2 metric 20 onlink
123.234.66.152/30 dev Ethernet1 proto kernel scope link src 188.64.78.153
192.168.255.0/24 dev Vlan2 proto kernel scope link src 192.168.255.2
240.127.1.0/24 dev docker0 proto kernel scope link src 240.127.1.1 linkdown

Steps to reproduce the issue:

  1. setup a bgp peering with a remote AS as default gateway
  2. follow https://support.edge-core.com/hc/en-us/articles/6840823990169--Edgecore-SONiC-SAG-static-anycast-gateway-
  3. verify peer route with ISP (it's source address has become the SAG Loopback address)

Describe the results you expected:

Don't change my uplink source address maybe ? ;-)

Output of show version:

root@SoNiC-01-PROD:~# show version

SONiC Software Version: SONiC.Edgecore-SONiC_20221117_052015_ec202111_245
Distribution: Debian 11.5
Kernel: 5.10.0-8-2-amd64
Build commit: b3225170d
Build date: Thu Nov 17 06:19:13 UTC 2022
Built by: ubuntu@ip-10-5-1-155

Platform: x86_64-accton_as5835_54x-r0
HwSKU: Accton-AS5835-54X
ASIC: broadcom
ASIC Count: 1
Serial Number: 583554X2140066
Model Number: FP1ZZ56540B7A
Hardware Revision: N/A
Uptime: 11:00:14 up 2 days, 13:53,  1 user,  load average: 3.37, 2.83, 2.70

Docker images:
REPOSITORY                    TAG                                           IMAGE ID       SIZE
docker-syncd-brcm             Edgecore-SONiC_20221117_052015_ec202111_245   be26205e9c43   656MB
docker-syncd-brcm             latest                                        be26205e9c43   656MB
docker-fpm-frr                Edgecore-SONiC_20221117_052015_ec202111_245   85400455d252   497MB
docker-fpm-frr                latest                                        85400455d252   497MB
docker-teamd                  Edgecore-SONiC_20221117_052015_ec202111_245   0808e577bf45   467MB
docker-teamd                  latest                                        0808e577bf45   467MB
docker-stp                    Edgecore-SONiC_20221117_052015_ec202111_245   4855f6267c47   482MB
docker-stp                    latest                                        4855f6267c47   482MB
docker-platform-monitor       Edgecore-SONiC_20221117_052015_ec202111_245   71ce22e0a9f2   679MB
docker-platform-monitor       latest                                        71ce22e0a9f2   679MB
docker-sflow                  Edgecore-SONiC_20221117_052015_ec202111_245   45ccdd476630   468MB
docker-sflow                  latest                                        45ccdd476630   468MB
docker-orchagent              Edgecore-SONiC_20221117_052015_ec202111_245   9cfe6b202709   489MB
docker-orchagent              latest                                        9cfe6b202709   489MB
docker-nat                    Edgecore-SONiC_20221117_052015_ec202111_245   1156ba5dfcc1   470MB
docker-nat                    latest                                        1156ba5dfcc1   470MB
docker-macsec                 Edgecore-SONiC_20221117_052015_ec202111_245   4b6008db84c3   470MB
docker-macsec                 latest                                        4b6008db84c3   470MB
docker-iccpd                  Edgecore-SONiC_20221117_052015_ec202111_245   aa412431de61   471MB
docker-iccpd                  latest                                        aa412431de61   471MB
docker-snmp                   Edgecore-SONiC_20221117_052015_ec202111_245   26e60029594d   495MB
docker-snmp                   latest                                        26e60029594d   495MB
docker-sonic-p4rt             Edgecore-SONiC_20221117_052015_ec202111_245   fe209ceda8f0   526MB
docker-sonic-p4rt             latest                                        fe209ceda8f0   526MB
docker-dhcp-relay             latest                                        2646690c7f07   441MB
docker-sonic-telemetry        Edgecore-SONiC_20221117_052015_ec202111_245   1ac3e84be311   514MB
docker-sonic-telemetry        latest                                        1ac3e84be311   514MB
docker-sonic-mgmt-framework   Edgecore-SONiC_20221117_052015_ec202111_245   c3654fdf6616   708MB
docker-sonic-mgmt-framework   latest                                        c3654fdf6616   708MB
docker-router-advertiser      Edgecore-SONiC_20221117_052015_ec202111_245   5647620e21d2   428MB
docker-router-advertiser      latest                                        5647620e21d2   428MB
docker-mux                    Edgecore-SONiC_20221117_052015_ec202111_245   f8d965fe9626   480MB
docker-mux                    latest                                        f8d965fe9626   480MB
docker-lldp                   Edgecore-SONiC_20221117_052015_ec202111_245   3709e334e7d1   468MB
docker-lldp                   latest                                        3709e334e7d1   468MB
docker-gbsyncd-credo          Edgecore-SONiC_20221117_052015_ec202111_245   7241a3386320   482MB
docker-gbsyncd-credo          latest                                        7241a3386320   482MB
docker-database               Edgecore-SONiC_20221117_052015_ec202111_245   99c3b9b11c50   428MB
docker-database               latest                                        99c3b9b11c50   428MB
k8s.gcr.io/pause              3.4.1                                         0f8457a4c2ec   683kB

Output of show techsupport:

(paste your output here or download and attach the file here )

Additional information you deem important (e.g. issue happens only occasionally):

arlakshm commented 1 year ago

SAG is not supported in the community SONiC. Edgecore to handle this.

dulitz commented 1 year ago

@delandtj is this issue still present? do you know which part of the procedure is installing that route-map?