From 623eb9e47d70919f58ac64eaaa8079c638c8100b Mon Sep 17 00:00:00 2001 From: Zhiyu Li Date: Sun, 8 Sep 2024 21:54:40 +0000 Subject: [PATCH] better core dump for debugging --- src/xpk/core/core.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/xpk/core/core.py b/src/xpk/core/core.py index 91db6298..cc1fdc32 100644 --- a/src/xpk/core/core.py +++ b/src/xpk/core/core.py @@ -2104,8 +2104,12 @@ def get_main_container(args, system, docker_image, resource_type) -> str: ' is required but not installed. Aborting"; exit 24;};' ) xpk_internal_commands += ( + 'set -x;' 'WORKER_ID=$HOSTNAME;' - f'gsutil -m cp -r /tmp/xla_dump/ {args.debug_dump_gcs}/$WORKER_ID;' + f'gcloud storage cp -r /tmp/xla_dump/ {args.debug_dump_gcs}/$WORKER_ID;' + f'gcloud storage cp /tmp/*.dump {args.debug_dump_gcs}/$WORKER_ID;' + f'gcloud storage cp -r /tmp/tpu_logs {args.debug_dump_gcs}/$WORKER_ID;' + 'sleep 120;' ) command = args.command