Installing openHAB 2.5.0 on Raspberry Pi 4

I saw a couple of folk struggling to install openHAB 2.5.0 on a raspberry Pi 4, first off the Pi architecture is well suited for 64bit and backporting that is shrinkwrapped is not necesarily a good trait.
I would recommend downloading the raspberry Pi 4 64bit server image from Ubuntu (19.10 Eoan Ermine)
Download the image, flash it to a microSD card, insert into then connect to network and boot your Raspberry Pi, watch the console screen to see the IPv4 address obtained.
Then open a Putty or terminal session to your Pi4 IPv4 address, the default login is ubuntu, password ubuntu, it will ask you to change the password straight away. Once done re-open the terminal session, login as ubuntu with your new password, and issue root a passwd.
sudo passwd root
Repeat the password, then switch to the root user.
su root
Enter the password you just assigned.
Then copy and paste the script below

apt-get update
#Install dependancies
apt-get install openjdk-8-jdk libjna-java -y
echo “Pausing for 30 seconds after Java installation …”
sleep 30
#Package Installation
#1.Add the repository key
wget -qO - ‘’ | sudo apt-key add -
#2.Add the HTTPS transport for APT
sudo apt-get install apt-transport-https -y
#3.Add the repository
echo ‘deb stable main’ | sudo tee /etc/apt/sources.list.d/openhab2.list
#4.Update the package lists and install the openHAB distribution package
apt-get -y install unzip zip
sudo apt-get update && sudo apt-get -y install openhab2 --allow-unauthenticated
#5.(Optional) Install the add-ons for offline use
sudo apt-get install openhab2-addons -y --allow-unauthenticated
sudo /bin/systemctl enable openhab2.service
sudo /bin/systemctl daemon-reload
service openhab2 stop
cat >> /etc/openhab2/services/addons.cfg << ‘EOF_PACKAGES’
package = expert
ui = basic,paper,habpanel,habmin

sudo /bin/systemctl start openhab2.service
#lets just give openhab a minute to let all the services start
#6.Navigate with a web browser to http://:8080
echo “Pausing for 60 seconds after openHAB installation…”
echo “Please note it will take a few minutes for the openHAB packages to load and the GUI on port 8080 to become available”
sleep 60

Trust someone will find use in this.

Installed it last night (using the official openhab 2.5.9 32bit Buster image). I had NO issues at all.

What took most time was to move root to my SSD drive connected to the USB3. I ran into a huge known issue where the SATA interface wouldn´t get recogniced correctly on the USB3 port, (after moving root. It worked fine on the USB2 port). So I struggled a few hours with this issue.

When I finally found the solution, it took me aprox 15-20 minutes in all to write a new image on the SD, and install Openhab 2.5 stable and move it to root.

Yes the Rpi4 support 64bit. So did the Rpi 3B+. The 32bit official image works just fine though.

Just my opinion!