Skip to content

Hub becomes unavailable #163

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

Open
pipolaq opened this issue Mar 13, 2025 · 21 comments
Open

Hub becomes unavailable #163

pipolaq opened this issue Mar 13, 2025 · 21 comments
Assignees

Comments

@pipolaq
Copy link

pipolaq commented Mar 13, 2025

Description

Hi,

I’m having an issue with my AX Pro hub, which regularly becomes 'unavailable'. As a result, my automations are failing!
Do you know what could be causing this?
Thank you in advance!

Version 3.0.0

Reproduction steps

Nothing specific

Image

Image

Integration Version

v3 (beta)

HA Version

latest stable (v2025)

Relevant log output

Screenshots

@pipolaq pipolaq added the bug Something isn't working label Mar 13, 2025
@petrleocompel
Copy link
Owner

Would be great to get some logs. Also is your device on ethernet or wifi?

@pipolaq pipolaq changed the title 🐛 [BUG] - <title> Hub becomes unavailable Mar 13, 2025
@pipolaq
Copy link
Author

pipolaq commented Mar 13, 2025

Thank you for your quick response. My hub is connected via Wi-Fi and is located right next to the router. No internet drops or anything like that.

However, the log (attached) seems to show some timeouts?

2025-03-13 15:06:22.391 ERROR (MainThread) [custom_components.hikvision_axpro] Timeout fetching hikvision_axpro data
2025-03-13 15:06:22.391 DEBUG (MainThread) [custom_components.hikvision_axpro] Finished fetching hikvision_axpro data in 10.003 seconds (success: False)

home-assistant_hikvision_axpro_2025-03-13T14-07-58.699Z.log

Thanks!

@TW500
Copy link

TW500 commented Mar 15, 2025

Hi, I have the same problem. The problem occurs especially when I arm or disarm the AX Pro. At that moment, the AX Pro is "Not available" for a few seconds, so I also have problems with my automation.
The problem has arisen for me since the last update of the AX Pro control centre.
Since then, it also takes a very long time for the alarm system to be armed. However, this is not only the case when I arm the system via HA, but also when I arm it in the Hik-Connect app.

Thank you in advance!

@petrleocompel
Copy link
Owner

I will say it again. Logs, logs and logs. Please bring logs. @TW500 Can be completely different issue. Logs will decide.

@TW500
Copy link

TW500 commented Mar 15, 2025

Does that help? It always throws this into the events when the Alsrman system is "Not available".

Dieser Fehler stammt von einer benutzerdefinierten Integration

Logger: custom_components.hikvision_axpro
Quelle: helpers/update_coordinator.py:386
Integration: hikvision_axpro (Dokumentation, Probleme)
Erstmals aufgetreten: 00:57:22 (6 Vorkommnisse)
Zuletzt protokolliert: 09:53:11

Timeout fetching hikvision_axpro data

@petrleocompel
Copy link
Owner

And nothing more? Did you went through full log? @TW500

In @pipolaq i still have to go through the full log.

@TW500
Copy link

TW500 commented Mar 15, 2025

I have now armed the alarm system once and deactivated it again. So I can provoke the “Unavailable” status. then I saved the logs from the hikvision_axpro intigration about 2 minutes before arming / disarming and 2 minutes after.
I have attached the log as a text file. I hope this helps.
Many thanks in advance

hikvision_logs_1135_1140.txt

@petrleocompel
Copy link
Owner

@pipolaq log is even showing me there is some problem with connection

2025-03-13 14:01:57.391 ERROR (MainThread) [custom_components.hikvision_axpro] Timeout fetching hikvision_axpro data
....

2025-03-13 14:02:01.453 ERROR (MainThread) [homeassistant.components.automation.ouverture_automatique_portail] Ouverture automatique portail: Error executing script. Unexpected error for choose at pos 1:
Traceback (most recent call last):
  File "/config/custom_components/hikvision_axpro/__init__.py", line 417, in _async_update_data
    await self.hass.async_add_executor_job(self._update_data)
asyncio.exceptions.CancelledError

And the posted config does not match kinda the log - set up interval between request should be 28 seconds.

2025-03-13 14:37:19.008 DEBUG (MainThread) [custom_components.hikvision_axpro] Finished fetching hikvision_axpro data in 8.613 seconds (success: True)
....
2025-03-13 14:37:33.493 DEBUG (MainThread) [custom_components.hikvision_axpro] Finished fetching hikvision_axpro data in 9.104 seconds (success: True)

33-19 = 14 seconds and your "system response" takes 9 seconds. Soo it seems the interval is set up as 7 - 10 seconds.

If you have pull interval lower than 30 sec it can cause instability.

You can go lower than 30 but.. If you have camera connected to AXPro I do not recommend it. More than 50 sensors I also would not recommend. But It will vary and you have to experiment.
Same goes with device type. Lower model = less powerful = higher pull interval should be.

(cheapest) AX Hub < AX Pro < AX Pro hybrid (priciest)

@TW500
Copy link

TW500 commented Mar 15, 2025

The problems started the day I updated the AX Pro to the latest firmware. Before that, everything ran smoothly with the same settings.

I have set the interval down. The reason is that I have an automation system that turns on all the lights when the alarm system is triggered and I have installed an additional siren that is triggered by an automation system.
Before I changed this, it took about 30 seconds for the automation to be triggered and that is too long.

I will not be adding cameras as I use a different system from Reolink.
The number of sensors will remain as it is in the future except for 2 motion detectors.

Translated with DeepL.com (free version)

@petrleocompel
Copy link
Owner

@TW500 In your case it seems it is not related to this issue at all. Your log is not showing me any instabilities. If you truncated log too much It can happen that I do not see something related. Also I do not see "connection sequence" so I do not know your system model. And cannot determine more.
This is why I said It does not have to be related.

