gnu parted user manual

26
7/29/2019 Gnu Parted User Manual http://slidepdf.com/reader/full/gnu-parted-user-manual 1/26 GNU Parted User Manual GNU Parted, version 3.1, 2 February 2012 Andrew Clausen [email protected] Richard M. Kreuter [email protected] Leslie Patrick Polzer [email protected] Copyright c 1999-2011 Free Sotware Foundation, Inc. Permission is granted to copy, distribute and/or modiy this document under the terms o the GNU Free Documentation License, Version 1.3 or any later version published by the Free Sotware Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy o the license is included in the section entitled “GNU Free Documentation License”.

Upload: john-hunt

Post on 04-Apr-2018

242 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 1/26

GNU Parted User ManualGNU Parted, version 3.1, 2 February 2012

Andrew Clausen [email protected]

Richard M. Kreuter [email protected]

Leslie Patrick Polzer [email protected]

Copyright c 1999-2011 Free Sotware Foundation, Inc.Permission is granted to copy, distribute and/or modiy this document under the terms o the GNU Free Documentation License, Version 1.3 or any later version published by theFree Sotware Foundation; with no Invariant Sections, with no Front-Cover Texts, and withno Back-Cover Texts. A copy o the license is included in the section entitled “GNU FreeDocumentation License”.

Page 2: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 2/26

i

Short Contents

1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

2 Using Parted. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

43 Related information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

A Copying This Manual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

B This manual’s history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22

Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

Page 3: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 3/26

Chapter 1: Introduction 1

1 Introduction

1.1 Overview of GNU Parted

GNU Parted is a program or creating and manipulating partition tables.

This documentation is written with the assumption that the reader has some under-standing o partitioning and le systems.

GNU Parted was designed to minimize the chance o data loss. For example, it wasdesigned to avoid data loss during interruptions (like power ailure) and perorms manysaety checks. However, there could be bugs in GNU Parted, so you should back up yourimportant les beore running Parted.

The GNU Parted homepage is http://www.gnu.org/software/parted. The libraryand rontend themselves can be downloaded rom ftp://ftp.gnu.org/gnu/parted. Youcan also nd a listing o mailing lists, notes or contributing and more useul inormation

on the web site.Please send bug reports to [email protected]. When sending bug reports, please

include the version o GNU Parted. Please include the output rom these commands (ordisk ‘/dev/hda’):

# parted /dev/hda print unit s print unit chs print

Feel ree to ask or help on this list — just check that your question isn’t answeredhere rst. I you don’t understand the documentation, please tell us, so we can explain itbetter. General philosophy is: i you need to ask or help, then something needs to be xedso you (and others) don’t need to ask or help.

Also, we’d love to hear your ideas :-)

1.2 Software Required for the use of Parted

I you’re installing or compiling Parted yoursel, you’ll need to have some other programsinstalled. I you are compiling Parted, you will need both the normal and devel packageso these programs installed:

• libuuid, part o the e2sprogs package. I you don’t have this, you can get it rom:

http://web.mit.edu/tytso/www/linux/e2fsprogs.html

I you want to compile Parted and e2sprogs, note that you will need to make install

and make install-libs e2sprogs.

• GNU Readline (optional), available rom

ftp://ftp.gnu.org/gnu/readline

I you are compiling Parted, and you don’t have readline, you can disable Parted’sreadline support with the --disable-readline option or configure.

• GNU gettext (or compatible sotware) or compilation, i internationalisation supportis desired.

ftp://ftp.gnu.org/gnu/gettext

• libreisers, i you want reisers support:

http://reiserfs.osdn.org.ua

Page 4: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 4/26

Chapter 1: Introduction 2

Note that parted will automatically detect libreisers at runtime, and enable reiserssupport. libreisers is new, and hasn’t been widely tested yet.

1.3 Platforms on which GNU Parted runs

Hopeully, this list will grow a lot. I you do not have one o these platorms, then you canuse a rescue disk and a static binary o GNU Parted.

GNU/LinuxLinux versions 2.0 and up, on Alpha, x86 PCs, PC98, Macintosh PowerPC, Sunhardware.

GNU/Hurd

1.4 Terms of distribution for GNU Parted

GNU Parted is ree sotware, covered by the GNU General Public License Version 2. Thisshould have been included with the Parted distribution, in the COPYING le. I not, writeto the Free Sotware Foundation, Inc., 51 Franklin St, Fith Floor, Boston, MA 02110-1301,USA.

Libparted is considered part o GNU Parted. It is covered by the GNU General PublicLicense. It is NOT released under the GNU Lesser General Public License (LGPL).

1.5 Building GNU Parted

I you want to compile GNU Parted, this is generally done with:

$ ./configure

$ make

However, there are a ew options or configure:

--without-readline

turns of use o readline. This is useul or making rescue disks, etc., where ewlibraries are available.

--disable-debug

don’t include assertions

--disable-dynamic-loading

disables dynamic loading o some libraries (only libreisers or now, althoughwe hope to expand this). Dynamic loading is useul because it allows you toreuse libparted shared libraries even when you don’t know i some libraries willbe available. It has a small overhead (mainly linking with libdl), so it may be

useul to disable it on bootdisks i you don’t need the exibility.--disable-nls

turns of native language support. This is useul or use with old versions o glibc, or a trimmed down version o glibc suitable or rescue disks.

--disable-shared

turns of shared libraries. This may be necessary or use with old versions o GNU libc, i you get a compile error about a “spilled register”. Also useul orboot/rescue disks.

