host_log_scan
Scan recent ESXi host logs for error and warning patterns to quickly identify issues across your cluster. Filter by host and log lines for targeted troubleshooting.
Instructions
[READ] Scan recent ESXi host syslog lines for error/warning patterns.
Reads the last lines entries of the hostd/vmkernel/vpxa logs on each
host via the diagnostic system and returns only the lines matching known
trouble patterns (error, fail, critical, panic, lost access, timeout, …).
Each entry has severity, source (host_log:<key>), message, time, and
entity (host name). Returns an empty list when no matching lines are found.
Only errors/warnings are returned, not the full log, so output stays small
even on large clusters. Filter to one host with host_name to keep the
scan fast on environments with many hosts.
Args: host_name: Filter to a single host by exact name (None = all hosts). lines: How many recent lines per log to scan (default 500). target: Optional vCenter/ESXi target name from config. Uses default if omitted.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lines | No | ||
| target | No | ||
| host_name | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |