Filebeat System Module Setup Prompt
Set up the Filebeat system module to harvest syslog and auth logs across distros, mapping the right journald or file paths and handling the auth fileset so login and sudo events parse into ECS.
- Target user
- Sysadmins shipping OS-level syslog and auth logs with the Filebeat system module
- Difficulty
- Beginner
- Tools
- Claude, ChatGPT, Cursor
The prompt
You are a senior Filebeat engineer who standardizes OS log collection with the system module across mixed Debian/Ubuntu and RHEL fleets. I will provide: - My distros and versions, and whether they log to plain files (`/var/log/syslog`, `/var/log/auth.log`, `/var/log/messages`, `/var/log/secure`) or to journald - Filebeat version and module enablement method - Whether I need both `syslog` and `auth` filesets Your job: 1. **Pick the source** — decide per distro whether to use the file-based `system` module filesets or the `journald` input, and explain the tradeoff (file paths differ RHEL vs Debian; journald avoids path guessing). 2. **Write the module config** — produce `system.yml` with `syslog` and `auth` filesets, correct `var.paths` per distro, and `enabled` flags; note where paths diverge (`messages`/`secure` on RHEL vs `syslog`/`auth.log` on Debian). 3. **Confirm parsing** — explain how the auth fileset parses sshd, sudo, and useradd events into ECS (`user.name`, `source.ip`, `event.action`) and how to verify a login event lands correctly. 4. **Handle harvesting** — set options so rotated OS logs (logrotate rename) are tracked without duplication. 5. **Validate** — provide `filebeat test config`, `filebeat test output`, and a sample document check for both filesets. Output as: the `system.yml` per-distro (or a templated version), a path-mapping table Debian vs RHEL, and a validation checklist. Default to caution: treat auth-log data as sensitive, verify paths exist on each target distro before rollout, and test against one host per distro family first.
Run this prompt with AI
Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.
Related prompts
-
Filebeat Docker Autodiscover with Hints Prompt
Design a Filebeat Docker autodiscover configuration driven by container labels (hints) so per-service multiline, modules, and JSON parsing are applied automatically as containers come and go.
-
Filebeat close_* and clean_* Options Tuning Prompt
Tune Filebeat's harvester close_* and registry clean_* options so file handles release promptly, deleted files stop being held open, and registry state is purged without dropping in-flight data.
-
Filebeat container Input Design Prompt
Configure the Filebeat container input to read CRI/Docker JSON log files correctly, parsing the runtime envelope, stream (stdout/stderr), and partial-line reassembly before application parsing.
-
Filebeat filestream vs log Input Migration Prompt
Plan and execute a safe migration from the deprecated log input to the filestream input, preserving read state so you neither re-ship old data nor drop lines during the cutover.
More Filebeat prompts & error guides
Browse every Filebeat prompt and troubleshooting guide in one place.
Reading prompts? Get all 500 in one free PDF
500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.
- 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
- Instant PDF download — yours free, forever
- Plus one practical AI-workflow email a week (no spam)
Single opt-in · unsubscribe anytime · no spam.