Page 5: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 5/26

Chapter 1: Introduction 3

--enable-discover-only

support only reading/probing (reduces size considerably)

--enable-mtrace

enable malloc() debugging--enable-read-only

disable writing (or debugging)

1.5.1 Introduction

I you want to run GNU Parted on a machine without GNU/Linux in-stalled, or you want to modiy a root or boot partition, use GParted Live:http://gparted.sourceforge.net/livecd.php .

Page 6: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 6/26

Chapter 2: Using Parted 4

2 Using Parted

2.1 Introduction to Partitioning

Unortunately, partitioning your disk is rather complicated. This is because there are in-teractions between many diferent systems that need to be taken into consideration.

This manual used to introduce the reader to these systems and their working. Thiscontent has moved to the GNU Storage Guide.

2.2 Using GNU Parted

Parted has two modes: command line and interactive. Parted should always be startedwith:

# parted device

where device  is the hard disk device to edit. (I you’re lazy and omit the DEVICE argument,

Parted will attempt to guess which device you want.)In command line mode, this is ollowed by one or more commands. For example:

# parted /dev/sda mklabel gpt mkpart P1 ext3 1MiB 8MiB 

Options (like --help) can only be specied on the command line.

In interactive mode, commands are entered one at a time at a prompt, and modiy thedisk immediately. For example:

(parted) mklabel gpt

(parted) mkpart P1 ext3 1MiB 8MiB 

Unambiguous abbreviations are allowed. For example, you can type “p” instead o “print”,and “u” instead o “units”. Commands can be typed either in English, or your nativelanguage (i your language has been translated). This may create ambiguities. Commandsare case-insensitive.

Numbers indicating partition locations can be whole numbers or decimals. The suxselects the unit, which may be one o those described in Section 2.4.13 [unit], page 10,except CHS and compact. I no sux is given, then the deault unit is assumed. Negativenumbers count back rom the end o the disk, with “-1s” indicating the sector at the endo the disk. Parted will compute sensible ranges or the locations you speciy (e.g. a rangeo  +/- 500 MB when you speciy the location in “G”). Use the sector unit “s” to speciyexact locations. With parted-2.4 and newer, IEC binary units like “MiB”, “GiB”, “TiB”,etc., speciy exact locations as well. See See [IEC binary units], page 11.

I you don’t give a parameter to a command, Parted will prompt you or it. Forexample:

(parted) mklabel

New disk label type? gpt

Parted will always warn you beore doing something that is potentially dangerous,unless the command is one o those that is inherently dangerous (viz., rm, mklabel andmkpart). Since many partitioning systems have complicated constraints, Parted will usuallydo something slightly diferent to what you asked. (For example, create a partition startingat 10.352Mb, not 10.4Mb) I the calculated values difer too much, Parted will ask you orconrmation.

Page 7: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 7/26

Chapter 2: Using Parted 5

2.3 Command Line Options

When invoked rom the command line, Parted supports the ollowing syntax:

# parted [option ] device [command [argument]]

Available options and commands ollow. For detailed explanations o the use o Partedcommands, see Section 2.4 [Command explanations], page 5. Options begin with a hyphen,commands do not:

Options:

‘-h’‘--help’ display a help message

‘-s’‘--script’

never prompt the user

‘-a alignment-type’‘--align alignment-type’

Set alignment or newly created partitions, valid alignment types are: none,cylinder, minimal and optimal.

‘-v’‘--version’

display the version

2.4 Parted Session Commands

GNU Parted provides the ollowing commands:

Note that ater version 2.4, the ollowing commands were removed: check, cp, mks,

mkparts, move, resize.

2.4.1 align-check

[Command]align-check align-type nDetermine whether the starting sector o partition n meets the disk’s selected align-ment criteria. align-type  must be ‘ minimal’, ‘optimal’ or an abbreviation. When inscript mode, i the partition does not meet the alignment requirement, exit with sta-tus 1; otherwise (including on older kernels or which alignment data is not available),continue processing any remaining commands. Without ‘--script’, print either ‘N 

aligned’ or ‘N  not aligned’.

Example:

(parted) align-check minimal 1

1 aligned

2.4.2 disk set

[Command]disk_set flag stateChanges a ag on the disk. A ag can be either “on” or “of”. Some or all o theseags will be available, depending on what disk label you are using:

Page 8: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 8/26

Chapter 2: Using Parted 6

‘pmbr_boot’(GPT) - this ag enables the boot ag on the GPT’s protective MBRpartition.

The disk’s ags are displayed by the print command on the "Disk Flags:" line. Theyare also output as the last eld o the disk inormation in machine mode.

(parted) disk_set pmbr_boot on

Set the PMBR’s boot ag.

2.4.3 help

[Command]help [command ]Prints general help, or help on command .

Example:

(parted) help mklabel

Print help or the mklabel command.

2.4.4 mklabel

[Command] mklabel label-typeCreates a new disk label, o type label-type . The new disk label will have no parti-tions. This command (normally) won’t technically destroy your data, but it will makeit basically unusable, and you will need to use the rescue command (see Chapter 3 [Re-lated inormation], page 13) to recover any partitions. Parted works on all partitiontables.1

label-type  must be one o these supported disk labels:

• bsd

• loop (raw disk access)

• gpt

• mac

• msdos

• pc98

• sun

Example:

(parted) mklabel msdos

Create an MS-DOS disk label. This is still the most common disk label or PCs.

2.4.5 mkpart

