Upgrade using a temp instance

  • Platform information:
    • Hardware: x86 server
    • OS: ubuntu
      version_
    • openHAB version: 2.4
    • using external MQTT
    • Things: Tasmota and zigbee through zigbee2mqttt

I plan to upgrade all my installation, recreating my “ugly barely working installation” into a “clean upgraded installation”

To do so I thought of running a parallel openhab instance in the same server. All interaction are through MQTT. Is it possible? what should I take into account? which ports should I redirect?

Thanks

Never tried it but I think you can run a second instance on the same server but you will only want to use the second instance for testing.

You will need to configure the testing OH instance to use different ports if you are running on the same host. I run in Docker so I’m not entirely sure where to change that. Maybe /etc/defaults/openhab2.

You can’t share hardware (e.g. Zwave dongle) between the two instances at the same time but you indicate you don’t have that case.

However, there still might be interactions between the two as both will be receiving and acting upon the same MQTT messages so you need to account for that as you progress.

If you can manage it, I’d only run one version at a time. Stop production, start up testing, do your work and then stop testing and restart production. Or put the testing OH instance on another machine.

I don’t have zwave, and zigbee is taken care by zigbee2mqtt
I created a new systemd service changing ports
Enviorment=“OPENHAB_HTTPS_PORT=8444”
Enviorment=“OPENHAB_HTTP_PORT=8081”

I want to test discovering items and rules engines, without custom file editing. Most of devices are “read only”, and I have a switch to disable all rules, so I should be fine just disabling rules and not shutting down instances.

Thanks