man, help, info

LPIC-1LINUX

man

The manual pages — the standard reference for commands, system calls, config files, etc. Organized into numbered sections:

  1. User commands

  2. System calls

  3. Library calls

  4. Special files (/dev)

  5. File formats

  6. Games

  7. Miscellaneous

  8. Admin/root commands

Main sections:

Section Content Type Example

1 User Commands ls, pwd, grep

5 File Formats /etc/passwd, /etc/fstab

8 System Admin Commands fdisk, reboot, iptables

Same name can exist in multiple sections — man 5 passwd (file format of /etc/passwd) vs man 1 passwd (the command). Without a number, man shows the first match found.

Structure of the 'man' page:

NAME ..
SYNOPSIS ..
DESCRIPTION ..

Navigating inside a Man Page

Since man uses the less pager by default, you need to know these keyboard shortcuts:

  • /pattern: Search forward for "pattern".

  • ?pattern: Search backward for "pattern".

  • n / N: Go to the next or previous match.

  • g / G: Go to the top (start) or bottom (end) of the page.

  • q: Quit the manual.

Location and Path

Where these manual files are stored or how the system finds them.

  • Location: Usually /usr/share/man.

man -k (same as apropos)

Searches the short descriptions of all man pages for a keyword, when you don't know the exact command name. It relies on a search index (mandb), which is why a fresh system sometimes needs mandb run to build it before -k works. Related: whatis, which gives a one-line description if you already know the exact name.

Note:

If you get a "...: nothing appropriate." message after running "man -k", it means that you need to rebuild your man database. For that, you can safely execute:

sudo mandb

(It takes a few seconds. Then try "man -k" again, for example, "man -k partition")

help

This is for shell builtins — commands that are part of the shell itself (bash), not separate executables. Things like cd, echo, export, type don't have their own binary, so man cd won't give you useful info (you'd just get a generic bash builtins page or nothing specific). help cd gives you the actual builtin's usage. Use type command first if you're unsure whether something is a builtin or an external program — that tells you whether help or man is the right tool.

info

GNU's own hypertext-style documentation system, used especially for GNU tools. More structured and often more detailed than man pages, organized into linked nodes you navigate with keys (n next node, p previous, u up, q quit, etc.). Not every command has an info page, but many core GNU utilities do, and it's often more thorough than the equivalent man page.

Summary:

Tool Use for

man External commands, config files, syscalls (numbered sections)

man -k / apropos Searching by keyword when you don't know the command name

help Shell builtins only

info GNU-style detailed docs, hypertext navigation

Contact

Email

hello@unixtips.eu

© 2025. All rights reserved.