ubuntu disk management

  • show partition information
    insert image description heremount device here
    insert image description here
  • Display file system information
    insert image description here
  • build file system
mkfs -t ext4 /dev/nvme0n1p4

Command function: format /dev/nvme0n1p4 as ext4

  • Create a swap partition
mkswap -c -v1 /dev/nvme0n1p4 102400

-c: check
-v1: new swap partition -v0: old version

show disk info

df -l # 显示本地文件系统
df -a # 显示disastrous 文件系统信息
df -i # 显示inode信息
  • What is an inode? - the information of the files in the external storage/memory, the external storage address is indicated by the directory
  • In the figure below, the beginning of / indicates external storage files (the root file of ubuntu system and the boot sector of windows boot manager respectively), and the rest are memory file systems, 1.6G, 8G, 1.6G
    insert image description here

Guess you like

Origin blog.csdn.net/shuia64649495/article/details/132197439