Remote zigbee2 mqtt instance removes local zigbee2mqtt devices

Hi All,
To cover long distance communications try to get 2 lan zigbee coordinators to work.

My setup:
1 intel nuc running home assistant, zigbee2mqtt and Mqtt. My zigbee2mqtt on my nuc connects to a remote lan coordinator.
All works fine connecting to a remote lan coordinator. Zigbee2mqtt page is accessible and All devices show up in home assistant.

Now I want to add a 2nd lan device. Since I’m not able to run 2x zigbee2mqtt within home assistant I use a raspberry pi running home assistant and installed zigbee2mqtt.
I configure zigbee2mqtt on my RPI such it connects to the mqtt broker on the NUC. Configuration wise I changed the base topic and pointed to my original nuc IP-adress to connect zigbee2mqtt to my main homeassistant.

Every time I do this all my zigbee devices which where originally present on my nuc get removed and only the raspberry zigbee devices are visible and working.

Ofcourse I do want to see all my zigbee devices…

Does this have to do with creating an automation which changes the basetopic? <— where can I find more details?
Is there maybe another issue?

Help is appreciated.

Are you running HA OS or Supervised?

If you are running Home Assistant OS you cannot run multiple instances of the Zigbee2MQTT add-on because of the docker-signature.
In that case you need to run one of your coordinators with Zigbee2MQTT and the other one with ZHA.

If you are not running HA OS make sure you have a different base_topic and channel configured for the second Zigbee2MQTT instance.

Not entirely correct. You can run the Zigbee2mqtt add-on and the Zigbee2mqtt-edge add-on at the same time on HA OS. However, you do need indeed a different base_topic and channel.

As Andreas already said, you need both another base topic and channel on your Nuc and RbPi.

Yes, that’s possible but I would not recommend mixing beta-software into a production environment.

Thanks for the reply.

On my intel nuc I’m running home assistant supervised

On my rpi I’m running homeassistant OS

On both devices I run zigbee2mqtt
On both I have configured a unique base topic and a unique channel.

Running both items individually works without problems.

As soon as I connect zigbee2mqtt running on my Raspberry Pi to my mqtt broker on the intel NUC (to see and control all other devices)Al the zigbee devices controlled by the NUC dissapear from the mqtt service.
At that moment I’m able to control and read only the zigbee devices originally linked to the RPi

Is this related to mqtt? And it’s setup?
What to do?

You only have one mqtt server ? Common to both zigbee2mqtt instances ?

Yes, only one mqtt server running on my intel NUC.

The home assistant running on my raspberry pi is now only used to get zigbee2mqtt up and running and have a nice way of accessing its UI

I find it strange that when I activate and link thé zigbee2mqtt application on my raspberry all my zigbee devices linked to the zigbee2mqtt application on my NUC dissapear from my NUC home assistant device tree.

I have the feeling that there is something wrong with my zigbee2mqtt settings. But cannot find what’s wrong.
As said, I have for both instances different base topics and channel numbers.
I also tried setting and using different mqtt users.

It all sounds simple… but I’m stuck…
any suggestions?

What I cannot work out is why you are running ha on the pi. Install raspbian, docker, zigbee2mqtt.

Can you post the two Zigbee2MQTT configs from the NUC and RPi please?

Have you checked with MQTT-Explorer if both Zigbee2MQTT instances correctly talk to your MQTT-broker?

Have you verified that zigbee2mqtt is really using the unique topic you configured?
Maybe the are both still using the default topic because of a config issue. I would look at the messages on the broker with a tool like mqttbox.

That’s why I recommended MQTT-Explorer in my reply above.

Thank you for your suggestions, I was on a short holiday an back home; I will try what you have suggested and let you know the response.

MQTT explorer really helped tracking down the issue;

True the frontend i configured my zigbee2mqtt add-on. It seems that the base topic change I configured there was not applied to the add-on. (even after a hard reboot).
Modifying the settings in the zigbee2mqtt UI (settings/MQTT) worked well.

Now both instances have 2 base topics which show me all of my old and newly added sensors of both zigbee2mqtt add-on’s.

1 feature request I would recommend developing is to allow a 2nd zigbee2mqtt add-in to be run from within home assistant (or allowing a 2nd zigbee network to be created / supported); It seems that i’m not the only one with a “large size” setup.

Thanks for all your help.

How did you get your old devices to re-appear? I have a different base topic for each instance of Z2m (One running locally as an add on, the other in a remote location)