This is why I do not like people to jump in to issues and say I have the same problem but their setup is completely different every time.

So far from the logs I cannot tell.. Also I need to know your configuration.
Still I cannot even consider this an issue because:

  • I personally test this integration on 2 different AX Pro devices 2 different HA
    • AX Hybrid (top model)
    • AX Pro (on of the cheaper models)
  • I had 0 issues past 5 months. And I had every single beta version.
  • Still have no info about your setup

To clarify:

  • What model do you have?
  • Is it connected via Ethernet or Wifi ?
  • Is your HA connected via Ethernet or Wifi?
  • Do you have some cameras connected ?
  • What is your pull interval?
  • Do you use "cloud account" or "local account" for "authorization"?
  • What is the firmware you have on the device ?

@petrleocompel
Copy link
Owner

I have set the interval down. The reason is that I have an automation system that turns on all the lights when the alarm system is triggered and I have installed an additional siren that is triggered by an automation system.
Before I changed this, it took about 30 seconds for the automation to be triggered and that is too long.

https://github.com/petrleocompel/hikaxpro_hacs?tab=readme-ov-file#can-i-make-data-appear-faster--can-i-speed-up-updating-sensors

The problems started the day I updated the AX Pro to the latest firmware. Before that, everything ran smoothly with the same settings.

AX Pro Firmware. I keep my systems at older firmware. Because I am too scared that exactly something like this will start happening. Or that the API will be closed down. There are no release notes for the firmware.
So I have a big problem with "firmware updates". Sadly you pointed out maybe the correct problem.
"The firmware"
Device will be overloaded because they changed something. And now the combination of "newest firmware" and "API calls" can be too much.
Again sadly you can only complain at manufacturer not about the integration.

@petrleocompel petrleocompel removed the bug Something isn't working label Mar 15, 2025
@TW500
Copy link

TW500 commented Mar 15, 2025

Answer to the questions:
I have the Hikvision AX Pro DS-PWA64-L-WE
Version: V1.3.0 build 250210
I have connected the alarm system via WLAN 2.4 Ghz. The WLAN access point is in the same room as the alarm panel
No cameras
Scan interval: 3
I have authorized the integration with e-mail. So I assume that it is cloud. I don't know any other possibility.
Firmware: V.1.3.0 build 250210

@TW500
Copy link

TW500 commented Mar 15, 2025

I also thought about the firmware and I regret the update.
Has anyone ever downgraded the alarm system?

@TW500
Copy link

TW500 commented Mar 15, 2025

Hello, I wanted to give you a brief update on what happened next. I have flashed my firmware back to 1.2.9 Build: 240621. The problems are now gone and everything is working as before the update.

If anyone else does this, they must be aware that the alarm system has to be completely reconfigured - at least that's how it was for me. In addition, it is of course not intended by the manufacturer to flash back the firmware.

Home Assistant automatically took over all the sensors again after the new setup, so I didn't need to set them up again.

I would also like to thank you once again for developing this integration and sharing it with the community!

petrleocompel added a commit that referenced this issue Mar 15, 2025
@petrleocompel
Copy link
Owner

I added warning to README.

@TW500
Was there any necessary steps except reconfiguration?
Where did you get the firmware can you directly link it here?
Maybe even upload it here as an backup so HikVision cannot delete it?

@petrleocompel
Copy link
Owner

@pipolaq can you check your firmware version ? if it is lower than 1.3.0.
Can you answer kind the same questions?

  • What model do you have?
  • Is it connected via Ethernet or Wifi ? - you said it is via Wifi.
  • Is your HA connected via Ethernet or Wifi?
  • Do you have some cameras connected ?
  • What is your pull interval?
  • Do you use "cloud account" or "local account" for "authorization"?
  • What is the firmware you have on the device ?

@TW500
Copy link

TW500 commented Mar 15, 2025

I selected the firmware in the web interface under "Upgrade" and started the update process. After a few minutes, the control panel was accessible again. However, only the base station was displayed, and all sensors were missing.

When I tried to add the sensors again, a message appeared stating that the sensor was already added to the base station. As a result, I reset the alarm base to factory settings, re-added the control panel, and re-registered the sensors.

After the downgrade, I had trouble logging into the web interface. I was able to resolve the issue by clearing the browser cache and flushing the DNS cache in Windows using the command (ipconfig /flushdns).

I had completely deleted the hikvision_axpro configuration in Home Assistant, but I don't think that was necessary. Home Assistant recognized all the sensor entities again after I re-added the configuration with the same IP address. This meant I didn't have to adjust any automations or dashboards.

I am providing the link to the firmware. The firmwares are available in multiple languages. Simply download, extract, and perform the downgrade. The firmware files are located in the "AX Pro Control Panel Firmware" directory.

Link Firmwares:
https://www.hikvisioneurope.com/eu/portal/?dir=portal%2FTechnical%20Materials%2F10%20%20Intrusion%26Alarm%2F00%20Product%20Firmware%2FWireless%20Control%20Panel%2FAx%20Pro

@XanaX2016
Copy link

Don't want to downgrade and loose config. An issue will be found?

thanks for your help

@petrleocompel
Copy link
Owner

This is on hardware side. In the firmware.

And as rumours are going on... support of ISAPI is not something hikvision really wants.

Sadly, if that will be removed it will be the end of local support.

@XanaX2016
Copy link

Thanks for your reply. So nothing to do now execpt downgrade

@petrleocompel
Copy link
Owner

There might will be fix of the firmware but i am not part of hikvision and so far last upgrades were pretty disappointing.

I kept my fw on stable older version. And even posted to release notes of the integration a warning so... probably yes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants