Add UEFI Support to PXE Boot Server on CentOS 7
BIOS (Basic Input/Output System) and UEFI (Unified Extensible
Firmware Interface) are two firmware interfaces for computer systems
which work as an interpreter between the operating system and the
computer firmware.
Both of these are installed at the time of manufacturing and is the first
program that runs when a computer is turned on. BIOS uses
the Master Boot Record (MBR) to save information about the hard
drive data while UEFI uses the GUID partition table (GPT).
MBR uses 32-bit entries in its table which limits the total physical
partitions to only 4 with maximum size of 2 TB each.
Whereas, GPT uses 64-bit entries in its table which allows it use more
than 4 physical partitions with larger sizes.
In our previous article Setup a PXE Boot Server in RHEL/CentOS 7, we
have configured a PXE boot server and added the RHEL 7.5
installation option in it. The configuration worked fine with BIOS based
computer systems, but didn’t support UEFI based clients.
In this article, we will add UEFI support to our PXE Boot Server on
CentOS 7.
Note: In this article, we are performing everything from CLI, therefore,
it is highly recommended that, you should have Linux Pocket Guide:
Essential Commands for quick reference.
System Specification:
We use the same CentOS 7 server that we have configured as PXE
Boot Server in our previous article. The specifications have been re-
mentioned below for convenience of the readers.
CPU: 2 Core (2.4 Mhz)
Memory: 2 GB
Storage: 50 GB
Operating System: CentOS 7.5
Hostname: pxe-server.itlab.com
IP Address: 192.168.116.41/24
Configure PXE Boot Server to support UEFI based systems:
Connect to pxe-server.itlab.com using ssh .
Adjust DHCP server configuration to support UEFI systems.
#vi /etc/dhcp/dhcpd.conf
Search for following lines in the above file.
#PXE boot server
next-server 192.168.116.41;
filename "pxelinux.0";
Replace above lines with following configurations.
class "pxeclients" {
match if substring (option vendor-class-identifier, 0, 9) =
"PXEClient";
next-server 192.168.116.41;
if substring (option vendor-class-identifier, 15, 5) = "00009" {
filename "grubx64.efi";
} else {
filename "pxelinux.0";
}
}
Restart dhcpd.service to apply changes.
#systemctl restart dhcpd.service
If dhcpd.service gives error during startup, then look for any
possible syntax errors therein and try to restart the service again.
For more details on comparisons in the above configurations, please
refer to RFC 4578 - Dynamic Host Configuration Protocol (DHCP)
Options for the Intel Preboot eXecution Environment (PXE).
Now, we need a bootloader (such as grubx64.efi ) to support UEFI
clients. This bootloader is available in CentOS 7.5 ISO.
Copy grubx64.efi to /var/lib/tftpboot directory.
#cp /var/ftp/pub/rhel7/EFI/BOOT/grubx64.efi /var/lib/tftpboot/
Our PXELINUX menu does not work for UEFI systems, therefore we
have to create another menu for the UEFI clients.
The menu filename is grub.cfg and it is located
at /var/lib/tftpboot . Therefore, we will define RHEL 7.5
installation option in this file as follows:
#cat >> /var/lib/tftpboot/grub.cfg << EOF
> set timeout=60
>
> menuentry 'Install RHEL 7.5' {
> linuxefi /networkboot/rhel7/vmlinuz
inst.repo=ftp://192.168.116.41/pub/rhel7/
> initrdefi /networkboot/rhel7/initrd.img
> }
> EOF
Restart tftp.service to apply changes.
#systemctl restart tftp.service
UEFI configurations has been completed.
To test the configurations, connect a UEFI based system to network,
and turn it on.
The UEFI client will fetch the above menu from PXE boot server.
Add RHEL 6 installation option to PXE Server
In our previous posts, we have configured a PXE boot server for automated installation
of RHEL 7.5 operating system that supports both BIOS and UEFI based clients.
Now, we will add RHEL 6 installation option in our PXE boot server. We will also create
a Kickstart file for automated installation of RHEL 6 operating system, and ensure that
it will support both BIOS and UEFI based clients.
The task can be broken down into following steps:
1) Copy RHEL 6 ISO/DVD contents to FTP Server
2) Create a Kickstart file for RHEL 6 automated installation
3) Copy Boot images to tftpboot directory
4) Create Menu Entries for RHEL 6 installation
Note: In this article, we are performing everything from CLI, therefore, it is highly
recommended that, you should have Linux Pocket Guide: Essential Commands for
quick reference.
System Specification:
We use the same Linux server that we have configured as PXE Boot Server in our
previous article. These specifications have been re-mentioned below for convenience
of the readers.
CPU: 2 Core (2.4 Mhz)
Memory: 2 GB
Storage: 50 GB
Operating System: RHEL 7.5
Hostname: pxe-server.itlab.com
IP Address: 192.168.116.41/24
Copy RHEL 6 ISO/DVD contents to FTP Server:
Connect to pxe-server.itlab.com using ssh .
Attach RHEL 6 ISO/DVD and mount it at /mnt/iso (you can use any mountpoint,
according to your choice).
# mount -t iso9660 /dev/cdrom /mnt/iso
mount: /dev/sr0 is write-protected, mounting read-only
Copy contents of /mnt/iso directory to FTP server.
# cp -rf /mnt/iso /var/ftp/pub/rhel6
Create a Kickstart file for automated installation of RHEL 6:
We have to write a Kickstart file for RHEL 6 within
the /var/ftp/pub/rhel6 directory, so it can be accessed by PXE clients via FTP
service.
# vi /var/ftp/pub/rhel6/rhel6.cfg
A sample kickstart file is given below, you can modify it according to your
requirements.
Read Also: Automate PXE Client Installations with Kickstart
#platform=x86, AMD64, or Intel EM64T
#version=DEVEL
# Install OS instead of upgrade
install
# Keyboard layouts
keyboard 'us'
# Root password
rootpw --iscrypted $1$vyNMLtgd$VmtByshddZSBK..uuFhoH0
# Use network installation
url --url="ftp://192.168.116.41/pub/rhel6"
# System language
lang en_US
# System authorization information
auth --useshadow --passalgo=sha512
# Use graphical install
graphical
firstboot --disable
# SELinux configuration
selinux --enforcing
# Firewall configuration
firewall --enabled --ssh
# Network information
network --bootproto=dhcp --device=eth0
# Reboot after installation
reboot
# System timezone
timezone Asia/Karachi
# System bootloader configuration
bootloader --location=mbr
autopart
# Partition clearing information
clearpart --none --initlabel
# Packages to be installed
%packages
@core
%end
Copy boot images to tftpboot directory:
We need to copy initrd.img and vmlinuz files from RHEL 6 ISO
to /var/lib/tftpboot/networkboot/rhel6 directory. These files will be later
referenced in the menu entry of PXE boot menu.
# mkdir /var/lib/tftpboot/networkboot/rhel6
# cp /var/ftp/pub/rhel6/images/pxeboot/vmlinuz
/var/lib/tftpboot/networkboot/rhel6/
# cp /var/ftp/pub/rhel6/images/pxeboot/initrd.img
/var/lib/tftpboot/networkboot/rhel6/
Create Menu Entries for RHEL 6 installation:
Edit PXE boot menu for BIOS based clients.
# vi /var/lib/tftpboot/pxelinux.cfg/default
add a menu entry for RHEL 6 installation therein.
default menu.c32
prompt 0
timeout 30
menu title Ahmer's PXE Menu
label Install RHEL 7.5
kernel /networkboot/rhel7/vmlinuz
append initrd=/networkboot/rhel7/initrd.img
inst.repo=ftp://192.168.116.41/pub/rhel7
ks=ftp://192.168.116.41/pub/rhel7/rhel7.cfg
label Install RHEL 6.0 (64-bit)
kernel /networkboot/rhel6/vmlinuz
append initrd=/networkboot/rhel6/initrd.img
inst.repo=ftp://192.168.116.41/pub/rhel6
ks=ftp://192.168.116.41/pub/rhel6/rhel6.cfg
Edit PXE boot menu for UEFI based clients.
# vi /var/lib/tftpboot/grub.cfg
add a menu entry for RHEL 6 installation therein.
set timeout=60
menuentry 'Install RHEL 7.5' {
linuxefi /networkboot/rhel7/vmlinuz
inst.repo=ftp://192.168.116.41/pub/rhel7/
inst.ks=ftp://192.168.116.41/pub/rhel7/rhel7.cfg
initrdefi /networkboot/rhel7/initrd.img
}
menuentry 'Install RHEL 6.0' {
linuxefi /networkboot/rhel6/vmlinuz
inst.repo=ftp://192.168.116.41/pub/rhel6/
inst.ks=ftp://192.168.116.41/pub/rhel6/rhel6.cfg
initrdefi /networkboot/rhel6/initrd.img
}
Now, connect a BIOS based PXE client to network and boot it. It will display the
following PXE boot menu.
Similarly, connect a UEFI based PXE client to network and boot it. It will display the
following PXE boot menu.
We have successfully added the RHEL 6 installation option to our PXE boot server.
You can add other versions of RHEL or CentOS in similar manner.
Configure CentOS 7 PXE Server to Install Windows 10
In our previous posts, we have configured a PXE boot server for automated installation
of RHEL 7.5 operating system that supports both BIOS and UEFI based clients.
Later on, we added RHEL 6 and Ubuntu 18.10 installation options in our PXE boot
server. We have also writed Kickstart files for automated installations of both operating
systems.
Before concluding our PXE server configuration series, we decided to write an article
to add the installation option of a Microsoft’s operating system. Therefore, we have
selected the Microsoft Windows 10 (the latest OS at the time of this writeup) as the
candidate for our PXE boot server.
In this article, we will add the installation option of MS Windows 10 to our PXE server.
Note: In this article, we are performing everything from CLI, therefore, it is highly
recommended that, you should have Linux Pocket Guide: Essential Commands for
quick reference.
System Specification:
We use the same Linux server that we have configured as PXE Boot Server in our
previous article. These specifications have been re-mentioned below for convenience
of the readers.
CPU: 2 Core (2.4 Mhz)
Memory: 2 GB
Storage: 50 GB
Operating System: RHEL 7.5
Hostname: pxe-server.itlab.com
IP Address: 192.168.116.41/24
Furthermore, we need a client system to create Windows PE iso file. Here, we are
using a MS Windows 8.1 machine for this purpose, however, you can use other
versions of MS Windows as well (be noted that configurations are slightly different in
MS Windows versions prior to 8.1).
Install and Configure Samba Server:
We used Samba server to share installation media of MS Windows 10 Operating
System with PXE clients.
Connect to pxe-server.itlab.com using ssh and install Samba server.
#yum install -y samba
Create a directory to share Windows 10 installation media.
#mkdir /smbshare
Adjust SELinux permissions.
#semanage fcontext -a '/smbshare(/.*)?' -t samba_share_t
#restorecon -Rv /smbshare
Create an user to control access to Samba share.
#useradd -s /sbin/nologin ahmer
#smbpasswd -a ahmer
Change owner of the shared directory with user ahmer .
# chown ahmer:ahmer /smbshare/
Allow Samba service in Linux Firewall.
#firewall-cmd --permanent --add-service=samba
success
#firewall-cmd --reload
success
Add directives in /etc/samba/smb.conf to share the directory /smbshare with
clients.
#cat >> /etc/samba/smb.conf << EOF
> [install]
> comment = Installation Media
> path = /smbshare
> public = yes
> writable = no
> printable = no
> browseable = yes
> EOF
Start and enable Samba services.
#systemctl start smb nmb
#systemctl enable smb nmb
Attach MS Windows 10 ISO/DVD and mount it at /mnt/iso (you can use any
mountpoint, according to your choice).
#mount -t iso9660 /dev/cdrom /mnt/iso
mount: /dev/sr0 is write-protected, mounting read-only
Copy contents of /mnt/iso to /smbshare/windows10 directory.
#cp -rf /mnt/iso /smbshare/windows10
Create a Customized Windows PE ISO:
Connect to MS Windows 8.1 client.
We required Windows ADK (Assessment and Deployment Kit) to create our Windows
PE iso. Therefore, we have downloaded it from Microsoft's website and installed it on
our Windows 8.1 client.
After installation, run Deployment and Imaging Tools Environment as
Administrator.
Run the following command to create working directories for Win PE. (Command
output has been trimmed to show only success status)
C:\Program Files (x86)\Windows Kits\8.0\Assessment and Deployment Kit\Windows Pr
einstallation Environment> copype x86 c:\WinPE_x86
---
186 File(s) copied
1 file(s) copied.
1 file(s) copied.
1 file(s) copied.
Success
c:\WinPE_x86>
We will customize the startup script startcmd.net , so MS Windows 10 setup will
start automatically. Therefore, mount the image file and customize it accordingly.
c:\WinPE_x86> Dism /Mount-Image /ImageFile:"c:\WinPE_x86\media\sources\boot.wim"
/index:1 /MountDir:"c:\WinPE_x86\mount"
Deployment Image Servicing and Management tool
Version: 6.2.9200.16384
Mounting image
[==========================100.0%==========================]
The operation completed successfully.
c:\WinPE_x86>
Now, edit startnet.cmd.
c:\WinPE_x86> notepad c:\WinPE_x86\mount\Windows\System32\Startnet.cmd
And add following lines therein.
wpeinit
net use z: \\192.168.116.41\install\windows10 /user:ahmer 123
z:\setup.exe
Save and unmount the image file.
c:\WinPE_x86> Dism /Unmount-Image /MountDir:"c:\WinPE_x86\mount" /commit
Deployment Image Servicing and Management tool
Version: 6.2.9200.16384
Saving image
[==========================100.0%==========================]
Unmounting image
[==========================100.0%==========================]
The operation completed successfully.
c:\WinPE_x86>
Generate winpe.iso file.
c:\WinPE_x86> MakeWinPEMedia /ISO c:\WinPE_x86 c:\winpe.iso
Creating c:\winpe.iso...
100% complete
Success
c:\WinPE_x86>
Transfer winpe.iso file to pxe-server-itlab.com and copy it
to /var/lib/tftpboot/networkboot/windows10/ directory.
Add MS Windows 10 installation option to PXE boot menu:
Now, connect to pxe-server.itlab.com again using ssh .
Edit PXE boot menu for BIOS based clients.
#vi /var/lib/tftpboot/pxelinux.cfg/default
And add following menu option at the end of file.
label Install MS Windows 10
menu label Install MS Windows 10
kernel memdisk
initrd /networkboot/windows10/winpe.iso
append iso raw
Connect a new client to your network and turn it on. It should get the IP address from
DHCP server and display our PXE boot Menu as follows:
Select Install MS Windows 10 option and press <ENTER>.
We have successfully added the MS Windows 10 installation option in our Linux based
PXE server.
Configure CentOS 7 PXE Server to Install Ubuntu 18.10
In our previous posts, we have configured a PXE boot server that supports both BIOS and UEFI based clients. We
have also configured our CentOS 7 PXE server to install RHEL 6 and RHEL 7 operating systems using Kickstart. Now, we
will configure our CentOS 7 PXE server to install Ubuntu 18.10.
We will also create a Kickstart file for automated installation of Ubuntu 18.10 operating system, and ensure that it will
support both BIOS and UEFI based clients.
This task can be broken down into following steps:
1) Share Ubuntu 18.10 ISO/DVD contents via NFS Server
2) Create a Kickstart file for Ubuntu 18.10 automated installation
3) Copy Boot images to tftpboot directory
4) Create Menu Entries for Ubuntu 18.10 installation
Note: In this article, we are performing everything from CLI, therefore, it is highly recommended that, you should
have Linux Pocket Guide: Essential Commands for quick reference.
System Specification:
We use the same CentOS 7 machine that we have configured as PXE Boot Server in our previous article. These
specifications have been re-mentioned below for convenience of the readers.
CPU: 2 Core (2.4 Mhz)
Memory: 2 GB
Storage: 50 GB
Operating System: CentOS 7.5
Hostname: pxe-server.itlab.com
IP Address: 192.168.116.41/24
Share Ubuntu 18.10 ISO/DVD contents via NFS Server:
Connect to pxe-server.itlab.com using ssh as root user.
Install NFS packages using yum command.
#yum install -y nfs-utils
Loaded plugins: product-id, search-disabled-repos, subscription-manager
This system is not registered with an entitlement server. You can use subscription-
manager to register.
localyum | 4.3 kB 00:00
Resolving Dependencies
--> Running transaction check
---> Package nfs-utils.x86_64 1:1.3.0-0.54.el7 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
nfs-utils x86_64 1:1.3.0-0.54.el7 localyum 407 k
Transaction Summary
================================================================================
Install 1 Package
Total download size: 407 k
Installed size: 1.0 M
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : 1:nfs-utils-1.3.0-0.54.el7.x86_64 1/1
Verifying : 1:nfs-utils-1.3.0-0.54.el7.x86_64 1/1
Installed:
nfs-utils.x86_64 1:1.3.0-0.54.el7
Complete!
Start and Enable NFS service.
#systemctl start nfs-server
#systemctl enable nfs-server
Created symlink from /etc/systemd/system/multi-user.target.wants/nfs-server.service to
/usr/lib/systemd/system/nfs-server.service.
Create a directory for sharing Ubuntu 18.10 ISO.
#mkdir /nfsshare
#chown nfsnobody:nfsnobody /nfsshare
Allow NFS and relevant ports in CentOS 7.5 Firewall.
#firewall-cmd --permanent --add-service={nfs,mountd,rpc-bind}
success
[root@pxe-server /]# firewall-cmd --reload
success
Adjust SELinux Permissions.
[root@pxe-server /]# semanage fcontext --add -t nfs_t '/nfsshare(/.*)?'
[root@pxe-server /]# restorecon -Rv /nfsshare/
restorecon reset /nfsshare context unconfined_u:object_r:var_t:s0-
>unconfined_u:object_r:nfs_t:s0
Export /nfsshare directory for all clients.
[root@pxe-server /]# echo "/nfsshare *(ro)" >> /etc/exports
[root@pxe-server /]# exportfs -r
Attach Ubuntu 18.10 Server ISO/DVD and mount it at /mnt/iso (you can use any mountpoint, according to your
choice).
#mount -t iso9660 /dev/cdrom /mnt/iso
mount: /dev/sr0 is write-protected, mounting read-only
Copy contents of /mnt/iso directory to NFS server.
#cp -rf /mnt/iso /nfsshare/ubuntu18
Create a Kickstart file for automated installation of Ubuntu 18.10:
We have to write a Kickstart file for Ubuntu 18.10 within the /nfsshare/ubuntu18/preseed/ directory, so it
can be accessed by PXE clients via NFS service.
#vi /nfsshare/ubuntu18/preseed/ubuntu.seed
A sample kickstart file is given below, you can modify it according to your requirements.
# Enable extras.ubuntu.com.
d-i apt-setup/extras boolean true
# Install the Ubuntu desktop.
tasksel tasksel/first multiselect ubuntu-desktop
# On live DVDs, don't spend huge amounts of time removing substantial
# application packages pulled in by language packs. Given that we clearly
# have the space to include them on the DVD, they're useful and we might as
# well keep them installed.
ubiquity ubiquity/keep-installed string icedtea6-plugin openoffice.org
#System language
lang en_US
#Language modules to install
langsupport en_US
#System keyboard
keyboard us
#System mouse
mouse
#System timezone
timezone Asia/Karachi
#Root password
rootpw --disabled
#Initial user (user with sudo capabilities)
user ubuntu --fullname "ahmer" --password ahmer1234
#Reboot after installation
reboot
#Use text mode install
text
#Install OS instead of upgrade
install
#Installation media
nfs --server=192.168.116.41 --dir=/nfsshare/ubuntu18/
#System bootloader configuration
bootloader --location=mbr
#Clear the Master Boot Record
zerombr yes
#Partition clearing information
clearpart --all --initlabel
#Basic disk partition
part / --fstype ext4 --size 1 --grow --asprimary
part swap --size 1024
part /boot --fstype ext4 --size 256 --asprimary
#System authorization infomation
auth --useshadow --enablemd5
#Network information
network --bootproto=dhcp --device=eth0
#Firewall configuration
firewall --disabled --trust=eth0 --ssh
Copy boot images to tftpboot directory:
The Boot images in the Ubuntu ISO won’t work for network boot Therefore, we downloaded netboot images
from Ubuntu website.
#wget http://archive.ubuntu.com/ubuntu/dists/cosmic/main/installer-
amd64/current/images/netboot/netboot.tar.gz
--2018-11-17 11:09:13-- http://archive.ubuntu.com/ubuntu/dists/cosmic/main/installer-
amd64/current/images/netboot/netboot.tar.gz
Resolving archive.ubuntu.com (archive.ubuntu.com)... 91.189.88.152, 91.189.88.161,
91.189.88.162, ...
Connecting to archive.ubuntu.com (archive.ubuntu.com)|91.189.88.152|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 56245393 (54M) [application/x-gzip]
Saving to: ânetboot.tar.gz.1â
100%[======================================>] 56,245,393 179KB/s in 7m 23s
2018-11-17 11:16:40 (124 KB/s) - ânetboot.tar.gz.1â saved [56245393/56245393]
Extract download TARBall.
#mkdir netboot
#tar xvf netboot.tar.gz -C netboot
./
./ldlinux.c32
./pxelinux.cfg
./ubuntu-installer/
./ubuntu-installer/amd64/
./ubuntu-installer/amd64/linux
./ubuntu-installer/amd64/boot-screens/
./ubuntu-installer/amd64/boot-screens/txt.cfg
./ubuntu-installer/amd64/boot-screens/f2.txt
./ubuntu-installer/amd64/boot-screens/ldlinux.c32
./ubuntu-installer/amd64/boot-screens/f8.txt
./ubuntu-installer/amd64/boot-screens/libcom32.c32
./ubuntu-installer/amd64/boot-screens/f10.txt
./ubuntu-installer/amd64/boot-screens/prompt.cfg
./ubuntu-installer/amd64/boot-screens/f3.txt
./ubuntu-installer/amd64/boot-screens/rqtxt.cfg
./ubuntu-installer/amd64/boot-screens/syslinux.cfg
./ubuntu-installer/amd64/boot-screens/f1.txt
./ubuntu-installer/amd64/boot-screens/f5.txt
./ubuntu-installer/amd64/boot-screens/f4.txt
./ubuntu-installer/amd64/boot-screens/menu.cfg
./ubuntu-installer/amd64/boot-screens/adtxt.cfg
./ubuntu-installer/amd64/boot-screens/f7.txt
./ubuntu-installer/amd64/boot-screens/stdmenu.cfg
./ubuntu-installer/amd64/boot-screens/libutil.c32
./ubuntu-installer/amd64/boot-screens/splash.png
./ubuntu-installer/amd64/boot-screens/exithelp.cfg
./ubuntu-installer/amd64/boot-screens/f9.txt
./ubuntu-installer/amd64/boot-screens/vesamenu.c32
./ubuntu-installer/amd64/boot-screens/f6.txt
./ubuntu-installer/amd64/pxelinux.cfg/
./ubuntu-installer/amd64/pxelinux.cfg/default
./ubuntu-installer/amd64/initrd.gz
./ubuntu-installer/amd64/pxelinux.0
./version.info
./pxelinux.0
We need to copy initrd.gz and linux files from netboot directory ~/netboot/ubuntu-
installer/amd64/ to /var/lib/tftpboot/networkboot/ubuntu18 directory. These files will be
referenced in the menu entry of PXE boot menu.
#mkdir /var/lib/tftpboot/networkboot/ubuntu18
#cp ~/netboot/ubuntu-installer/amd64/{linux,initrd.gz}
/var/lib/tftpboot/networkboot/ubuntu18/
Create Menu Entries for Ubuntu 18.10 installation:
Edit PXE boot menu for BIOS based clients.
#vi /var/lib/tftpboot/pxelinux.cfg/default
Add a menu entry for Ubuntu 18.10 installation therein.
default vesamenu.c32
prompt 0
timeout 30
menu title Ahmer's PXE Menu
label Install RHEL 7.5
kernel /networkboot/rhel7/vmlinuz
append initrd=/networkboot/rhel7/initrd.img inst.repo=ftp://192.168.116.41/pub/rhel7
ks=ftp://192.168.116.41/pub/rhel7/rhel7.cfg
label Install RHEL 6.0 (64-bit)
kernel /networkboot/rhel6/vmlinuz
append initrd=/networkboot/rhel6/initrd.img inst.repo=ftp://192.168.116.41/pub/rhel6
ks=ftp://192.168.116.41/pub/rhel6/rhel6.cfg
label Install Ubuntu 18.10 Server
menu label Install Ubuntu 18.10 Server
kernel networkboot/ubuntu18/linux
append vga=788 initrd=networkboot/ubuntu18/initrd.gz
ks=nfs:192.168.116.41:/nfsshare/ubuntu18/preseed/ubuntu.seed --- quiet
Edit PXE boot menu for UEFI based clients. For more information on UEFI, please refer to Add UEFI Support to PXE
Server in CentOS 7.
#vi /var/lib/tftpboot/grub.cfg
Add a menu entry for Ubuntu 18.10 installation in this file.
set timeout=60
menuentry 'Install RHEL 7.5' {
linuxefi /networkboot/rhel7/vmlinuz inst.repo=ftp://192.168.116.41/pub/rhel7/
inst.ks=ftp://192.168.116.41/pub/rhel7/rhel7.cfg
initrdefi /networkboot/rhel7/initrd.img
menuentry 'Install RHEL 6.0' {
linuxefi /networkboot/rhel6/vmlinuz inst.repo=ftp://192.168.116.41/pub/rhel6/
inst.ks=ftp://192.168.116.41/pub/rhel6/rhel6.cfg
initrdefi /networkboot/rhel6/initrd.img
menuentry "Install Ubuntu 18.10 Server" {
set gfxpayload=keep
linuxefi /networkboot/ubuntu18/linux
inst.repo=nfs:192.168.116.41:/nfsshare/ubuntu18
inst.ks=nfs:192.168.116.41:/nfsshare/ubuntu18/preseed/ubuntu.seed
initrdefi /networkboot/ubuntu18/initrd.gz
Now, connect a BIOS based PXE client to network and boot it. It will display the following PXE boot menu.
Similarly, connect a UEFI based PXE client to network and boot it. It will display the following PXE boot menu.
We have successfully configured our CentOS 7 PXE boot server to install Ubuntu 18.10. You can also add other versions
of Ubuntu in similar manner.