10. Installing FreeBSD with the boot floppy
Introduction to FreeBSD
10.1.  An explanation of install screen options
10.2.  Step 1) Format, fdisk, and partition the disks
10.3.  Step 2) Allocate Filesystem Space
10.4.  Step 3) Select Distributions
10.5.  Step 4) Format and Configure the Media Type

Welcome to an install of FreeBSD. From here you can install FreeBSD on a new machine, upgrade an existing machine, configure your machine after an installation, and add extra distributions and packages.


With a special ``Fixit'' floppy disk or CD-ROM, you can troubleshoot problems in an existing system.

The install process is mostly automated. All the required information is collected before the installation actually starts. The Novice and Express installation options guide you through the information collection procedure. They let you install only after all necessary information has been gathered. The Custom install option gives you the flexibility of installing select sections without performing a complete install.

The install process consists of 4 Steps:

  • Partitioning disk space

  • Allocating filesystem space

  • Selecting distributions to install

  • Configuring the medium you will use to install.


The next section is an explaination of each option on the main menu. If you want to begin installing immediately, skip ahead to Step 1.

10.1.   An explanation of install screen options

10.1.1.   Usage
10.1.2.   Doc
10.1.3.   KeyMap
10.1.4.   Options
10.1.5.   Novice
10.1.6.   Express
10.1.7.   Custom
10.1.8.   Fixit
10.1.9.   Upgrade
10.1.10.   Configure
10.1.11.   Load Configuration
10.1.12.   Index

10.1.1.   Usage

This screen is a tutorial on what each key does when you press it during the install. The ENTER key, sometimes called the RETURN key, will finish or exit you out of a menu whether or not you have selected anything. This might cause you to skip a menu section, thinking you have selected something.

You must press the SPACE BAR to select most menu items. Usually, an X will appear next to the selected item.

10.1.2.   Doc

FreeBSD comes with several very good sets of documents that are available during the install process. It is a good idea to read all the install documentation before attempting to install for the first time.

10.1.3.   KeyMap

If you need special characters to write in the language that you are running FreeBSD on, you need to use the keyboard map for that country. This page lets you select from the available keymaps.

10.1.4.   Options

This page lets you tweak with the default settings. For the most part, everything should work fine with the default values. Unless you know what you are doing, you probably shouldn't mess with this section.

10.1.5.   Novice

The Novice Install will walk you through each required part of the install process. Before each step, a help screen will appear and explain what is about to happen and what you are expected to do.

10.1.6.   Express

Express is just like Novice, but without all the help. It walks you through all the important steps and collects the information required to start the installation.

10.1.7.   Custom

The Custom Install allows you to do a specialized install, or a specific re-install, with out affecting previously installed components. For instance, this would allow you to add an extra hard drive to your system, or add/re-install a distribution. You could also repartition a hard disk or restore the boot-sector/boot-manager to your boot disk.

10.1.8.   Fixit

If anything should happen to your system that would cause it not to boot properly, the Fixit option will give you access to your filesystem. The Fixit option is an advanced feature. Knowledge of how to mount filesystems is required to gain access to your hard disks.

10.1.9.   Upgrade

The Upgrade option allows you to convert an existing FreeBSD machine to a new version of FreeBSD, without re-formatting your disk drives, or losing all of your data. An upgrade is a lot like re-installing a distribution set. It copies all the distributions you choose over the top of you existing files, replacing the ones with the same name. It does not delete extra files that it finds.

10.1.10.   Configure

This menu helps you setup your basic networking services, install extra packages (pre-compiled ``3rd party'' software), add additional distributions and prepare your system for general use.

10.1.11.   Load Configuration

10.1.12.   Index

This screen could be looked at as a ``Custom Install''. Instead of being organized into an install menu structure, all of the install commands have been extracted, alphabetized, and placed on a single menu. This makes it an alphabetized list of every command available during the install process. Pressing ENTER at this point, will execute the highlighted option as though you had selected it from an active menu.

