I made my way through installation of OH2 2.0.0.b2 on a vanilla Synology Diskstation DS214play (Intel Atom CE5335 2x1,6GHz, 512MB RAM) on DSM 5.2 with all your help here which was adventure of its own. OH2 is now up and running, bindings are also well working. Nice work!
However, OH2 doesn’t seem to automatically reload conf files. I have to configure a lot in .items, .sitemap, and .rules and I have to manually shutdown OH2 on its console and restart the OH2 server (which takes around 2 minutes) everytime I do changes on any of the files.
Is there a way to configure auto reload or to enforce reload on the console?
In the console you can type log:tail to see what OpenHAB is actually doing. Sitemaps, Items, Rules, etc, etc, should be reloaded upon change in OpenHAB2b2. At least, that is working just fine on my setup.
That helps.This means that my setup (or the Synology package) is broken. I am using log tail all the time using the debug start script but there is no indication about rereading any config. When I change my conf files and wait for 30minutes, there is no change propagated.
In a working environment, is there a log entry once a new config is (re)read?
But I have to say, that I edit my config files via an AFP-Share and thought about something that checks the filechange which will not be triggered by the changes made via a network share.
But even if I “touch” the files on the CLI where I run OH2 nothing is reloaded according to the log.
you mentioned problems with symlinked config/models? I discovered the same issue today and I’am able to confirm your observation. I have my OH-config folder symlinked to another folder because i’m using docker and i need a persistent folder. Refreshing the models without symlink works perfect, but it fails with a symlink.
I have investigated this problem and found out, that OH2 uses Eclipse Smarthome AbstractWatchService. See
The problem is the WalkFileTree which ignores per default symlinks. FileVisitOption.FOLLOW_LINKS should passed into the Walker.
I will start a discussion on github and prepare a PR.
Thx for the hint with the symlinks
Thank you very much for sharing the link. I did NOT read that before.
" The : prepended to each configuration property is removed in the new .cfg files."
By this line, it seems “folder:sitemaps=10,sitemap” should be put in something like folder.cfg without folder: prepend. Am I correct to say that?
If so, as I do not find folder.cfg, should I create a blank folder.cfg? Or is there any extra steps I should go through?
Hello, you seem to have another problem clouding your experience.
You do not need the folder.cfg. Delete it.
OH2 reloads sitemaps automatically. Normally you just have to refresh the page after 2-3 seconds.
Your example looks valid. I expect the error to be some place else. Please have a close look at the log while you are editing the sitemap file. Here is one example you could add to hopefully see a successful change:
Text label="Testing Refresh..."
Which version of openHAB2 are you on / when did you set it up?