Want to install hassos qcow2 appliance on KVM iSCSI target LUN

Using Centos 8.2 KVM with iSCSI storage

  • I followed the Installing Home Assistant OS guide and was able to install the hassos_ova-4.16.qcow2 appliance on the Centos 8.2 host file system. So, Home Assistant OS was running fine on local storage, but I want to deploy it to iSCSI storage.
  • Then, I made an iSCSI target and a 40GB LUN, and made a Linux formatted file system by using fdisk and mkfs. It looks like an xfs file system.
  • I mounted the LUN to a directory I made called /lunmount.
  • I made another copy of hassos_ova-4.16.qcow2, expanded it to 39GB by using ‘qemu-img resize hassos_ova-4.16.qcow2 +33G’ and copied it to /lunmount.
  • KVM virt-manager was able to use that mount, see the qcow2 file, and install the appliance using the same instructions for installing Home Assistant OS using KVM.

To me, this is a kludgy way to install and run hassos on iSCSI storage, but it’s all I could come up with!

Is there a way to enable virt-manager to build the appliance using an ISO installation file, and then install it onto an iSCSI target LUN? Is there another solution that can enable KVM virt-manager to see the hassos qcows2 file on an iSCSI target LUN and install it?

Thanks in advance for any help!

1 Like

Another thought on the subject:

The kludgy method that I used seems to be working just fine. I added UUID of the iSCSI LUN into /etc/fstab and /lunmount is mounted automatically when the Centos 8.2 host starts. Here is the line I put in fstab:

UUID=7042e726-ac1d-4455-b478-4f8075591779 /lunmount xfs defaults,_netdev0 0

I picked up this method from reading a half-dozen well-written tutorials that are centered on Centos 8, QEMU/KVM, and iSCSI. My hypervisor host is a refurbished HP Elite 8300 SFF PC with an i7-3770 and an extra 2-port gigabit NIC from Amazon. The iSCSI host is a QNAP TS-453Be. I have 4 VMs running right now and the response is fast, unless I am copying an 8GB file from one to another!

Anyway, I am happy with the Centos 8/KVM platform, now I just need to learn how to set up some network-connected relays that open and close on a schedule in Home Assistant. Oh, and I need to learn Python 3.