\" TROFF Macro Summary: http://www.fileformat.info/info/man-pages/macro.htm .TH CGPT "1" "January 2014" "cgpt " "System Administration Commands" .SH NAME cgpt \- Utility to manipulate GPT partitions with Chromium OS extensions .SH SYNOPSIS .B cgpt \fICOMMAND\fR [\fIOPTIONS\fR] \fIDRIVE\fR .SH DESCRIPTION Cgpt is a tool to manipulate a GUID Partition Table from the command line. Although several other utilities exist for the same basic purpose \- some with more features and a captive user interface \- cgpt is unique in that it also supports Chromium OS extensions. These extensions are not generally useful; they are specific to the u-boot firmware found on some Chromebooks. They may be used to change priority for kernel partitions and give other hints to u-boot Chromebook firmware. Use this utility only to manipulate a partition table for compatible Chromebooks. .SH COMMANDS Each action performed by this program \- with the notable exception of the \fI\-h\fR \fIOPTION\fR \- is initiated by a command which tells cgpt the type of operation to perform. All available commands are described below. .IP \fBcreate\fR Create or reset GPT headers and tables. .IP \fBadd\fR Add, edit, or remove a partition entry. .IP \fBshow\fR Show the partition table and entries. .IP \fBrepair\fR Repair damaged GPT headers and tables. .IP \fBboot\fR Edit the PMBR sector for legacy BIOSes. If no \fIBOOT OPTIONS\fR are specified, this command will just print the PMBR boot GUID. .IP \fBfind\fR Find a partition by its GUID. If no \fIDRIVE\fR is specified, this command will scan all physical drives for a match. .IP \fBprioritize\fR Reorder the priority of all ChromeOS kernel partitions. If no options are specified, this command will set the lowest active kernel to priority 1 while maintaining the original order. .IP \fBlegacy\fR Switch between GPT and Legacy GPT. .SH GENERAL\ OPTIONS The options described in this section apply to every \fICOMMAND\fR supported by this program. .IP \fB-h\fR For more detailed usage, use \fBcgpt\fR \fICOMMAND\fR \fI-h\fR .SH EXAMPLES The following examples demonstrate valid syntax only. It is up to you to interpret them based on the documentation in this manual. \fBcgpt\fR \fIshow\fR /dev/mmcblk0 .br \fBcgpt\fR \fIcreate\fR /dev/mmcblk0 .br \fBcgpt\fR \fIadd\fR \fI-i\fR 2 \fI-S\fR 1 \fI-T\fR 15 \fI-P\fR 15 /dev/mmcblk0 .br \fBcgpt\fR \fIadd\fR \fI-i\fR 1 \fI-t\fR data \fI-l\fR "STATE" /dev/mmcblk0 .br \fBcgpt\fR \fIadd\fR \fI-i\fR 2 \fI-t\fR kernel \fI-l\fR "KERN-A" /dev/mmcblk0 .br \fBcgpt\fR \fIadd\fR \fI-i\fR 3 \fI-t\fR rootfs \fI-l\fR "ROOT-A" /dev/mmcblk0 .SH AUTHOR This manual page was written by Karl Lenz for the Debian project (but may be used by others). .SH COPYRIGHT Cgpt is copyright 2010-2013, The Chromium OS Authors .br This manual page is copyright 2014, Karl Lenz Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved. Cgpt is provided "as is" with no warranty. The exact terms under which you may use and (re)distribute this program are detailed in the BSD 3-Clause License, which is distributed with this program in the LICENSE file. On Debian systems, the complete text of the BSD 3-Clause License can be found in /usr/share/common-licenses/BSD. .SH SEE\ ALSO .BR parted (8), .BR gdisk (8), .BR gptsync (8)