sonic-net / sonic-swss

SONiC Switch State Service (SwSS)
https://azure.github.io/SONiC
Other
170 stars 503 forks source link

[portsorch] Make exception handling when Remove Bridge fails #3211

Open inspurSDN opened 1 month ago

inspurSDN commented 1 month ago

Why I did it Add static mac 00:00:00:01:01:01 to Ethernet1 (Vlan 100 member) and remove Ethernet1 from Vlan 100, then orchagent process would crash

Jun 28 05:35:41.148167 DUT-1 ERR swss#orchagent: :- meta_generic_validation_remove: object 0x3a000000000a97 reference count is 1, can't remove Jun 28 05:35:41.148167 DUT-1 ERR swss#orchagent: :- removeBridgePort: Failed to remove bridge port Ethernet1 from default 1Q bridge, rv:-17 Jun 28 05:35:41.148174 DUT-1 ERR swss#orchagent: :- handleSaiRemoveStatus: Encountered failure in remove operation, exiting orchagent, SAI API: SAI_API_BRIDGE, status: SAI_STATUS_OBJECT_IN_USE Jun 28 05:35:42.586693 DUT-1 ERR swss#supervisor-proc-exit-listener: orchagent process crash in swss container

What I did Make exception handling when Remove Bridge fails, still let it sync, but try to delete BridgePort again when vlanMember has been deleted.

What I did

Why I did it

How I verified it

Details if related

prsunny commented 1 month ago

Can you fix coverage?

inspurSDN commented 1 month ago

@prsunny unitest or dvs ok?

inspurSDN commented 1 month ago

@prsunny can you give some advice for Coverage ?