TachEmail r90
Docs / Operate / Troubleshoot an install

Troubleshoot an install

What a failed install, upgrade, backup or restore step prints, how to rerun a failed first install, and how to ask for help.

Built from commit f569b4a on Nov 14, 2026

This page is generated from the maintained install guide, GUIDE.md, at source commit fa247a8. Keep the signed guide that came with your installed release.

Troubleshooting

When an install, upgrade, backup or restore step fails, the error names the step, shows the last few error lines of the failing command, and names the log to read, such as sudo journalctl -u docker -n 50 --no-pager or sudo journalctl -u tach-selfhost -n 50 --no-pager. Fix the cause and rerun the same command.

A first install failed

You can rerun a failed first install the same way. If creating the database failed before anything was written, the rerun removes the empty /etc/tach/first-admin-keys.json and creates the database again.

The installer never removes or overwrites a keys file that has any content. If one is left from an install that did not finish, the installer stops, names the file and says what to do. Never delete that file yourself: it may be the only copy of the first administrator’s keys.

A failed first install can also leave files in the data directory, for example when the disk filled up. If creating the database fails with database_start_failed, the error ends with a df -h command for the data directory: check free space there first. The rerun then stops, names the directory, and prints on its own line a sudo mv command that moves the directory aside to a new name. The new name is the data directory followed by .failed-init- and the UTC time, such as /var/lib/tach/data.failed-init-20261026T091500Z. If this is a new installation with no data to keep, free disk space, run that command, then rerun the same install command. If the disk is still full, the rerun stops again with the step name and the same df -h check. That failed rerun leaves new files in the data directory, so the next rerun prints another sudo mv command with a new UTC name: free space, run it, then rerun.

A moved directory holds no keys. Keep it until the rerun has finished and the first administrator has signed in. If the disk is full and a moved directory is using that space, you can delete it before the rerun; the new installation uses nothing in it. To list moved directories, set DATA_DIR to your data_dir:

DATA_DIR=/var/lib/tach/data
sudo find "$(dirname "$DATA_DIR")" -maxdepth 1 -name "$(basename "$DATA_DIR").failed-init*"

Delete only an exact name that the installer printed. It always ends in .failed-init- and a UTC time, with -2, -3 and so on when repeated, for example sudo rm -r -- /var/lib/tach/data.failed-init-20261026T091500Z. Never run rm on the data directory itself.

Help

See Support.

If a step fails and this guide does not say what to do, stop and email hello@r90group.com. Include the package version, the /healthz revision, the locally inspected support-bundle archive described below, and the failing operation without private arguments. Never send raw status output or journals. Never include keys, config contents, cookies, sign-in codes, message text or your database. Support never needs access to your VM or cloud account.

Optional telemetry

