How to implement PXE with Synology NAS

Overview

Equipped with TFTP support and Synology's service, Synology NAS serves as an integral part of your Preboot Execution Environment (PXE) setup. With PXE, client devices can boot over the network using network bootstrap programs stored on your Synology NAS, instead of booting up with operating systems stored on local storage. This is an ideal solution for companies that wish to centralize and simplify management in mass deployment environments.

This article will guide you through the steps of enabling TFTP service and setting up PXE with your Synology NAS.

Note: This article assumes that you possess prior programming or network management experience.

Contents

  1. What is PXE?
  2. Before you start
  3. Setting up PXE

1. What is PXE?

Preboot Execution Environment (PXE) is an environment that allows devices to boot up over the network prior to booting up with the operating system on local storage. Instead of using the operating system on its local storage, a client device can boot up using a network bootstrap program (NBP) stored on your Synology NAS.

In this type of environment, operating systems can be installed on client devices from your Synology NAS, eliminating the need to physically visit each client PC with a stack of installation CDs. Setting up a new client PC is as simple as connecting it to the network and powering it on. This can dramatically reduce administration time.

To implement PXE, network bootstrap programs are stored on your Synology NAS in the folder of your choice. After modifying the settings of your existing DHCP server to redirect client devices to the appropriate file path, client devices can access the network bootstrap programs via TFTP. Alternatively, you can set up Synology's DHCP services, which allow you to provide both DHCP and TFTP service with the same Synology NAS, implementing an all-in-one PXE solution.

2. Before you start

Before starting, please do the following:

  • Set up your Synology NAS and install Synology DiskStation Manager (DSM).
  • Create at least one volume (see here) and shared folder (see here).
  • Make sure your client device supports PXE.

For information about basic hardware and software setup, please refer to the Quick Installation Guide for your Synology product. In addition, you can also see Synology DiskStation User's Guide for additional information related to this article. Both documents are available at the Synology Download Center.

3. Setting up PXE

In the sections below, we'll take a look at two ways Synology NAS can help you implement PXE:

3.1 Setting up PXE with TFTP service on Synology NAS and an external DHCP server

Trivial File Transfer Protocol (TFTP) is a simple file transfer protocol, which is often used to transfer network bootstrap programs to PXE client devices. Enabling TFTP service on your Synology NAS allows it to transfer network bootstrap programs to client devices. When combined with your existing DHCP server, client devices will be able to obtain and boot up using the network bootstrap program stored on your Synology NAS. Figure 1 below illustrates the role of each device in this type of PXE setup.

Figure 1 illustrates the three devices which are essential for this type of PXE setup.
  1. The DHCP server provides the client device with the IP address of the TFTP server and network bootstrap program information (e.g. file path, etc).
  2. The TFTP server (i.e. your Synology NAS) transfers the network bootstrap program to the client device via TFTP.
  3. The client device boots up using the network bootstrap program.

To enable TFTP on Synology NAS:

  1. Go to Main Menu > Control Panel > File Services and select the TFTP/PXE tab.
  2. Tick Enable TFTP service.
  3. In the TFTP root folder section, select the folder where you stored the network bootstrap program and any other files required for booting up your client device. (Your settings and environment will differ from the example below.)
  4. Click Apply to save the settings.
  5. Log into your DHCP server and finish setting up the appropriate network settings. (Alternatively, you may also refer to the section below to set up DHCP services on your Synology NAS and complete PXE on one Synology NAS.)
  6. Power on your client device. You will now be able to boot it up using PXE.

3.2 Set up DHCP services and implement PXE on one Synology NAS

If you wish to provide both TFTP and DHCP service with your Synology NAS, you can set up Synology's DHCP services from Control Panel. When running DHCP services, the necessary services for PXE can be provided by one Synology NAS, thus simplifying your environment. Figure 2 illustrates the role of each device in this type of PXE setup.

Figure 2 illustrates the role of each device to when running DHCP services and implementing PXE on one Synology NAS.
  1. The TFTP + DHCP service (i.e. your Synology NAS) provides the client device with the network bootstrap program information (e.g. file path, etc).
  2. The client device boots up using the network bootstrap program.

To set up DHCP service on the Synology NAS:

  1. Go to Main Menu > Control Panel > File Services and select the TFTP / PXE tab.
  2. Tick the box marked Set up DHCP service on this server for PXE.
  3. In the Boot loader section, select your network bootstrap program stored in the TFTP root folder you specified above. (Your settings and environment will differ from the example below.)
  4. Modify the DHCP subnet settings appropriately. PXE client devices will be assigned IP addresses based on these settings.
  5. Power on your client device. You will now be able to boot it up using PXE.