Error map

FastCGI sent in stderr: PHP message Nginx: [error] FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught Error: Call to undefined function mysqli_connect()" while reading response header from upstream

Nginx / Apache · layer 3, Edge & web server

Open the full error page →

Centre: this error. First ring: errors it is linked with (8). Outer ring: what those are linked with. Colours show the layer of a request each error belongs to. Click any dot to re-centre the map on it; hover to follow its connections. The centre dot opens the error page.

FastCGI sent in stderr: PHP message — Nginx: [error] FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught Error: Call to undefined function mysqli_connect()" while reading response header from upstream (Nginx / Apache)FastCGI sen…500 — HTTP 500 Internal Server Error (HTTP)500Primary script unknown — FastCGI sent in stderr: "Primary script unknown" (PHP)Primary script unkn…OPcache stale code — PHP still runs old code after deploy (OPcache not reset) (PHP)OPcache stale codeconnect() to unix:/run/php/php-fpm.sock failed (13: Permission denied) — Nginx: [crit] connect() to unix:/run/php/php8.3-fpm.sock failed (13: Permission denied) while connecting to upstream (Nginx / Apache)connect() to unix:/…ModSecurity: Access denied with code 403 — Nginx/Apache: ModSecurity: Access denied with code 403 (phase 2). Matched "Operator GE matched 5 at TX:anomaly_score" (Nginx / Apache)ModSecurity: Access…nginx: client intended to send too large body — Nginx: [error] client intended to send too large body: 5242880 bytes (413 Request Entity Too Large) (Nginx / Apache)nginx: client inten…upstream sent too big header while reading response header — Nginx: [error] upstream sent too big header while reading response header from upstream (502 Bad Gateway) (Nginx / Apache)upstream sent too b…PHP file downloads instead of running (Nginx) — Browser downloads index.php instead of rendering — Nginx has no fastcgi PHP location (Nginx / Apache)PHP file downloads …404 — HTTP 404 Not Found (HTTP)404502 — HTTP 502 Bad Gateway (HTTP)502503 — HTTP 503 Service Unavailable (HTTP)503403 — HTTP 403 Forbidden (HTTP)403Allowed memory size exhausted — PHP Fatal error: Allowed memory size of X bytes exhausted (PHP)Allowed memory size…ArgumentCountError — Fatal error: Uncaught ArgumentCountError: Too few arguments to function foo(), 1 passed and exactly 2 expected (PHP)ArgumentCountErrorApp Service Application Error — Azure App Service: ":( Application Error" / container didn’t respond to HTTP pings (Azure)App Service Applica…FileNotFoundException assembly — Could not load file or assembly 'X, Version=…' or one of its dependencies (.NET)FileNotFoundExcepti…Unexpected token < — SyntaxError: Unexpected token '<' (HTML served instead of JavaScript) (JavaScript)Unexpected token <nginx: bind() to 0.0.0.0:80 failed (13: Permission denied) — Nginx: nginx: [emerg] bind() to 0.0.0.0:80 failed (13: Permission denied) (Nginx / Apache)nginx: bind() to 0.…connect() failed (111: Connection refused) while connecting to upstream — Nginx: [error] connect() failed (111: Connection refused) while connecting to upstream, upstream: "http://127.0.0.1:3000/" (Nginx / Apache)connect() failed (1…1020 — Cloudflare Error 1020: Access Denied (Cloudflare)1020bind() failed (98: Address already in use) — nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use) (Linux)bind() failed (98: …cf-mitigated: challenge — API/app requests get 403 with cf-mitigated: challenge (Bot Fight Mode / challenge on non-browser clients) (Cloudflare)cf-mitigated: chall…413 — HTTP 413 Content Too Large (Request Entity Too Large) (HTTP)413EMFILE — Too many open files (EMFILE) (Linux)EMFILELink expired — WordPress: The link you followed has expired (WordPress)Link expiredrecv() failed (104: Connection reset by peer) while reading response header — Nginx: [error] recv() failed (104: Connection reset by peer) while reading response header from upstream (Nginx / Apache)recv() failed (104:…WebSocket connection failed through Nginx (missing Upgrade headers) — Browser: WebSocket connection to 'wss://example.com/socket' failed: Error during WebSocket handshake: Unexpected response code: 400 (nginx proxy) (Nginx / Apache)WebSocket connectio…proxy_pass with a URI changes the path (404 from upstream) — Nginx: reverse proxy returns 404 — location /api/ { proxy_pass http://app:3000/; } strips the prefix (or keeps it) (Nginx / Apache)proxy_pass with a U…DB connection — WordPress: Error Establishing a Database Connection (WordPress)DB connectionERR_INVALID_ARG_TYPE — TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined (Node.js)ERR_INVALID_ARG_TYPEopen_basedir — Warning: file_exists(): open_basedir restriction in effect. File(/x) is not within the allowed path(s) (PHP)open_basedir

Directly related (8)

500HTTP

HTTP 500 Internal Server Error

The server hit an unexpected condition — usually an unhandled exception or misconfiguration in the application.

Primary script unknownPHP

FastCGI sent in stderr: "Primary script unknown"

Nginx passed a script path to PHP-FPM that PHP-FPM couldn’t find — usually a wrong SCRIPT_FILENAME or root.

OPcache stale codePHP

PHP still runs old code after deploy (OPcache not reset)

OPcache keeps serving cached bytecode, so changes uploaded to the server don’t take effect.

connect() to unix:/run/php/php-fpm.sock failed (13: Permission denied)Nginx / Apache

Nginx: [crit] connect() to unix:/run/php/php8.3-fpm.sock failed (13: Permission denied) while connecting to upstream

Nginx can't open the PHP-FPM (or app) Unix socket because of socket ownership/permissions or SELinux.

ModSecurity: Access denied with code 403Nginx / Apache

Nginx/Apache: ModSecurity: Access denied with code 403 (phase 2). Matched "Operator GE matched 5 at TX:anomaly_score"

The ModSecurity WAF (OWASP Core Rule Set) blocked the request as suspicious.

nginx: client intended to send too large bodyNginx / Apache

Nginx: [error] client intended to send too large body: 5242880 bytes (413 Request Entity Too Large)

A request body exceeded `client_max_body_size` (default 1 MB), so Nginx returned 413 before reaching your app.

upstream sent too big header while reading response headerNginx / Apache

Nginx: [error] upstream sent too big header while reading response header from upstream (502 Bad Gateway)

The backend's response headers (cookies, Set-Cookie, long headers) exceeded Nginx's proxy/fastcgi buffer size.

PHP file downloads instead of running (Nginx)Nginx / Apache

Browser downloads index.php instead of rendering — Nginx has no fastcgi PHP location

Nginx serves `.php` files as static downloads because no `location ~ \.php$` passes them to PHP-FPM.

Two steps away (23)

404HTTP

HTTP 404 Not Found

The server can’t find anything at the requested URL.

502HTTP

HTTP 502 Bad Gateway

A proxy or gateway (Nginx, load balancer, CDN) got an invalid response — or no response — from the upstream server behind it.

503HTTP

HTTP 503 Service Unavailable

The server is temporarily unable to handle the request — overloaded, in maintenance, or has no healthy backends.

403HTTP

HTTP 403 Forbidden

The server understood the request but refuses to authorize it — you (or the server process) are not allowed to access this resour…

Allowed memory size exhaustedPHP

PHP Fatal error: Allowed memory size of X bytes exhausted

The script tried to use more memory than PHP’s `memory_limit` allows.

ArgumentCountErrorPHP

Fatal error: Uncaught ArgumentCountError: Too few arguments to function foo(), 1 passed and exactly 2 expected

A function was called with fewer arguments than it requires.

App Service Application ErrorAzure

Azure App Service: ":( Application Error" / container didn’t respond to HTTP pings

App Service started your app but it crashed or never listened on the expected port.

FileNotFoundException assembly.NET

Could not load file or assembly 'X, Version=…' or one of its dependencies

The runtime couldn’t find or load a referenced DLL — missing from the output, wrong version, or wrong platform (x86/x64).

Unexpected token <JavaScript

SyntaxError: Unexpected token '<' (HTML served instead of JavaScript)

The browser loaded a .js file but received HTML (an error page or the SPA index.html).

nginx: bind() to 0.0.0.0:80 failed (13: Permission denied)Nginx / Apache

Nginx: nginx: [emerg] bind() to 0.0.0.0:80 failed (13: Permission denied)

Nginx isn't allowed to bind that port — a privileged port as non-root, or SELinux restricts it.

connect() failed (111: Connection refused) while connecting to upstreamNginx / Apache

Nginx: [error] connect() failed (111: Connection refused) while connecting to upstream, upstream: "http://127.0.0.1:3000/"

Nginx tried to proxy a request but nothing listens on the upstream address, so the client gets 502.

1020Cloudflare

Cloudflare Error 1020: Access Denied

A Cloudflare firewall/WAF custom rule blocked the request — the visitor’s IP, country, user agent or request pattern matched a bl…

bind() failed (98: Address already in use)Linux

nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)

