Server Debugging TL;DR

TL;DR because the post I wrote was over 10 pages with snippets and all the various issues tracked down over the last 6 months. This is the distilled approach to solving issues on the server level.

Check the Relevant Logs

MYSQL: /var/log/mysql/error.log
PHP: /var/log/php8.0-fpm.log
Nginx: /var/log/nginx/error.log and /var/log/nginx/access.log
System: /var/log/syslog

Make More Logs

https://github.com/evinr/bash-scripts/blob/master/log-high-cpu-processes.sh
Correlate data from custom logs and the relevant logs listed above via timestamps

Hypothesize Why it is Fucked

The logs and links should be used as sources
Changes made to the server should be incremental
Multiple points of failure may have cascading effects

Band-aid the Technical Debt

Short term fix, skip this step if time permits
Long-term fix
Share the knowledge of the solution like a feather in a hat

Leave a Reply

Your email address will not be published.