@nickrout - I am not familiar with what VM was install but on the icon it say " Oracle VM Virtualbox. i recalled my buddy said it linux based or something along that line.
Oh my… VirtualBox is okay(ish) for quick testing something… I wouldn’t rely on it to run a service 24/7!
I suppose this VM runs on a Windows machine maybe? What type of hardware is it? A desktop?
If you give us some more info, whatever level you can provide (or better: ask your friend) maybe we can help.
To me, vbox isn’t that bad. Ha restarts more because of updates and not because of instability.
If ha don’t respond at any time, go to you vm window and see if there is an error on the cli.
ha core logs
And see what error are showing.
Also, try to do a ha only restart.
Ha core restart.
If that’s sufficient, you don’t need to reboot whole.machine. if it’s not sufficient, then other parts of your setup might be/contain the root cause.
OP reports hangs, not restarts. Also, updated don’t happen automagically every few hours.
There is most likely something not working as expected, could be lack of resources, host OS going to sleep or the like.
I suggest you ask your friend for support.
the major problem here is in fact:
“my buddy did…” and: “I am not familiar with…”
Honestly speaking - this kind of setup (oracle virtual box) is more a setup I would use for testing purpose rather than running a productive environment on it… in the ‘worst case’ - with Node Red and so on running as an Addon within the virtualized HA installation.
Don’t get me wrong - having not a deep IT knowledge isn’t a big deal - you can run HomeAssistant without being an IT professional, but for using such kind of setups, having some knowledge about these systems would be required.
First:
-
why did your buddy choose to install HA within a VM?
- is there already a server running? Or is it running on an older Desktop Computer?
- why not using a small RaspberryPi instead and running HassOS directly on it?
-
what HA Installation was choosen in the VM?
- HA Core?
- HA Supervised?
- HA OS? (I beleive, it should be this)
-
on what OS is the Virtual Box running? Linux? Windows?
In your case, you have added some additional points of failure - and you should be able to check, if it is Virtua Box that is causing the issues, or if it is the Virtual Machine itself - meaning your HomeAssistant installation which is causing these issues.
Personally, I am also running HomeAssistant as a Virtualized system on my server - and I don’t have any issues like you described.
So I can’t agree that HA isn’t reliable on a VM at all… it might be, depending on the resources given to the machine, the Setup itself, the host, etc…
Small correction: I didn’t say HA isn’t reliable on a VM, I run it on a VM myself (on a Proxmox VE cluster). What I said is that VirtualBox is not an hypervisor that can run 24/7 services reliably, being more a desktop product.
Other than that, I agree 100% that the main issue is that OP is troubleshooting something he has not enough knowledge of. We need more information in order to help, but I have the hunch that his friend is better qualified to answer and give support.
Ha is on OS Win 10 with power setting to never Sleep.
it’s a toshiba nb555D laptop . AMD C Series Processor C30 – 1.2 GHz, 10.1” WSVGA LED,4 GB DDR3, 250GB HDD S-ATA, Integrated Graphics, LAN, Realtek 802.11 bgn, Integrated Web
Thank you for your suggestion. I will take a pic of HA banner when the issue arise.
My freind and I are puzzle why my HA is doing this. he has a similar setup and does not have this issue.
I would buy a 50$ raspberry pi and move your installation on it. It will be more reliable and will remove complexity to your setup.
Tbh, if you don’t know why ha stops responding, it’s not a good idea to just replace the hardware or anything else. If i see that sometimes there is no IP address, it could be very well a utp cable causing it or any other network component.
Reliability does not become an issue just based on vm situation ( mine on vbox is stable as a rock and moved from pi to VM , so let’s take that discussion in the other topics , there are plenty)
My bet is on not enough RAM, you have 4GB to shuffle between the host OS and the VM. If you’re also running stuff like NodeRed on it, it won’t be enough.
By all means do like others suggest and keep troubleshooting, but IMHO it’s a waste of time. This HW could be perfect to run HassOS or HA on a headless Linux OS, but the added overhead of Win10 is a complete waste of resources.
I used to use Vbox, but it is highly unstable on ny machine (i see a lot of cpu stall errors).
After moving to VMWare all my issues disappeared.
Although it’s a bit of a hassle to configure it
Thank you everyone for helping me answer my comment. I will keep track of when HA goes offline ( unable to log in) the report back for more suggestions.
I notice another issue arise, I did a search for Smartthing Intergration which I am having issue but don’t know how to resolve it
Definitely agree. The hardware does not have enough power to run windows and a vm.
I would ditch windows, ditch the VM, and install HassOS as the sole system running on the machine, and follow the generic x86-64 install instructions.
Yeah good luck with that…
A few years ago it made sense that the RPI was the “go to” way to setup Home Assistant, with its small size, low cost, and minimal energy use.
Now, as mentioned, good luck finding one, and if you do, you’ll pay (the rpi4 linked to Amazon in the install instructions as I post this costs $173).
To me, it makes no sense to buy an rpi when you have perfectly good hardware to run home assistant lying around collecting dust.
But don’t put a VM on if the hardware specs aren’t there, Just install hassos like you would on an RPI.
I know this is a 9 month old thread but for anyone else that is having reliability problems with virtual box running Home Assistant OS, I increased the RAM from 2048 MB to 4096 MB and all the freezing issues were gone.
Before that it was freezing every 4-6 hours. The only way it would work again was to reboot the virtual box machine.
This is a viable way only if you have more than those 4 gb ram on the host of course. Otherwise it might not change anything. Also this depends on if 4 GB are enough to run HA with all installed add-ons.