Same machine-id for automated installation

willifehler

New Member
Jul 17, 2023
10
0
1
Hey there,

I'm using an automated installation fashion to completely deploy my bare metal servers with Proxmox. Lately I've started to switch to the Enterprise repositories.
I want to automate the Enterprise registration now too. If I redeploy my nodes they will get a new machine-id. Is there any way to make sure my node always will have the same machine-id?

Cheers - Willi
 
Last edited:
Hi,

Is there any way to make sure my node always will have the same machine-id?
no, the installer will always generate a new one - as is also specified/expected by systemd that this value should be unique per-installation.

But you could use e.g. systemd.machine_id= on the kernel commandline (see man machine-id(5)) or use the first-boot hook to set the machine-id to some predictable value.
Of course, that value still must be unique per host, which you will need to ensure!

If I redeploy my nodes they will get a new machine-id.
Asking the other way, from what it sounds - why are you redeploying nodes on a regular basis in the first place?
 
  • Like
Reactions: waltar
I'm redeploying my test machines on a regular basis to make sure my automation is really working. Thank you very much for the details. I guess for my test machines it makes sense to use the same machine-ids.