10.2.   Step 1) Format, fdisk, and partition the disks

10.2.1.   A single disk FreeBSD ONLY install
10.2.2.   A single disk Multi-OS install
10.2.3.   A Multi-disk FreeBSD ONLY install
10.2.4.   A Multi-disk Multi-OS install

Here we are going to prepare our drives for use with FreeBSD. If you already have an operating system installed on your disks, and don't plan on using the whole disk for FreeBSD, you will need to free up a partition to install FreeBSD on. There are several methods of doing this. You can delete your stuff, re-arrange the partitions, and re-install it. (Cleanest, but takes the most work.) Or you can re-partition it using a program that preserves your information. There are several programs that can repartition your drives with out losing your information. A shareware program FIPS will work, or there are several commercial packages, such as ``Disk Magic''.

fips.exe can be found at ftp.freebsd.org/pub/FreeBSD/tools/fips.exe.

If you use DOS fdisk to make a new partition, you will be required to delete the existing partition. However, with FIPS and other such programs, you can ``shrink'' an existing partition, freeing up room for a new partition. FreeBSD can be installed on any available partition, including extended DOS partitions, logical drives, and Non-DOS partitions.


Once you have a partition available for FreeBSD, it does not matter if it is formatted, the install process will format it for use with FreeBSD. It makes no difference whether DOS or any other OS is installed on it.

Four possible fdisk scenarios are outlined, based on how many hard drives you have available, and whether FreeBSD is the only OS installed.

10.2.1.   A single disk FreeBSD ONLY install

This is the simplest install scenario. It is when you only have one disk in the computer and you want to dedicate it to FreeBSD.

In the fdisk editor, delete any partitions that may exist by moving the cursor to the partition and pressing d. Then press a to use the entire disk as shown in the figure below.

This is an example of a 2.1 Gig SCSI disk. It does not matter whether the disk is SCSI or IDE.

Now, press q to quit.

Install the standard MBR (Master Boot Record)

Use the SPACEBAR to select Standard and press ENTER to move on.

Move on to Step Two, ``Allocating filesystem space''.

10.2.2.   A single disk Multi-OS install

This is one of the more complex scenarios, you don't have to worry about which drive to boot from like you do with Multi-disk setup-ups, but you need to be careful about which OS you install First. DOS and FreeBSD are friendly to each other; Window95 and WinNT are not friendly to FreeBSD. They both want to try and take over the Boot Sector (MBR). Also, DOS and Win95 usually need to be installed on the first 1026 sectors of the first hard disk to avoid the 530Meg limit imposed by DOS.

Now you should see several partitions. The first one says that is it unused, starts at 0 and goes 63 sectors. This is your boot sector. There is nothing you can, or want to do with this at this time. Then you should see a section starting at 63 and named sd0s1 or wd0s1 depending on whether you have SCSI or IDE disks. sd0 is the name for a SCSI disk and s1 is the first partition we made on the drive.

You should see a big section that is unused. This will be used to create our FreeBSD partition.

If there is no partition marked unused, then the partition that you have reserved already has information on it, and will need to be deleted and recreated as a FreeBSD partition. Press d to delete a highlighted partition.

For example, you have 3 Gb of space on one disk. It is partitioned into a C: drive (2Gb), and a D: drive(1Gb). The plan is to keep your 'C: drive' and just use the 'D: drive' for FreeBSD. This is what your partition table looks like:

offset Size End Name PType Desc Subtype
0	63	 62	 -	 6	 unused	 0
63	4193217 4193279 wd0s1 2 fat 6
4193280 2080512 6273791 wd0s2 4 extended 5
6273792 8064 6281855 - 6 unused 0

Here you want to delete the 'extended' partition and re-create it as a FreeBSD partition. Just highlight it and press 'd'. Then press 'c' to create a new one. Accept the default size.

The partition labeled fat is a DOS Partition. The partition labeled extended is an Extended DOS Partition. (ie not the primary DOS Partition)

