Error map

syntax error: unexpected end of file (bash script) script.sh: line 25: syntax error: unexpected end of file

Linux · layer 6, Platform & cloud

Open the full error page →

Centre: this error. First ring: errors it is linked with (12). 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.

syntax error: unexpected end of file (bash script) — script.sh: line 25: syntax error: unexpected end of file (Linux)syntax erro…unknown instruction — Dockerfile parse error line N: unknown instruction (Docker)unknown instructionAH00526: Syntax error on line of apache config — Apache: AH00526: Syntax error on line 12 of /etc/apache2/sites-enabled/site.conf: Invalid command 'Foo', perhaps misspelled or defined by a module not included in the server configuration (Nginx / Apache)AH00526: Syntax err…nginx: directive is not terminated by ";" — Nginx: nginx: [emerg] directive "proxy_pass" is not terminated by ";" in /etc/nginx/sites-enabled/app:15 (Nginx / Apache)nginx: directive is…nginx: [emerg] unexpected end of file, expecting ";" or "}" — Nginx: nginx: [emerg] unexpected end of file, expecting ";" or "}" in /etc/nginx/conf.d/site.conf:42 (Nginx / Apache)nginx: [emerg] unex…bash: x: unbound variable (set -u) — script.sh: line 12: DB_HOST: unbound variable (Linux)bash: x: unbound va…fatal: bad config line 5 in file .git/config — fatal: bad config line 12 in file /home/user/.gitconfig (Git)fatal: bad config l…fatal: bad boolean config value 'x' for 'core.autocrlf' — fatal: bad boolean config value 'yes please' for 'core.filemode' (Git)fatal: bad boolean …crontab: "(none)":N: bad minute / errors in crontab file, can't install — "/tmp/crontab.abc":3: bad minute errors in crontab file, can't install. Do you want to retry the same edit? (Linux)crontab: "(none)":N…sudo: >>> /etc/sudoers: syntax error near line 25 <<< — sudo: parse error in /etc/sudoers near line 25 sudo: no valid sudoers sources found, quitting (Linux)sudo: >>> /etc/sudo…bash: ./script.sh: Permission denied — bash: ./script.sh: Permission denied (Linux)bash: ./script.sh: …bash: ./script: /bin/bash^M: bad interpreter — -bash: ./script.sh: /usr/bin/python3\r: bad interpreter: No such file or directory (Linux)bash: ./script: /bi…[: too many arguments / unary operator expected — line 8: [: too many arguments (Linux)[: too many argumen…Parse error — PHP Parse error: syntax error, unexpected … (PHP)Parse errorIndentationError — IndentationError: unexpected indent / expected an indented block (Python)IndentationErrorELIFECYCLE — npm ERR! code ELIFECYCLE / Command failed with exit code 1 (npm)ELIFECYCLEAH00558 — Apache: AH00558: apache2: Could not reliably determine the server's fully qualified domain name (Nginx / Apache)AH00558SSLCertificateFile: file does not exist — Apache: AH02240: Server should be SSL-aware but has no certificate configured / SSLCertificateFile: file '/etc/ssl/x.crt' does not exist or is empty (SSL / TLS)SSLCertificateFile:…AH01909: server certificate does NOT include an ID which matches the server name — Apache: [ssl:warn] AH01909: example.com:443:0 server certificate does NOT include an ID which matches the server name (SSL / TLS)AH01909: server cer…nginx: [emerg] unknown directive — Nginx: nginx: [emerg] unknown directive "x" in /etc/nginx/sites-enabled/x:12 — configuration file test failed (Nginx / Apache)nginx: [emerg] unkn…no "ssl_certificate" is defined for the "listen ... ssl" directive — Nginx: [emerg] no "ssl_certificate" is defined for the "listen ... ssl" directive in /etc/nginx/sites-enabled/default:3 (SSL / TLS)no "ssl_certificate…nginx: duplicate location — Nginx: nginx: [emerg] duplicate location "/" in /etc/nginx/sites-enabled/default:52 (Nginx / Apache)nginx: duplicate lo…nginx: conflicting server name ignored — Nginx: nginx: [warn] conflicting server name "example.com" on 0.0.0.0:80, ignored (Nginx / Apache)nginx: conflicting …nginx: [emerg] open() failed (2: No such file or directory) — Nginx: nginx: [emerg] open() "/etc/nginx/snippets/fastcgi-php.conf" failed (2: No such file or directory) in /etc/nginx/sites-enabled/app:20 (Nginx / Apache)nginx: [emerg] open…nginx: invalid PID number in nginx.pid — Nginx: nginx: [error] invalid PID number "" in "/run/nginx.pid" (when running nginx -s reload) (Nginx / Apache)nginx: invalid PID …E: Failed to fetch ... Hash Sum mismatch — E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy/main/binary-amd64/Packages.gz Hash Sum mismatch Hashes of expected file: SHA256:... (Linux)E: Failed to fetch …E: Could not get lock /var/lib/apt/lists/lock. It is held by process 1234 (unattended-upgr) — E: Could not get lock /var/lib/dpkg/lock-frontend. It is held by process 1234 (unattended-upgr) (Linux)E: Could not get lo…The following packages have been kept back — The following packages have been kept back: linux-generic linux-headers-generic 0 upgraded, 0 newly installed (Linux)The following packa…not a git repository — fatal: not a git repository (or any of the parent directories): .git (Git)not a git repositoryauthor identity unknown — Author identity unknown *** Please tell me who you are. (Git)author identity unk…error: There was a problem with the editor 'vi' — error: There was a problem with the editor 'vi'. Please supply the message using either -m or -F option. (Git)error: There was a …openssl.cnf — OpenSSL: Can't open openssl.cnf for reading / error loading config file (SSL / TLS)openssl.cnfssl_ciphers — nginx: [emerg] SSL_CTX_set_cipher_list("...") failed — invalid ssl_ciphers string (SSL / TLS)ssl_ciphersPushes use the wrong GitHub account / key (multiple SSH keys) — ERROR: Permission to org/repo.git denied to other-user. (Git)Pushes use the wron…lock — Certbot: Another instance of Certbot is already running (SSL / TLS)lockcron job fails: Operation not permitted (needs Full Disk Access for cron) — /usr/sbin/cron: Operation not permitted (macOS)cron job fails: Ope…systemd timer never runs (OnCalendar) — (behavior) timer is active but service never triggers (Linux)systemd timer never…sudoers — user is not in the sudoers file. This incident will be reported. (Linux)sudoerssudo: unable to resolve host — sudo: unable to resolve host <hostname>: Name or service not known (Linux)sudo: unable to res…sudo with Touch ID stops working after macOS update — sudo: a password is required (pam_tid.so removed) (macOS)sudo with Touch ID …daemon — Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? (Docker)daemondata directory permissions — FATAL: data directory "/var/lib/postgresql/data" has invalid permissions — Permissions should be u=rwx (0700) or u=rwx,g=rx (0750). (PostgreSQL)data directory perm…exec permission denied — exec /entrypoint.sh: permission denied (container won't start) (Docker)exec permission den…cannot execute binary file — cannot execute binary file: Exec format error (Linux)cannot execute bina…bad end line — PEM routines: bad end line / no start line — Windows CRLF line endings or truncated PEM file (SSL / TLS)bad end line/bin/bash^M: bad interpreter — /usr/bin/env: 'bash\r': No such file or directory (Git)/bin/bash^M: bad in…

Directly related (12)

unknown instructionDocker

Dockerfile parse error line N: unknown instruction

A line in the Dockerfile doesn’t start with a valid instruction — usually a broken line continuation or a typo.

AH00526: Syntax error on line of apache configNginx / Apache

Apache: AH00526: Syntax error on line 12 of /etc/apache2/sites-enabled/site.conf: Invalid command 'Foo', perhaps misspelled or defined by a module not included in the server configuration

Apache's config has a syntax problem or a directive from a module that isn't loaded.

nginx: directive is not terminated by ";"Nginx / Apache

Nginx: nginx: [emerg] directive "proxy_pass" is not terminated by ";" in /etc/nginx/sites-enabled/app:15

A directive's arguments run into the next line because the `;` is missing (or a quote is unbalanced).

nginx: [emerg] unexpected end of file, expecting ";" or "}"Nginx / Apache

Nginx: nginx: [emerg] unexpected end of file, expecting ";" or "}" in /etc/nginx/conf.d/site.conf:42

The config ends while a block or directive is still open — a missing `}` or `;`.

bash: x: unbound variable (set -u)Linux

script.sh: line 12: DB_HOST: unbound variable

`set -u` stops on an undefined variable.

fatal: bad config line 5 in file .git/configGit

fatal: bad config line 12 in file /home/user/.gitconfig

A Git config file has invalid syntax.

fatal: bad boolean config value 'x' for 'core.autocrlf'Git

fatal: bad boolean config value 'yes please' for 'core.filemode'

A boolean Git setting has an invalid value.

crontab: "(none)":N: bad minute / errors in crontab file, can't installLinux

"/tmp/crontab.abc":3: bad minute errors in crontab file, can't install. Do you want to retry the same edit?

The crontab syntax is invalid.

sudo: >>> /etc/sudoers: syntax error near line 25 <<<Linux

sudo: parse error in /etc/sudoers near line 25 sudo: no valid sudoers sources found, quitting

A broken sudoers file blocks sudo entirely.

bash: ./script.sh: Permission deniedLinux

bash: ./script.sh: Permission denied

The script isn't executable or lives on a noexec mount.

bash: ./script: /bin/bash^M: bad interpreterLinux

-bash: ./script.sh: /usr/bin/python3\r: bad interpreter: No such file or directory

The shebang has a wrong path or CRLF line endings.

[: too many arguments / unary operator expectedLinux

line 8: [: too many arguments

An unquoted variable expanded to several words or nothing.

Two steps away (33)

Parse errorPHP

PHP Parse error: syntax error, unexpected …

PHP can’t parse the file because of a syntax mistake — the real error is often on the line before the one reported.

IndentationErrorPython

IndentationError: unexpected indent / expected an indented block

Python’s block structure is broken — inconsistent indentation or mixed tabs and spaces.

ELIFECYCLEnpm

npm ERR! code ELIFECYCLE / Command failed with exit code 1

An npm script (build, start, test, postinstall) exited with an error. ELIFECYCLE is only the wrapper — the real error is printed…

AH00558Nginx / Apache

Apache: AH00558: apache2: Could not reliably determine the server's fully qualified domain name

A harmless startup warning: Apache has no global ServerName, so it guessed one from the host’s IP.

SSLCertificateFile: file does not existSSL / TLS

Apache: AH02240: Server should be SSL-aware but has no certificate configured / SSLCertificateFile: file '/etc/ssl/x.crt' does not exist or is empty

Apache cannot find the certificate or key file named in its configuration, or `SSLEngine on` is set without any certificate.

AH01909: server certificate does NOT include an ID which matches the server nameSSL / TLS

Apache: [ssl:warn] AH01909: example.com:443:0 server certificate does NOT include an ID which matches the server name

Apache's SSL virtual host name does not match any name inside the certificate it loads.

nginx: [emerg] unknown directiveNginx / Apache

Nginx: nginx: [emerg] unknown directive "x" in /etc/nginx/sites-enabled/x:12 — configuration file test failed

Nginx found a directive it doesn’t know — a typo, a missing semicolon on the previous line, a directive from a module that isn’t…

no "ssl_certificate" is defined for the "listen ... ssl" directiveSSL / TLS

Nginx: [emerg] no "ssl_certificate" is defined for the "listen ... ssl" directive in /etc/nginx/sites-enabled/default:3

A server block listens with `ssl` but has no `ssl_certificate` and `ssl_certificate_key`.

nginx: duplicate locationNginx / Apache

Nginx: nginx: [emerg] duplicate location "/" in /etc/nginx/sites-enabled/default:52

Two `location` blocks with the same match exist in one server block (often from two included files).

nginx: conflicting server name ignoredNginx / Apache

Nginx: nginx: [warn] conflicting server name "example.com" on 0.0.0.0:80, ignored

Two server blocks listen on the same port with the same `server_name`; the second is ignored.

nginx: [emerg] open() failed (2: No such file or directory)Nginx / Apache

Nginx: nginx: [emerg] open() "/etc/nginx/snippets/fastcgi-php.conf" failed (2: No such file or directory) in /etc/nginx/sites-enabled/app:20

The config includes a file (snippet, certificate, ssl option file) that doesn't exist.

nginx: invalid PID number in nginx.pidNginx / Apache

Nginx: nginx: [error] invalid PID number "" in "/run/nginx.pid" (when running nginx -s reload)

Nginx can't signal the master process because the PID file is empty, stale or missing.

E: Failed to fetch ... Hash Sum mismatchLinux

E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy/main/binary-amd64/Packages.gz Hash Sum mismatch Hashes of expected file: SHA256:...

The downloaded index doesn't match its checksum.

E: Could not get lock /var/lib/apt/lists/lock. It is held by process 1234 (unattended-upgr)Linux

E: Could not get lock /var/lib/dpkg/lock-frontend. It is held by process 1234 (unattended-upgr)

Another apt/dpkg process is running.

The following packages have been kept backLinux

The following packages have been kept back: linux-generic linux-headers-generic 0 upgraded, 0 newly installed

apt won't upgrade some packages automatically.

not a git repositoryGit

fatal: not a git repository (or any of the parent directories): .git

You ran a Git command outside a Git working tree.

author identity unknownGit

Author identity unknown *** Please tell me who you are.

Git doesn’t know your name and email for commits.

error: There was a problem with the editor 'vi'Git

error: There was a problem with the editor 'vi'. Please supply the message using either -m or -F option.

Git couldn't open your configured editor to collect a message or todo list.

openssl.cnfSSL / TLS

OpenSSL: Can't open openssl.cnf for reading / error loading config file

OpenSSL can't find or parse its configuration file, so `req`, `ca` or `x509` commands abort.

ssl_ciphersSSL / TLS

nginx: [emerg] SSL_CTX_set_cipher_list("...") failed — invalid ssl_ciphers string

The `ssl_ciphers` value contains a cipher or syntax OpenSSL doesn't accept, so nginx won't load the config.

Pushes use the wrong GitHub account / key (multiple SSH keys)Git

ERROR: Permission to org/repo.git denied to other-user.

SSH offers the wrong key, so GitHub sees another account.

lockSSL / TLS

Certbot: Another instance of Certbot is already running

A previous certbot process (or cron/systemd timer) holds the lock file, so a new run refuses to start.

cron job fails: Operation not permitted (needs Full Disk Access for cron)macOS

/usr/sbin/cron: Operation not permitted

cron lacks Full Disk Access.

systemd timer never runs (OnCalendar)Linux

(behavior) timer is active but service never triggers

The timer isn't scheduled as you expect.

sudoersLinux

user is not in the sudoers file. This incident will be reported.

Your account isn’t allowed to use sudo.

sudo: unable to resolve hostLinux

sudo: unable to resolve host <hostname>: Name or service not known

The machine’s hostname isn’t in /etc/hosts (or DNS), so sudo prints this warning — usually after changing the hostname.

sudo with Touch ID stops working after macOS updatemacOS

sudo: a password is required (pam_tid.so removed)

macOS updates overwrite `/etc/pam.d/sudo`.

daemonDocker

Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

The docker CLI can’t talk to the Docker engine — it isn’t running, or your user can’t access the socket.

data directory permissionsPostgreSQL

FATAL: data directory "/var/lib/postgresql/data" has invalid permissions — Permissions should be u=rwx (0700) or u=rwx,g=rx (0750).

PostgreSQL refuses to start because the data directory is too open or owned by the wrong user.

exec permission deniedDocker

exec /entrypoint.sh: permission denied (container won't start)

The entrypoint or command isn’t marked executable inside the image, or it’s on a volume mounted noexec.

cannot execute binary fileLinux

cannot execute binary file: Exec format error

The program was built for a different CPU architecture or OS — e.g. an x86_64 binary on an ARM machine (Raspberry Pi, Graviton, A…

bad end lineSSL / TLS

PEM routines: bad end line / no start line — Windows CRLF line endings or truncated PEM file

OpenSSL can't parse a PEM file because it has Windows line endings, missing newlines or a damaged BEGIN/END line.

/bin/bash^M: bad interpreterGit

/usr/bin/env: 'bash\r': No such file or directory

A shell script has Windows line endings, so the interpreter name includes a carriage return.