OpenHAB installed, but no webinterface

  • Platform information:
    • Hardware: Raspberry Pi 4, 4Gb
    • OS: Raspbian
    • Java Runtime Environment: Zulu build of OpenJDK11.x
    • openHAB version: latest
  • Issue of the topic: Cannot get OpenHAB running

Hi,

my setup runs on a Pi with other goals, so I executed the manual installation as described in the documentation, under Linux (Package Repository Installation) for Apt Based Systems.

wget -qO - ‘https://openhab.jfrog.io/artifactory/api/gpg/key/public’ | sudo apt-key add -
sudo apt-get install apt-transport-https
sudo apt-get update
sudo apt-get install openhab
sudo apt-get install openhab-addons
sudo /etc/init.d/openhab start
sudo /etc/init.d/openhab status
sudo update-rc.d openhab defaults
sudo systemctl start openhab.service
sudo systemctl status openhab.service
sudo systemctl daemon-reload
sudo systemctl enable openhab.service

Also changed /etc/default/openhab to other ports (8088 and 8444), to prevent conflicts.

The command sudo systemctl status openhab.service reports:
● openhab.service - openHAB - empowering the smart home
Loaded: loaded (/lib/systemd/system/openhab.service; enabled; vendor preset: enabled)
Active: active (running) since Mon 2021-07-19 09:16:05 CEST; 1h 15min ago

Main PID: 549 (java)
Tasks: 44 (limit: 4915)
CGroup: /system.slice/openhab.service
└─549 /usr/bin/java -XX:-UsePerfData -Dopenhab.home=/usr/share/openhab -Dopenhab.conf=/etc/openhab -Dopenhab.runtime=/usr/share/openhab/runtime -Dopenhab.userdata=/var/lib/openhab -Dopenhab.logdir=/var/log/openhab -Dfelix.cm.d

Jul 19 09:16:05 Multi-Pi systemd[1]: Started openHAB - empowering the smart home.`

Which looks fine to me, also Glances reports OpenHAB running.
But even if I wait for hours, the webinterface fails to show.
Scanning ports does also not show ports from OpenHAB active.

Logfiles of OpenHAB in the default locations are all empty.

Hopefully this makes sense to someone?

Regards,

Erwin

What does

sudo netstat -tulpn

especially

sudo netstat -tulpn | grep java 

show.

What does

sudo journalctl -u openhab

show ?

Hi Wolfgang, thanks for your reply!

Below the output generated by the commands:
sudo netstat -tulpn

Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 413/cupsd
tcp 0 0 127.0.0.1:4711 0.0.0.0:* LISTEN 719/pihole-FTL
tcp 0 0 0.0.0.0:5900 0.0.0.0:* LISTEN 586/vncserver-x11-c
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 707/lighttpd
tcp 0 0 0.0.0.0:53 0.0.0.0:* LISTEN 719/pihole-FTL
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 635/sshd
tcp6 0 0 ::1:631 :::* LISTEN 413/cupsd
tcp6 0 0 127.0.0.1:33209 :::* LISTEN 549/java
tcp6 0 0 :::443 :::* LISTEN 704/domoticz
tcp6 0 0 :::6144 :::* LISTEN 704/domoticz
tcp6 0 0 127.0.0.1:8101 :::* LISTEN 549/java
tcp6 0 0 ::1:4711 :::* LISTEN 719/pihole-FTL
tcp6 0 0 :::5900 :::* LISTEN 586/vncserver-x11-c
tcp6 0 0 :::8080 :::* LISTEN 704/domoticz
tcp6 0 0 :::80 :::* LISTEN 707/lighttpd
tcp6 0 0 :::53 :::* LISTEN 719/pihole-FTL
tcp6 0 0 :::22 :::* LISTEN 635/sshd
udp 0 0 0.0.0.0:68 0.0.0.0:* 497/dhcpcd
udp 0 0 0.0.0.0:631 0.0.0.0:* 544/cups-browsed
udp 0 0 0.0.0.0:5353 0.0.0.0:* 423/avahi-daemon: r
udp 0 0 0.0.0.0:45364 0.0.0.0:* 423/avahi-daemon: r
udp 0 0 0.0.0.0:53 0.0.0.0:* 719/pihole-FTL
udp6 0 0 :::5353 :::* 423/avahi-daemon: r
udp6 0 0 :::42969 :::* 423/avahi-daemon: r
udp6 0 0 :::53 :::* 719/pihole-FTL

With the grep java:

tcp6 0 0 127.0.0.1:33209 :::* LISTEN 549/java
tcp6 0 0 127.0.0.1:8101 :::* LISTEN 549/java

And last the sudo journalctl -u openhab command

– Logs begin at Mon 2021-07-19 09:16:03 CEST, end at Mon 2021-07-19 14:49:44 CEST. –
Jul 19 09:16:05 Multi-Pi systemd[1]: Started openHAB - empowering the smart home.

Especially the last looks very little to log…

I hope this clarifies where it goes wrong.

Regards,

Erwin

Indeed that is less than expected.
Does /var/log/openhab directory exist and is it owned by openhab user as well as the logfile inside the directory ?

Hi Wolfgang,

Below the openhab folder under /var/log:

drwxr-xr-x 2 openhab openhab 120 Jul 18 12:05 openhab

Underlying files exist, but are all 0 bytes.

-rw-r–r-- 1 openhab openhab 0 Jul 18 12:05 audit.log
-rw-r–r-- 1 openhab openhab 0 Jul 18 12:05 events.log
-rw-r–r-- 1 openhab openhab 0 Jul 18 12:05 openhab.log
-rwxr-xr-x 1 openhab openhab 0 Jun 27 22:57 Readme.txt

Are the user rights sufficient?

Regards,

Erwin

yes, they are correct.