service_logs
Fetches recent systemd journal logs for a service, with filters for time range, priority, and grep patterns to debug issues and monitor output.
Instructions
Fetch recent journal logs for a systemd service. Supports filtering by time range, priority level, and grep patterns. Useful for debugging service issues and monitoring application output.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| grep | No | Filter log lines matching this pattern (passed to journalctl --grep). | |
| user | No | If true, query user-level service logs (--user). | |
| lines | No | Number of recent log lines to return (1-1000, default 50). | |
| since | No | Show logs since this time. Accepts journalctl time specs: '1h ago', '2024-01-15', 'today', etc. | |
| service | Yes | Name of the systemd service to fetch logs for. | |
| priority | No | Minimum log priority level to include. |