sonic-net / sonic-buildimage

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

Dangling VRFs in STATE_DB #8739

Open chaichairiko opened 3 years ago

chaichairiko commented 3 years ago

Description

VERSION: 202012

STATE_DB holds a reference to a VRF that no longer exists:

redis-cli -n 6 keys "VRF_OBJECT_TABLE|*"
1) "VRF_OBJECT_TABLE|Vrf-Two"
2) "VRF_OBJECT_TABLE|Vrf-One"

Show Command

show vrf
VRF      Interfaces
-------  ------------
Vrf-One  Vlan210
         Vlan110

Linux also has no recollection of this:

show ip route vrf all
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, D - SHARP,
       F - PBR, f - OpenFabric,
       > - selected route, * - FIB route, q - queued, r - rejected, b - backup

VRF Vrf-One:
C>* 11.0.0.0/24 is directly connected, Vlan110, 14:48:20
C>* 21.0.0.0/24 is directly connected, Vlan210, 14:48:18

VRF default:
K>* 0.0.0.0/0 [0/202] via 192.168.10.1, eth0, 14:50:10
C>* 10.0.0.0/29 is directly connected, eth1, 14:50:04
C>* 192.168.10.0/23 is directly connected, eth0, 14:50:10

Steps to reproduce the issue:

(This issue happens occasionally, so not exactly sure of the exact commands)

  1. Add VRFs
  2. config reload -y

Describe the results you received:

Describe the results you expected:

prsunny commented 2 years ago

We may want to fix the table name here . Can you please check if it helps?