[Command] mkpart [ part-type fs-type name] start endCreates a new partition, without  creating a new le system on that partition. Thisis useul or creating partitions or le systems (or LVM, etc.) that Parted doesn’t

1 Everyone seems to have a diferent word or “disk label” — these are all the same thing: partition

table, partition map.

Page 9: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 9/26

Chapter 2: Using Parted 7

support. You may speciy a le system type, to set the appropriate partition code inthe partition table or the new partition. fs-type  is required or data partitions (i.e.,non-extended partitions). start and end are the ofset rom the beginning o the disk,that is, the “distance” rom the start o the disk.

 part-type  is one o ‘primary’, ‘extended’ or ‘logical’, and may be specied onlywith ‘ msdos’ or ‘dvh’ partition tables. A name  must be specied or a ‘gpt’ partitiontable. Neither part-type  nor name  may be used with a ‘sun’ partition table.

fs-type must be one o these supported le systems:

• ext2

• at16, at32

• hs, hs+, hsx

• linux-swap

• NTFS

• reisers

• us

Example:

(parted) mkpart logical 0.0 692.1

Create a logical partition that will contain an ext2 le system. The partition willstart at the beginning o the disk, and end 692.1 megabytes into the disk.

2.4.6 name

[Command]name number nameSets the name or the partition number  (GPT, Mac, MIPS and PC98 only). Thename can be placed in quotes.

Example:

(parted) name 2 ’Secret Documents’

Set the name o partition 2 to ‘Secret Documents’.

2.4.7 print

[Command]print [number ]Displays the partition table on the device parted is editing, or detailed inormationabout a particular partition.

Example:

Page 10: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 10/26

Chapter 2: Using Parted 8

(parted) print

Disk geometry for /dev/hda: 0.000-2445.679 megabytes

Disk label type: msdos

Minor Start End Type Filesystem Flags

1 0.031 945.000 primary fat32 boot, lba

2 945.000 2358.562 primary ext2

3 2358.562 2445.187 primary linux-swap

(parted) print 1

Minor: 1

Flags: boot, lba

File System: fat32

Size: 945.000Mb (0%)

Minimum size: 84.361Mb (0%)

Maximum size: 2445.679Mb (100%)

2.4.8 quit

[Command]quitQuits Parted.

It is only ater Parted exits that the Linux kernel knows about the changes Partedhas made to the disks. However, the changes caused by typing your commands willprobably  be made to the disk immediately ater typing a command. However, theoperating system’s cache and the disk’s hardware cache may delay this.

2.4.9 rescue

[Command]rescue start endRescue a lost partition that used to be located approximately between start and end .

I such a partition is ound, Parted will ask you i you want to create a partition orit. This is useul i you accidently deleted a partition with parted’s rm command, orexample.

Example:

(parted) print

Disk geometry for /dev/hdc: 0.000-8063.507 megabytes

Disk label type: msdos

Minor Start End Type Filesystem Flags

1 0.031 8056.032 primary ext3

(parted) rm

Partition number? 1

(parted) printDisk geometry for /dev/hdc: 0.000-8063.507 megabytes

Disk label type: msdos

Minor Start End Type Filesystem Flags

OUCH! We deleted our ext3 partition!!! Parted comes to the rescue...

(parted) rescue

Start? 0

End? 8056

Page 11: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 11/26

Chapter 2: Using Parted 9

Information: A ext3 primary partition was found at 0.031MB ->

8056.030MB. Do you want to add it to the partition table?

Yes/No/Cancel? y 

(parted) print

Disk geometry for /dev/hdc: 0.000-8063.507 megabytes

Disk label type: msdos

Minor Start End Type Filesystem Flags

1 0.031 8056.032 primary ext3

It’s back! :)

2.4.10 rm

[Command]rm number Removes the partition with number number . I you accidently delete a partition withthis command, use mkpart to recover it. Also, you can use the gpart program (see

Chapter 3 [Related inormation], page 13) to recover damaged disk labels.Note or msdos disk labels: i you delete a logical partition, all logical partitions witha larger partition number will be renumbered. For example, i you delete a logicalpartition with a partition number o 6, then logical partitions that were number 7, 8and 9 would be renumbered to 6, 7 and 8 respectively. This means, or example, thatyou have to update ‘/etc/fstab’ on GNU/Linux systems.

Example:

(parted) rm 3 

Remove partition 3.

2.4.11 select[Command]select device

Selects the device, device , or Parted to edit. The device can be a Linux hard diskdevice, a partition, a sotware RAID device or LVM logical volume.

Example:

(parted) select /dev/hdb

Select ‘/dev/hdb’ (the slave device on the rst ide controller on Linux) as the deviceto edit.

2.4.12 set

[Command]set number flag stateChanges a ag on the partition with number number . A ag can be either “on” or“of”. Some or all o these ags will be available, depending on what disk label youare using:

‘bios_grub’(GPT) - Enable this to record that the selected partition is a GRUBBIOS partition.

Page 12: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 12/26

Chapter 2: Using Parted 10

‘legacy_boot’(GPT) - this ag is used to tell special purpose sotware that the GPTpartition may be bootable.

‘boot’ (Mac, MS-DOS, PC98) - should be enabled i you want to boot of thepartition. The semantics vary between disk labels. For MS-DOS disklabels, only one partition can be bootable. I you are installing LILO ona partition that partition must be bootable. For PC98 disk labels, allext2 partitions must be bootable (this is enorced by Parted).

‘lba’ (MS-DOS) - this ag can be enabled to tell MS DOS, MS Windows 9x andMS Windows ME based operating systems to use Linear (LBA) mode.

