Skip to content

Preserve per-ASIC subdirectory structure for sdk_dbg collection#4334

Open
william8545 wants to merge 1 commit intosonic-net:masterfrom
william8545:generate-dump-per-asic-sdk-dbg-public
Open

Preserve per-ASIC subdirectory structure for sdk_dbg collection#4334
william8545 wants to merge 1 commit intosonic-net:masterfrom
william8545:generate-dump-per-asic-sdk-dbg-public

Conversation

@william8545
Copy link

What I did

Fixed generate_dump to preserve per-ASIC subdirectory structure when collecting sdk_dbg files into techsupport dumps.

How I did it

Extract the relative subdirectory from each file's path under /var/log/sdk_dbg/ and use it as part of the dump destination (e.g., sai_sdk_dump/0/, sai_sdk_dump/1/), instead of saving all files flat into sai_sdk_dump/. This avoids basename collisions when multiple ASICs produce files with the same timestamp. Single-ASIC systems are unaffected.

How to verify it

  1. Extract the dump and verify sai_sdk_dump/ contains per-ASIC subdirectories (0/, 1/, etc.) with each ASIC's pcap files preserved separately.
  2. On a single-ASIC switch, verify sai_sdk_dump/ remains flat with no regressions.

Previous command output (if the output of a command-line utility has changed)

New command output (if the output of a command-line utility has changed)

…_dbg collection

Signed-off-by: William Tsai <willtsai@nvidia.com>
@mssonicbld
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants