Some notes to anyone reading this in the course of an upgrade to OH4:
FAQ
There’s a FAQ thread on upgrading to OH4: openHAB 4 migration FAQ.
Java 17 and buster
Note that installing OH4 and with it Java 17 requires your existing openHABian system to be on Debian 11 “bullseye” distribution level. If you are still on Debian 10 (“buster”) or older, attempting to install OpenJDK will probably fail with a package dependency problem.
Note: selecting menu option 03 - Upgrade will refuse to upgrade if you’re still on buster or older.
Debian 10 “buster” is end of life now with Debian 12 “bookworm” now released, so you should be upgrading any “buster” system of yours.
This is how to proceed if you’re on Raspberry Pi OS: Raspberry Pi Documentation - Raspberry Pi OS . For other Debian variants there’s many more resources on the web.
Note: there’s a fair chance that upgrading the distro will fail.
So alternatively and especially on Raspberry, it might be better to start from scratch (with a new SD card) and to import your openHAB configuration.
Alternative: fresh install
Like so:
- get a new SD card (best: an “Endurance” labelled one) and keep the old one as your fallback
- run option 50 to create an OH config backup and copy it to some box of yours
- download and flash latest openHABian
- Put the SD in your Windows system and open the first (only) partition. Edit
openhabian.conf
setclonebranch=openHAB3
That should result in (latest) OH3 being installed.
Also put your backup zip file there, name itinitial.zip
. That’ll auto-import the config during install. - Now put the SD in the Raspi and turn it on. Let openHABian do its install magic.
- When finally done, login and run
openhabian-config
menu option 03 to upgrade to OH4
Finally, FWIW, openHABian is not confirmed to be ready for bookworm yet so you should not be upgrading there but to bullseye. Well, or do and help with testing and getting openHABian ready for it.
Memory usage
The Java upgrade seems to be using quite some more memory than before and memory reserves are tight particularly if you are on Raspberry. See corresponding question in the FAQ .