‘root’ (Mac) - this ag should be enabled i the partition is the root device tobe used by Linux.

‘swap’ (Mac) - this ag should be enabled i the partition is the swap device to

be used by Linux.‘hidden’ (MS-DOS, PC98) - this ag can be enabled to hide partitions rom Mi-

crosot operating systems.

‘raid’ (MS-DOS) - this ag can be enabled to tell linux the partition is a sotwareRAID partition.

‘LVM’ (MS-DOS) - this ag can be enabled to tell linux the partition is a physicalvolume.

‘PALO’ (MS-DOS) - this ag can be enabled so that the partition can be used bythe Linux/PA-RISC boot loader, palo.

‘PREP’ (MS-DOS) - this ag can be enabled so that the partition can be used as aPReP boot partition on PowerPC PReP or IBM RS6K/CHRP hardware.

‘DIAG’ (MS-DOS) - Enable this to indicate that a partition can be used as adiagnostics / recovery partition.

The print command displays all enabled ags or each partition.

Example:

(parted) set 1 boot on

Set the ‘boot’ ag on partition 1.

2.4.13 unit

[Command]unit unitSelects the current deault unit that Parted will use to display locations and capacitieson the disk and to interpret those given by the user i they are not suxed by anunit.

unit may be one o:

‘s’ sector (n bytes depending on the sector size, oten 512)

‘B’ byte

Page 13: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 13/26

Chapter 2: Using Parted 11

‘KiB’ kibibyte (1024 bytes)

‘MiB’ mebibyte (1048576 bytes)

‘GiB’ gibibyte (1073741824 bytes)

‘TiB’ tebibyte (1099511627776 bytes)

‘kB’ kilobyte (1000 bytes)

‘MB’ megabyte (1000000 bytes)

‘GB’ gigabyte (1000000000 bytes)

‘TB’ terabyte (1000000000000 bytes)

‘%’ percentage o the device (between 0 and 100)

‘cyl’ cylinders (related to the BIOS CHS geometry)

‘chs’ cylinders, heads, sectors addressing (related to the BIOS CHS geometry)

‘compact’ This is a special unit that deaults to megabytes or input, and picks aunit that gives a compact human readable representation or output.

The deault unit apply only or the output and when no unit is specied ater aninput number. Input numbers can be ollowed by an unit (without any space or othercharacter between them), in which case this unit apply instead o the deault unit

or this particular number, but CHS and cylinder units are not supported as a sux.I no sux is given, then the deault unit is assumed. Parted will compute sensibleranges or the locations you speciy (e.g. a range o  +/- 500 MB when you speciy thelocation in “G”, and a range o  +/- 500 KB when you speciy the location in “M”)and will select the nearest location in this range rom the one you wrote that satisesconstraints rom both the operation, the lesystem being worked on, the disk label,other partitions and so on. Use the sector unit “s” to speciy exact locations (i theydo not satisy all constraints, Parted will ask you or the nearest solution). Note thatnegative numbers count back rom the end o the disk, with “-1s” pointing to the lastsector o the disk.

Note that as o parted-2.4, when you speciy start and/or end values using IEC

binary units like “MiB”, “GiB”, “TiB”, etc., parted treats those values as exact, andequivalent to the same number specied in bytes (i.e., with the “B” sux), in thatit provides no “helpul” range o sloppiness. Contrast that with a partition startrequest o “4GB”, which may actually resolve to some sector up to 500MB beore orater that point. Thus, when creating a partition, you should preer to speciy unitso bytes (“B”), sectors (“s”), or IEC binary units like “MiB”, but not “MB”, “GB”,etc.

Example:

Page 14: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 14/26

Chapter 2: Using Parted 12

(parted) unit compact

(parted) print

Disk geometry for /dev/hda: 0kB - 123GB

Disk label type: msdos

Number Start End Size Type File system Flags

1 32kB 1078MB 1077MB primary reiserfs boot

2 1078MB 2155MB 1078MB primary linux-swap

3 2155MB 123GB 121GB extended

5 2155MB 7452MB 5297MB logical reiserfs

(parted) unit chs print

Disk geometry for /dev/hda: 0,0,0 - 14946,225,62

BIOS cylinder,head,sector geometry: 14946,255,63. Each cylinder

is 8225kB.

Disk label type: msdos

Number Start End Type File system Flags

1 0,1,0 130,254,62 primary reiserfs boot2 131,0,0 261,254,62 primary linux-swap

3 262,0,0 14945,254,62 extended

5 262,2,0 905,254,62 logical reiserfs

(parted) unit mb print

Disk geometry for /dev/hda: 0MB - 122942MB

Disk label type: msdos

Number Start End Size Type File system Flags

1 0MB 1078MB 1077MB primary reiserfs boot

2 1078MB 2155MB 1078MB primary linux-swap

3 2155MB 122935MB 120780MB extended

5 2155MB 7452MB 5297MB logical reiserfs

Page 15: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 15/26

Chapter 3: Related inormation 13

3 Related information

I you want to nd out more inormation, please see the GNU Parted web site.

These les in the Parted distribution contain urther inormation:• ABOUT-NLS  - inormation about using Native Language Support, and the Free Transla-

tion Project.

• AUTHORS  - who wrote what.

• ChangeLog  - record o changes made to Parted.

• COPYING  - the GNU General Public License, the terms under which GNU Parted maybe distributed.

• COPYING.DOC  - the GNU Free Documentation Licence, the term under which Parted’sdocumentation may be distributed.

