LFCS · Question #696
In order to display all currently mounted filesystems, which of the following commands could be used? (Choose TWO correct answers.)
The correct answer is A. cat /proc/self/mounts C. mount. To display all currently mounted filesystems, one can use the mount command without arguments or examine the /proc/self/mounts file.
Question
Options
- Acat /proc/self/mounts
- Bfree
- Cmount
- Dlsmounts
- Ecat /proc/filesystems
How the community answered
(30 responses)- A90% (27)
- B7% (2)
- E3% (1)
Why each option
To display all currently mounted filesystems, one can use the `mount` command without arguments or examine the `/proc/self/mounts` file.
The file `/proc/self/mounts` (which is a symbolic link to `/proc/mounts`) contains a list of all currently mounted filesystems, including their device, mount point, type, and options, making `cat` an effective way to display this information.
The `free` command provides information about free and used memory, swap space, and kernel buffers, not about mounted filesystems.
The `mount` command, when executed without any options or arguments, will list all currently mounted file systems, detailing their source, mount point, type, and mount options in a human-readable format.
`lsmounts` is not a standard Linux command for listing mounted filesystems; typical commands for this purpose are `mount`, `findmnt`, or reading `/proc/mounts`.
`cat /proc/filesystems` lists the filesystem types supported by the kernel, such as ext4, xfs, or fat, rather than the currently mounted instances of filesystems.
Concept tested: Listing active mounted filesystems
Source: https://man7.org/linux/man-pages/man8/mount.8.html
Topics
Community Discussion
No community discussion yet for this question.