How to add a hard disk in Centos full tutorial Linux hard disk recognition: sda indicates 1st SCSI hard disks. hda indicates 1st IDE hard disks. content 0 indicates 1st USB optical drives. Generally, the fdisk-l command can be used to list the hard disks currently connected to the system. steps: www.2cto. com1. close... how to add a hard disk in Centos full tutorial Linux hard disk recognition: sda indicates 1st SCSI hard disks. hda indicates 1st IDE hard disks. content 0 indicates 1st USB optical drives. Generally, the "fdisk-l" command can be used to list the hard disks currently connected to the system. steps: www.2cto.com 1. disable the server and add a new hard disk. start the server and log on as the root user. view hard Disk information fdisk-l: www.2cto.com Disk/dev/sda: 146.1 GB, 146163105792 bytes 255 heads, 63 sectors/track, 17769 cylinders Units = cylinde Rs of 16065*512 = 8225280 bytes Device Boot Start End Blocks Id System/dev/sda1 * 1 13 104391 83 Linux/dev/sda2 14 5112 40957717 + 83 Linux/dev/sda3 5113 5243 1052257 + 82 Linux swap/Solaris/dev/sda4 5244 17769 100615095 5 Extended/dev/sda5 5244 17769 100615063 + 83 Linux Disk/dev/sdb: 291.3 GB, 291331192320 bytes 255 heads, 63 sectors/track, 17769 cylinders Units = cylinders of 16065*512 = 8225280 bytes Disk/dev/sdb1: 291.3 GB, 291331192320 bytes 4. to create a new hard disk partition, run the "m" command to view the internal command of the "fdisk" command. a: command to specify the start partition; d: command to delete an existing partition; l: command to display the list of partition ID numbers; m: view the help of the fdisk command; n: create a new partition; p: command to display the partition list; t: command to modify the partition type ID; w: the command is to modify and save the partition table to make it work. Fdisk/dev/sdb Command (m for help): n Command action e extended // input e to create an extended partition p primary partition (1-4) p Partion number (1-4): 1 Command (m for help): w input n press enter, p press enter, 1 press enter, one press enter, enter w and press enter to save. View: fdisk-l shows/dev/sdb1 partition 5. format partition: # mkfs-t ext3-c/dev/sdb16. create/data Directory: mkdir/data7. Mount partition: www.2cto.com mount/dev/sdb1/data8. it is automatically mounted after startup # vim/etc/fstab 9. add the following content to the last line:/dev/sdb1/data ext3 defaults 0 0 0 10. test umount/data/mount-a/datadf-h
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service