1. Divide the primary partition of the external storage:
Assuming that the external storage is recognized as/DEV/SDB in the Linux system, use the FDISK/DEV/SDB to enter the partition tool operator interface.
Press the P key to print the current external storage partition, if displayed as empty, it means that the storage is not partitioned;
Press N to create a new partition and press the P key to create a new primary partition (press the E key to create a new partition). If you are/dev/sdb all resources into a primary partition, type 1 (carriage return), (carriage return), and (carriage return) to create a partitioned table.
Press the W key to exit and save the Fdisk partition tool, at which point the external storage is partitioned into a primary partition named/DEV/SDB1.
2. Format the primary partition
Use the command line MKFS.EXT3/DEV/SDB1 to format/dev/sdb1 as a ext3-formatted partition.
Hint this: Writing superblocks and filesystem accounting information: Enter can
3. Mount Partition
Create Mount Path: Mkdir/mnt/sdb.
Manually mount the/DEV/SDB1 under the/mnt/sdb path: Mount/dev/sdb1/mnt/sdb.
After completing the above steps, the external storage has been mounted to the/mnt/sdb file directory, and users can access the files in the external storage by accessing/MNT/SDB. However, after the system shutdown, the external storage will be automatically uninstalled, the user in the boot system to be manually mounted to the/MNT/SDB
4. Configure system files to automatically mount the external storage when the system starts
Modify the/etc/fstab file at the end of the file in a row, enter "/dev/sdb1/mnt/sdb ext3 defaults 1 1", Save and exit.
CentOS disk partitioning, formatting and mounting external storage methods