Home >Operation and Maintenance >Linux Operation and Maintenance >What does linux hard disk mount mean?
Linux hard disk mounting refers to attaching a device to an existing directory; mounting refers to the operating system making a computer file on a storage device (such as a hard disk, CD-ROM or shared resource) A process by which directories are made accessible to users through a computer's file system.
#The operating environment of this tutorial: linux5.9.8 system, Dell G3 computer.
What does Linux hard disk mounting mean?
Linux disk mounting
1. Mounting concept
Mounting (mounting) refers to the use of a storage device by the operating system The process by which computer files and directories on a computer (such as a hard drive, CD-ROM, or shared resource) become accessible to users through the computer's file system.
In the Windows operating system: Mounting usually refers to assigning a drive letter to a disk partition (including a virtualized disk partition).
In the Linux operating system: It refers to attaching a device (usually a storage device) to an existing directory.
2. Check the disk status (mounted information)
df -h
3. Check the current Disk partition status
If there is no output content, this situation means that the user rights are insufficient. You need to use root to use
fdisk -l
to see clearly There is still a lot of unused space in /dev/vdb
4. Partition
fdisk /dev/vdb
Check the partition situation
lsblk
5. Formatting
mkfs.xfs /dev/vdb1mkfs -t ext4 /dev/vdb1
7. Mount
Mount the device /dev/vdb1 to the /data directory
mkdir /datamount /dev/vdb1 /data
8. Check the situation after mounting
df -hfdisk -llsblk -f
9. Implement automatic mounting
Implement automatic mounting by modifying /etc/fstab. After the addition is completed, execute mount -a. It can take effect
vim /etc/fstab# 添加一行/dev/vdb1 /data ext4 defaults 0 0
10. Restart verification
After mounting, be sure to restart and verify it. If you mount it incorrectly, disappear, you can proceed to the next step of installation, otherwise all the things you installed will be formatted
If you find that the mount has disappeared after restarting, check what is configured and mounted in vim /etc/fstab Not consistent.
Recommended study: "linux video tutorial"
The above is the detailed content of What does linux hard disk mount mean?. For more information, please follow other related articles on the PHP Chinese website!