Linux & VPS

Fix "command not found" on Linux

command not foundNo such file or directorynot in PATH
4 min read Updated 12 June 2026 ESAGAMES Team

"command not found" means the shell couldn't locate that program. Either it isn't installed, or it is but isn't on your PATH. Here's how to tell which and fix it.

Is it installed at all?

Search for the binary. If which finds nothing but the file exists somewhere, it's a PATH problem; if it's nowhere, install it:

which toolname
ls /usr/bin/toolname /usr/local/bin/toolname 2>/dev/null

Install it

# Debian/Ubuntu
apt install package
# RHEL/Alma/Rocky
dnf install package

Installed but "not found"? Fix your PATH

If the binary exists but the shell can't see it, its folder isn't on PATH. Add it (and persist it in your shell profile):

export PATH=":/usr/local/bin"
# make it permanent: add that line to ~/.bashrc
Run it by full path to confirm

If /usr/local/bin/toolname works but toolname alone doesn't, it's definitely PATH — not a missing install.

Not found = not installed, or not on PATH. which/ls to tell which, then install the package or add its folder to PATH.

A clean VDS to work on

Our VDS plans give you full root to install whatever you need, on protected NVMe in Frankfurt.

See VDS plans
FAQ

Frequently asked questions

What does "command not found" mean on Linux?

The shell couldn't find that command in any folder on your PATH. Either the program isn't installed, or it is but its directory isn't on your PATH.

How do I know if it's installed or just not on PATH?

Run which toolname and look for the binary with ls in common bin folders. If the file exists but which doesn't find it, it's a PATH issue; if it doesn't exist, install the package.

How do I add something to my PATH permanently?

Add export PATH="$PATH:/your/dir" to your ~/.bashrc (or ~/.profile), then reload it. That makes the directory available in every new shell session.

Knowledge base

Related articles

Skip the troubleshooting

Managed, protected hosting in Frankfurt — we handle the Linux, the network and the DDoS so you don't have to.

Payments Secure checkout with cards, banking apps and digital wallets.

Choose the payment flow that fits your stack and region without leaving the platform.

Pay by Zen Visa Mastercard Paysafecard PaysafeCash Skrill Trustly Bancontact UnionPay iDeal WebMoney