Bash is not finding a program even though it's on my path

Note the output here:

root:/usr/local/bin# siege
bash: /usr/bin/siege: No such file or directory

Bash maintains an internal hash of previously found executables in your path. In this case, it has details that at one time there was an executable at /usr/bin/siege, and reuses that path to avoid having to search again. You need to tell bash to manually rehash the path for siege like so:

hash siege

You can also clear all hashed locations:

hash -r

Tags:

Bash

Path