1

I am trying to create Terraform/Ansible/Cloud-init Hybrid for creating Openshift and OKD clusters on Proxmox. Since CoreOS doesn't support cloudinit, but rather ignition there are only a couple of options available. Netboot being the "simpler" one. So I have followed a bunch of different approaches regarding this topic and I think that the general idea is to have DHCP Server + TFTP Server for booting + http server for ignition. Mostly I am trying to do a version of this guys setup. I've setup all of that and still cannot boot neither RHCOS nor FCOS using pxe.

I have trying using different Linux Distros (CentOS 8/9, Alma 8/9, RHEL 8/9, Debian12, Ubuntu 22/24) as TFTP but they all provide the same result:

Failed to load ldlinux.c32

Here are my configs:

DHCP (!important: we don't use dhcp in the company, this server is specifically created for this purpose - that's why the range is very small.)

subnet 10.11.0.0 netmask 255.255.0.0 { range 10.11.223.2 10.11.223.40; option routers 10.11.111.100; option domain-name-servers 10.11.2.71; option broadcast-address 10.11.255.255; allow booting; allow bootp; allow-unknown-clients; default-lease-time 600; max-lease-time 7200; next-server 10.11.223.1; # TFTP server IP filename "pxelinux.0"; # PXE boot file }

Bootconfig (for bootstrap node):

default menu.c32
prompt 1 timeout 9 ONTIMEOUT 1
menu title OKD installation label 1
menu label ^1) Bootstrap node menu default kernel fcos/kernel append initrd=fcos/initramfs.img nomodeset rd.neednet=1 console=tty0 console=ttyS0 ip=dhcp coreos.inst=yes coreos.inst.install_dev=/dev/sda coreos.live.rootfs_url=http://{{ service.ip }}:8080/okd4/rootfs.img coreos.inst.ignition_url=http://{{ service.ip }}:8080/okd4/bootstrap.ign

TFTP folder structure which includes the images for CoreOS, pxelinux.0, ldlinux.c32 and my bootconfigs under pxelinux.cfg

Basically, at this point I am begging for inputs on how to proceed. Tried every kind of variation with this configs, different versions etc. Very grateful for any advice.

Also, happy to hear arguments why going with the other way coreos-install with modifying the images is a better option (or maybe even simpler). Also would be happy if anyone has completely different solutions for running OpenShift on Proxmox.

koubler
  • 11

1 Answers1

0

Since nobody came to rescue in the meantime, I've given up on standard pxeboot and went with iPXE. It's basically the same approach, just different file names for primary boot and the syntax of the specific bootconfigs is somewhat different.

For those in the future that are going to struggle like I did I am posting my results. !!Bare in mind, my use case is only running openshift/okd (4.16, 4.17,4.18) on proxmox hypervisor (8.0.2) using Terraform and ansible - didn't test this with any other setups.

  • Step 0 & 1: install ipxe, dhcp, tftp-server and http-server (on Debian I used isc-dhcp-server, tftpd-hpa & apache2)
  • copy the initial boot binary (undionly.kpxe) to your tftp server dir if you want to boot from Proxmox gui using the console, or create your bootconfig <script_name>.ipxe in the same tftp directory containing the bootconfig if automation is needed. The syntax is pretty basic, also well documented. In this step I've switched to switched to serving .ipxe scripts using http server, because of the need to have different bootconfigs for different hosts (bootstrap, control-plane, workers)
  • configure your DHCP-server to provide IPs for these VMs - I've used very specific range and MAC Addresses as identifiers since we don't have DHCP in the company and I didn't want my IPs quickly taken over by some random VMs.
koubler
  • 11