Skip to content
WasFor
Back to home
Documentation/Operations

Troubleshooting

Most incidents fall into a small number of patterns. Work from the symptom to the layer, confirm with a command, then apply the smallest fix.

Symptom matrix

SymptomLikely layerFirst check
502 Bad GatewayPHP-FPM or upstreamPHP-FPM pool status, error log
503 Service UnavailableMaintenance mode or overloadPanel maintenance flag, load average
504 Gateway TimeoutUpstream too slowmax_execution_time, slow queries
500 Internal Server ErrorApplicationSite error log, display_errors off
Site unreachableDNS or firewalldig, curl -I, port 80/443
SSL errorCertificateExpiry, chain, hostname mismatch
Mail deferredDNS or quotaSPF/DKIM, mailbox quota, queue
Disk fullStoragedf -h, largest directories
Panel downPanel servicesystemctl status wasfor-panel

502 Bad Gateway

The web server could not reach PHP-FPM.

bash
systemctl status php8.3-fpm --no-pager
tail -n 100 /home/acme/sites/app.example.com/logs/error.log
ss -lntp | grep fpm
CauseFix
FPM pool crashedRestart the pool; inspect the crash log
Socket path mismatchRe-apply the site PHP version
Memory exhaustedLower memory_limit or add RAM
Worker timeoutRaise request_terminate_timeout carefully

500 Internal Server Error

The application failed. Turn on logging rather than display_errors:

bash
tail -f /home/acme/sites/app.example.com/logs/error.log
grep -i "PHP Fatal" /home/acme/sites/app.example.com/logs/error.log | tail -20

Common causes: missing PHP extension, wrong file permissions, stale config cache, failed migration. Fix the cause, then clear caches.

504 Gateway Timeout

The request exceeded a timeout. Compare three values:

text
Client / proxy timeout   ≥ max_execution_time
max_execution_time       ≥ expected work
Database query time      < max_execution_time

Long jobs belong in a queue worker, not in a web request.

DNS and reachability

bash
dig +short app.example.com A
dig +short app.example.com AAAA
curl -I -H "Host: app.example.com" http://203.0.113.10

If the local Host request works but the domain fails, the problem is DNS or the edge firewall, not the application.

SSL failures

bash
openssl s_client -connect app.example.com:443 -servername app.example.com </dev/null 2>/dev/null \
  | openssl x509 -noout -dates -subject -issuer
MessageMeaning
certificate has expiredRenewal failed; re-issue
unable to verify the first certificateIncomplete chain
certificate is valid for …Hostname mismatch; add an alias

Mail deferred

bash
mailq | tail -20
grep -i "deferred" /var/log/mail.log | tail -30

Check SPF/DKIM/DMARC, mailbox quota, and whether the destination is rate-limiting you. A sudden spike in outbound volume usually means a compromised account or script.

Disk full

bash
df -h
du -xh --max-depth=1 /home | sort -h | tail -10
du -xh --max-depth=1 /var/log | sort -h | tail -10

Rotate logs, clear old snapshots, and check for runaway backups. Never delete /var/lib/mysql files by hand.

Database connection errors

bash
systemctl status mariadb --no-pager
mysqladmin status -u root -p
ErrorMeaning
Too many connectionsRaise max_connections or fix connection leaks
Access deniedWrong user, host or password
Disk fullSee the disk section
Table is marked as crashedRestore or run a repair on a stopped server

Panel not loading

bash
systemctl status wasfor-panel --no-pager
journalctl -u wasfor-panel -n 200 --no-pager
curl -sk https://127.0.0.1:<port>/api/health

If the health endpoint responds but the UI is blank, check the browser console and the static asset cache. Clear the panel cache and reload.

Escalation

Collect before opening a ticket:

  • Exact timestamps with timezone.
  • Request IDs and affected URLs.
  • Relevant log excerpts.
  • What changed immediately before the incident.
  • Steps already attempted.

See AI & support for ticket priorities and response targets.

Last updated: 2026-12-01