openHABian hassle-free openHAB Setup

That’s a default message from Raspi OS you can ignore, raspi-config is not installed.

so how did you manage to install without setting the country locale?

I have a new RPi 4 and Aeon Z-stick Gen5+ and I’m anxious to upgrade from my Pine64. I really want the benefit of openHABian, in particular the config tool, but am also looking to get off the Pine64 soon. How long away is openHABian support of V3 expected or or should I be consider 2.5 for now or manually install 3.0?

There’s nothing wrong with running OH2.5.x, and you don’t have to make all steps in one go, better separate.
So migrate to the RPi first. You should be able to install it with the openHABian image and import your existing config.
And you don’t want to move to OH3.0 for production today or in the very near future. Stick with 2.5.
openHABian support is being worked on.

1 Like

Hi Markus,

I just ran sudo openhabian-config to upgrade the scripts to the latest version.

While running menu 10 > 13 (System Tweaks) I came across the following warning:

Creating persistent systemd journal folder location: /var/log/journal

$ mkdir -p /var/log/journal 

$ systemd-tmpfiles --create --prefix /var/log/journal 
[/usr/lib/tmpfiles.d/fail2ban-tmpfiles.conf:1] Line references path below legacy directory /var/run/, updating /var/run/fail2ban → /run/fail2ban; please update the tmpfiles.d/ drop-in file accordingly.
Keeping at most 30 days of systemd journal entries

So it appears that fail2ban needs some manual help to adapt to the new folder settings?

Hi @mstormi,

I also wanted to reinstall ZRAM through openhabian-config by first uninstalling ZRAM and then reinstalling, but the uninstall failed with an error message, and I also got a pop-up in openhabian-config

$ systemctl disable --now zram-config.service zramsync.service 
Removed /etc/systemd/system/
Failed to stop zramsync.service: Unit zramsync.service not loaded.
FAILED (disable service)

It appears that the systemctl disable is invoked before stop

I then stopped ZRAM from the command-line, disabled the ZRAM service and rebooted the RPi

$ sudo systemctl stop zram-config
$ sudo systemctl disable --now zram-config.service zramsync.service
Failed to disable unit: Unit file zramsync.service does not exist.
$ sudo reboot now

When I attempt at (un)installing zram through openhabian-config, I get in a deadlock:

$ sudo openhabian-config 
[sudo] password for openhabian: 
2020-10-20_09:45:02_CEST [openHABian] Checking for root privileges... OK
2020-10-20_09:45:03_CEST [openHABian] Loading configuration file '/etc/openhabian.conf'... OK
2020-10-20_09:45:03_CEST [openHABian] openHABian configuration tool version: [stable]v1.6-880(769ea17)
2020-10-20_09:45:03_CEST [openHABian] Checking for changes in origin branch HEAD... OK
2020-10-20_09:45:07_CEST [openHABian] Switching to branch stable... OK
2020-10-20_09:45:14_CEST [openHABian] Updating Linux package information... OK
2020-10-20_09:45:19_CEST [openHABian] Removing ZRAM service... 
$ systemctl disable --now zram-config.service zramsync.service 
Failed to disable unit: Unit file zramsync.service does not exist.
FAILED (disable service)
2020-10-20_09:45:37_CEST [openHABian] Updating Linux package information... OK
2020-10-20_09:45:37_CEST [openHABian] Refusing to install ZRAM as it is already installed, please uninstall and then try again... EXITING
2020-10-20_09:45:42_CEST [openHABian] Checking for default openHABian username:password combination... OK
2020-10-20_09:45:42_CEST [openHABian] We hope you got what you came for! See you again soon ;)

When checking for ram packages, I get:

$ sudo apt list --installed | grep zram

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

What should I do now?

In reply to myself… I manually removed 3 ZRAM-related files in /etc:

  • /etc/ztab
  • /etc/logrotate.d/zram-config
  • /etc/systemd/system/zram-config.service

Then I was able to reinstall zram through openhabian-config

open a Github issue please.

no, disable --now includes the stop

debug=maximum in /etc/openhabian.conf and explain what you entered.

Try if uninstall/reinstall works now. You had a premature version installed, that’s why.


It works now:

