Skip to content

Commit

Permalink
Export GOTRACEBACK=crash env variable (#18559)
Browse files Browse the repository at this point in the history
### Why I did it

Improve visibility for telemetry crashes by allowing core to be dumped.

### How I did it

Export GOTRACEBACK=crash as an environment variable.

#### How to verify it

Manual test

1) Change telemetry binary to crash always, first line of telemetry.go main() -> panic("problem")
2) Add change to telemetry.sh
3) Restart telemetry
4) See core in /var/core
  • Loading branch information
zbud-msft authored and mssonicbld committed Sep 12, 2024
1 parent 1ca10c1 commit 7c4961d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions dockers/docker-sonic-telemetry/telemetry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ CERTS=$(echo $TELEMETRY_VARS | jq -r '.certs')

TELEMETRY_ARGS=" -logtostderr"
export CVL_SCHEMA_PATH=/usr/sbin/schema
export GOTRACEBACK=crash

if [ -n "$CERTS" ]; then
SERVER_CRT=$(echo $CERTS | jq -r '.server_crt')
Expand Down

0 comments on commit 7c4961d

Please sign in to comment.