gbmc-collect-logs: upload 1 most recent core
Instead of sending all the kdumps, we will just send 1 most recent cores
as the total size of the log bundle might be a concern.
Google-Bug-Id: 317372429
Change-Id: Ied102f429ae6f67e75adff05daf58e31f76ea4c2
Signed-off-by: Yuxiao Zhang <yuxiaozhang@google.com>
(cherry picked from commit 1c8f7dbcc823cf62f2cf4c026b8766c17701bfbd)
diff --git a/recipes-google/gbmc-collect-logs/files/gbmc-collect-logs b/recipes-google/gbmc-collect-logs/files/gbmc-collect-logs
index 6c92188..b553eeb 100644
--- a/recipes-google/gbmc-collect-logs/files/gbmc-collect-logs
+++ b/recipes-google/gbmc-collect-logs/files/gbmc-collect-logs
@@ -18,7 +18,7 @@
collect_journal $TMPDIR
-kdump_file_list=$(kdumpctl list-path)
+kdump_file_list=$(kdumpctl list-path | head -n 1)
# a workaround of writing tarball to stdout
tar -czO $TMPDIR/$journal_name $kdump_file_list | cat