I was looking through some documentations for my university task and noticed that all of the syscalls there are followed by (2), like execv(2), fork(2) or fcntl(2). What do they represent?
-
2Try `man man` :) – pzaenger Jan 12 '20 at 17:02
-
1This has been asked and answered before. – Jonathan Leffler Jan 12 '20 at 17:16
-
1Does this answer your question? [What does the number in parentheses shown after Unix command names in manpages mean?](https://stackoverflow.com/questions/62936/what-does-the-number-in-parentheses-shown-after-unix-command-names-in-manpages-m) – pipe Jan 12 '20 at 17:19
2 Answers
Linux man pages are grouped in sections. Section 2 is "System calls (functions provided by the kernel".
- Executable programs or shell commands
- System calls (functions provided by the kernel)
- Library calls (functions within program libraries)
- Special files (usually found in /dev)
- File formats and conventions eg /etc/passwd
- Games
- Miscellaneous (including macro packages and conventions), e.g. man(7), groff(7)
- System administration commands (usually only for root)
- Kernel routines [Non standard]
Some man pages, such as unlink
" exist in several categories (e.g. 1 and 2), so to browse the page of a specific category, run man section page
(e.g. man 2 unlink
to browse the syscall manual)

- 246,190
- 53
- 318
- 364
Sounds like the same approved answer in this post:
What does the number in parentheses shown after Unix command names in manpages mean?
"It's the section that the man page for the command is assigned to.
These are split as
General commands System calls C library functions Special files (usually devices, those found in /dev) and drivers File formats and conventions Games and screensavers Miscellanea System administration commands and daemons Original descriptions of each section can be seen in the Unix Programmer's Manual (page ii)."

- 139
- 1
- 11