Files
Blanton_TTL_Script/src/Script_ABC_Blanton/config.ttl
T
etwenandClaude Opus 5 9cdd651d79 feat(ttl): Run the CPU stress as a systemd unit, and add two config knobs
mlucas-avx2 was backgrounded with '&' in the login shell, so it belonged
to that one terminal. Close Tera Term, drop the console, or reconnect on
a different session and the load was gone - and 'jobs' from the new
session showed nothing to say so. A multi-day soak could spend most of
its length with an idle CPU while the thermal numbers looked fine.

Script B now starts it as a transient unit:

  systemd-run --unit=mlucas-amm --property=Type=exec \
    --property=Restart=always --property=RestartSec=2 ...

The log is truncated once with '>' before the unit starts and appended
with '>>' inside it, so a restart adds to the run instead of erasing it.
'systemctl is-active mlucas-amm' now sits beside 'jobs', both in the
one-shot check and in every pass of the monitor loop. The old '&' line is
kept commented out above the new one to fall back to.

Script C has the matching stop. utils/kill_all_process.ttl is only
"kill $(jobs -p)" and a systemd unit is not a shell job, so without this
the load would have run through the post-test snapshot and into the next
test - every temperature and power reading taken at full load, with
nothing in 'show interfaces status' to reveal it. mlucas_amm_log is
copied to /host/hw-eval/jobs/ with the other stress logs.

Two values move into config.ttl:

  EN_timestamp      feeds logopen's 5th argument in Script A, so the
                    per-line timestamp is a knob rather than a literal 1
  BMC_USB_RUNTIME   feeds Script B's ping unit; it was hard-coded to
                    -w 14400 (4 h), which no longer matched the soak
                    lengths the SSD and USB knobs were being set to

SSD_RUNTIME and USB_RUNTIME also go 600 -> 3600, so the shipped default
is a one hour stress rather than the ten minutes V1.1.7 went out with.
--runtime is still the job's overall limit; COUNT does not multiply it.

Script A's Version History carries the V1.1.8 entries for all of this.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014RetWKFZFG1ZHcitQAyhwM
2026-09-06 17:21:52 +08:00

35 lines
1.6 KiB
Turtle

;================================================================
; User Configuration
;================================================================
project_name = "Blanton"
strTestcase="ENV" ;ENV,EMC,Margin...etc
EN_Margin = 0 ; 1: Enable Margin Test, 0: Disable Margin Test
EN_log = 1 ; 1: Enable log, 0: Disable log
EN_timestamp = 1 ; 1: Enable timestamp in log, 0: Disable timestamp in log
;================================================================
; FAN_SPEED
;================================================================
FAN_SPEED = 100
;================================================================
; Switch Unit Population
;================================================================
SWB_UNIT0 = 1 ; 1 = this DUT has switch unit 0, wait for it ; 0 = skip
SWB_UNIT1 = 1 ; 1 = this DUT has switch unit 1, wait for it ; 0 = skip
;================================================================
; Stress_Test
;================================================================
SSD_RUNTIME = 3600 ; Unit seconds, 3600 = 1 hour
SSD_COUNT = 240 ; Total time = SSD_RUNTIME * SSD_COUNT
USB_RUNTIME = 3600 ; Unit seconds, 3600 = 1 hour
USB_COUNT = 240 ; Total time = USB_RUNTIME * USB_COUNT
BMC_USB_RUNTIME = 172800 ; Unit seconds, 172800 = 2 days
;================================================================
; Prompt Definitions
;================================================================
prompt_login = "sonic login:"
prompt_sonic = "admin@sonic:~$"
prompt_sonic_root = "root@sonic:~#"