fdisk-Creating partitions

Source: Internet
Author: User

~]# fdisk-l# list partition table

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/7F/A4/wKioL1cnVJShC6c3AAHcHcJyK-0745.jpg "title=" 1.jpg " alt= "Wkiol1cnvjshc6c3aahchcjyk-0745.jpg"/>

~]# fdisk/dev/sda# Change the specified disk ~]# cat/proc/partitions confirm the change effect

Change Disk command actions

D (delete a partition): Delete partition

N (add a new partition): Create a new partition

P (Print the partition table): Show existing partitions

Q (quit without saving changes): Do not save exit

W (write table to disk and exit): writes to disk and exits


650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M02/7F/A6/wKiom1cnXquTxHyYAACaW-Fl5Vo574.jpg "style=" float: none; "title=" 1.jpg "alt=" Wkiom1cnxqutxhyyaacaw-fl5vo574.jpg "/>

650) this.width=650; "src=" http://s5.51cto.com/wyfs02/M02/7F/A6/wKiom1cnXqvSsVT1AAEZlPfw38k457.jpg "style=" float: none; "title=" 2.jpg "alt=" Wkiom1cnxqvssvt1aaezlpfw38k457.jpg "/>

Enter n(create partition) carriage return, default p(primary partition), default allocation partition number, use default start sector, allocate space using +size , allocate 10G here

Note: The disk only supports 4 primary Partitions (3 primary partitions +1 extended partitions (N logical partitions)), currently only 2 primary partitions, so the default recommended p (primary partition)


650) this.width=650; "src=" http://s4.51cto.com/wyfs02/M02/7F/A4/wKioL1cnX6GSRo5yAAEh2Y1Xpb8543.jpg "title=" 3.jpg " alt= "Wkiol1cnx6gsro5yaaeh2y1xpb8543.jpg"/>

Enter n(create partition) carriage return, default e(extended partition), automatically assign partition number, use default start and end sectors

Note: Disk only supports4primary partition, currently available3Primary partition (existing2One, new1one), once redistributedP(primary partition) without using the remaining space, the remaining space will no longer be allocated, so the default recommendede(extended partition), allocating all the remaining space to thee(extended partition) that can be used in the futuree(extended partition) based on the partitioning of logical partitions


650) this.width=650; "src=" http://s1.51cto.com/wyfs02/M00/7F/A6/wKiom1cnXvHjC8ZmAADhh8foK8A326.jpg "title=" 4.jpg " alt= "Wkiom1cnxvhjc8zmaadhh8fok8a326.jpg"/>

Enter n(create partition) carriage return, partitionlogical partition on E (extended partition), allocate space using +size, allocate 5G here


650) this.width=650; "src=" http://s4.51cto.com/wyfs02/M01/7F/A6/wKiom1cnXwzxntFGAAHzCn4fhKI889.jpg "title=" 5.jpg " alt= "Wkiom1cnxwzxntfgaahzcn4fhki889.jpg"/>

View the current partition list


650) this.width=650; "src=" http://s4.51cto.com/wyfs02/M01/7F/A4/wKioL1cnYAOAhEuuAAE7g3x5dOo703.jpg "title=" 6.jpg " alt= "Wkiol1cnyaoaheuuaae7g3x5doo703.jpg"/>

Writes to disk, but is not saved successfully because the device or resource is busy


650) this.width=650; "src=" http://s4.51cto.com/wyfs02/M02/7F/A6/wKiom1cnX03C63qfAAC2iZ9Cnk0913.jpg "title=" 7.jpg " alt= "Wkiom1cnx03c63qfaac2iz9cnk0913.jpg"/>

~] #cat/proc/partitions(Confirm change effect, no new partition)


650) this.width=650; "src=" http://s5.51cto.com/wyfs02/M02/7F/A4/wKioL1cnYDviaIUuAAGCoZ43-rM172.jpg "title=" 8.jpg " alt= "Wkiol1cnydviaiuuaagcoz43-rm172.jpg"/>

~]# partx-a/DEV/SDA (update partition, 2 times, cat/proc/partitions confirmation again)

~]# kpartx-a/DEV/SDA (update partition)

This article is from the "kim1220" blog, make sure to keep this source http://228984.blog.51cto.com/218984/1769545

fdisk-Creating partitions

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.