Creating a Data Drive
To meet data storage requirements, a data drive needs to be created for larger data storage capacity.
- Create a file system. XFS is used as an example. In the following command, /dev/nvme0n1 varies according to the actual drive name.
1mkfs.xfs /dev/nvme0n1If a file system has been created for the drive, an error will be reported when you run the command. The -f parameter can be used to forcibly create a file system.
1mkfs.xfs -f /dev/nvme0n1
- Create a data directory.
1mkdir /data - Mount the drive.
1mount /dev/nvme0n1 /data
- Open the /etc/fstab file.
vi /etc/fstab
- Press i to enter the insert mode and add the following content to the end of the file:
/dev/nvme0n1 /data xfs defaults 1 2
The following page is displayed after the modification:

- Press Esc, type :wq!, and press Enter to save the file and exit.
Parent topic: Configuring the Installation Environment