Newly bought 2T green plate arrived ~ ~ Very happy to say ~ But after all, is the first installation, in advance or on the Internet to search a lot of information to dare to do, the following began ~
Environment: CENTOS7, Dell Server, 2T capacity green disk
1. After the hard drive is connected, start using FDISK-L to query disk information, you can find the hard disk is located in the/dev/sdb directory# fdisk-l
2. The next partition operation is required, since the use of a large capacity hard disk with 2T capacity, the command that must be partitioned using the GPT large partition format is# parted SDB
3. First execute the instruction to modify the partition format, select Yes to confirm the operation(parted) Mklabel GPT
4. Create primary partition, command is Mkpart Primary < start address > < space size/footprint >(parted)/dev/sdb Mkpart primary 2048s 100%
PS. Because the hard disk I only want to do a bit of data storage, a primary partition is sufficient, if more than one primary partition can be done as follows
(parted)/dev/sdb Mkpart primary 0 500GB
(parted)/dev/sdb Mkpart primary 500GB 1400GB
...
But in this step it is easy to get a warning: For example, I have this warning when I perform the following partitioning method (parted)/dev/sdb Mkpart primary 0 2000GB "The resulting partition is not a properly aligned for best performance." Finding data from the Web can be known as a warning because of an unreasonable start-sector location in the partition. Here's how to fix it: View the values of several files separately # cat/sys/block/sdb/queue/optimal_io_size 0 # cat/sys/block/sdb/queue/minimum_io_size 4096 # Cat/sys/block/sdb/alignment_offset 0 # cat/sys/block/sdb/queue/physical_block_size 4096 If Optimal_io_size is not 0, use the corresponding value to bring in the following formula (Optimal_io_size + alignment_offset)/physical_block_size Calculates a reasonable value that is the starting position of the primary partition If Ptimal_io_size is 0, you can use the start sector default value of 2048 directly IE (parted) primary 2048s-1 Reference: http://rainbow.chard.org/2013/01/30/how-to-align-partitions-for-best-performance-using-parted/ |
5. Quit with the QUIT command(parted) Quit
and use MKFS for formatting
# mkfs.ext4-f/DEV/SDB1
Then wait for the creation to finish
6. Mounting
#mount/dev/sdb1/mnt/disk
If you want to automatically mount the boot
Can be written in the/etc/fstab file
/dev/sdb1/mnt/disk Auto Defaults 0 0
[Capacity expansion]centos7 install 2T mass storage HDD