diff --git a/pages/linux/systemd-machine-id-setup.md b/pages/linux/systemd-machine-id-setup.md new file mode 100644 index 000000000..49e873f47 --- /dev/null +++ b/pages/linux/systemd-machine-id-setup.md @@ -0,0 +1,21 @@ +# systemd-machine-id-setup + +> Initialize the machine ID stored in `/etc/machine-id` at install time with a provisioned or randomly generated ID. +> Note: Always use `sudo` to execute these commands as they require elevated privileges. +> More information: . + +- Print the generated or committed machine ID: + +`systemd-machine-id-setup --print` + +- Specify an image policy: + +`systemd-machine-id-setup --image-policy={{your_policy}}` + +- Display the output as JSON: + +`sudo systemd-machine-id-setup --json=pretty` + +- Operate on a disk image instead of a directory tree: + +`systemd-machine-id-setup --image={{/path/to/image}}`