Hetzner - DokuWiki

FreeBSD installieren/en



The FreeBSD rescue system (mfsBSD) allows you to install the following versions:

  • FreeBSD 9.3 (64bit)
  • FreeBSD 10.1 (64bit)

Starting the Rescue System

To install FreeBSD on your server, you first need to start the FreeBSD Rescue System. Log in to your server via SSH. For reasons of security, it is recommended that you have a backup of your server before proceeding.

Automatic Installation

The installation can be started by using the following command:

# bsdinstallimage

The script is based on the official freebsd "bsdinstall". In the dialogs you can select options like version, architecture and packets. The source file are downloaded from the official freebsd mirror. After the installation is complete, you can restart your server:

# reboot

A few minutes later your server will once again be reachable via SSH.

Manual Installation

An installation can also be performed by using the original installer of FreeBSD. The following command can be used for this:


A note about the CX models: The following line must be added to /boot/loader.conf, as FreeBSD will otherwise not boot:


Network Configuration

Please note that it is not possible to reach servers on the same subnet directly. Instead, you will have to send the packets to your gateway.


The special routing paramters can be specified in /etc/rc.conf:

ifconfig_re0="inet <insert main ip>/32"
gateway_ip="<insert gateway ip>"
static_routes="gateway default"
route_gateway="-host $gateway_ip -interface $gateway_if"
route_default="default $gateway_ip"

Notice: do not use the "defaultrouter" keyword with this configuration!


The default IPv6 gateway fe80::1 can be defined in /etc/rc.conf:

# set a static local interface-route

Configure additional IP addresses

The configuration of an additional IP addresses or subnets in FreeBSD is achieved by adding the alias entries in /etc/rc.conf. For each additional subnet (or if the additional IP is on a different subnet than the main IP), the correct netmask must be used on the first IP address for that subnet. All subsequent IP addresses should be added as /32's (

ifconfig_<interface>_alias0="inet <ipadresse1> netmask"
ifconfig_<interface>_alias1="inet <ipadresse2> netmask"

© 2015. Hetzner Online GmbH. Alle Rechte vorbehalten.