How To: Switch installed version (stable build to latest dev snapshot) - openhabian

With the recent announcement of openHAB 2.2 scheduled for release on Dec 18th – Link Here

I wanted to be a part of the testing by switching from stable v 2.1 to the v. 2.2 developmental “unstable” version. I am running openhabian on a raspberryPi3.

This guide will show you how to switch the installed version of openHAB from the latest stable build on openhabian using the configuration tool.

References
Package repository: http://docs.openhab.org/installation/linux.html#package-repository-installation
openhabian-config: http://docs.openhab.org/installation/openhabian.html#openhabian-config

Note: Please ensure you take proper backups before attempting an upgrade. you should back up all your configuration files and user data before attempting this.

Step 1: login via ssh and run the openhabian-config tool

$ sudo openhabian-config

Step 2: Choose the option to “Switch the installed openHAB version or apply tweaks”. on the next screen, select “openHAB 2.2 unstable

Take warning! Continue at your own risk… (recall my note above about making backups…)

Note: IMPORTANT: The next message instructs you to replace current configurations files with the newer ones… this WILL potentially remove any of your custom configuration which you will likely want to take note of and, add back in once the install completes. Therefore, it would be wise to run the DIFF option when prompted in order to see what is being removed so that you can add it back in after the installation completes. (more below)

openHAB-switch-version_3

at the shell prompt, the installer will ask you to overwrite configuration files with the newer versions. select option D for Diff to see the changes. (take note, copy to text editor etc)
take note, press q to quit diff. Then Y or I to accept newer version.

Once finished, you should see the following screen.

openHAB-switch-version_4

Now, go back and edit/update your config files as needed. Here is an example where I had to add back in to get my AEOtec Z-Stick working again. (followed by restarting openhab2)

Reference: http://docs.openhab.org/installation/linux.html#privileges-for-common-peripherals

Edit services config file
I also also had to edit the services config file to set influxdb as my persistence engine and to specify my default audio sink.

$ cd :/etc/openhab2/services
$ sudo nano rungtime.cfg

-org.eclipse.smarthome.persistence:default=influxdb (original line - change back to this)
+#org.eclipse.smarthome.persistence:default= (line add from newer config)

-org.eclipse.smarthome.audio:defaultSink=sonos:PLAY1:hallway (original line - change back to this)
+#org.eclipse.smarthome.audio:defaultSink= (line add from newer config)

After making all changes, I restarted everything

$ sudo reboot

5 Likes