This section details how to make disks that are totally dedicated to FreeBSD. Remember, dedicated mode disks sometimes cannot be booted by the PC architecture.
/stand/sysinstall, the system installation utility, has been expanded in recent versions to make the process of dividing disks properly a less tiring affair. The fdisk and disklabel editors built into sysinstall are GUI tools that remove much of the confusion from slicing disks. For FreeBSD versions 2.1.7 and later, this is perhaps the simplest way to slice disks.
Start sysinstall as root by typing
Select the disk to edit with arrow keys and SPACE.
If you are using this entire disk for FreeBSD, select A.
Do you want to do this with a true partition entry so as to remain cooperative with any future possible operating systems on the drive(s)?
When asked if you still want to do this, answer Yes.
When warned about writing on installed systems, answer Yes.
Quitthe FDISK Editor and ESCAPE back to the Index menu.
Select Label from the Index menu.
Label as desired. For a single partition, enter C to Create a partition, accept the default size, partition type Filesystem, and a mountpoint (which is not used).
Enter W when done and confirm to continue. The filesystem will be newfs'd for you, unless you select otherwise (for new partitions you will want to do this!). You will get the error:
Exit out by repeatedly pressing ESCAPE.
Execute the following commands, replacing ad2 with the disk name.
# dd if=/dev/zero of=/dev/ad2 count=2 # disklabel /dev/ad2 | disklabel -B -R -r ad2 /dev/stdin We only want one partition, so using slice 'c' should be fine: # newfs /dev/ad2c
If you need to edit the disklabel to create multiple partitions (such as swap), use the following:
# dd if=/dev/zero of=/dev/ad2 count=2 # disklabel /dev/ad2 > /tmp/label Edit disklabel to add partitions: # vi /tmp/label # disklabel -B -R -r ad2 /tmp/label newfs partitions appropriately
Your disk is now ready for use.
This, and other documents, can be downloaded from ftp://ftp.FreeBSD.org/pub/FreeBSD/doc/.
For questions about FreeBSD, read the
before contacting <questions@FreeBSD.org>.
For questions about this documentation, e-mail <doc@FreeBSD.org>.
Закладки на сайте
Проследить за страницей
Created 1996-2024 by Maxim Chirkov
Добавить, Поддержать, Вебмастеру