Table of Contents

Basic installation

Booting

On first boot, we get to see the bootloader as shown at https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/bsdinstall-start.html. The automatic boot sequence can be interrupted using the “space” bar.

For the basic installation, the first option “Boot Multi User” is correct. The single user boot is used e.g. for fixing a b0rked system.

Note: if you're stuck in the VM and can't get the mouse pointer back - remember that hitting the right control key will return you to your host system. Click into the VM to go back there.

Hit enter and you'll see a series of messages from the kernel, as was usual too for linux a while back.

The installer will come on with the question of beginning an installation of using the live CD - it's clearly “install” here.

Installer

keymap

The installer's first question concerns the keyboard map. Choose yours - it's swiss french for me, so I select: “Swiss-French ISO-8859-1 (accent keys)”. Testing it gives me strange results on accents and umlauts and some of the special characters, while most is actually right. It's quite the same with “Swiss-French ISO-8859-1” or even the Codepage 850 version, so I keep the first. I'm frankly surprised it's not in UTF-8. I finally continue with swissfrench.iso.acc.kbd keymap.

hostname

The next question regards the hostname. Ask your network admin what to use, if it's you, use some name, avoid non-alphanumeric characters (so as not to have issues with DNS). I'm using “server2016”.

optional system components

We are now asked to choose optional system components to install:

In our case, doc, games, sources are certainly irrelevant, as we'll find documentation online anyway, won't need sources, and certainly no games. lib32 allows using 32bit stuff on a 64bit install, which might be useful. ports is a collection of tools to automate d/l, compilation and installation of 3rd-party stuff, which also might be useful - but needs some 500MB of space.

network installation

Since we're in network installation mode, we'll now be asked about the configuration so as to fetch stuff online.

First, the network interface to configure is chosen - only one in the list here, em0.

Second, IPv4 for that interface. As we'll run a server anyway, we'll need a static IP here, so let's set it up right away. No, not DHCP, but fully manual configuration. Here, I'll use IP 192.168.1.5 with subnet mask 255.255.255.0 and default router 192.168.1.1, that being consistent with my local network.

Third, IPv6 for the interface. Let's skip that for now.

Fourth, DNS resolver. We'll search hellsnet.lu, and use resolver 192.168.1.1 (maybe add one from the ISP).

Fifth, we're asked which mirror to use, it should be the closest one in network terms. There's no FreeBSD mirror here in Luxembourg, but I usually get good results with Switzerland, so I'll try that.

disk partitioning

The next question is about disk partitioning. Considering my lack of experience with FreeBSD, I lean towards letting the installer handling this, i.e. “Auto (UFS)” guided disk setup. As this is a small VM, there's no point in dealing with ZFS or fine-tuning for performance, also the entire disk can be left to FreeBSD. The partition scheme for the volume can again be left to default (GPT - GUID partition table).

The installer automatically created the setup:

It is friendly enough to ask for re-confirmation, since this step will erase any already-existing data. Here on a new VM it's irrelevant, but could be disastrous on a physical machine. I choose “commit”.

After doing the partitioning, the installer tries to fetch data from the mirror server - here I get my first error “file not found, no access” - indeed, I should have checked from the mirror list at https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/mirrors-ftp.html, from where I also don't get access to that swiss mirror. The first link for Germany does work, so I'll use that after restarting the installation. The restart implies re-answering the same questions, but some values were kept from the previous run.

fetching base system

The installer now fetches the files for the base system from the mirror, i.e. base.txz, kernel.txz, lib32.txz, ports.txz. The downloaded files are checked for integrity, then extracted.

post-installation

After the installation of the basic system comes the post-installation configuration.

password

We're asked for a root password.

clock

We're asked whether the CMOS clock is set to UTC or local time.

I set it to UTC, so I choose “yes”.

time zone selection

The region here is Europe, the country is Luxembourg. Based on that, confirmation is asked for “CET” (central european time) - which is perfectly reasonable indeed.

services to start at boot

The following services are proposed for start at boot:

I might to for the local dns resolver later, sshd is a MUST, ntpd is nice to have, don't need/want moused, powerd or dumpdev.

additional accounts

Would I like more users, yes - if only to disable straight root login via ssh, forcing attackers to at least have a guess at the account name, besides the password. To be able to su to root, the user must be added to the wheel group!

Provide all the details where necessary, leave the defaults otherwise. After the review, confirm with “yes”, say no as to whether to add another user.

final configuration

We can change or redo some of what we already previously saw, or exit the installer so as to apply the configuration. Since we already did it all, no point reviewing stuff, exit.

We could now opt for going into a shell so as to manually do stuff, but no need at this point.

reboot

The installation is complete, we can reboot to get into the newly installed system. It is necessary though to disconnect the virtual CD/DVD medium first, else you'll just restart the installer.

fix behavior of DEL key

I got pretty annoyed at the DEL key not working as expected, at least when connecting to the VM from Linux (TERM is set to xterm). This was true for the root user, which runs a C shell (csh), not a normal user running a bourne shell (sh).

This is easily remedied by adding a line to /etc/csh.cshrc:

bindkey "\e[3~"   delete-char              # xterm

A round of “exit” and “su -” then gets you a working DEL key.