• INSTALL — how to compile and install Parted, and most other ree sotware

Page 16: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 16/26

Appendix A: Copying This Manual 14

Appendix A Copying This Manual

A.1 GNU Free Documentation License

Version 1.3, 3 November 2008

Copyright c 2000, 2001, 2002, 2007, 2008 Free Sotware Foundation, Inc.http://fsf.org/

Everyone is permitted to copy and distribute verbatim copieso this license document, but changing it is not allowed.

0. PREAMBLE

The purpose o this License is to make a manual, textbook, or other unctional anduseul document free  in the sense o reedom: to assure everyone the efective reedomto copy and redistribute it, with or without modiying it, either commercially or non-commercially. Secondarily, this License preserves or the author and publisher a wayto get credit or their work, while not being considered responsible or modicationsmade by others.

This License is a kind o “copylet”, which means that derivative works o the documentmust themselves be ree in the same sense. It complements the GNU General PublicLicense, which is a copylet license designed or ree sotware.

We have designed this License in order to use it or manuals or ree sotware, becauseree sotware needs ree documentation: a ree program should come with manualsproviding the same reedoms that the sotware does. But this License is not limited tosotware manuals; it can be used or any textual work, regardless o subject matter orwhether it is published as a printed book. We recommend this License principally orworks whose purpose is instruction or reerence.

1. APPLICABILITY AND DEFINITIONS

This License applies to any manual or other work, in any medium, that contains anotice placed by the copyright holder saying it can be distributed under the termso this License. Such a notice grants a world-wide, royalty-ree license, unlimited induration, to use that work under the conditions stated herein. The “Document”,below, reers to any such manual or work. Any member o the public is a licensee, andis addressed as “you”. You accept the license i you copy, modiy or distribute the workin a way requiring permission under copyright law.

A “Modied Version” o the Document means any work containing the Document ora portion o it, either copied verbatim, or with modications and/or translated intoanother language.

A “Secondary Section” is a named appendix or a ront-matter section o the Documentthat deals exclusively with the relationship o the publishers or authors o the Documentto the Document’s overall subject (or to related matters) and contains nothing thatcould all directly within that overall subject. (Thus, i the Document is in part atextbook o mathematics, a Secondary Section may not explain any mathematics.) Therelationship could be a matter o historical connection with the subject or with relatedmatters, or o legal, commercial, philosophical, ethical or political position regardingthem.

Page 17: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 17/26

Appendix A: Copying This Manual 15

The “Invariant Sections” are certain Secondary Sections whose titles are designated, asbeing those o Invariant Sections, in the notice that says that the Document is releasedunder this License. I a section does not t the above denition o Secondary then it isnot allowed to be designated as Invariant. The Document may contain zero InvariantSections. I the Document does not identiy any Invariant Sections then there are none.

The “Cover Texts” are certain short passages o text that are listed, as Front-CoverTexts or Back-Cover Texts, in the notice that says that the Document is released underthis License. A Front-Cover Text may be at most 5 words, and a Back-Cover Text maybe at most 25 words.

A “Transparent” copy o the Document means a machine-readable copy, representedin a ormat whose specication is available to the general public, that is suitable orrevising the document straightorwardly with generic text editors or (or images com-posed o pixels) generic paint programs or (or drawings) some widely available drawingeditor, and that is suitable or input to text ormatters or or automatic translation toa variety o ormats suitable or input to text ormatters. A copy made in an otherwise

Transparent le ormat whose markup, or absence o markup, has been arranged tothwart or discourage subsequent modication by readers is not Transparent. An imageormat is not Transparent i used or any substantial amount o text. A copy that isnot “Transparent” is called “Opaque”.

Examples o suitable ormats or Transparent copies include plain ASCII withoutmarkup, Texino input ormat, LaTEX input ormat, SGML or XML using a publiclyavailable DTD, and standard-conorming simple HTML, PostScript or PDF designedor human modication. Examples o transparent image ormats include PNG, XCFand JPG. Opaque ormats include proprietary ormats that can be read and editedonly by proprietary word processors, SGML or XML or which the DTD and/or pro-cessing tools are not generally available, and the machine-generated HTML, PostScript

or PDF produced by some word processors or output purposes only.The “Title Page” means, or a printed book, the title page itsel, plus such ollowingpages as are needed to hold, legibly, the material this License requires to appear in thetitle page. For works in ormats which do not have any title page as such, “Title Page”means the text near the most prominent appearance o the work’s title, preceding thebeginning o the body o the text.

The “publisher” means any person or entity that distributes copies o the Documentto the public.

A section “Entitled XYZ” means a named subunit o the Document whose title eitheris precisely XYZ or contains XYZ in parentheses ollowing text that translates XYZ inanother language. (Here XYZ stands or a specic section name mentioned below, such

as “Acknowledgements”, “Dedications”, “Endorsements”, or “History”.) To “Preservethe Title” o such a section when you modiy the Document means that it remains asection “Entitled XYZ” according to this denition.

The Document may include Warranty Disclaimers next to the notice which states thatthis License applies to the Document. These Warranty Disclaimers are considered tobe included by reerence in this License, but only as regards disclaiming warranties:any other implication that these Warranty Disclaimers may have is void and has noefect on the meaning o this License.

Page 18: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 18/26

Appendix A: Copying This Manual 16

2. VERBATIM COPYING

You may copy and distribute the Document in any medium, either commercially ornoncommercially, provided that this License, the copyright notices, and the license