$ sudo openhabian-config 
2020-10-20_10:11:24_CEST [openHABian] Checking for root privileges... OK
2020-10-20_10:11:25_CEST [openHABian] Loading configuration file '/etc/openhabian.conf'... OK
2020-10-20_10:11:25_CEST [openHABian] openHABian configuration tool version: [stable]v1.6-880(769ea17)
2020-10-20_10:11:25_CEST [openHABian] Checking for changes in origin branch HEAD... OK
2020-10-20_10:11:28_CEST [openHABian] Switching to branch stable... OK
2020-10-20_10:11:34_CEST [openHABian] Updating Linux package information... OK
2020-10-20_10:11:56_CEST [openHABian] Removing ZRAM service... 
$ systemctl disable --now zram-config.service zramsync.service 
Removed /etc/systemd/system/
Removed /etc/systemd/system/

$ rm -f /etc/systemd/system/zram-config.service /etc/systemd/system/zramsync.service 

$ systemctl unmask unattended-upgrades.service 
Removed /etc/systemd/system/unattended-upgrades.service.
2020-10-20_10:12:10_CEST [openHABian] Removing ZRAM... 
$ rm -f /usr/local/sbin/zram-config 

$ rm -f /usr/local/sbin/zramsync 

$ rm -f /etc/ztab 

$ rm -rf /storage/zram 

$ rm -rf /usr/local/share/zram-config 

$ rm -rf /usr/local/lib/zram-config 

$ rm -rf /etc/sysctl.d/zram.conf 

$ rm -f /etc/logrotate.d/zram-config 
2020-10-20_10:12:28_CEST [openHABian] Updating Linux package information... OK
2020-10-20_10:12:29_CEST [openHABian] Installing ZRAM code... 
$ mkdir -p /opt/zram 

$ update_git_repo /opt/zram/overlayfs-tools master 
2020-10-20_10:12:29_CEST [openHABian] Updating overlayfs-tools, master branch from git... 
$ git -C /opt/zram/overlayfs-tools fetch origin 

$ git -C /opt/zram/overlayfs-tools fetch --tags --force --prune 

$ git -C /opt/zram/overlayfs-tools reset --hard origin/master 
HEAD is now at 77bf3f7 Merge pull request #11 from amir73il/deref-cmd

$ git -C /opt/zram/overlayfs-tools clean --force -x -d 
Removing logic.o
Removing main.o
Removing overlay
Removing sh.o

$ git -C /opt/zram/overlayfs-tools checkout master 
Already on 'master'
Your branch is up to date with 'origin/master'.

$ update_git_repo /opt/zram/openhabian-zram master 
2020-10-20_10:12:32_CEST [openHABian] Updating openhabian-zram, master branch from git... 
$ git -C /opt/zram/openhabian-zram fetch origin 

$ git -C /opt/zram/openhabian-zram fetch --tags --force --prune 

$ git -C /opt/zram/openhabian-zram reset --hard origin/master 
HEAD is now at 2f51a14 parametrize storage dir in zramsync.service

$ git -C /opt/zram/openhabian-zram clean --force -x -d 

$ git -C /opt/zram/openhabian-zram checkout master 
Already on 'master'
Your branch is up to date with 'origin/master'.
2020-10-20_10:12:34_CEST [openHABian] Setting up OverlayFS... 
$ make --always-make --directory=/opt/zram/overlayfs-tools 
make: Entering directory '/opt/zram/overlayfs-tools'
gcc -Wall -std=c99 -c main.c
gcc -Wall -std=c99 -c logic.c
gcc -Wall -std=c99 -c sh.c
gcc -lm main.o logic.o sh.o -o overlay
make: Leaving directory '/opt/zram/overlayfs-tools'

$ mkdir -p /usr/local/lib/zram-config/ 

$ install -m 755 /opt/zram/overlayfs-tools/overlay /usr/local/lib/zram-config/overlay 
2020-10-20_10:12:36_CEST [openHABian] Setting up ZRAM... 
$ install -m 755 /opt/zram/openhabian-zram/zram-config /usr/local/sbin 

$ install -m 755 /opt/zram/openhabian-zram/zramsync /usr/local/sbin 

$ install -m 644 /opt/openhabian/includes/ztab /etc/ztab 

$ mkdir -p /usr/local/share/zram-config/log 

$ install -m 644 /opt/zram/openhabian-zram/zram-config.logrotate /etc/logrotate.d/zram-config 
2020-10-20_10:12:36_CEST [openHABian] Setting up ZRAM service... 
$ install -m 644 /opt/openhabian/includes/sysctl-zram.conf /etc/sysctl.d/zram.conf 

$ sysctl -q -p /etc/sysctl.d/zram.conf 

$ systemctl mask unattended-upgrades.service 
Created symlink /etc/systemd/system/unattended-upgrades.service → /dev/null.

$ systemctl enable --now zram-config.service zramsync.service 
Created symlink /etc/systemd/system/ → /etc/systemd/system/zram-config.service.
Created symlink /etc/systemd/system/ → /etc/systemd/system/zramsync.service.
2020-10-20_10:12:50_CEST [openHABian] Checking for default openHABian username:password combination... OK
2020-10-20_10:12:50_CEST [openHABian] We hope you got what you came for! See you again soon ;)

I got that on openhabian image for raspi on my first time logging in from ssh.

Thank you for providing a new version of openhabian. Great to see the new features!

Please can you give some more details on the new auto-backup functionality. Maybe it makes also sense to add those to the documentation.

openHABian will create partitions 1 and 2 to be mirrors of your internal card and will assign the remaining space to a storage partition. Full mirroring will take place semiannually and changes will be synced once a week.

Does that mean both partitions are mirrors, but partition 1 is updated semiannually and partition 2 weekly? Or is the same partition used, but different backup options are used?
Partition 1: dd (plus some more as mentioned in a post above), semiannually
Partition 2: rsync weekly

Use menu option 54 to copy your active backup card back to the new one

If the backup SD has two partitions, how does the restore mechanism work? Can the user decide which backup (half-year/weekly) to restore on the new SD? Or is this dependent on which partition of the backup SD is booted?

Additionally I would like to understand if the following assumption is correct:
Menu option 53 (mirroring) is automating the menu options 54 + 55.

Thanks in advance!

You’re overcomplicating things.
openHABian consists of TWO active partitions, the boot vfat one and the Linux root one.
Both are mirrored. Only the second one is rsync’ed (as only that will change in operations).

54+55 are to manually run once.
53 will setup timers to execute 54+55 at regular intervals.

I see Im over complicating it.

The second card needs to have at least twice the size of your internal card.

Based on the above I thought the backup is stored twice on the backup SD. Now I know this is not the case. However please could you explain (just high level) why the backup SD needs to have twice the size or the internal one?

to have Amanda fit on partition #3 and to avoid “destination too small” issues when people use different SD models

1 Like

I have been working on installing openHABian on a RPI4 2GB so that I can migrate off of my Pine64. The openHABian basic install went very well. Thank you for making such a hassle-free openHAB setup.

Since I was going to a new system, I thought it was a perfect time to also implement features I have not previously used. One of those is graphing of temperatures over time. I used the the openHABian configuration tool item to install optional component #24 for InfuxDB+Grafana. I was able to successfully create a dashboard in Grafana. Where I struggled was getting a Grafana graph to show in my sitemap but had no luck. After doing some research, my takeaway is that I need to install Grafana Image Renderer.

    • Is this true, do I need Grafana Image Renderer to show charts from RPi4 in my sitemap?
    • If so, is there a plan to make the renderer part of the openHABian configuration tool install optional components?

When I was trying to get Grafana working, I manually installed and edited some configuration files. My plan is to start fresh with another openHABian install in case I unintentionally messed something up. Ideally I’d like to import the working parts of my config. Where is the best documentation on installing openHABian, the optional components and moving configurations? The struggle I have is that I find great documentation or how-to videos but they are dated. If there is a most recent set of documents, I’d be happy to give feedback/edits on things I find which could benefit from updates.

Thank you!

I don’t know. For sure there’s means to graph without Grafana but that’s no openHABian question.


The official docs are at
That’s actually a copy of the files in /opt/openhabian/docs of your box.
They are kept up to date.

The rest is up to you guys and girls. Figure out, take notes while you install and post your experience on this forum in the Tutorials section or (better) create a PR on

Thank you for the reply.

Thank you. I’ll look into options other than Grafana since Grafana can no longer render images without the Grafana renderer plugin which is not currently suported on ARM.

Thank you!

I’m about to do this and buying a new Raspi. Should I but the best Raspi available? So Pi 4 8gb or is that to much and can I do with less?
So I should backup my config and load this in a new install of Openhab. Do you think I can just unplug my Z-wave stick and plug it in the new Raspi? Or are the some more things I should consider?
Thanks in advance

I attempted my first change request for the documentation. I noticed that the docs referred to the new install’s hostname as openhab instead of openhabiandevice. Please let me know if I should have done something different.