tail_log
Fetch the last N lines of a remote log file on a single host or multiple hosts concurrently. Returns a JSON map for multi-host queries.
Instructions
Fetch the last N lines of a remote log file on a single host ('host') or multiple hosts concurrently ('hosts'). If using 'hosts', returns a JSON map mapping hostnames to their log output. Prefer 'hosts' to query logs across multiple machines simultaneously.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | No | The target hostname or IP address | |
| hosts | No | A list of hostname targets to query concurrently | |
| lines | No | Number of lines to read from the end (default: 100) | |
| file_path | Yes | Absolute path to log file on remote target |