Resolve issues such as AWS mounting, resolving hangs, and disappearing
There is a difference between a disk on Linux and a window, which must be mounted on a directory, otherwise useless
The actions on the new hard disk, SSD, and Mount to Linux are as follows :
Df-h #显示目前在Linux系统上的文件系统的磁盘使用情况统计.
lsblk # list block device information (volumes that df-h cannot see)
Mount #挂载命令
Now we have a new hard drive, 450G without mount
1. View the space and use space of the hard disk mounted under Linux
Use the following command to format a volume that is attached, but df-h cannot see
Use command: df-h
Filesystem File System
Size File sizes
Used using space
Mounted on Mount Directory
Don't see the 450G disk, now we're going to mount
2. Check if no mounted hard drive is detected in the system
To view the system-detected hard disk commands:lsblk
See indeed NvmeOn1 without a mount, but there
3, Mount (Mount the load , to configure the Mount information under/etc/fstab or restart the mount will disappear)
Use the following command to format a volume that is attached, but df-h cannot see
sudo mkfs-t ext4/dev/nvmeon1 #备注 nvmeOn1 are present in/dev below
Create a directory to mount
Mkdir/data
Mount Command put space on/data mount the formatted volume to a directory
Mount/dev/nvmeon1/data
Check with Df-h again for normal
/dev/nvme0n1/data Auto Defaults,nofail,comment=cloudconfig 0 2
After you add it, you can try the Fstab file to see if it works correctly.
sudo mount-a test for Mount success (do not restart if wrong, otherwise GG)
Haha, see this and you're done.
Linux hard disk usage, mounts, SSD mounts (view volumes not seen by Df-h)