The sizes are shown in 512 byte blocks instead of 1K blocks. So you need to cut the size in half. The size '4123217' partition is the 2G disk. The '2080512' size partiton is the 1G drive. The '8064' sized chunk is unallocatable space due to cylinder boundaries not matching up.

To create our FreeBSD partition, highlight an unused partition and press c for Create. If you want to use the remaining amount of space for FreeBSD, accept the number that is written in the box, otherwise enter a new number. There are two ways to enter the amount that you want. First you can specify the exact number of sectors that you want the partition to be. Or, you can specify the size in Megabytes by typing in the number followed by an M For example, If you want a partition of 1000 Megabytes, you type: 1000M in the box.

The following graphic shows a 1000M DOS partition, labeled 'fat', as sd0s1.

It also shows a 1100M FreeBSD partition.


By keeping the partition compatible with other partitions, a small portion of the hard drive might become unusable. The last partition shown on the graphic, starting at offset 4192965, is unusable. This is nothing to worry about, because it is a very small part of the available disk space. It is only 1093 Sectors in size.

When you are done creating your partitions, press q to quit and move on to the next part of the install.

Next it is going to ask how you want to boot the disk. Because we are booting several OSes from one disk, we need to install a boot manager.

This screen lets you select the Boot Manager that comes with FreeBSD. At this screen all you have to do is select BootMgr and it will install the BootEasy Boot Manager on to your disk.

Since BootMgr is the default, just press ENTER to go on.


There are other Boot Managers available, but this is the only one available during the install. If you have a boot manager already installed, such as OSBS or the OS/2 Boot loader, select NONE from the menu.

Move on to Step Two, ``Allocating filesystem space''.

10.2.3.   A Multi-disk FreeBSD ONLY install

This is a very common server-type setup. It is fairly easy to setup and very reliable.

Now we need to partition each of our disks. We will select one disk at a time and partition it, repeating the same process for each disk.

Select a disk by moving the cursor to the appropriate disk and pressing the space bar.


* (Do NOT press ENTER at this point, because this will move us out of the FreeBSD fdisk utility, with out partitioning any disks.

Since this is a FreeBSD only install, we need to delete any partitions that are there and create new ones for FreeBSD. Move your cursor to each partition and press d until there is only one partition that says unused

Now, just press a to use the entire disk.

It will ask you if you want to keep the disk partition compatible with other OS's by making it a true partition. If you are using SCSI disks and are not going to be using any other OS on this system, it is fine to say no and dedicate them to FreeBSD. If you are using IDE drives, it might be a good idea to answer yes and let them conform to regular partitioning methods.

The following graphic is a 2.1 Gig SCSI disk that has NOT been keep compatible with other OS's, therefore it shows no Boot Sector.

We have just completed the fdisking the first disk; press q to quit and it will return us to the Select Drives menu. The disk we just finished will have a X in the box and the remaining disks still need to be fdisk'd. Repeat this procedure until all disks have been fdisk'd.

When all disks have been fdisk'd, press ENTER at the 'Select Drives' menu.

Move on to Step Two, ``Allocating filesystem space''.

10.2.4.   A Multi-disk Multi-OS install

A Multi-disk Multi-OS installation can take on just about any format imaginable. You can have one OS for each disk. Multi-OS's on a on Multiple disks; or any combination of the two. If you are putting more than one OS on a single disk, it will work exactly like the Single disk Multi-OS installation described previously. Of the several options available, one of the easiest, and most sane, is to put one OS per disk. For example, you would put DOS/Win95 on the First disk and FreeBSD on the second disk. I find this to be safer, because sometimes DOS tries to take over the first drive with out telling you and formats it without asking your permission.

One OS per Drive/Two Drive system.

In this example, we have two drives. We are going to put Win95 on the first drive and FreeBSD on the second. Win95 should already be installed and running on the first disk.

We are going to install the Boot Manager on the Win95 disk, because it is the boot disk. To do this, select the first disk, in this case sd0, and install the boot manager. At the Select Drives screen, move the cursor to the first disk and press the SPACE BAR.

This will bring up the fdisk partitioning editor.

At this screen, you should see one DOS partition. Do NOT delete or change it. just press q to quit out of it. Then the Boot Manager screen should come up.

Here we want to select BootMgr; since it is the default, we just need to press ENTER.

This will bring us back to the Select Drives screen. Now, just move the cursor to the next disk and press the SPACE BAR. From here it is exactly like a single disk FreeBSD install. Just delete any existing partitions by moving the cursor to them and pressing d. When they have been all deleted, press a to use the entire disk for FreeBSD. Then press q to quit. You will need to install the BootMgr on this disk also.

10.3.   Step 2) Allocate Filesystem Space

10.3.1.   Workstation\Desktop system
10.3.2.   Server (More than 100 People)
10.3.3.   Internet Server (E-mail/Pop3/Web Pages/FTP)
10.3.4.   News Server

The FreeBSD Filesystem is one big directory structure. There is no noticable separation of drives, or partitions, just one big filesystem. All additional hard drives must be assimilated into the directory system. This is accomplished by mounting each partition, sometimes called a ``slice'', as a sub-directory in the filesystem. A partition can mount to, or attach to, any existing directory, preferably an empty one.

Next, we will enter the disk label editor. This will allow you to distribute your disk space throughout the filesystem. At a minimum, you will need to allocate disk space for a / directory and for ``Swap Space''.

Space is allocated for a directory by mounting a partition, or ``slice'' of a partition, to it. If you do not allocate disk space for a directory, it will use disk space from it's parent directory. Below is an explanation of the standard directories that FreeBSD installs and whether you should consider allocating space for it. Subsections of this chapter describe extra allocations you should consider based on the anticipated use of your system. These are in addition to the basic allocations mentioned below.

  • /

    / is your ``root'' directory, not to be confused with the /root directory, which is the home directory of the user ``root''. All other directories are sub-directories to /.

    Like an upside down tree, ``root''(/), sits at the top and everything branches outward from it. The root directory doesn't need to be very big, 32-50 Meg. is sufficient. It just needs to have enough room to hold the kernel and various system configuration files.

  • /etc

    The /etc directory contains all of your system configuration files. You should not need to mount a partition here, nor do you want to. In the event that you are unable to boot properly, you would have trouble accessing your configuration files.

  • /usr

    The bulk of the system is contained in the /usr, or UNIX System Resources directory. Depending on your systems intended use and available disk space, you should reserve at least 100M for the /usr directory. Usually you would allocate the most disk space for this partition.

  • Swap Space

    You must create at least one swap partition. You can have several swap partitions, and it is best to spread them out over all your disks. You don't need to specify a mount point, because the swap partitions are not accessible from the filesystem. Your swap partitions should total at least twice the size of the amount of RAM memory you have installed in your machine.


    A swap partition must not occupy the first sector of a disk. You must put a filesystem partition on it first. It is good to have one swap partition per disk.

  • /var

    The /var directory holds various system logs and databases. It also holds a lot of transient files, such as queued e-mail and spooled print jobs. Depending on the role of your system, this directory can require several hundred Meg., or only a few Meg. You should mount a partition there of at least 32Meg. to take the strain off of your root directory. Some directories you might want to consider mounting volumes on are /var/mail and /var/log, depending on your anticipated usage.

  • /bin and /sbin

    These directories contain all the basic binary files that make up the core FreeBSD system. Do NOT mount partitions to these directories. They contain the utilities that allow you to mount filesystems. If you booted improperly, you could not gain access to any of your filesystems.

  • /root

    This is the Home directory of the user root. Unless you mount a partition to a sub-directory, it uses available disk space from its parent directory. Therefore you want to be careful what you put in the /root directory, because it uses up the available disk space from the / directory. If you find your / filesystem happens to be full, you might want to check this directory for excess files.

  • /dev

    This directory contains ``file'' representations of all of the devices that exist in your system. You don't need to mount anything here.