notice saying this License applies to the Document are reproduced in all copies, andthat you add no other conditions whatsoever to those o this License. You may not usetechnical measures to obstruct or control the reading or urther copying o the copiesyou make or distribute. However, you may accept compensation in exchange or copies.I you distribute a large enough number o copies you must also ollow the conditionsin section 3.

You may also lend copies, under the same conditions stated above, and you may publiclydisplay copies.

3. COPYING IN QUANTITY

I you publish printed copies (or copies in media that commonly have printed covers) o the Document, numbering more than 100, and the Document’s license notice requires

Cover Texts, you must enclose the copies in covers that carry, clearly and legibly, allthese Cover Texts: Front-Cover Texts on the ront cover, and Back-Cover Texts onthe back cover. Both covers must also clearly and legibly identiy you as the publishero these copies. The ront cover must present the ull title with all words o the titleequally prominent and visible. You may add other material on the covers in addition.Copying with changes limited to the covers, as long as they preserve the title o theDocument and satisy these conditions, can be treated as verbatim copying in otherrespects.

I the required texts or either cover are too voluminous to t legibly, you should putthe rst ones listed (as many as t reasonably) on the actual cover, and continue therest onto adjacent pages.

I you publish or distribute Opaque copies o the Document numbering more than 100,you must either include a machine-readable Transparent copy along with each Opaquecopy, or state in or with each Opaque copy a computer-network location rom whichthe general network-using public has access to download using public-standard networkprotocols a complete Transparent copy o the Document, ree o added material. I you use the latter option, you must take reasonably prudent steps, when you begindistribution o Opaque copies in quantity, to ensure that this Transparent copy willremain thus accessible at the stated location until at least one year ater the last timeyou distribute an Opaque copy (directly or through your agents or retailers) o thatedition to the public.

It is requested, but not required, that you contact the authors o the Document well

beore redistributing any large number o copies, to give them a chance to provide youwith an updated version o the Document.

4. MODIFICATIONS

You may copy and distribute a Modied Version o the Document under the conditionso sections 2 and 3 above, provided that you release the Modied Version under preciselythis License, with the Modied Version lling the role o the Document, thus licensingdistribution and modication o the Modied Version to whoever possesses a copy o it. In addition, you must do these things in the Modied Version:

Page 19: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 19/26

Appendix A: Copying This Manual 17

A. Use in the Title Page (and on the covers, i any) a title distinct rom that o theDocument, and rom those o previous versions (which should, i there were any,be listed in the History section o the Document). You may use the same title asa previous version i the original publisher o that version gives permission.

B. List on the Title Page, as authors, one or more persons or entities responsible orauthorship o the modications in the Modied Version, together with at least veo the principal authors o the Document (all o its principal authors, i it has ewerthan ve), unless they release you rom this requirement.

C. State on the Title page the name o the publisher o the Modied Version, as thepublisher.

D. Preserve all the copyright notices o the Document.

E. Add an appropriate copyright notice or your modications adjacent to the othercopyright notices.

F. Include, immediately ater the copyright notices, a license notice giving the public

permission to use the Modied Version under the terms o this License, in the ormshown in the Addendum below.

G. Preserve in that license notice the ull lists o Invariant Sections and required CoverTexts given in the Document’s license notice.

H. Include an unaltered copy o this License.

I. Preserve the section Entitled “History”, Preserve its Title, and add to it an itemstating at least the title, year, new authors, and publisher o the Modied Versionas given on the Title Page. I there is no section Entitled “History” in the Docu-ment, create one stating the title, year, authors, and publisher o the Documentas given on its Title Page, then add an item describing the Modied Version asstated in the previous sentence.

J. Preserve the network location, i any, given in the Document or public access toa Transparent copy o the Document, and likewise the network locations given inthe Document or previous versions it was based on. These may be placed in the“History” section. You may omit a network location or a work that was publishedat least our years beore the Document itsel, or i the original publisher o theversion it reers to gives permission.

K. For any section Entitled “Acknowledgements” or “Dedications”, Preserve the Titleo the section, and preserve in the section all the substance and tone o each o thecontributor acknowledgements and/or dedications given therein.

L. Preserve all the Invariant Sections o the Document, unaltered in their text andin their titles. Section numbers or the equivalent are not considered part o thesection titles.

M. Delete any section Entitled “Endorsements”. Such a section may not be includedin the Modied Version.

N. Do not retitle any existing section to be Entitled “Endorsements” or to conict intitle with any Invariant Section.

O. Preserve any Warranty Disclaimers.

I the Modied Version includes new ront-matter sections or appendices that qualiyas Secondary Sections and contain no material copied rom the Document, you may at

Page 20: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 20/26

Appendix A: Copying This Manual 18

your option designate some or all o these sections as invariant. To do this, add theirtitles to the list o Invariant Sections in the Modied Version’s license notice. Thesetitles must be distinct rom any other section titles.

You may add a section Entitled “Endorsements”, provided it contains nothing butendorsements o your Modied Version by various parties—or example, statements o peer review or that the text has been approved by an organization as the authoritativedenition o a standard.

You may add a passage o up to ve words as a Front-Cover Text, and a passage o upto 25 words as a Back-Cover Text, to the end o the list o Cover Texts in the ModiedVersion. Only one passage o Front-Cover Text and one o Back-Cover Text may beadded by (or through arrangements made by) any one entity. I the Document alreadyincludes a cover text or the same cover, previously added by you or by arrangementmade by the same entity you are acting on behal o, you may not add another; butyou may replace the old one, on explicit permission rom the previous publisher thatadded the old one.

