Skip to content
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

Device Already configured #88

Closed
matfil92 opened this issue Sep 22, 2021 · 5 comments
Closed

Device Already configured #88

matfil92 opened this issue Sep 22, 2021 · 5 comments
Labels
question Further information is requested suspended Suspended: either unknown resolution or need further inspection

Comments

@matfil92
Copy link

Hi,
I've successfully installed Meross LAN component with various devices.
All works correctly but yesterday I've tried to remove one entities of smart plug and now, also if I've reset it, if I try to setup it again I correctly see in Meross APP but in home assistant they will find it correctly but if I try to add it I've an error that said "Device Already configure"

How can I solve it?

image

@krahabb
Copy link
Owner

krahabb commented Sep 23, 2021

Hello @matfil92,
Maybe there's an 'ignored' version of the config entry hidden behind or in a 'disabled' state.
You can check from the top right corner of the Integrations page if it's hidden (by default) by HA and regain acces to it.
If you're absolutely sure there are no other hidden configured devices/entries and still it shows you this error you might try restart HA: usually this is a consequence of an 'inconsistent' state which gets resolved only by rebooting HA. It might happen some 'disable' or 'remove' operations are not carried out cleanly maybe for transient errors or for permanent bugs (hard to identify because they really depends on a lot of factors). Rebooting is the easiest fix.
Just be sure the entry is not still there disabled or ignored

@krahabb krahabb added question Further information is requested suspended Suspended: either unknown resolution or need further inspection labels Sep 30, 2021
@krahabb
Copy link
Owner

krahabb commented Nov 22, 2021

I assume this issue is not actual anymore ;)

@krahabb krahabb closed this as completed Nov 22, 2021
@davisgoodman
Copy link

@krahabb I'm seeing this issue still with one of my Smart_Plugs. I've looked through all the disabled/hidden entities/configs and can't find the ip reporting to be already configured. Is there a file where the devices are listed I could look through?

That is the last of my smart plug that needs to be added. All the others went really well.
image

@krahabb
Copy link
Owner

krahabb commented Jun 16, 2022

The 'Device is already configured' error comes from another 'config_entry' (integration configuration entry) having the same 'unique_id' as the one you're adding. These 'config_entries' are stored in plain json format under .homeassistant/.storage/core.config_entries. (This file contains all of your integrations configurations: beware when manually editing it)
meross_lan initially uses the MAC address as unique_id when devices are discovered by DHCP but, when the configuration is being finalized and you have set the correct key (thus allowing a complete identification of the device) this unique_id is set according to the 'meross device UUID' which should be unique too (like the MAC).
Still can't get where this mess comes from and I'm sorry for that but you can try manually inspecting that 'core.config_entries' file looking for all the 'meross_lan' entries and isolate the offending one (i.e. the one you're sure is not related to any of your working devices).
Editing the file as I said might be dangerous if you break the json layout. As usual a good backup copy might be handy. Also, I guess it would be safer to stop HA before editing the file so it could then restart on a clean configuration.

I guess it would be nice to have the device UUID of this newly added conflicting device so you could look straight for that value in the config file but, as of now, there's no easy way to expose that. I'm looking forward to show this field information on the configuration form for the next release so it could help digging into the issue.

@krahabb krahabb reopened this Jun 16, 2022
@davisgoodman
Copy link

@krahabb That's fine I'll look it up. At least I know where and what to look for. I'm ok with the json file. For now I've used another plug I had aside to replace that one but I'll get the MAC address of the offending one and look it up. I'll let you know if I'm able to have HA register it back once I`ve found the right one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested suspended Suspended: either unknown resolution or need further inspection
Projects
None yet
Development

No branches or pull requests

3 participants