Deploying a KVM host¶
The portal installs a KVM host from scratch: its iLO and BIOS set as its server profile says, its local storage made again, Ubuntu installed from the site's portal node, then OpenNebula, the host's networks and datastores. The new host is made the same as the hosts already in service. Deploy does it for a planned host, Reinstall for a host already in use. Both erase the host's data: the boot device is partitioned again from the profile's boot storage, every existing volume on the other controllers is deleted with its data, and only the new datastore volume is wiped afterwards.
Before you start¶
The run checks all of this before it changes anything, and stops with the reason when something is missing:
- The platform is on its baseline. Settings → Platforms → Baseline holds the base OS (an Ubuntu LTS release), OpenNebula and FRR releases every platform runs. While a platform is out of baseline, or not yet checked against the current values, no host is deployed; the refusal names the platforms.
- The internal domain is set. Settings → Customer → Customers → Internal domain: the DNS domain of the
provider's own hosts (for example example.com). The host is named
<host>.<internal domain>and gets the domain as its DNS search domain. - The host's server profile is verified (Infrastructure → Hardware profiles → Servers) and its boot storage fits the profile's boot device (Hardware profiles → Boot storage; the installation brings one, standard). The profile also gives the BIOS and iLO firmware versions a host must have, the BIOS settings it gets and the iLO services left on.
- The installer is on the site's portal node. Settings → Platforms → Installation media shows it; the portal keeps the newest point release of the base OS ready and serves it only to the iLO networks of the site's hosts. A host whose iLO address is not an IPv4 address cannot be served.
- The host is in no other cluster in OpenNebula and has no VMs there. An existing registration is disabled at once, and checked again right before the power-off.
- For the FRR step: the site's host-frr template (Infrastructure → Templates) and every value it uses, the hosts' BGP password in Secrets included. The template may hold plain substitutions ({{ name }}, {{ ix.asn }}, …) and for / if blocks only - no filters and no other tags. A template that does not keep to this stops the FRR step with the line numbers and the reason (never the template's text); correct it in Infrastructure → Templates. A credential the template uses with no value in Secrets stops the step, naming it.
Starting the run¶
- Open the site in Infrastructure, tab Hosts, and select the host.
- Press Deploy (a planned host) or Reinstall (a host in use).
- In the dialog choose the cluster the host joins, tick Reset to factory if the BIOS should get a real factory reset first (the iLO keeps its address and accounts), confirm that a powered-on host may be powered off, and type the host's name in full.
Only one run per host runs at a time.
What the run does¶
- iLO settings: the iLO is named "m" plus the host's name without its leading "h"; it gets the site's NTP servers (an iLO holds two: the first two of the site's list), its DNS servers, its time zone and, when one is set, the remote syslog server as one syslog subscription (UDP, the site's syslog server) with the old single-destination setting off. LLDP is turned on and read back. If the iLO refuses the remote syslog setting, the run notes a warning in its log and goes on; any other iLO setting that is not applied stops the run.
- BIOS settings: after the reset to factory settings, only the server profile's BIOS settings are set, network boot (PXE) is turned off on every NIC the BIOS has, and the site's time zone is set. Every other BIOS setting stays as the factory reset and the workload profile make it. After the installation the readback checks exactly the settings the deployment set.
- Local storage: on every controller but the boot controller, the volumes are deleted and one volume is made over all its drives (RAID5 for three drives or more, RAID1 for two); on the host it becomes the volume group vg_one, mounted on OpenNebula's datastores folder. Deleting the old volumes loses everything on them; afterwards only the new volume, found by its own identifier, is wiped. Nothing is deleted when the boot controller is not certain. iLO 6 and 7 see the storage only after the server has started, so the step starts the host once into the BIOS setup (no operating system starts), does its work and powers the host off again before the installer starts.
- Ubuntu installed: the base OS is installed from the site's portal node, with the boot storage of the profile. The step waits until the host answers over SSH with the operating system this run installed and cloud-init has finished its first start. The answers file's cloud-init part is as small as it can be: the host's name, root and password login off, and the SA user with its key - no other user and no packages. The installer itself only adds the SSH server.
- OS baseline: oneadmin is made after the installation, by this step: the oneadmin group and user are created with their ids and home given in the command (group 9869, user 9869, home /var/lib/one) and checked. This step does not create the /var/lib/one directory - the OpenNebula packages do, after it. oneadmin's sessions use umask 0027 (checked over ssh as oneadmin), so what OpenNebula's drivers create gets no group write and no access for others: a file created 0666 is 640, a directory created 0777 is 750. No kernel dump (kdump-tools, kexec-tools and the crashkernel option removed); time comes from systemd-timesyncd with the site's NTP servers (chrony removed); snapd is removed and fwupd masked.
- Packages: lldpd, ufw and AppArmor are installed; oneadmin is in the disk, kvm and libvirt groups. The Packages step installs nothing unless oneadmin is 9869:9869 with home /var/lib/one, so no OpenNebula package is ever installed before it.
- OpenNebula, networks and datastores: OpenNebula is installed from the repository in Settings → Platforms. The host gets its networks, the live migration network (core-lm) among them, and its datastores. /var/lib/one/datastores and every datastore in it are 750 oneadmin:oneadmin.
- FRR: the host's FRR configuration is the site's host-frr template filled in with the host's name, its address on the EVPN network, that network's route reflectors, AS number and the hosts' BGP password. Nothing is written when a value is missing; the step waits until every route reflector has accepted the session.
- Firewall, AppArmor, LLDP (before the reboot): AppArmor and lldpd are turned on. ufw (IPv4) drops incoming and routed traffic except from the site's management hosts, the core, live-migration and EVPN networks, and ssh and the node exporters from the front end. VM traffic on the host's bridges passes ufw (OpenNebula's security groups filter it) and the host's outgoing connections are open, so when the platform reaches OneGate through hosts (OneGate through hosts ticked) VMs still reach it through their host: OpenNebula's transparent proxy answers on each bridge in its own network namespace and connects out to the front end. While ufw is turned on, a way back turns it off again after a few minutes unless the portal can still open a new ssh connection to the host, so a wrong rule cannot lock the host out.
- Once OpenNebula monitors the host: RESERVED_CPU is set from the cluster's vCPU:pCPU ratio and read back. The host's IPMI health is read at the end of the run.
The host joins the chosen cluster disabled. Check it, then enable it yourself.
When a step fails¶
The run's steps and its log are shown on the host; the last run folds under its heading, open while it runs or after it failed. A step that fails stops the run with its reason:
- Resume from the failed step continues it, also after a restart of the portal interrupted it. A run resumed after an upgrade of the portal redoes the OS baseline, the packages, oneadmin's keys and the reboot when an older version did them, and sets LLDP on the iLO if it was not set yet;
- Abandon leaves the host as it is and deletes its answers ISO.
All the details: Portal reference, Deploying and retiring hosts.