Skip to content

Comment on Rocky Linux releases its first release candidateparent

Comments

PXE for Ubuntu is a nightmare compared to centos, but it is doable. It took me about four months (on and off with other responsibilities) to figure it out... It's been a while but iirc the biggest trick is to use the "legacy" installer iso.

Yeah, I have a PXE install system for Ubuntu too, built on the text mode installer. They are really pushing people to use MAAS, for a while the legacy installer for 20.04 wasn't released, and I thought I'd have to change, but it's out now. We'll see if they still have it for 22.04. :fingers crossed:

I really wantedan excuse to PXE alpine Linux, but I couldn't figure out how to bootstrap a post-pxe script. Which I'm sure is super easy and I just missed a really obvious strategy about Linux sysadminning, the docs anyway do not provide easy to understand guidance on that, unfortunately, and I have no idea where to go to get community support for quick one-off questions.

I expect PXE booting hasn't changed much in 15 years, so you can go find The Linux Documentation Project's HOWTOs on PXE and network booting and it should be about the same now. After that you just need to learn how to extract and create an initrd, and how the init system works to trace the execution of your network boot system.

This is also where shell script-based init systems rock. It's pretty easy to figure out how things get executed in an unusual environment like a network-installer because you can just open up the files used by your installer and follow them. To figure out how systemd might work in a PXE environment you'll need to find the version of systemd and then go download the source code and start reading... Might want to keep a notebook as you go.

Hell, I wrote my own PXE server (from scratch, starting with UDP primitives for DHCP and TFTP) that could PXE boot and track/log the status of several concurrently PXE booting servers in a rack. That sounds crazy, but its' surprisingly easy in Elixir. It was arguably easier (and more reproducible) to do this than to figure out how to configure, say, isc-dhcpd to give out specific ip addresses based on a mac-ip lookup table you put on s3, log the progress of each client, and then ninja out isc-dhcpcd to not exist anymore once you've provisioned the rack (and then figure out what to do if you had an error)... you can imagine the nightmarish statefulness problems with system config files all over the place.

learn how to extract and create an initrd

that was the hard part. CentOS and Ubuntu (poorly documented) give you a specific bootstrapping pathway that would kick in the initial installer, and at the other end you would have the system as you wanted it. The PXE instructions for alpine drops you into a shell. I couldn't figure out how to create and launch a "script" that would kick off the software installation beyond the basics. Like I said, it's probably easy, just not my wheelhouse.

Ah, nice. The installer mess was one of the reasons I steered clear of 20.04. (Along with the netplan vs cloudinit dumpster fire, and Canonical's rabid pro-snap stance).

Might be worth taking another look if the old installer is back again.

Right, I forgot that I had tried nfsroot with Ubuntu which surprisingly much easier to get started. I like the idea in a sibling thread of your own pxe server: I switched from dhcpd to dnsmasq a while ago just because it was a lot simpler to get working.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.