I wanted to access man pages for command chmod.
Command whatis chmod gave this output:
chmod (2) - change permissions of a file
chmod (1) - change file mode bits
But I was actually looking for chmod(2).
When I type man chmod, man pages for chmod(1) appears.
Both man chmod(2) and man 'chmod(2)' commands show error.
I tried running info coreutils 'chmod invocation', but output is some kind of documentation which doesn’t look like a typical man page.
Answers:
Thank you for visiting the Q&A section on Magenaut. Please note that all the answers may not help you solve the issue immediately. So please treat them as advisements. If you found the post helpful (or not), leave a comment & I’ll get back to you as soon as possible.
Method 1
Type: man 2 chmod, or man -a chmod to get all the versions.
Note: man -a chmod may be useful on some systems, because there may be other man pages on the same function, which may give additional information. For instance, under Debian, if the manpages-posix-dev package is installed, there’s also the chmod(3posix) man page, also accessible via man 3 chmod.
All methods was sourced from stackoverflow.com or stackexchange.com, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0