Merge "Avoid timeout in capture-system-logs due to df command"

This commit is contained in:
Zuul
2025-11-08 02:34:08 +00:00
committed by Gerrit Code Review
2 changed files with 8 additions and 1 deletions
+1
View File
@@ -456,6 +456,7 @@
/etc/sudoers.d: logs
'{{ stage_dir }}/iptables.txt': logs
'{{ stage_dir }}/df.txt': logs
'{{ stage_dir }}/mount.txt': logs
'{{ stage_dir }}/pip2-freeze.txt': logs
'{{ stage_dir }}/pip3-freeze.txt': logs
'{{ stage_dir }}/dpkg-l.txt': logs
+7 -1
View File
@@ -4,7 +4,13 @@
executable: /bin/bash
cmd: |
sudo iptables-save > {{ stage_dir }}/iptables.txt
df -h > {{ stage_dir }}/df.txt
# NOTE(sfernand): Run 'df' with a 60s timeout to prevent hangs from
# stale NFS mounts.
timeout -s 9 60s df -h > {{ stage_dir }}/df.txt || true
# If 'df' times out, the mount output helps debug which NFS share
# is unresponsive.
mount > {{ stage_dir }}/mount.txt
for py_ver in 2 3; do
if [[ `which python${py_ver}` ]]; then