All fixes
MySQL EXPLAIN in practice: from a slow query to the right index
Put EXPLAIN in front of the query and read four columns: type, key, rows and Extra. They show whether an index is used, how well, and what is done after it.
nginx 502 Bad Gateway with PHP-FPM: read the error log line first
A 502 means nginx got no usable answer from PHP-FPM. One line in the nginx error log says why: no socket, no permission, a dead worker or a big header.
Where is php.ini? Finding the file PHP actually loads
Run php --ini for the command line, and call php_ini_loaded_file() through the browser for the website. They are often two different files, and both count.
Install phpMyAdmin on Ubuntu with nginx and PHP-FPM, the manual way
Download and verify the archive, unpack it outside the web root, write a server block with a PHP location, add config.inc.php and lock the address down.
PHP error reporting and the PHP error log: where the errors go
PHP decides three things about an error: whether to report it, whether to show it, and where to log it. Print those settings first, then read the file.
Increase the maximum number of open files on Ubuntu (ulimit -n)
For a service such as nginx or PHP-FPM set LimitNOFILE in a systemd drop-in. The limits.conf file only changes login sessions, which is why edits seem ignored.
gpg: can't connect to the agent: IPC connect call failed
gpg could not reach gpg-agent over its socket. Restart the agent with gpgconf, check the home folder's path and permissions, and move WSL 1 to WSL 2.
Can't install a Let's Encrypt certificate through Plesk after an update
When Plesk cannot reach Let's Encrypt after an update (cURL error 6, could not resolve host), restart its own services, then check DNS and the API host name.
Laravel in a subdirectory: the nginx server block
Serve a Laravel project under /shop with one prefix location that aliases its public folder, a nested PHP location and a named fallback to its index.php.
MySQL server has gone away (2006) and lost connection (2013): the causes
MySQL error 2006 means the connection was closed before your query arrived: check idle timeout, packet size and server restarts, in that order, then reconnect.
MySQL error 1064: how to read the message and find the broken part
MySQL error 1064 quotes the statement from the first token the parser could not accept, so look at that word and the one just before it for the cause.
MySQL error 1045 (28000) access denied for user: what it is telling you
Error 1045 names the user, the host the server saw and whether a password was sent. Read those three parts first and you know which fix applies.
PHPSolvedThe fix first, then the reason