10.3.1.   Workstation\Desktop system

Unless you have special plans, on a system like this, just use the defaults. Press a to use the defaults. This option will create a 32Meg / partition, a 32 Meg /var partition, calculate a swap partition based on available RAM memory, and allocate the rest as a /usr partition.

10.3.2.   Server (More than 100 People)

The more people you have on the system, the more you want to think about making a /home partition. You should decide on a minimum amount of disk space that you are going to alot for each user. Say 3-4 Megs of disk space for each user, and make /home partition that has enough space to hold all the anticipated user files.

10.3.3.   Internet Server (E-mail/Pop3/Web Pages/FTP)

On an e-mail server, you want to add extra space to the directory /var. The directories /var/log and /var/mail receive extra heavy use in Internet servers. If you anticipate a large volume of e-mail, you might want to add a separate /var/mail partition.

If this is a print server, /var/spool might get heavier than normal usage. However, spooled print jobs don't stay very long.

10.3.4.   News Server

A News server is a very advanced project, but I mention it here so you can plan disk space for it. You will want to use several 2.1 Gig SCSI disks, and look into ccd. ccd can be used to stripe several disks together, and also mirror hard disks.

10.4.   Step 3) Select Distributions

A distribution is a collection of files that make up part of the operating system, sort of like separate components that can be added individually. A distribution set is a selection of distributions. Six ``typical'' distribution sets have been prepared to make it easy for new users to select distributions based on the intended use of the system. A list of the distributions installed by each distribution set is included at the end of this chapter.

You also have the option of selecting your own distribution set. Every distribution set includes the bin distribution. The bin distribution contains all the files required to make FreeBSD run. Everything else is optional. You'll notice that the minimal distribution set only installs the bin distribution.

One of the strong points of using an operating system that includes the Source Code is the ability to adjust for special hardware. If you have special hardware, such as a multi-port serial card, or Symmetric Multi-Processors, you will need to be able to re-compile and generate a custom kernel. Installing the kernel source code also allows you to streamline your kernel for optimum performance, by removing unused device drivers.

I would recommend installing the source code for creating a custom kernel. The Developer, X-Developer, and Kern-Developer distribution sets all include the kernel source code.

If you have an SVGA video card and SVGA monitor, I would recommend installing the X Window System binaries. XFree86 is the free version of X Window System for FreeBSD. In order to configure X Window System properly, you need to know the Brand of Video Card, the Refresh rates for your monitor, and what kind of mouse you have.

X-Developer and X-User both include the X-Windows system. I would recommend the X-Developer because it includes the kernel sources also.

After you select one of the distribution sets, it ask you if you want to install the DES encryption components.

If you are outside of North America (USA or Canada) don't install it over the Internet from a North American site. The copy of DES on the CD-ROM is fine. DES technology originating from the US is not exportable, so you'll have to pick an overseas server to install from (which is the logical way to do it anyhow...)

Selecting Custom from the distribution menu allows you to specify which components to install.

This screen also lets you add distributions, or re-install corrupted distributions. If you are adding distributions to an existing system, you probably don't want to select BIN. When installing a new system, I would recommend the following as very necessary: BIN, DOC, MAN, XFree86, and Selected SRC sets.

When you select SRC from the Custom Distribution Menu, it asks you which sets of source code you want to install.

At the very least, I would install SYS, the FreeBSD kernel sources. This will allow you to build your own kernel.

10.5.   Step 4) Format and Configure the Media Type

10.5.1.   Installing from a FreeBSD CD-ROM
10.5.2.   Installing from an FTP Site

10.5.1.   Installing from a FreeBSD CD-ROM

To install from a CD-ROM:

Just stick the CD in to the CD-ROM Drive and sysinstall should find it. As long as your CD-ROM drive is recognized at start up, you should not have problems. Most ATAPI IDE and SCSI CD-ROMs are supported.

The newer installation CD-ROM's for FreeBSD are bootable. If your computer supports booting from a CD-ROM, all you need to do is stick it in the CD-ROM drive and REBOOT the machine.

