Format command can be used to display a disk's partition table.
Example:
# format
Please see here for more detailed information.
Creating slices and partitions
# format
Specify disk (enter its number): disk number
format> partition
partition> print
partition> slice number
Enter partition id tag [unassigned]: ? *then pick something*
Enter partition permission flags [wm]: press Return
Enter new starting cyl [0]: press Return
Enter partition size [0b, 0c, 0.00mb, 0.00gb]: 200mb
partition> print
Label the disk!
After ensuring the partition table is accurate, label the disk.
partition> label
Ready to label disk, continue? y
Save partition table (VTOC)
To save a partition table to the /etc/format.dat file follow these steps within the format utility.
partition> name
Enter table name (remember quotes): partition table name
partition> quit
format> save
Saving new partition definition
Enter file name ["./format.dat"]: /etc/format.dat
Format utility saves the partition table to ./format.dat by default.
You can also save the VTOC by using the prtvtoc command.
Example: # prtvtoc /dev/rdsk/disk slice name > /dir/filename
Verify file: # more /dir/filename
The fmthard Command
More information later
Creating ufs file systems
Use the newfs command which front ends the mkfs command.
The newfs will delete all data on your hard disk.
#newfs /dev/rdsk/disk slice name
Example:
#newfs /dev/rdsk/c1t3d0s0
newfs will ask for confirmation!
The mount command
mount command maintains the /etc/mnttab file
mount command lists which files are mounted and provides a means to mount
/etc/vfstab lists file systems to mount at boot
Command format
mount [option(s)] device_name mount_point
No options is default
Default options are read/write, setuid, nologging, largefiles, and noerror.
read/write=file permissions, access is based on permissions of files and directories in the file sysetm.
setuid=permits the execution of setuid programs in the file system
nologging=disables logging for ufs
largefiles=allows files greater than 2Gbytes
onerror=actionspecifies action ufs should take to recover from an internal inconsistency on a file system [panic, lock, umount]
Mounts file system as read only.
# mount -o -ro /dev/dsk/device_name mount_point
Unmount All
# umountall (all systems listed in /etc/mnttab)
# umountall -l (local system)
Back