Module Name: src Committed By: wiz Date: Fri Nov 11 13:26:45 UTC 2011
Modified Files: src/sbin/gpt: gpt.8 Log Message: Add an EXAMPLE section showing how to add a swap file system using gpt. Bump date. To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sbin/gpt/gpt.8 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sbin/gpt/gpt.8 diff -u src/sbin/gpt/gpt.8:1.8 src/sbin/gpt/gpt.8:1.9 --- src/sbin/gpt/gpt.8:1.8 Mon Sep 19 10:40:35 2011 +++ src/sbin/gpt/gpt.8 Fri Nov 11 13:26:45 2011 @@ -1,4 +1,4 @@ -.\" $NetBSD: gpt.8,v 1.8 2011/09/19 10:40:35 wiz Exp $ +.\" $NetBSD: gpt.8,v 1.9 2011/11/11 13:26:45 wiz Exp $ .\" .\" Copyright (c) 2002 Marcel Moolenaar .\" All rights reserved. @@ -26,7 +26,7 @@ .\" .\" $FreeBSD: src/sbin/gpt/gpt.8,v 1.17 2006/06/22 22:22:32 marcel Exp $ .\" -.Dd September 19, 2011 +.Dd November 11, 2011 .Dt GPT 8 .Os .Sh NAME @@ -301,6 +301,38 @@ option takes precedence over the .Fl u option. .El +.Sh EXAMPLES +.Bd -literal +nas# gpt show wd3 + start size index contents + 0 1 PMBR + 1 3907029167 +nas# gpt create wd3 +nas# gpt show wd3 + start size index contents + 0 1 PMBR + 1 1 Pri GPT header + 2 32 Pri GPT table + 34 3907029101 + 3907029135 32 Sec GPT table + 3907029167 1 Sec GPT header +nas# gpt add -s 10486224 -t swap -i 1 wd3 +Partition added, use: + dkctl rwd3d addwedge dk<N> 34 10486224 <type> +to create a wedge for it +nas# gpt label -i 1 -l swap_1 wd3 +parition 1 on rwd3d labeled swap_1 +nas# gpt show wd3 + start size index contents + 0 1 PMBR + 1 1 Pri GPT header + 2 32 Pri GPT table + 34 10486224 1 GPT part - NetBSD swap + 10486258 3896542877 + 3907029135 32 Sec GPT table + 3907029167 1 Sec GPT header +nas# +.Ed .Sh SEE ALSO .Xr boot 8 , .Xr fdisk 8 ,