You may use /stand/sysinstall
to partition and label a new
disk using its easy to use menus. Either login as user root
or use the su
command. Run /stand/sysinstall
and enter
the Configure menu. With in the FreeBSD Configuration
Menu
, scroll down and select the Partition item. Next you
should be presented with a list of hard drives installed in your system.
If you do not see sd1
listed, you need to recheck your physical
installation and dmesg
output in the file
/var/run/dmesg.boot
.
Select sd1
to enter the FDISK Partition Editor
.
Choose A
to use the entire disk for FreeBSD. When asked if you
want to ``remain cooperative with any future possible operating systems'',
answer YES. Write the changes to the disk using W.
Now exit the FDISK editor using q.
Next you will be asked about the Master Boot Record. Since you are
adding a disk to an already running system, choose None.
Next enter the Disk Label Editor. This is where you will create the traditional BSD partitions. A disk can have up to eight partitions, labeled a-h. A few of the partition labels have special uses. The a partition is used for the root partition (/). Thus only your system disk (e.g, the disk you boot from) should have an a partition. The b partition is used for swap partitions, and you may have many disks with swap partitions. The c partition addresses the entire disk in dedicated mode, or the entire FreeBSD slice in slice mode. The other partitions are for general use.
Sysinstall's Label editor favors the e partition for non-root,
non-swap partitions. With in the Label editor, create a single file
system using C. When prompted if this will be a FS (file
system) or swap, choose ``FS'' and give a mount point (e.g,
/mnt
). When adding a disk in post-install mode, Sysinstall
will not create entries in /etc/fstab
for you, so the
mount point you specify isn't important.
You are now ready to write the new label to the disk and create a file system on it. Do this by hitting W. Ignore any errors from Sysinstall that it could not mount the new partition. Exit the Label Editor and Sysinstall completely.
The last step is to edit /etc/fstab
to add an entry for your
new disk.