The author(s) and publisher(s) o the Document do not by this License give permissionto use their names or publicity or or to assert or imply endorsement o any ModiedVersion.

5. COMBINING DOCUMENTS

You may combine the Document with other documents released under this License,under the terms dened in section 4 above or modied versions, provided that youinclude in the combination all o the Invariant Sections o all o the original documents,unmodied, and list them all as Invariant Sections o your combined work in its licensenotice, and that you preserve all their Warranty Disclaimers.

The combined work need only contain one copy o this License, and multiple identicalInvariant Sections may be replaced with a single copy. I there are multiple Invariant

Sections with the same name but diferent contents, make the title o each such sectionunique by adding at the end o it, in parentheses, the name o the original author orpublisher o that section i known, or else a unique number. Make the same adjustmentto the section titles in the list o Invariant Sections in the license notice o the combinedwork.

In the combination, you must combine any sections Entitled “History” in the vari-ous original documents, orming one section Entitled “History”; likewise combine anysections Entitled “Acknowledgements”, and any sections Entitled “Dedications”. Youmust delete all sections Entitled “Endorsements.”

6. COLLECTIONS OF DOCUMENTS

You may make a collection consisting o the Document and other documents released

under this License, and replace the individual copies o this License in the variousdocuments with a single copy that is included in the collection, provided that youollow the rules o this License or verbatim copying o each o the documents in allother respects.

You may extract a single document rom such a collection, and distribute it individu-ally under this License, provided you insert a copy o this License into the extracteddocument, and ollow this License in all other respects regarding verbatim copying o that document.

Page 21: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 21/26

Appendix A: Copying This Manual 19

7. AGGREGATION WITH INDEPENDENT WORKS

A compilation o the Document or its derivatives with other separate and independentdocuments or works, in or on a volume o a storage or distribution medium, is called

an “aggregate” i the copyright resulting rom the compilation is not used to limit thelegal rights o the compilation’s users beyond what the individual works permit. Whenthe Document is included in an aggregate, this License does not apply to the otherworks in the aggregate which are not themselves derivative works o the Document.

I the Cover Text requirement o section 3 is applicable to these copies o the Document,then i the Document is less than one hal o the entire aggregate, the Document’s CoverTexts may be placed on covers that bracket the Document within the aggregate, or theelectronic equivalent o covers i the Document is in electronic orm. Otherwise theymust appear on printed covers that bracket the whole aggregate.

8. TRANSLATION

Translation is considered a kind o modication, so you may distribute translations

o the Document under the terms o section 4. Replacing Invariant Sections withtranslations requires special permission rom their copyright holders, but you mayinclude translations o some or all Invariant Sections in addition to the original versionso these Invariant Sections. You may include a translation o this License, and all thelicense notices in the Document, and any Warranty Disclaimers, provided that youalso include the original English version o this License and the original versions o those notices and disclaimers. In case o a disagreement between the translation andthe original version o this License or a notice or disclaimer, the original version willprevail.

I a section in the Document is Entitled “Acknowledgements”, “Dedications”, or “His-tory”, the requirement (section 4) to Preserve its Title (section 1) will typically require

changing the actual title.9. TERMINATION

You may not copy, modiy, sublicense, or distribute the Document except as expresslyprovided under this License. Any attempt otherwise to copy, modiy, sublicense, ordistribute it is void, and will automatically terminate your rights under this License.

However, i you cease all violation o this License, then your license rom a particularcopyright holder is reinstated (a) provisionally, unless and until the copyright holderexplicitly and nally terminates your license, and (b) permanently, i the copyrightholder ails to notiy you o the violation by some reasonable means prior to 60 daysater the cessation.

Moreover, your license rom a particular copyright holder is reinstated permanently i 

the copyright holder noties you o the violation by some reasonable means, this is therst time you have received notice o violation o this License (or any work) rom thatcopyright holder, and you cure the violation prior to 30 days ater your receipt o thenotice.

Termination o your rights under this section does not terminate the licenses o partieswho have received copies or rights rom you under this License. I your rights havebeen terminated and not permanently reinstated, receipt o a copy o some or all o thesame material does not give you any rights to use it.

Page 22: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 22/26

Appendix A: Copying This Manual 20

10. FUTURE REVISIONS OF THIS LICENSE

The Free Sotware Foundation may publish new, revised versions o the GNU FreeDocumentation License rom time to time. Such new versions will be similar in spirit

to the present version, but may difer in detail to address new problems or concerns.See http://www.gnu.org/copyleft/.

Each version o the License is given a distinguishing version number. I the Documentspecies that a particular numbered version o this License “or any later version”applies to it, you have the option o ollowing the terms and conditions either o thatspecied version or o any later version that has been published (not as a drat) bythe Free Sotware Foundation. I the Document does not speciy a version number o this License, you may choose any version ever published (not as a drat) by the FreeSotware Foundation. I the Document species that a proxy can decide which utureversions o this License can be used, that proxy’s public statement o acceptance o aversion permanently authorizes you to choose that version or the Document.

11. RELICENSING

“Massive Multiauthor Collaboration Site” (or “MMC Site”) means any World WideWeb server that publishes copyrightable works and also provides prominent acilitiesor anybody to edit those works. A public wiki that anybody can edit is an example o such a server. A “Massive Multiauthor Collaboration” (or “MMC”) contained in thesite means any set o copyrightable works thus published on the MMC site.