Pre-FreeBSD-2.2.5 Users:

The IDE/ATAPI CD-ROMs need to be setup as a slave on the Hard drive controller. It will not be recognized properly as a master on the second Hard drive controller This has been fixed in recent FreeBSD releases.

10.5.2.   Installing from an FTP Site

Installing from an FTP site is one of the easiest ways to install FreeBSD. It simplifies things greatly, because all you need is a boot disk and an internet connection.

Just Select a site that is close to where you are and press ENTER.

It is possible to install from a local FTP site that you have prepared. The site must include copies of all the distributions you wish to install. This would be helpful if you are planning to install several times from a slow link to the Internet. The distribution could be downloaded ahead of time and installed as many times as needed from local FTP site. See the section on Preparing Distribution Sets for a list of what to download and where to put it.

To install using FTP, your computer must be configured to reach the FTP site. You can do this a variety of ways.

If FreeBSD has detected a device that it could possibly connect, using FTP, protocols to another machine with, it will list them here. This list includes, Network Cards, COM ports, and parallel ports. If you have installed a Network Card, but it is not listed on this list, FreeBSD did not detect it during start up. You may need to check for the device during boot up, and make sure the IRQ and other address settings are correct.

Once you have selected an interface (Network card, modem, etc...), you will need to give your computer an identity on the network.

You have to give your computer a name. In the host field, enter in the name you have given this computer. This field can be anything of your choosing. It should be unique in your domain. In this example, the computer's name is wiggy. You only need to enter the name, the domain name will automatically get added to the host field as soon as you fill in the domain field. The domain name should be given to you by your ISP. A domain name is unique to a particular site or business. Each computer should have an individual hostname, but a common domain name. Kinda like first and last names in a family.

In the Example, the domain name is foo.com If you are configuring this for the Network or Internet, an IP address, gateway address, and nameserver IP address are also necessary. All of these should be provided to you by your ISP (Internet Service Provider).

The Gateway address in an IP address that TCP/IP uses to know how to get out to the internet. It is the address of the router that acts as a gateway between you and the internet.

The Name Server address is the IP address of the computer that will translate internet names into IP addresses so that TCP/IP protocols can connect using easy to read names. For example, freebsd.org is at IP address However, that is very hard to remember. The DNS (Domain Name Server) will translate that IP address into something readable to us, and vice-versa.

The IP address is your personal IP address that belongs to the machine you are setting up FreeBSD on. The hostname you just gave it will correspond to this IP address. An entry will need to be setup later in your DNS to make this happen. Do not pick a random IP address. Each IP address has to be unique on the internet. Please get this information from your ISP.

The Netmask is an indication of the relationship between the IP address on this machine and the Gateway IP address. Each 255 that appears in the Netmask means that that field is the same in both Gateway and local IP address. The standard Netmask is This netmask tells us that the first three sets of numbers on the IP address match with the first three numbers on the Gateway IP address.

	IP address:

This would be a correct scenario. If the numbers differ in the fields, either the netmask would need to be opened up a bit, or a router would need to be installed between the two sets of numbers. A router would create a reachable gateway.

	IP address:
			 ^^^(These are Different.)
			 ^^^(These are Different.)
			 ^^^(Therefore this mask blocks them.)

This would not be a reachable Gateway. If the Netmask was opened up to, then the Gateway would be visable.

You do not need to give any parameters to Extra options to ifconfig.

From here you are ready to start installing the actual files. Just select OK. If you are in the Novice or Express installs, it will move you ahead and ask you if you are sure you want to do this. If you are in a custom install, you have to select Commit from the install Menu

If you experience any difficulties, copy down any error messages you received during the install process and consult the FAQ and handbook for anything relating to that topic. Then search the mailing list archives. If that reveals nothing, consult the people on the questions@freebsd.org mailing list. Be sure to reference the errors you received.

Return to Table of Contents

Visit the Gifcom