Using virt-install
to install SUSE Elemental on KVM.
When creating your Machine Registration Endpoint in the Rancher UI, ensure that registration.emulated-tpm-seed
is set to -1
, if you plan to add more than a single machine using the ISO you will be building.
For example:
config:
cloud-config:
users:
- name: root
passwd: root
elemental:
install:
device: /dev/vda
poweroff: true
registration:
auth: tpm
emulate-tpm: true
emulated-tpm-seed: -1
reset:
reboot: true
reset-oem: true
reset-persistent: true
machineInventoryLabels:
environment: suse-qemu-local-dev
machineUUID: '"${System Information/UUID}"'
manufacturer: '"${System Information/Manufacturer}"'
productName: '"${System Information/Product Name}"'
serialNumber: '"${System Information/Serial Number}"'
Once your ISO is downloaded this script assumes a default image path of /var/lib/libvirt/images
and that your ISO will be under that path. It assumes an external bridge, br0
, please update to reflect your host configuration (i.e. default virbr0
).
The script takes positional arguments for the path to the ISO, the memory allocation in MB, and vcpus:
./boot.sh elemental-general-2023-11-18T04_34_47Z.iso 8196 4
Connect to the console to view the setup:
/var/lib/libvirt/images# virsh list
Id Name State
------------------------------------
6 rancher running
...
23 elemental-32b69400 running
24 elemental-4cbfd4e4 running
25 elemental-f621b6b6 running
virsh console 23
Upon completion, the machines will reboot to the virtual disk.
Check your Rancher UI for the Machine Inventory which will update with your new machines during the initial installation, and will show active once the reboot to the virtual disk is completed, and you can proceed to create your Elemental cluster.