Take Control of your Smarthome with Home Assistant! Installation Tutorial on Proxmox

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
so if you're building your first Home Server the first app you should install is home assistant home assistant is a completely locally managed home automation platform it can really change your life when it comes to basically things like automating lighting all kinds of automation around the home lab and your house in general and it's very useful it's completely self-controlled so how much data you share with the internet in the cloud depends on what devices you choose to integrate and what approach you choose to take but it's all up to you and that's why I love home assistance so much it's an excellent platform to build on to build automations to integrate everything you have together in one place so today I'm going to walk through installing home assistant on my ultimate Home Server project this little Nas here so in the past video I set this little guy up as a proxmox server and that was the first episode of My ultimate Home Server series now we're going to add to the ultimate Home Server by adding home assistant to it this little box is absolutely plenty to run home assistant it does not need a lot of resources so if you have something relatively powerful like an old desktop or a Nas like this or didn't tell Nook or something it's a great idea to run home assistant in a virtual machine and I'm going to show you how today as a bonus I've got the zigbee dongle too and we're going to pass this through to the virtual machine using USB passthrough so our zigbee network still works even though we're virtualized and this same approach would work with any USB dog will be at zigbee or Z-Wave rtl433 any of that stuff so let's Jump On In shall we so the page you're interested here is home assistant dot IO slash installation slash Linux so if we go there they have the links to download the virtual machine image in three different formats vdi qcat 2 and vmdk we're going to need the qcat 2 but we'll get to that one a little bit later first we need to create the virtual machine they recommend two gigs of RAM 32 gigs of storage and two vcpus and this is the same setup that I use in my own home assistant install if you're running some really heavy add-ons like frigate NVR for example you might need some more RAM and CPU power and you might want to do storage a little bit differently too but if you're not doing that you should be fine with these recommendations and that's what I'm going to use for this video so hopping over onto proxmox here you can see I have my data center and I have my one host this is the Terra Master Nas that I set up in my previous video it's part of my ultimate Home Server project go ahead and check out that playlist or whatever so on my chairmaster Nas I'm going to create a VM up here create VM and so it defaulted in my case to 400 it'll pick a number probably close to 100 you can pick whatever number you want here it's only used internally within proxbox and we're going to give it a name so I'm going to call it home assistant home assistant next up it wants us to select an installer image but because we're importing a pre-made virtual machine we can just say do not use any media because we don't need a CD-ROM drive and the guest OS should be Linux now for this system so the graphics card we can leave as default that'll be standard VGA we don't really need graphics for our virtual machine for the machine type we're going to select Q35 and for firmware we're going to select ovmf UEFI so the machine can boot in UEFI mode now we need to add a UEFI disk this is what stores the EFI settings and EFI keys so we need to pick a storage location for this disk it's going to be pretty small so if you followed my last tutorial we have local ZFS which is SSD and we have d-pool which is our hard drive storage I put on the SSD Source just because it's small if you're installing proxbox on your own system local ZFS should exist if you installed via ZFS now very important here we're going to uncheck pre-enroll keys because otherwise it's going to enable secure boot with Microsoft keys and it's going to fail to boot home assistant which doesn't support secure boot so make sure that's unchecked for scuzzy controller we're going to use vert IO scuzzy single that's a good option for Linux VMS we can enable the qemu agent that'll help so that proxmox can identify how much memory and processor and network addresses and things like that are actually being used by the VM it's not strictly necessary but it's nice to have so next on to disks so I'm actually going to delete this disk that it created by default and we are going to create disks later when we import the VM image so for CPU we're going to select one socket with two cores and instead of the defaults here for type we're going to select host should be all the way at the bottom this will pass through all of the CPU flags that the host CPU supports so we can get things like AES acceleration in the virtual machine you can get a decent performance approvement by doing this if you're using a cluster you'll you'll have to figure that out on your own now for memory it defaults to two gigs which is perfect we'll just leave it at that and for Network we're going to say vertio pair virtualized and default to vmbr0 which means we're going to bridge with our host Network so it'll become part of our host Network which is usually the LAN no VLAN tag you can add a VLAN tag if you need to and we'll confirm and save that so now if I expand out on Terra here you can see it's setting up 400 as soon as it's done this should show up with a name there it goes home assistant so now the VM is created but it doesn't have a hard drive so we need to add that so let's go back over to the home assistant guide and copy the link under KVM that should be the qcau2 file now here I'm going to click on the proxmox Node and go to Shell then I'm going to use the command W get to download it so wget and then I paste in the address I got by copying the link from home assistance website now we wait for it to download so now that it's downloaded if we LS we can see the file there it's called Haws OVA in this case version 9.4 so now we need to decompress it so the command for that is XZ Dash D for decompress Dash B for verbose which gives us progress and then haos ova-9.4.qcal2 dot XD and we wait for the decompression so now the file is decompressed if we LS again we can see we have the Q cow 2 without the XC so now we can import that into proxbox and the command for this as of proxmox 7.3 is qm disk import so qm space disk space import and in previous versions of proxmox this was called qm import disk instead and so now we need to give it the ID of the VM we're going to import in this case it's 400 for me then we need a file name so haos OVA Dash 9.4 .q file Q and the last option we need is what storage we want to put it under so in my case I'm going to put it on the SSD on the Terra Master Nas and that is at storage local ZFS if you have your own storage set up you can look at the storage options here on the left so in this case I have d-pool iridium local and local ZFS local ZFS should be created automatically if you use ZFS during the installer uh d-pool in my example would be the hard drive and you could use that too if you wanted and if you're using a file based storage such as NFS or Samba then you also need to add a format option so format and you probably want cuecat 2. but in this case with ZFS we automatically use native ZFS block storage so we don't need the format so then we hit enter and it should copy it there we go successfully imported disk so the disk is now showing up as unused vm400 disk one so we can delete this file now so RM it's AOS star and I'll delete that file now the file we downloaded has been deleted because the disk has been imported into ZFS but we don't we didn't tell it yet how to attach it to the virtual machine so go back to our virtual machine and click on hardware and we have a new disk here unused disk 0. and we need to give it an attachment so by default it's using scuzzy and vertio scuzzy single and that's a great option in addition I'm going to click Advanced here and I'm going to say SSD emulation and discard and this means it's going to tell the virtual machine that the virtual machine is running on an SSD to enable trim or discard support So when the virtual machine deletes files it will tell the underlying storage that those blocks can be recovered or deleted that way the virtual machine won't always be using 32 gigs of storage it'll be using however much it's actually using on the host system and for ZFS we want to use no cache we'll click add now the last step is to add it to our boot order because we added the disk after we created the VM it doesn't know that it's bootable so we go to options here and there's boot order you can see that enabled is IDE which is the CD-ROM drive and net so we're going to enable scuzzy which is our new disk and move it up to the top that way it will by default boot from this disk which we want so now we should be good to start the VM so I'm going to click Start and then I'm going to click console so we can see what it does so now we see waiting for home assistant CLI to be running there we go it's starting up so now we should be able to go to homeassistant.local call it 8123 it's like many people have searched that before if your computer has mdns enabled this should work if it doesn't you can go back over to proxmox and read the IP address which will be on the console of the VM so here you can see here's all the IP addresses assigned to the VM you can type one of those and go to Port 8123 as well so from this point on I'm going to leave you with the home assistant onboarding guide they have a great tutorial here on how to set up home assistant for your first time home assistant dot IO getting started slash onboarding Link in the description for this and this will let you start setting up your user account and home assistant your location time zone unit preferences and setting up some of your first devices and where you go from here really depends on what you want to do in home assistant so another thing you might be interested in is USB passthrough as I showed in the intro I have a zigbee dongle I'm going to pass through to my home assistant instance to show you how easy it is so back here in proxbox I'm on the home assistant VM on the hardware tab I'm going to click add USB device I can either choose a port or a device ID in this case I probably know the device ID of the dongle so I'm going to click on it so in this case it's a TI cc2531 USB and that's my zigbee dongle so let's click on that say add we should be able to hot plug USB devices so home assistant should see that so in my case I had to reboot the virtual machine for to find the device I'm not entirely sure why it should be able to hot plug just fine so coming back over to home assistant going into settings if I turn my face off there's a button called add integration and from here we can search league b and use zigbee home automation there we found our radio TTY ACM zero blah blah blah blah let's do that so in this case this is an old dongle of mine that I've used before so it shows up as already having settings you could probably erase settings and start new if you're doing Z-Wave you would do something similar except you would install a Z-Wave JS add-on instead of using zigbee home automation there we go here's our zigbee coordinator pass through from proxbox so hopefully you're able to follow through and install home assistant on your proxmox server for me home assistant is really the ultimate first step in a home lab it's not destructive like messing with your network can be and it gives you a really big bang for the buck in reward versus effort home assistant has an excellent community that I hope you can enjoy and I hope you can set up some nice automations to improve your life if you want to see how I set proxmox up on this little tiny nass here for 300 bucks I got a video on that link I don't know up here down there or something like that if you want to chat with me on Discord about any of these topics I have a link down below and as always I'll see you on the next adventure
Info
Channel: apalrd's adventures
Views: 29,177
Rating: undefined out of 5
Keywords:
Id: beo7pnKLEC4
Channel Id: undefined
Length: 12min 58sec (778 seconds)
Published: Thu Jan 12 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.