hassio-addons / addon-unifi

UniFi Network Application - Home Assistant Community Add-ons
https://addons.community
MIT License
278 stars 138 forks source link

Cant Adopt Ap #387

Closed kitt2011 closed 1 year ago

kitt2011 commented 2 years ago

Hello,

I have the following problem. I bought a used UNIFI UAC-AP. I can't get this one adopted. The Unifi add-on is installed and under settings, system, other configuration - override inform host this setting is enabled and the IP address of the home assistant is entered (192.168.178.17).

The UAC-AP was set up by the previous owner and was recognized. It said something like "the AP is assigned to another controller" under unifi devices.

I have set the UAC-AP to factory state. I also assigned it a fixed ip (192.168.178.6). It is also found under unifi devices, however I cannot adopt it. Nothing happens. Via SSH I can connect to the UAC-AP but also here the adoption fails with the line: set-inform http://192.168.178.17:8080/inform

then comes the error message:

Adoption request sent to 'http://192.168.178.17:8080/inform'.

  1. please adopt it on the controller
  2. issue the set-inform command again
  3. will be saved after device is successfully managed

Does anyone have another idea?

thanks a lot

SirMartin commented 2 years ago

I found the documentation in the addon page, and was my fault, it works now perfect

I have kind of the same issue. I made a factory reset of a lite AP. After that I tried in multiple ways registering into the addon, and stays forever on adopting/offline infinity loop

The UAP-AC-Lite has the latest firmware version.

I installed a Windows version of the controller and adopted without any issue. Also generated a backup in the working one, and tried to use it to restore on the addon, and I get exactly the same issue, forever in adopting status.

The only thing I found in the logs is this, but not sure is related.

org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: destroy called Exception in thread "Thread-11" java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext at org.springframework.context.support.AbstractRefreshableApplicationContext.getBeanFactory(AbstractRefreshableApplicationContext.java:168) at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1172) at com.ubnt.service.C.Ö00000(Unknown Source) at com.ubnt.ace.Launcher.o00000(Unknown Source) at java.lang.Thread.run(Thread.java:750)

Thanks

github-actions[bot] commented 2 years ago

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!

SirMartin commented 1 year ago

Not sure if it is the same issue at 100%, but now I am trying with another Unifi installation.

I am trying with HomeAssistant in a virtual machine (my "production" one is on a Raspberry Pi), in the same raspberry pi I have the Unifi Network App installed natively. And now I am trying to install this addon in the VM one.

I made a full backup of my Unifi "Prod" Installation from the Raspberry, and after installing the addon, restore the backup from the guide, no issues, and nothing wrong, but I can see some of the data, for example, I can see in the dashboard a list of clients, but after it, in clients tab, I cannot see anything.

And if I try to check the devices in my network, I can see all 3 of them are in adopting mode. Right now, the raspberry is off, so cannot make any conflict.

But in the beginning, all 3 of them were in adopting mode, in the screenshot 1 of them is offline, and while I am writing this, are 2 of them are offline, and just one continues trying to be adopted :cry:

image

Any idea?

I will try to make a normal installation on my machine (windows for example) and restore the same backup file, and see if I get the same issues or not.

SirMartin commented 1 year ago

I have just installed the windows version, and I can restore it without any issues.

image

sinclairpaul commented 1 year ago

Did you set the inform host?

Go to the settings (gears icon in the bottom left) -> System -> Application Configuration.

Toggle Override Inform Host.

Change the Host for Inform to match the IP or hostname of the device running Home Assistant.
SirMartin commented 1 year ago

Did you set the inform host?

Go to the settings (gears icon in the bottom left) -> System -> Application Configuration.

Toggle Override Inform Host.

Change the Host for Inform to match the IP or hostname of the device running Home Assistant.

Thanks, it worked like a charm !!!

github-actions[bot] commented 1 year ago

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!