Troubleshooting Registering Cloned Clients
If you are using Uyuni to manage virtual machines, you might find it useful to create clones of your VMs. A clone is a VM that uses a primary disk that is an exact copy of an existing disk.
While cloning VMs can save you a lot of time, the duplicated identifying information on the disk can sometimes cause problems.
If you have a client that is already registered, you create a clone of that client, and then try and register the clone, you probably want Uyuni to register them as two separate clients. However, if the machine ID in both the original client and the clone is the same, Uyuni registers both clients as one system, and the existing client data is overwritten with that of the clone.
This can be resolved by changing the machine ID of the clone, so that Uyuni recognizes them as two different clients.
Each step of this procedure is performed on the cloned client. This procedure does not manipulate the original client, which remains registered to Uyuni. |
-
On the cloned machine, change the hostname and IP addresses. Make sure
/etc/hosts
contains the changes you made and the correct host entries. -
For distributions that support systemd: If your machines have the same machine ID, as root, delete the files on each duplicated client and re-create it:
rm /etc/machine-id rm /var/lib/dbus/machine-id rm /var/lib/zypp/AnonymousUniqueId dbus-uuidgen --ensure systemd-machine-id-setup
-
For distributions that do not support systemd: As root, generate a machine ID from dbus:
rm /var/lib/dbus/machine-id rm /var/lib/zypp/AnonymousUniqueId dbus-uuidgen --ensure
-
If your clients still have the same Salt client ID, delete the
minion_id
file on each client (FQDN is used when it is regenerated on client restart). For Salt Minion clients:rm /etc/salt/minion_id rm -rf /etc/salt/pki
For Salt Bundle clients:
rm /etc/venv-salt-minion/minion_id rm -rf /etc/venv-salt-minion/pki
-
Delete accepted keys from the onboarding page and the system profile from Uyuni, and restart the client with. For Salt Minion clients:
service salt-minion restart
For Salt Bundle clients:
service venv-salt-minion restart
-
Re-register the clients. Each client now has a different
/etc/machine-id
and should be correctly displayed on theSystem Overview
page.