Red Flag asianux Server 3 System Management: Disk partition management

Source: Internet
Author: User
Keywords Disk partition management Asianux
Tags aliyun create creating customize data deleting disk disk partition management

The parted program makes it easy to manage and customize disk partitions, such as viewing existing partitioned tables, changing the size of partitions, deleting partitions, creating new partitions, and so on.

&http://www.aliyun.com/zixun/aggregation/37954.html ">NBSP; changing the system's hard disk partitions is a very dangerous thing, even for experienced system administrators We still recommend that you make the necessary data backups before changing the disk partitions.

For more information about the naming design and partitioning methods and principles for disk partitions, see related content in the Red Flag asianux Server 3 Installation Guide. At the shell prompt, type the following command as Superuser (/DEV/HDB represents the device name to be customized).

# PARTED/DEV/HDB

After you start parted, type help at the (parted) prompt to display a list of available commands. The following table lists the parted commands most commonly used by users.

parted command

Command and parameter description and description check minor-num the file system for a simple check. The CP from to, which copies the file system from one partition to another; From and to represents a list of available command lists Mklabel label is a partition Table Create disk label MKFS minor-num fs-type Create file system Mkpart Part-type fs-type START-MB end-mb make partitions with Fs-type Mkpartfs Fs-type START-MB END-MB make partitions and create specified file system move minor-num start-mb END-MB Mobile partition print display partition table quit exit parted program resize Minor-num St ART-MB END-MB partition size, from START-MB to end-mb RM minor-num Delete Partition Select device Choose another device to customize, no reboot parted set Minor-num flag State Set flag on partition, state can be on or off

To create a new, delete, or repartition partition size, the partition's device cannot be used, that is, the partition cannot be mounted, and the swap space cannot be enabled. If the partition does not contain files that are being used, you can uninstall the partition with the Umount command and use the Swapoff command to turn off the swap space.

2.2.1 View partition Table

After you start parted, type the print command to view the partition table, and the screen will output the following information.

The first line shows the size of the disk, the second row shows the disk label type, and the following section is the partition table, where:

The minor field represents a number in a partitioned device name, such as a number 1 representing/dev/hda1;start and end representing the corresponding partition on the hard disk, in megabytes, and the type in MB, which can be one of the primary, extended, and logical FileSystem is the type of file system, can be ext2, ext3, FAT, LINUX-SWAP, etc. the Flags field lists the criteria that the partition is set up, and the available flags are: boot, root, swap, hidden, RAID, LVM, and so on.

Related Article

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.