I have a Debian Jessie installation that I boot with PXE and I need to set the hostname at boot using a script.
I used /etc/init.d/hostname.sh with the previous Debian version, but it doesn't seems to be executed at boot. Maybe because of systemd.
I have a Debian Jessie installation that I boot with PXE and I need to set the hostname at boot using a script.
I used /etc/init.d/hostname.sh with the previous Debian version, but it doesn't seems to be executed at boot. Maybe because of systemd.
Check you gave execution right to your script
Why don't you use the DHCP option 12 instead?
https://www.rfc-editor.org/rfc/rfc1533
Edit_1
you can also add the deb-conf variable "hostname" as a kernel parameter in the "append" line i.e.