Man(ual pages in Unix)

From COMP15212 Wiki
Revision as of 13:04, 2 August 2019 by pc>Yuron
Depends on LibrariesShell

Man is the default Unix manual page reader application. It allows the user to access the built in documentation for the software installed on the computer.

Usage: man [SECTION] PAGES...

To quote the manual page of the man program:

man is the system’s manual pager. Each page argument given to man is normally the name of a program, utility or function. The manual page associated with each of these arguments is then found and displayed. A section, if provided, will direct man to look only in that section of the manual.

Some interesting/useful man pages to check are, hier, ascii, and suffixes.

The manuals can be a very useful source of information but they are rather uncompromising: you usually need to know what you are looking for first, and then they will remind you of the precise syntax. They are not so useful when starting out so don’t worry if they look rather cryptic.

Sections

Some pages (keywords) are used for multiple purposes, depending on context. These are identified by section. Try (e.g.) man -a read to see (successively) the various interpretations of “read”. If you want a specific interpretation you can use (again, e.g.) man 2 read.

Section   Type
1 Executable programs or shell commands
2 System calls (functions provided by the kernel)
3 Library calls (functions within program libraries)
4 Special files (usually found in /dev)
5 File formats and conventions e.g. /etc/passwd
6 Games
7 Miscellaneous (including macro packages and conventions)
8 System administration commands (usually only for root)
9 Kernel routines [Non standard]

 


Hints

  • Running man man will have man present its own manpage
  • Don’t know the command to search for?
    Try the apropos option with man -k <keyword>.
  • Man on Wikipedia


Articles on User
"Everything is a File" • Application Binary Interface (ABI) • Arrays • Boot • Buffer Overflow • Containers • Daemons • Disk Partition • Dynamic Memory Allocation • Emulator traps • Environment Variables • Errors • Exceptions • File Attributes • File Locking • File Permissions • Introduction to Operating Systems • Journalling File System • Links • Locks • Man(ual pages in Unix) • Memory Mapped Files • Monitoring • Network File System (NFS) • PATH • Pipes • Pointers • Relocatable Code • Reset • SETUID • Shell • Sockets • Spooling and Buffering • Streams • Structures • Superuser • System Calls • Unix Signals • User • Using Peripherals