All devices becomes unavailable to hass from time to time. Could it be PAN ID?

I moved from homeassistant in docker with z2m and mqtt also in dockers to home assistant os on a dedicated pi.

When setting up z2m I had problems with it not connecting because there was another pan id even though i Flashed my sonoff stick. So I changed the pan id myself to 6755 instead of 6754 and it all seemed to work.
Now I noticed though that my devices (all of them both aquara and hue) become unavailable from time time, only for a short time but this activates my automations for stuff like door sensors if they meet conditions.

Could this be because I changed the pan id?

I tried adding GENERATE in the hass z2m config but that just thought out some errors, and adding it directly to configuration.yaml under zigbee2mqtt folder did not seem to do anything either.

Could my problem be because of the Pan ID?

Any how if so, how can i fix it?

I hope someone here can help!

Thank you all in advance :slight_smile: