Openhab 2 don't start after reboot

  • Platform information: Odroid Xu4
    • Hardware: CPUArchitecture/RAM/storage
    • OS: _Dietpi
    • openHAB version: 2.1
  • Issue of the topic: after installation of openhab and Java on my odroidxu4 I played with my pilips hue, lights, kodi etc., Everything was working perfect.After a reboot it’s not working anymore.
    Here is the code :
* openhab2.service - openHAB 2 - empowering the smart home
   Loaded: loaded (/usr/lib/systemd/system/openhab2.service; disabled)
   Active: deactivating (stop) (Result: exit-code) since Sun 2017-11-26 17:16:26 GMT; 1s ago
     Docs: http://docs.openhab.org
           https://community.openhab.org
  Process: 30659 ExecStart=/usr/share/openhab2/start.sh server (code=exited, status=255)
 Main PID: 30659 (code=exited, status=255);         : 30838 (karaf)
   CGroup: /system.slice/openhab2.service
           └─control
             ├─30838 /bin/bash /usr/share/openhab2/runtime/bin/karaf stop
             └─30998 /usr/lib/jvm/java-8-oracle/jre/bin/java -Dopenhab.home=/usr/share/openhab2 -Dopenhab....

Nov 26 17:16:24 NAS systemd[1]: Started openHAB 2 - empowering the smart home.
Nov 26 17:16:24 NAS start.sh[30659]: Launching the openHAB runtime...
Nov 26 17:16:26 NAS start.sh[30659]: /var/log/openhab2/openhab.log (Permission denied)
Nov 26 17:16:26 NAS systemd[1]: openhab2.service: main process exited, code=exited, status=255/n/a
Nov 26 17:16:27 NAS stop[30838]: stop: Ignoring predefined value for KARAF_HOME

either the permissions are wrong or the file system is having problems?
check and post the result of:

ls -al /var/log/openhab2/

Hello. Thank you for your time. The output is :

drwxrwxr-x  2 root root  80 Nov 25 22:10 .
drwxrwxr-x 14 root root 800 Nov 27 00:17 ..
-rwxrwxr-x  1 root root   0 Nov 25 22:11 events.log
-rwxrwxr-x  1 root root   0 Nov 25 22:11 openhab.log

try

sudo chown openhab.openhab events.log openhab.log
1 Like

It’s ALIVE!. Thank you so much