Home  >  Article  >  Computer Tutorials  >  How to display mounts in Linux

How to display mounts in Linux

王林
王林forward
2024-03-21 10:30:03759browse

How to display mounts in Linux

File management in Linux has always been the most important part of the user's workflow. Fortunately, it has a great file system and provides various features for efficient file management. It has commands to create or delete directories, list directories, display directory contents, restrict access, etc. It allows you to view mounted drives and facilitates system monitoring, storage management, troubleshooting disk issues, remote system management, and more. However, learning how to display mounts is essential for every Linux user. So, in this quick blog, we will explain the different commands to display mounts in Linux.

How to display mounts in Linux

In order to view installed drives, just enter a few simple commands. Here are a few commands that can help you display mounted drives conveniently.

1. mount command

The "mount" command displays a complete list of mounts, including mount points, file system types, and mount options.

Mountain

2.df command

If you want detailed information about mounted file systems and the disk space they use, use the "df" command.

DF—H

The "-h" option instructs the system to display it in human-readable format.

3. Read the /etc/fstab file

You can view the disk drive and its partition information by reading the "/etc/fstab" file.

Cat/etc/fstab

This command displays everything on the command line when executed.

4. Findmnt command

The "findmnt" command is an advanced version of the mount command as it provides more verbose output. Additionally, it displays the mounts in a tree structure along with their file types and mount options.

in conclusion

Linux has a powerful file management system, and listing mounts is basic for most users. You can accomplish it using different commands depending on your use case. Therefore, this blog includes four ways to display Linux mounts: the mount, df and findmnt commands, and the "/etc/fstab" file.

The above is the detailed content of How to display mounts in Linux. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:mryunwei.com. If there is any infringement, please contact admin@php.cn delete
Previous article:Which command in LinuxNext article:Which command in Linux