The unattended night
A pipeline that has died and a pipeline with nothing to report look identical in the morning. Five minutes of checks before bed prevent most bad nights: disk, scope, locks and a dry run of one stage. Ten minutes in the morning turn the night’s output into decisions. Thirty minutes a week keep the scoring honest. A heartbeat and an outside health check tell you when the pipeline itself has died.
Pre-flight before you sleep
Section titled “Pre-flight before you sleep”Run these the first few nights, and after any change to scope, scripts or tools. The checklists page has a tick-box version.
# 1. Disk: warn if less than 5 GB is free on the pipeline filesystemfree_gb=$(df -BG --output=avail ~/pipeline | tail -1 | tr -dc '0-9'); echo "free: ${free_gb} GB"; [[ $free_gb -lt 5 ]] && echo "LOW DISK: fix before running"# 2. Scope: the files exist, are non-empty, and say what you think they sayfor p in ~/pipeline/programs/*/; do echo "== $p"; grep -vE '^\s*(#|$)' "$p/scope/in-scope.txt"; grep -E '^(RATE|AUTOMATED_SCANNING)=' "$p/scope/policy.env"; done# 3. Locks: nothing is running, so tonight's run will not be refused with exit 5for l in ~/pipeline/programs/*/state/.lock; do flock -n "$l" true && echo "free: $l" || echo "HELD: $l"; done# 4. Dry run one stage by hand: enumeration only, scope-filtered, nothing activePROGRAM=example; sed -nE 's/^\*\.([^ #]+).*/\1/p' ~/pipeline/programs/$PROGRAM/scope/in-scope.txt | subfinder -silent | PROGRAM=$PROGRAM ~/pipeline/bin/inscope | head# 5. Pre-flight: what each active stage would touch (Part 4)PROGRAM=example ~/pipeline/bin/preflight | less# 6. The scheduler will actually firesystemctl --user list-timers | grep auto-triageIf any step surprises you, do not run unattended tonight. Fix it, then run once while watching.
Morning review
Section titled “Morning review”Ten minutes, the same order every day. The goal is a decision for every new item, written down.
-
Health first (1 minute). Did the pipeline run? Read the heartbeat and the last lines of the run log.
Terminal window # Last run status per program: heartbeat line and any warningsfor p in ~/pipeline/programs/*/; do printf '%-12s %s\n' "$(basename "$p")" "$(cat "$p/state/heartbeat" 2>/dev/null || echo MISSING)"; grep -h 'WARN\|FATAL' "$p/current/run.log" 2>/dev/null | tail -3; done -
New findings (4 minutes). Read the digest, or
current/triage.tsvdirectly. For each line: openevidence/<fp>/meta.txtandresponse.txt.Terminal window # Everything the last run delivered, highest severity firstsort -t$'\t' -k1,1 ~/pipeline/programs/example/current/triage.tsv | column -t -s$'\t' -
Decide (3 minutes). Every finding gets one of three outcomes, recorded:
- Confirm: reproduce by hand, write
manual.md, then move the folder toreports/and start a report (see writing reports). - Suppress: add a line to
state/suppress.txtwith the date and reason. - Park: leave it; it is already in the ledger and will not alert again. Note it in
notes.mdif you want to come back.
Terminal window # Move a confirmed finding into the reports folder, keeping its fingerprint as the folder namemv ~/pipeline/programs/example/evidence/2d7bbe2f093b189d ~/pipeline/programs/example/reports/Terminal window # Suppress a template on this program, with a date and reasonecho "tid:tech-detect # $(date -u +%F) informational, never actionable here" >> ~/pipeline/programs/example/state/suppress.txt - Confirm: reproduce by hand, write
-
Queue (2 minutes). Read the top ten lines of
current/queue.tsv. Anything new near the top is where today’s manual testing starts.
If the review regularly takes more than ten minutes, the pipeline is sending too much. That is a tuning problem, not a discipline problem.
Weekly tuning
Section titled “Weekly tuning”Thirty minutes, once a week, with the weekly checklist.
| Task | Command or file | Decision |
|---|---|---|
| Re-score last week’s tested leads | The outcome rates in Part 5 | Move at most one or two weights, by 5 or 10 |
| Check the alert budget | Part 7 template counts | Suppress or reroute the noisiest template |
| Review suppressions | state/suppress.txt |
Remove lines whose reason no longer holds (a fixed host, a policy change) |
| Check timing | grep 'timed out' runs/*/run.log for the week |
Raise a timeout or shrink a stage’s input |
| Update tools and templates | pdtm -update-all, nuclei -update-templates |
Run one stage by hand after updating; flags and JSON fields can change |
| Refresh the CVE list | Part 6 | Check the file’s date is this week |
| Commit state | git commit in ~/pipeline |
A message saying what you changed and why |
Updating tools in the middle of the week, then leaving the pipeline to run, is a classic cause of a silent failure. Update during the weekly session, while you are watching.
Silent failures
Section titled “Silent failures”The dangerous failure is not a crash. It is the pipeline that stops producing output while everything looks calm. Three cheap defences.
Log rotation
Section titled “Log rotation”Run folders accumulate. Each one is small, but screenshots and responses add up, and a full disk makes every stage fail at once.
# Delete run folders older than 30 days, keeping current and everything in reports/ and evidence/find ~/pipeline/programs/*/runs -mindepth 1 -maxdepth 1 -type d -mtime +30 -exec rm -rf {} +# /etc/logrotate.d/auto-triage: rotate the scheduler's own log weekly, keep 8 compressed copies/home/hunter/pipeline/cron.log { weekly rotate 8 compress missingok notifempty copytruncate}Run the cleanup as its own scheduled job, not inside the pipeline, so a pipeline bug cannot also break cleanup. Never auto-delete evidence/ or reports/; those are yours to clean.
Heartbeat files
Section titled “Heartbeat files”At the very end of a successful run, the worked pipeline writes one line to state/heartbeat: the run stamp, ok, and the finding count. A run that died halfway never writes it. So the heartbeat’s age tells you when the last good run finished.
# Alert if any program's heartbeat is older than 26 hours (a daily job plus slack for random delay)for h in ~/pipeline/programs/*/state/heartbeat; do age=$(( ($(date +%s) - $(stat -c %Y "$h")) / 3600 )); [[ $age -gt 26 ]] && echo "STALE ${age}h: $h"; done | notify -id health -bulk -silentThat check itself runs from the scheduler, separately from the pipeline. If the pipeline and its own health check share one script, one bug kills both.
A simple health endpoint
Section titled “A simple health endpoint”The heartbeat check runs on the same VPS. If the VPS itself is down, nothing alerts. An outside “dead man’s switch” service solves that: your box pings a URL after each good run, and the service alerts you if the ping stops arriving. Healthchecks.io is one such service with a free tier and an open-source self-hosted version; check its docs for current limits.
# Add to the end of a successful run: ping the outside check, with a timeout and a few retriescurl -fsS -m 10 --retry 3 "https://hc-ping.com/$HC_UUID" >/dev/null || log "WARN health ping failed"| Defence | Catches | Misses |
|---|---|---|
| Run log warnings | A stage timing out or erroring | The whole script not starting |
| Heartbeat age check | Runs that died or never started | The VPS being down |
| Outside ping service | VPS down, scheduler broken, network gone | Runs that “succeed” with empty output |
| Weekly summary counts (Part 7) | Runs that succeed but find zero hosts for days | Nothing, if you read it |
The last row matters. A data source that dies, an expired API key or a resolver list gone stale can produce a run that exits 0 with a tiny host count. The weekly summary’s “new hosts” and the run log’s host count are how you notice. If a program that usually shows 1,400 hosts suddenly shows 40, something broke upstream.
What a night record proves
Section titled “What a night record proves”Heartbeat line
Section titled “Heartbeat line”2026-11-14T034510Z ok findings=4The finish block writes this with printf '%s ok findings=%s\n'. The count is wc -l of that run’s triage.tsv.
This record asserts stage 8 reached the end and the file’s mtime moved. It does not assert the four rows are confirmed bugs. Open current/triage.tsv and decide each one.
Held lock
Section titled “Held lock”HELD: /home/hunter/pipeline/programs/example/state/.lockThis record asserts flock -n could not take the lock, so a live process still holds it. The runner takes that lock with exec 9>"$P/state/.lock".
This record does not assert the pipeline crashed. A flock drops when the holder exits, including a crash, so a leftover .lock file after a reboot is not a held lock. HELD means the process is still alive. It does not mean the process is making progress. Read current/run.log. If lines are still arriving, let the run finish. If the log has stopped, the holder is hung.
Enum timeout
Section titled “Enum timeout”[2026-11-14T02:30:00Z] WARN enum timed out after 1800sThis record asserts timeout returned 124 for the enum stage and the stage helper logged it. The enum budget in the worked pipeline is 1800 seconds. Stderr for that stage is logs/enum.err in the run folder.
This record does not assert enumeration produced nothing. Stdout written before the kill stays in subfinder.txt, and the pipeline keeps that partial list. Exit 6 happens when no in-scope hosts remain, not merely because this WARN exists.
Next, decide whether you need more than one machine in Scaling up.
Open local graph around this page
Linked from here
- Auto-triage pipelinesRecon Atlas
- LLM-assisted triageRecon Atlas
- Notification and deliveryRecon Atlas
- Pipeline thinkingRecon Atlas
- Scheduling and process managementRecon Atlas
- Scoring and triage enginesRecon Atlas
- Validation layerRecon Atlas
- The worked pipelineRecon Atlas
- Long-game habits and mindsetRecon Atlas
- The complete personal systemRecon Atlas
- Synthetic program profilesRecon Atlas
Recon AtlasFor authorized testing only. Your scope is the map edge.