2ae5baf552
This adds an SVG plot with stats from the startup of the system. Test Plan: PASS: AIO-SX, AIO-DX, DC with AIO-SX subcloud PASS: bashate PASS: Verify plot is in collect PASS: Verify plot is empty if collect is run before startup is done Story: 2010533 Task: 49983 Change-Id: I60e9538e66806e284458105f2bf36c8bfdb209e5 Signed-off-by: Joshua Kraitberg <joshua.kraitberg@windriver.com>
26 lines
709 B
Bash
26 lines
709 B
Bash
#! /bin/bash
|
|
#
|
|
# Copyright (c) 2024 Wind River Systems, Inc.
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
#
|
|
|
|
# Loads Up Utilities and Commands Variables
|
|
|
|
source /usr/local/sbin/collect_parms
|
|
source /usr/local/sbin/collect_utils
|
|
|
|
SERVICE="systemd"
|
|
LOGFILE="${extradir}/${SERVICE}.info"
|
|
PLOTFILE="${extradir}/${SERVICE}-startup-plot.svg"
|
|
|
|
###############################################################################
|
|
# Systemd analysis
|
|
###############################################################################
|
|
echo "${hostname}: Systemd analyze .........: ${LOGFILE}"
|
|
|
|
delimiter ${LOGFILE} "systemd-analyze plot > ${PLOTFILE}"
|
|
timeout 30 systemd-analyze plot > ${PLOTFILE} 2>>${COLLECT_ERROR_LOG}
|
|
|
|
exit 0
|