I would like to install ubuntu 22.04 automatically with the PXE. When using the "cloud-init" script the installation freezes on "connecting ..." with a looping animation "/-|/" (screen attached)
I don't know what is blocking and I can't find any error message in the logs
Can you help me and do you know what this "connecting" step does?
pxelinux.cfg/default
menu title Ubuntu installer
label jammy
menu label Install Ubuntu Jammy (22.04)
menu default
kernel casper/vmlinuz
initrd casper/initrd
append root=/dev/ram0 ramdisk_size=1500000 ip=dhcp cloud-config-url=/dev/null url=http://192.168.42.151/jammy-live-server-amd64.iso autoinstall ds=nocloud-net;s=http://192.168.42.151/jammy/ # Don't forget the slash at the end.
prompt 0
timeout 0
default jammy
user-data
#cloud-config
autoinstall:
identity:
hostname: jammy-minimal
password: $6$gnqbMUzHhQzpDEw.$.cCNVVDsDfj5Feebh.5O4VbOmib7tyjmeI2ZsFP7VK2kWwgJFbfjvXo3chpeAqCgXWVIW9oNQ/Ag85PR0IsKD/
username: ubuntu
version: 1
in the apache server logs I can see the client taking the iso, meta-data and user-data files
/var/log/apache2/access.log
192.168.42.152 - - [30/Jul/2022:09:28:21 +0000] "GET /jammy-live-server-amd64.iso HTTP/1.1" 200 1466714112 "-" "Wget"
192.168.42.152 - - [30/Jul/2022:09:28:30 +0000] "GET /jammy/meta-data HTTP/1.1" 200 - "-" "Cloud-Init/22.1-14-g2e17a0d6-0ubuntu1~22.04.5"
192.168.42.152 - - [30/Jul/2022:09:28:30 +0000] "GET /jammy/user-data HTTP/1.1" 200 674 "-" "Cloud-Init/22.1-14-g2e17a0d6-0ubuntu1~22.04.5"
On client /var/lib/cloud/data/result.json
{
"v1": {
"datasource": "DataSourceNoCloudNet [seed=cmdline,/var/lib/cloud/seed/nocloud,http://192.168.42.151/jammy/][dsmode=net]",
"errors": []
}
}
Screenshot
Thanks for your help
s=http://192.168.42.151/jammy/
https://cloudinit.readthedocs.io/en/latest/topics/datasources/nocloud.html – iyrin Jul 30 '22 at 11:09I use the standard http port. but I tried to be sure.
It's the same result.
I can see downloads of user-data and meta-data files in web server logs (/var/log/apache2/access.log)
Extract of pxelinux.cfg/default
– Morphatrix Jul 31 '22 at 12:38