From 1224f6968bddf6ab16aa1814f7e447f9c6cc6bf3 Mon Sep 17 00:00:00 2001 From: Vicente Cheng Date: Thu, 13 Jun 2024 11:06:15 +0800 Subject: [PATCH] harvester-collector: move supportconfig to scc folder instead logs Signed-off-by: Vicente Cheng --- hack/collector-harvester | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/hack/collector-harvester b/hack/collector-harvester index aef5140d..afec64c1 100755 --- a/hack/collector-harvester +++ b/hack/collector-harvester @@ -86,13 +86,18 @@ collect_etc ${BUNDLE_DIR}/configs/etc ############################################################################### # collect logs ############################################################################### -mkdir -p logs -cd logs +mkdir -p scc # Generate supportconfig from node chroot $HOST_PATH /sbin/supportconfig -c -m -B supportconfig_$SUPPORT_BUNDLE_NODE_NAME \ -i BOOT,DAEMONS,ETC,ISCSI,MEM,MOD,NTP,SMART,DISK,pharvester_plugin_rke2,pharvester_plugin_console -mv $HOST_PATH/var/log/scc_supportconfig_$SUPPORT_BUNDLE_NODE_NAME.txz . +mv $HOST_PATH/var/log/scc_supportconfig_$SUPPORT_BUNDLE_NODE_NAME.txz ./scc + +############################################################################### +# collect logs +############################################################################### +mkdir -p logs +cd logs chroot $HOST_PATH /usr/bin/journalctl -k > kernel.log # also collect logs of previous two boots