Customer telemetry is off by default. To opt in, put a Sentry DSN or PostHog project ingestion key in separate root-owned 0600 (or 0400) regular files, then set [telemetry].sentry_dsn_file / posthog_key_file to their absolute paths. No inline values or environment-variable secret sources are accepted here. environment_file supplies the shared environment (default production); posthog_host_file optionally selects another HTTPS PostHog origin (default https://us.i.posthog.com). Never put a personal PostHog API key there. Run validate, then rerun the same package’s install to apply configuration.

Sentry receives stable server failure classes, release and environment. PostHog receives bounded journey outcomes and process-salted references, not usage, names, addresses, prompts, responses, tool arguments/results or credentials. Neither is an accounting store or a replacement for operator monitoring. Root-private runtime.env contains the resolved settings; never share it.

R90’s server settings are checked against the same client renderer by telemetry_config_test.py during portable/check.sh. Platform-owned listen and database paths are the only exceptions (documented in that test). The Fly secret-name inventory in fly.r90.toml must be kept current when secrets change; no secret values belong in that inventory.

Operational notices

The optional updates.notify_email address is the single operator route for updates and operational conditions. It is empty/off by default. updates.enabled controls update checks only; a configured address still enables operational monitoring. Use your approved relay and alert mailbox, then retain a real Inbox receipt; local SMTP acceptance is not proof of responder delivery.

The installed tach-monitor.timer runs sudo tach monitor every five minutes, starting three minutes after boot. No probes, state writes or mail are made by that command when the address is unset. With the route enabled it checks:

  • Backup: failed/stale canonical cycle receipt (including off-host failure); overdue means more than 26 hours, or an expired running cycle. A running or pending attempt is unknown, NOT recovery. An existing alarm clears only after an ok receipt confirms the completed validation, restore drill and configured copy.
  • TLS: every configured hostname through local Caddy, with chain and hostname verification, invalid certificates or expiry within 14 days. Frontend gateway certificates outside this VM still need that gateway’s own monitor.
  • Disk: available data-disk bytes below 10% or 3 x backup.max_mib + 64 MiB, whichever is larger. This is headroom, not capacity certification.
  • Delivery silence: Health’s known silent machines (three business days); empty or newly idle fleets are not fabricated missing usage. Truncated/unknown evidence cannot clear a previous notice.
  • Rejected senders: any client-side ingestion or collector receipt-readback rejection in the last hour, from bounded process-local counters, independent of optional analytics. Recovery needs one quiet hour; a server restart cannot falsely clear it.
  • Unavailable Health: the local authenticated Health document cannot be read. Existing delivery notices remain active/unknown, not recovered.

Each condition has one ALERT and one RECOVERED email on its transition, within five minutes plus a bounded check (up to 90 seconds). Bodies contain only fixed condition/action, timestamp and release/revision, never sender identity, usage, content, keys or dependency text. sudo tach monitor also prints the closed conditions/notification outcomes. Its private /etc/tach/monitor.json is delivery intent, not a second Health/accounting store; keep it across upgrades/rollback. Corrupt intent is refused, not silently reset. Recovery is owned by your IT: stop tach-monitor.timer, preserve the file under a new root-private name, and restore your own intact notice-state backup. If none exists, explicitly move /etc/tach/monitor.json aside to a new private name and run sudo tach monitor; this starts fresh notice intent and may repeat previously accepted/ambiguous alerts. Make that decision in your own change process, then start the timer. It never changes Facts, receipts or backups and needs no vendor communication. This recovery applies ONLY to monitor.json, not signed-update anti-replay state. Failed/uncertain SMTP is visible there and is not automatically retried after ambiguous acceptance. After fixing the relay, run sudo tach monitor --retry-notification. Repeating a check otherwise stays quiet. Monitoring never installs, restarts, restores or modifies ledger data.

The default Health credential is the private first administrator query key in /etc/tach/first-admin-keys.json. Before moving/revoking those first keys, set monitoring.query_key_file to an absolute root-private file holding an active administrator query key, validate, and rerun the same package’s install command. An ingest/member key is refused and produces Health-unavailable, not a false healthy verdict. The notification process runs outside maintenance/backup locks.

Monitoring alternatives: /healthz is public liveness/revision only; Azure Monitor can probe it without credentials, but that proves no backup, certificate headroom, disk or delivery condition. /health/ready requires an administrator session: 200 means no critical Health condition, 503 includes a failed/stale backup or unverifiable migrations; anonymous requests redirect to sign-in. Do not treat a redirect-following anonymous probe as readiness. Automation can POST /v1/health with an administrator query key and inspect status, problems and readiness; its HTTP 200 means the document was read, NOT that status is healthy. Keep the key in the monitor’s protected secret store, never a URL. These authenticated reads create no usage/incident state. No package on this VM can notify during loss of VM power/network or a dead mail relay: an external liveness monitor and approved escalation remain necessary.

The shared notice hook uses the same optional [smtp] username/password, private-CA bundle or Exchange commercial-cloud OAuth settings as sign-in mail. It requests one short-lived OAuth token per notice (five-second HTTPS budget, 64-KiB response cap, no redirects/proxies, no token cache or persistence), then uses XOAUTH2 over verified TLS. Tokens and SMTP secrets never enter a notice, error text, Health or the notice-state file. A provider/relay refusal records failed; repair your own configuration/egress/relay policy and explicitly retry. A private CA must be configured in smtp.ca_bundle_file for both paths. No R90 account, service access, tenant credential or customer approval is required to configure or operate the package; all provider/relay credentials are your own.

Installed notices resolve SMTP settings from the same root-private runtime.env generation as the serving image. This includes legacy smtp.*_env sources, which were resolved at installation; timers never depend on your interactive shell retaining those variables. Rotating a source secret is applied by validating and rerunning install, not by assuming a daemon rereads your shell/files. SMTP resolution is lazy: a missing or invalid mail setting marks a notice failed without stopping the signed update check or serving. An unset route reads no resolved secrets and creates no monitor lock/state file.

Local private diagnostics

Run sudo tach support-bundle /root/tach-support.tar.gz even if installation or service startup failed. The destination must be new, below root-owned parents not writable by other users (not /tmp). Nothing is uploaded. Inspect it with sudo tar -xOf /root/tach-support.tar.gz support.json before sharing it through your organization’s approved support route. The archive is mode 0600 and has one member, support.json, bounded to 16 KiB before compression.

Schema tach.support.v1 contains only fixed service names and closed state/error classes, validated release revision, numeric runtime versions, storage capacity and certificate validity timestamps. unknown/unavailable means a probe could not establish a value, not healthy. A missing/broken config does not prevent a bundle. TLS checks the configured main hostname against loopback, without public DNS or an external request. It does not qualify the optional ingest hostname. There are no journal lines, environment/config copies, database rows, hostnames, emails, codes, cookies, tokens, command lines or HTTP bodies. Logs must be reviewed separately on your machine; never attach them indiscriminately.

Enter to openEsc to close