User`s guide

Using Command-Line Tools 39
Step 5: Choose a device map to partition
Use pdisk to partition the 120 GB hard disk into two 60 GB partitions. When prompted,
type
e and choose the disk you want to partition (in this case, /dev/rdisk2). Then type p to
show the partition maps. The session, with output, looks like this:
pdisk
Top level command (? for help): e
Name of device: /dev/rdisk2
/dev/rdisk2
Command (? for help): p
/dev/rdisk2 map block size=512
Device block size=512, Number of Blocks=241254720
Step 6: Delete the existing partition
You must delete the partitions on the disk one at a time. So for each partition, when
prompted, type
d to delete the existing partition, specify the partition number, and then
enter
p to print the partition map. When you’re done, you will have one partition,
Apple_Free Extra. The final session looks like this:
Top level command (? for help): d
Partition number: 9
Top level command (? for help): p
/dev/rdisk2 map block size=512
Device block size=512, Number of Blocks=241254720
#: type name length base (size)
1: Apple_partition_map Apple Apple63 @ 1
2: Apple_Driver43*Macintosh 56 @ 64
3: Apple_Driver43*Macintosh 56 @ 120
4: Apple_Driver_ATA*Macintosh 56 @ 176
5: Apple_Driver_ATA*Macintosh 56 @ 232
6: Apple_FWDriver Macintosh 512 @ 288
7: Apple_Driver_IOKit Macintosh 512 @ 800
8: Apple_Patches Patch Partition 512 @ 1312
9: Apple_HFS part1 241252896 @ 1824 (115.0G)
#: type name length base (size)
1: Apple_Free Extra 241252896 @ 1824 (115.0G)
LL2133.book Page 39 Friday, May 24, 2002 11:17 AM