Commit 7d9ec5d
authored
Fix issue that namespace is not correctly fetched in Multi ASIC environment for mirror capability checking (#4159)
- What I did
Fix issue sonic-net/sonic-mgmt#21690
- How I did it
The logic to check the mirror capability is:
orchagent exposes capability to SWITCH_CAPABILITY table in STATE_DB during initialization
CLI (config mirror) fetches capability from the table when a CLI command is issued by a user.
On the multi ASIC environment, the table is in ASIC's namespace. But the CLI command fetches the capability from the host. As a result it always treats mirror is unsupported and fails the test.
Fixed by checking the mirror capability from the namespaces based on source and destination ports.
- How to verify it
Manual test.
Signed-off-by: Stephen Sun <[email protected]>1 parent f473b4f commit 7d9ec5d
1 file changed
+13
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1179 | 1179 | | |
1180 | 1180 | | |
1181 | 1181 | | |
| 1182 | + | |
| 1183 | + | |
| 1184 | + | |
| 1185 | + | |
1182 | 1186 | | |
1183 | 1187 | | |
1184 | 1188 | | |
| |||
1195 | 1199 | | |
1196 | 1200 | | |
1197 | 1201 | | |
| 1202 | + | |
| 1203 | + | |
1198 | 1204 | | |
1199 | 1205 | | |
1200 | 1206 | | |
1201 | 1207 | | |
1202 | 1208 | | |
1203 | 1209 | | |
1204 | 1210 | | |
| 1211 | + | |
| 1212 | + | |
1205 | 1213 | | |
1206 | 1214 | | |
1207 | 1215 | | |
| |||
1211 | 1219 | | |
1212 | 1220 | | |
1213 | 1221 | | |
1214 | | - | |
1215 | | - | |
1216 | | - | |
| 1222 | + | |
| 1223 | + | |
| 1224 | + | |
| 1225 | + | |
| 1226 | + | |
1217 | 1227 | | |
1218 | 1228 | | |
1219 | 1229 | | |
| |||
0 commit comments