Bootstrap System Configuration Over Network

About

This document aims to provide information on how to configure your device to obtain its configuration over the network.

For an overview of all available boot configuration options refer to the configuration guide:

For a more concrete use-case how to bootstrap the system configuration file over DHCP, see the following page:

Introduction

Allowing the device to obtain its configuration over the network can help with centralizing the distribution of configurations for multiple devices on a larger network. Necessary configuration changes to devices on the network can simply be performed on the server containing the files, when the specific device reboots it will obtain the new configuration.

Another advantageous aspect is that it allows for easier substitution of devices, where a new device can simply obtain the same configuration as the last device that it replaced.

                      .--------.
                      |        |
                      | Server |
                      |        |
                      '---+----'
                          |
                      .--.-.
                     ( (    )__
                    (_,  \ ) ,_)  Internet/Intranet
                      '-'--`--'
                       |
   ---------+----------+----------+---------
            |          |          |
          .-+--.     .-+--.     .-+--.
          | H1 |     | H2 |     | H3 |
          '----'     '----'     '----'

Figure 1: The hosts are configured to obtain their configuration files from the server, somewhere on the network.

Configuration

In order to configure the system to attempt obtaining its startup configuration over the network, the boot config-order needs to be adjusted:

example:/#> boot
example:/boot/#> config-order internal:net

The first part of the configured option, internal, dictates that we should mount the internal media. The second part of the option, net, states that we should attempt to obtain the configuration over the network.

Additional settings specific to the net configuration can be controlled in its own sub-context:

example:/boot/#> net
example:/boot/net/#>

For more information on these options refer to the boot configuration options page.

Sync

The net sync option allows syncing any configuration file, obtained during the net boot, to be stored on the currently active configuration media. The specific media is determined based on how net was configured in the config-order, for example:

  • internal:net -> If this config order option is active we will sync the obtained configuration file to the internal media definition.

  • internal:net -> If this config order option is active we will sync the obtained configuration file to the external media definition.

Keep in mind that other media definitions can be added using the media command.

The net sync is enabled in the following manner:

example:/boot/#> net
example:/boot/net/#> sync
example:/boot/net/#> end
example:/boot/#>

This allows for configurations where we can use the last obtained configuration file from the server on the network, if it for some reason would become unavailable. In order to do this we set the next entry in the config-order to match the startup of the media used for the net boot configuration:

example:/boot/#> config-order internal:net, internal:startup

If the net boot time out, we bootstrap the internal startup file. Because we have enabled sync it will be the last obtained net configuration file.

Note

The sync option under the net context, is not the be mixed up with the config-sync option. These two are completely different functionalities.

Network Bootstrap Mode

When the device is configured to perform a network bootstrap of a configuration file, it will by default attempt to ask for a configuration file over active link connected to the device. The first file that it receive that it can safely apply to the device will be used.

Further, when the device in network boot mode it is still possible to receive a login prompt to the device, if connected with console cable. This makes it possible to log on to the device even tough the file have not yet been received, this can among other things be useful for debugging.

netboot-12-34-50 login: admin

.--.--.--.-----.-----.-------.-----.----.--------.-----.
|  |  |  |  -__|__ --|_     _|  -__|   _|        |  _  |
|________|_____|_____| |___| |_____|__| |__|__|__|_____|
                                       www.westermo.com 

.....................[ NOTICE ]........................
. Network boot in progress, awaiting a valid startup  .
.     configuration to be downloaded and applied      .
.......................................................

netboot-12-34-50:/#>

When logging into the device when net boot is in progress a Notice will be displayed informing the user. In addition the hostname can also be used to identify that the device is in net bootstrap mode. Set to netboot and the MAC address of the device without the Organizationally Unique Identifier. In the example above it is netboot-12-34-50.

Once a valid configuration is obtained or if the net boot times out and the next config-order option is applied, that configuration file will be seamlessly applied to the device.

While the system is in net boot mode, login credentials are the default admin/admin. The password to the device while in network bootstrap mode can also be changed in the following manner:

example:/boot/#> net
example:/boot/net/#> password Example