Boot Kpi Analyzer

v1.0.0

分析并定位SS4车机开关机关键性能指标,支持开机慢、关机慢等问题的时序数据自动化分析与报告生成。

0· 256·1 current·1 all-time

Install

OpenClaw Prompt Flow

Install with OpenClaw

Best for remote or guided setup. Copy the exact prompt, then paste it into OpenClaw for lichm1007/boot-kpi-analyzer.

Previewing Install & Setup.
Prompt PreviewInstall & Setup
Install the skill "Boot Kpi Analyzer" (lichm1007/boot-kpi-analyzer) from ClawHub.
Skill page: https://clawhub.ai/lichm1007/boot-kpi-analyzer
Keep the work scoped to this skill only.
After install, inspect the skill metadata and help me finish setup.
Use only the metadata you can verify from ClawHub; do not invent missing requirements.
Ask before making any broader environment changes.

Command Line

CLI Commands

Use the direct CLI path if you want to install manually and keep every step visible.

OpenClaw CLI

Canonical install target

openclaw skills install lichm1007/boot-kpi-analyzer

ClawHub CLI

Package manager switcher

npx clawhub@latest install boot-kpi-analyzer
Security Scan
VirusTotalVirusTotal
Benign
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
Name/description describe analysis of boot/shutdown KPI data; the included script and SKILL.md operate on the exact log directories and files described (boot_kpi.log, unit_kpi.log, shutdown-monitor-units.log, report.json). No unrelated services, credentials, or broad system access are requested.
Instruction Scope
Instructions explicitly require reading files under /home/lixiang/... and optionally curling a private IP (http://10.122.86.46:9999). This is consistent with the skill's purpose, but the instructions hardcode a specific user path and instruct the agent to run shell commands (python3 and curl), which means the agent will access local files and make network requests when invoked.
Install Mechanism
No install spec; the skill is instruction+script only. Nothing is downloaded or written to disk at install time beyond the normal skill files, which is the lowest-risk pattern.
Credentials
The skill declares no required environment variables or credentials. Its file- and network-access needs (local log dirs and a private web API) are proportionate to the stated log-analysis purpose.
Persistence & Privilege
always:false (default) and model invocation is enabled (default). Autonomous invocation is the platform default; since the skill reads local files and can run curl/python3, users should be aware an agent could execute these actions autonomously if allowed. There is no always:true or other elevated persistence requested.
Assessment
This skill appears to do exactly what it claims: parse log files under /home/lixiang/... and optionally query a private web API. Before installing or running it: (1) confirm the indicated directories exist and that you want the agent to read them (the paths are hardcoded to /home/lixiang/...); (2) confirm you trust the private IP endpoint (http://10.122.86.46:9999) the skill may curl; (3) review the included script if you need to be certain it doesn't transmit data elsewhere — it appears to only parse local logs; (4) be aware the agent will run python3 and shell curl commands, so run in a principle-of-least-privilege context or on a machine/account that is allowed to expose those logs. If any of these assumptions don't hold (different home path, untrusted network endpoint), do not enable/auto-run the skill until modified.

Like a lobster shell, security has layers — review code before you run it.

latestvk97avdf9a73xcdgmvq34kvhstn82djbn
256downloads
0stars
1versions
Updated 1mo ago
v1.0.0
MIT-0

Boot KPI Analyzer Skill

功能描述

分析 SS4 车机的开机 KPI 和关机 KPI 时序数据,帮助定位启动慢、关机慢等性能问题。

数据路径

开机 KPI(Boot KPI)

/home/lixiang/work/sdata/code/smk-1125/boot_kpi_server/backend/uploads/<YYYYMMDD_HHMMSS>/

每个子目录包含:

  • boot_kpi_summary.txt — 预分析的中文摘要报告(3部分:系统服务启动分析、qcrosvm依赖分析、qcrosvm启动性能)
  • boot_kpi.log — 原始事件:<service> -> <state> at <ms>ms from system boot
  • unit_kpi.log — modemanager 日志:[UnitKPI] Dependency of qcrosvm.service ... -> <state> at <ms>ms

关机 KPI(Shutdown KPI)

/home/lixiang/work/sdata/code/smk-1125/boot_kpi_server/backend/reboot_tests/<YYYYMMDD_HHMMSS>/

每个子目录包含:

  • report.json — 测试报告,包含 reboot_duration(整个重启周期秒数)、test_result、build_id 等
  • shutdown-monitor-units.log — BPF 跟踪的关机事件日志

Web 查询接口(私有 IP,须用 curl)

http://10.122.86.46:9999/

⚠️ web_fetch 无法访问私有 IP,必须使用 execute_command 运行 curl 命令。

使用方法

列出可用的开机 KPI 数据

ls /home/lixiang/work/sdata/code/smk-1125/boot_kpi_server/backend/uploads/

列出可用的关机 KPI 数据

ls /home/lixiang/work/sdata/code/smk-1125/boot_kpi_server/backend/reboot_tests/

分析脚本

使用 skills/boot-kpi-analyzer/scripts/analyze.py 进行自动化分析:

# 分析最新的开机 KPI
python3 /home/lixiang/.openclaw/skills/boot-kpi-analyzer/scripts/analyze.py boot --latest

# 分析指定目录的开机 KPI
python3 /home/lixiang/.openclaw/skills/boot-kpi-analyzer/scripts/analyze.py boot --dir <YYYYMMDD_HHMMSS>

# 分析最新的关机 KPI
python3 /home/lixiang/.openclaw/skills/boot-kpi-analyzer/scripts/analyze.py shutdown --latest

# 分析指定目录的关机 KPI
python3 /home/lixiang/.openclaw/skills/boot-kpi-analyzer/scripts/analyze.py shutdown --dir <YYYYMMDD_HHMMSS>

# 列出所有可用数据
python3 /home/lixiang/.openclaw/skills/boot-kpi-analyzer/scripts/analyze.py list

curl 查询 Web 接口示例

curl -s http://10.122.86.46:9999/
curl -s http://10.122.86.46:9999/api/sessions
curl -s http://10.122.86.46:9999/api/latest

数据格式说明

boot_kpi.log 格式

<service_name> -> <state> at <ms>ms from system boot

关键状态:activatingactivedeactivatinginactivefailed

shutdown-monitor-units.log 格式

[YYYY-MM-DD HH:MM:SS.mmm] Unit: <service> | State: <FROM> -> <TO> | BPF_timestamp: <ns>
  • BPF_timestamp 单位:纳秒
  • 关键里程碑:
    • shutdown.target | State: INACTIVE -> ACTIVE — 关机流程开始
    • umount.target | State: INACTIVE -> ACTIVE — 关机晚期阶段
    • qcrosvm.service | State: ACTIVE -> DEACTIVATING — Android VM 开始关闭

report.json 关键字段

  • reboot_duration: 整个重启周期(秒),含关机+开机
  • test_result: success / failure
  • build_id: 固件版本
  • has_lastlog: 是否有 lastlog(异常重启标志)
  • error_message: 失败原因

分析要点

开机性能关键指标

  • qcrosvm.service 激活耗时:Android VM 启动时间,最重要的 KPI
  • 慢服务(>100ms):影响开机速度的服务
  • 频繁重启的服务:可能有依赖问题
  • 失败服务:需要重点关注

关机性能关键指标

  • 总关机时长:从 shutdown.target 激活到系统关机
  • qcrosvm.service 关机耗时:Android VM 关闭时间
  • reboot_duration:完整重启周期(越小越好,目标通常 < 40s)
  • umount.target 之前的耗时:文件系统卸载前的服务关闭阶段

典型分析流程

  1. 列出数据 → 找到最新或指定时间段的数据目录
  2. 读取 report.json → 快速了解总体情况(reboot_duration、是否成功)
  3. 分析关机日志 → 找出关机慢的服务(计算各服务从 DEACTIVATING 到 INACTIVE 的耗时)
  4. 读取 boot_kpi_summary.txt → 获取开机分析摘要
  5. 深挖 boot_kpi.log → 针对具体服务进行详细分析
  6. 对比多次数据 → 找出性能波动规律

Comments

Loading comments...