-
-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Docker Service sensor and VM Service sensor don't detect running services #36
Comments
Due to the scope of this update, you may need to reinstall the integration and clear your browser cache for everything to work smoothly. There is a high chance that your existing entities will not be migrated across and any automations will be affected. If you enable debug logging in the integration, reload the integration and then check the logs you should see if anything failed or loaded successfully |
I'm having the same issue with The VM and Docker services not being recognised as running. Integration completely removed, deleted and re installed from HACS cache cleared in multiple browsers. Debug log doesn't seem to help as far as I can see, just has: 2024-12-30 19:33:28.773 DEBUG (MainThread) [custom_components.unraid.api.vm_operations] Checking VM service status and similar for the docker. If I roll back to the previous integration version they are all detected and controllable it's only 2024.12.28 that is not detecting the VM or docker service. I run HASS on a VM on my unraid server. |
That's weird! Im running it from my HA dev container on laptop and production HA container on Unraid. No issues. |
This comment has been minimized.
This comment has been minimized.
Hi, I have the same issue and disk: |
This comment was marked as off-topic.
This comment was marked as off-topic.
@ond000 @mcolli31 I'm stumped about this issue I fired up my raspberry pi running latest HA version, installed the latest unraid release and works without issues. Docker and VM Services are running fine When I delete the VM and reload the integration it shows the entity is not available and can be removed which is fine and working as expected. VM Service then shows Not Running which is normal as no VMs are available or deployed. |
Can you enable debug logging in the integration, reload it and send the debug log please? |
Hi, |
Can you please run this diagnostic command from unraid terminal console?
And also these commands
Please provide the outputs |
Yes, this is the outputs commands. |
@domalab I'm not a programmer, I blunder my through most things, so I wish I could help more. I wonder if there is some issue with integration when HA is run as a VM on the unraid server? I note that both OP and I have it set up this way while you have it on a separate device. Happy to help hunt down the issue but not sure how much help I can be. |
It's probably not because you have it on the same device, I have HA installed on an Rpi4 and I'm monitoring two Unraid servers. |
Shouldn't matter if you are running HA in docker, VM or bare metal. I'm running my HA instance on UNRAID in docker container. The integration connects to UNRAID via SSH and executes the commands on UNRAID, gets the return status and updates the integration sensors, switches, etc. The updated code basically does a validation if you use VM service or not.
Previous code didn't have this and issues were logged by users that dont use VM and service was stopped then it logged errors in HA |
For my own sanity I tested this today from a HA VM running on UNRAID using latest source code VM is using Network Source br0 to get its own IP from the network. I can see container switches And the Home Assistant VM container switch Diagnostics is also showing Containers and VM service running |
It's strange. I used latest code, VM service is enabled. VM use network br0 to and is enabled. But I don't see VM switch and VM service sensor is in off state. Same situation for docker. For sure, I just tried to run command "/etc/rc.d/rc.libvirt status" and I don't got any response. Same situation is at both servers. |
This comment has been minimized.
This comment has been minimized.
Ok so I just noticed you are running unraid versions 6.12.13 and 6.12.14 I'm running version 7.0.0.rc2 So I'm wondering if there's a bug with 6.12.13 and 6.12.14 that it doesn't show the status of /etc/rc.d/rc.libvirt status command like it does with 7.0.0.rc2 If it's the case then I will need to enhance the validation check in the code Can you run these commands to see what it returns please Basic Service Status:
Socket and Port Validation:
VM Functionality:
Process Details:
Log Inspection:
If all these commands: Show libvirtd process running Then the service should be properly detected Updated validation check code will look something like this
|
Docker and VM Diagnostic script you can run from User Scripts plugin I just shows report if VM and Docker services are running and will help me to enhance the above validation check code.
|
Output from diagnostic script:
|
Yeah, that can be root cause.
First didn't return anything. Second:
Third:
First: Second: Third:
First:
Second:
Third:
First:
Second:
Both are empty |
I have the same issue after uninstalling and then installing the new version of unraid integration, I lost all the Docker entities. |
@ond000 @Guruleenyc I added extra validation checks to the code to check if VM and Docker services are running or not to see if I can get around the 6.12.x bug with not showing /etc/rc.d/rc.libvirt status. Here's the specific flow:
So even if the rc.d script check fails on 6.12.x:
This makes the integration much more robust across different Unraid versions, as it doesn't rely solely on the rc.d script output which can vary between versions. When you get time please download latest source code by manually copying updated unraid folder to home assistant custom_components and restarting HA. |
@domalab it helps, now I can see both services in state running and I have again switches for each docker container and VM, thanks for that. |
I'm having same issue. Does this feature also work on 6.11.x systems? |
@domalab I can also confirm that it is working again, thanks! Unraid 6.12.14 |
No idea! You need to try out the updated code. |
Is the updated code the 2024.12.28 version? |
You need to download the source code and not the release version. You need the source code from the unraid folder and overwrite it in HA custom_components\unraid. After doing that restart HA |
Thanks, thought it was probably that. It worked. |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Works for me as well. Although it doesn't recognise my windows 11 VM, this was an issue previously so that's a separate problem. |
Please log the VM issue as a bug. 👍🏻 |
Hello @domalab ,
Thank you for your help. |
@Iceman248 I have available actions, but I'm not sure which entity I can use in action as target for test... |
The issue is resolve for me, I think after upgrade HA Unraid to 2025.01.08. |
Describe the bug
Docker Service sensor is off even if I have running Docker containers and VM Service sensor is off too, even if I have running VM service. This behavior start from update of integration to version 2024.12.28.
From that time I can see in HA Core logs error "Command failed: open failed" from Unraid integration, but without more details in log, so I don't know if there is any connection between that.
Expected behavior
Sensors should be in on state
Screenshots
Unraid (please complete the following information):
Home Assistant (please complete the following information):
Home Assistant installation type (please complete the following information):
Priority of Request
Additional context
The text was updated successfully, but these errors were encountered: