1*16cf393cSbostic.\" Copyright (c) 1983, 1991, 1993 2*16cf393cSbostic.\" The Regents of the University of California. All rights reserved. 33ca0a292Smckusick.\" 413251ec2Scael.\" %sccs.include.redist.man% 53ca0a292Smckusick.\" 6*16cf393cSbostic.\" @(#)diskpart.8 8.1 (Berkeley) 06/06/93 713251ec2Scael.\" 813251ec2Scael.Dd 913251ec2Scael.Dt DISKPART 8 1013251ec2Scael.Os BSD 4 1113251ec2Scael.Sh NAME 1213251ec2Scael.Nm diskpart 1313251ec2Scael.Nd calculate default disk partition sizes 1413251ec2Scael.Sh SYNOPSIS 1513251ec2Scael.Nm diskpart 1613251ec2Scael.Op Fl p 1713251ec2Scael.Op Fl d 1813251ec2Scael.Op Fl s Ar size 1913251ec2Scael.Ar disk-type 2013251ec2Scael.Sh DESCRIPTION 2113251ec2Scael.Nm Diskpart 223ca0a292Smckusickis used to calculate the disk partition sizes based on the 2313251ec2Scaeldefault rules used at Berkeley. 2413251ec2Scael.Pp 2513251ec2ScaelAvailable options and operands: 2613251ec2Scael.Bl -tag -width Fl 2713251ec2Scael.It Fl p 2813251ec2ScaelTables suitable for inclusion in a device driver 2913251ec2Scaelare produced. 3013251ec2Scael.It Fl d 3113251ec2ScaelAn entry suitable for inclusion in the disk 323ca0a292Smckusickdescription file 3313251ec2Scael.Pa /etc/disktab 3413251ec2Scaelis generated; for example, 3513251ec2Scael.Xr disktab 5 . 3613251ec2Scael.It Fl s Ar size 3713251ec2ScaelThe size of the disk may be limited to 3813251ec2Scael.Ar size 3913251ec2Scaelwith the 4013251ec2Scael.Fl s 4113251ec2Scaeloption. 4213251ec2Scael.El 4313251ec2Scael.Pp 44eb9a5f87SkarelsOn disks that use 4513251ec2Scael.Xr bad144 8 4613251ec2Scaeltype of 47eb9a5f87Skarelsbad-sector forwarding, 4835e5bee6Skarelsspace is normally left in the last partition on the disk 4935e5bee6Skarelsfor a bad sector forwarding table, although this space 5035e5bee6Skarelsis not reflected in the tables produced. The space reserved 513ca0a292Smckusickis one track for the replicated copies of the table and 523ca0a292Smckusicksufficient tracks to hold a pool of 126 sectors to which bad sectors 533ca0a292Smckusickare mapped. For more information, see 5413251ec2Scael.Xr bad144 8 . 5513251ec2ScaelThe 5613251ec2Scael.Fl s 5713251ec2Scaeloption is intended for other controllers which reserve some space at the end 5835e5bee6Skarelsof the disk for bad-sector replacements or other control areas, 5935e5bee6Skarelseven if not a multiple of cylinders. 6013251ec2Scael.Pp 613ca0a292SmckusickThe disk partition sizes are based on the total amount of 62eb9a5f87Skarelsspace on the disk as given in the table below (all values 6313251ec2Scaelare supplied in units of sectors). The 6413251ec2Scael.Ql c 6513251ec2Scaelpartition 66eb9a5f87Skarelsis, by convention, used to access the entire physical disk. 67eb9a5f87SkarelsThe device driver tables include 6813251ec2Scaelthe space reserved for the bad sector forwarding table in the 6913251ec2Scael.Ql c 7013251ec2Scaelpartition; 71eb9a5f87Skarelsthose used in the disktab and default formats exclude reserved tracks. 7213251ec2ScaelIn normal operation, either the 7313251ec2Scael.Ql g 7413251ec2Scaelpartition is used, or the 7513251ec2Scael.Ql d , 7613251ec2Scael.Ql e , 7713251ec2Scaeland 7813251ec2Scael.Ql f 7913251ec2Scaelpartitions are used. The 8013251ec2Scael.Ql g 8113251ec2Scaeland 8213251ec2Scael.Ql f 8313251ec2Scaelpartitions 84eb9a5f87Skarelsare variable-sized, occupying whatever space remains after allocation 853ca0a292Smckusickof the fixed sized partitions. 863ca0a292SmckusickIf the disk is smaller than 20 Megabytes, then 8713251ec2Scael.Nm diskpart 8813251ec2Scaelaborts with the message 8913251ec2Scael.Dq Li disk too small, calculate by hand . 9013251ec2Scael.Bl -column Partition 20-60\ MB 61-205\ MB 206-355\ MB 356+\ MB 913ca0a292SmckusickPartition 20-60 MB 61-205 MB 206-355 MB 356+ MB 923ca0a292Smckusicka 15884 15884 15884 15884 933ca0a292Smckusickb 10032 33440 33440 66880 943ca0a292Smckusickd 15884 15884 15884 15884 953ca0a292Smckusicke unused 55936 55936 307200 963ca0a292Smckusickh unused unused 291346 291346 9713251ec2Scael.El 9813251ec2Scael.Pp 993ca0a292SmckusickIf an unknown disk type is specified, 10013251ec2Scael.Nm diskpart 1013ca0a292Smckusickwill prompt for the required disk geometry information. 10213251ec2Scael.Sh SEE ALSO 10313251ec2Scael.Xr disktab 5 , 10413251ec2Scael.Xr bad144 8 10513251ec2Scael.Sh BUGS 10635e5bee6SkarelsMost default partition sizes are based on historical artifacts 10713251ec2Scael(like the RP06), and may result in unsatisfactory layouts. 10813251ec2Scael.Pp 10913251ec2ScaelWhen using the 11013251ec2Scael.Fl d 11113251ec2Scaelflag, alternate disk names are not included 1123ca0a292Smckusickin the output. 11313251ec2Scael.Sh HISTORY 11413251ec2ScaelThe 11513251ec2Scael.Nm 11613251ec2Scaelcommand appeared in 11713251ec2Scael.Bx 4.2 . 118