Search

The whereis command

Locates the binary, the source code and the manual pages of a command.

Syntax

whereis comando

Most useful options

-bOnly the binary
-mOnly the manual pages

Copy-ready examples

$ whereis lsWhere ls lives

You can try them in the browser terminal: it does not touch your computer.

Typical mistakes

  • whereis searches known paths; if the program is somewhere unusual it will not see it. For that use which.

Related commands

FAQ

Difference from which?

which tells which executable would run; whereis also gives the manual and source.

Learn to actually use it

The basic Linux course takes you from zero to console fluency with 24 self-grading lessons.

Start the free course