“CC-BY-SA” means the Creative Commons Attribution-Share Alike 3.0 license pub-lished by Creative Commons Corporation, a not-or-prot corporation with a principalplace o business in San Francisco, Caliornia, as well as uture copylet versions o thatlicense published by that same organization.

“Incorporate” means to publish or republish a Document, in whole or in part, as parto another Document.

An MMC is “eligible or relicensing” i it is licensed under this License, and i all worksthat were rst published under this License somewhere other than this MMC, andsubsequently incorporated in whole or in part into the MMC, (1) had no cover textsor invariant sections, and (2) were thus incorporated prior to November 1, 2008.

The operator o an MMC Site may republish an MMC contained in the site underCC-BY-SA on the same site at any time beore August 1, 2009, provided the MMC iseligible or relicensing.

Page 23: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 23/26

Appendix A: Copying This Manual 21

ADDENDUM: How to use this License for your documents

To use this License in a document you have written, include a copy o the License in thedocument and put the ollowing copyright and license notices just ater the title page:

Copyright (C) year your name.Permission is granted to copy, distribute and/or modify this document

under the terms of the GNU Free Documentation License, Version 1.3

or any later version published by the Free Software Foundation;

with no Invariant Sections, no Front-Cover Texts, and no Back-Cover

Texts. A copy of the license is included in the section entitled ‘‘GNU

Free Documentation License’’.

I you have Invariant Sections, Front-Cover Texts and Back-Cover Texts, replace the“with. . .Texts.” line with this:

with the Invariant Sections being list their titles, with

the Front-Cover Texts being list, and with the Back-Cover Texts

being list.

I you have Invariant Sections without Cover Texts, or some other combination o the

three, merge those two alternatives to suit the situation.I your document contains nontrivial examples o program code, we recommend releas-

ing these examples in parallel under your choice o ree sotware license, such as the GNUGeneral Public License, to permit their use in ree sotware.

Page 24: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 24/26

Appendix B: This manual’s history 22

Appendix B This manual’s history

This manual was based on the le USER  included in GNU Parted version 1.4.22 sourcedistribution. The GNU Parted source distribution is available at ftp.gnu.org/gnu/parted.

Initial Texino ormatting by Richard M. Kreuter, 2002.

Maintainance by Andrew Clausen rom 2002 to 2005 and by Leslie P. Polzer rom July2005 onwards.

This manual is distributed under the GNU Free Documentation License, version 1.1or later, at your discretion, any later version published by the Free Sotware Foundation;with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. SeeAppendix A [Copying This Manual], page 14, or details.

Page 25: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 25/26

Index 23

Page 26: Gnu Parted User Manual

7/29/2019 Gnu Parted User Manual

http://slidepdf.com/reader/full/gnu-parted-user-manual 26/26

Index 24

Index

A

align-check, command description. . . . . . . . . . . . . . .

5

Bbugs, reporting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

building parted . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Ccommand description, align-check . . . . . . . . . . . . . . . 5

command description, disk set . . . . . . . . . . . . . . . . . . 5

command description, help . . . . . . . . . . . . . . . . . . . . . . 6

command description, mkindex . . . . . . . . . . . . . . . . . 6

command description, mkpart . . . . . . . . . . . . . . . . . . . 6

command description, name. . . . . . . . . . . . . . . . . . . . .

7command description, print . . . . . . . . . . . . . . . . . . . . . 7

command description, quit . . . . . . . . . . . . . . . . . . . . . . 8

command description, rescue . . . . . . . . . . . . . . . . . . . . 8

command description, rm . . . . . . . . . . . . . . . . . . . . . . . 9

command description, select . . . . . . . . . . . . . . . . . . . . 9

command description, set . . . . . . . . . . . . . . . . . . . . . . . 9

command description, unit . . . . . . . . . . . . . . . . . . . . . 10

command syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

commands, detailed listing . . . . . . . . . . . . . . . . . . . . . . 5

commands, overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

compiling parted . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

contacting developers . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

Ddescription o parted . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

detailed command listing . . . . . . . . . . . . . . . . . . . . . . . 5

disk set, command description . . . . . . . . . . . . . . . . . . 5

Ee2sprogs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

FFDL, GNU Free Documentation License . . . . . . . 14

urther reading. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

13

Ggettext . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

gnu gpl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

gpl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Hhelp, command description . . . . . . . . . . . . . . . . . . . . . . 6

history o this manual 22

I

invocation options. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

5

Llibuuid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

license terms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Mmklabel, command description . . . . . . . . . . . . . . . . . . 6

mkpart, command description . . . . . . . . . . . . . . . . . . . 6

modes o use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

Nname, command description

. . . . . . . . . . . . . . . . . . . . .

7

Ooptions at invocation . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

Pparted description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

partitioning overview . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

platorms, supported . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

print, command description . . . . . . . . . . . . . . . . . . . . . 7

Qquit, command description . . . . . . . . . . . . . . . . . . . . . . 8

Rreadline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

related documentation . . . . . . . . . . . . . . . . . . . . . . . . . 13

reporting bugs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

required sotware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

rescue, command description . . . . . . . . . . . . . . . . . . . . 8

rm, command description . . . . . . . . . . . . . . . . . . . . . . . 9

Sselect, command description . . . . . . . . . . . . . . . . . . . . 9

set, command description . . . . . . . . . . . . . . . . . . . . . . . 9

sotware dependencies. . . . . . . . . . . . . . . . . . . . . . . . . . . 1

supported platorms . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Tterms o distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

U