Spinning up the Trilio VM
Learn about spinning up the Trilio VM
For Canonical Openstack it is not necessary to spin up the Trilio VM. However, Trilio File Search functionality requires that the Trilio Workload manager (trilio-wlm) be deployed as a virtual machine. File Search will not function if the Trilio Workload manager (trilio-wlm) is running as a lxd container(s).
The Trilio Appliance is delivered as qcow2 image and runs as VM on top of a KVM Hypervisor.
Creating the cloud-init image
The Trilio appliance is utilizing cloud-init to provide the initial network and user configuration.
Cloud-init is reading it's information either from a metadata server or from a provided cd image. Trilio is utilizing the cd image.
Needed tools
To create the cloud-init image it is required to have genisoimage available.
#For RHEL and centos
yum install genisoimage
#For Ubuntu
apt-get install genisoimage
Providing the Metadata
Cloud-init is using two files for it's metadata.
The first file is called meta-data
and contains the information about the network configuration.
Below is an example of this file.
Keep the hostname localhost. The hostname gets changed through the configuration step. Changing the hostname will lead to the tvault-config service not properly starting, blocking further configuration.
[root@kvm]# cat meta-data
instance-id: triliovault
network-interfaces: |
auto eth0
iface eth0 inet static
address 158.69.170.20
netmask 255.255.255.0
gateway 158.69.170.30
dns-nameservers 11.11.0.51
local-hostname: localhost
The instance-id has to match the VM name in virsh
The second file is called user-data
and contains little scripts and information to set up for example the user passwords.
Below is an example of this file.
[root@kvm]# cat user-data
#cloud-config
chpasswd:
list: |
root:password1
stack:password2
expire: False
creating the image file
The image is getting created using genisoimage follwing this general command:
genisoimage -output <name>.iso -volid cidata -joliet -rock </path/user-data> </path/meta-data>
An example of this command is shown below.
genisoimage -output tvault-firstboot-config.iso -volid cidata -joliet -rock user-data meta-data
Spining up the Trilio appliance
After the cloud-init image has been created the TriloVault appliance can be spun up on the desired KVM server.
Extract the Trilio QCOW2 tar file using the following command :
tar Jxvf TrilioVault_file.tar.xz
See below an example command, how to spin up the Trilio appliance using virsh and the created iso image.
virt-install -n triliovault-vm --memory 24576 --vcpus 8 \
--os-type linux \
--disk tvault-appliance-os-3.0.154.qcow2,device=disk,bus=virtio,size=40 \
--network bridge=virbr0,model=virtio \
--network bridge=virbr1,model=virtio \
--graphics none \
--import \
--disk path=tvault-firstboot-config.iso,device=cdrom
Uninstalling cloud-init after first boot
Once the Trilio appliance is up and running with it's initial configuration is it recommended to uninstall cloud-init.
To uninstall cloud-init, follow the example below.
sudo yum remove cloud-init
[RHOSP, TripleO and Kolla only] Verify nova UID/GID for nova user on the Appliance
Red Hat OpenStack, TripleO, and Kolla Ansible Openstack are using the nova UID/GID of 42436 inside their containers instead of 162:162 which is the standard in other Openstack environments.
Please verify that the nova UID/GID on the Trilio Appliance is still 42436,
[root@TVM1 ~]# id nova
uid=42436(nova) gid=42436(nova) groups=42436(nova),990(libvirt),36(kvm)
In case of the UID/GID being changed back to 162:162 follow these steps to set it back to 42436:42436.
Download the shell script that will change the user id
Assign executable permissions
Execute the script
Verify that the
nova
user and group id have changed to '42436'
## Download the shell script
$ curl -O https://raw.githubusercontent.com/trilioData/triliovault-cfg-scripts/master/common/nova_userid.sh
## Assign executable permissions
$ chmod +x nova_userid.sh
## Execute the shell script to change 'nova' user and group id to '42436'
$ ./nova_userid.sh
## Ignore any errors and verify that 'nova' user and group id has changed to '42436'
$ id nova
uid=42436(nova) gid=42436(nova) groups=42436(nova),990(libvirt),36(kvm)
Updating the appliance to the latest minor version
It is recommended to directly update the Trilio appliance to the latest version.
To do so follow the minor update guide provided here:
Last updated
Was this helpful?