Nginx (or another server) can’t listen on the port because another process already holds it — often Apache, another Nginx, or a s…

cf-mitigated: challengeCloudflare

API/app requests get 403 with cf-mitigated: challenge (Bot Fight Mode / challenge on non-browser clients)

Cloudflare is answering API calls, webhooks or mobile-app requests with a challenge page (HTML 403) because bot protection treats…

413HTTP

HTTP 413 Content Too Large (Request Entity Too Large)

The request body is bigger than the server is willing to accept — usually a file upload over the configured limit.

EMFILELinux

Too many open files (EMFILE)

The process hit its file-descriptor limit — sockets, files and pipes all count.

Link expiredWordPress

WordPress: The link you followed has expired

Usually an upload (theme, plugin, media) larger than PHP’s upload/post limits — WordPress receives an empty request and shows thi…

recv() failed (104: Connection reset by peer) while reading response headerNginx / Apache

Nginx: [error] recv() failed (104: Connection reset by peer) while reading response header from upstream

The upstream (PHP-FPM, Node, Gunicorn) closed the connection abruptly while Nginx waited for the response.

WebSocket connection failed through Nginx (missing Upgrade headers)Nginx / Apache

Browser: WebSocket connection to 'wss://example.com/socket' failed: Error during WebSocket handshake: Unexpected response code: 400 (nginx proxy)

Nginx isn't forwarding the `Upgrade`/`Connection` headers needed for WebSockets.

proxy_pass with a URI changes the path (404 from upstream)Nginx / Apache

Nginx: reverse proxy returns 404 — location /api/ { proxy_pass http://app:3000/; } strips the prefix (or keeps it)

Whether `proxy_pass` has a URI part decides if the matched prefix is stripped, so the backend receives an unexpected path.

DB connectionWordPress

WordPress: Error Establishing a Database Connection

WordPress can’t connect to its MySQL/MariaDB database with the credentials in wp-config.php, or the database server is down.

ERR_INVALID_ARG_TYPENode.js

TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined

A Node API got an argument of the wrong type — usually undefined because an env var or config value is missing.

open_basedirPHP

Warning: file_exists(): open_basedir restriction in effect. File(/x) is not within the allowed path(s)

PHP is configured to access only certain directories, and the script tried to touch a file outside them.