I’m running now OpenHAB2 on my Pine64 (Fedora 27) for a couple of days and after some initial issues, things seem to get stable and reliable. Still I want to prepare for hardware breaks (e.g. dying SD card, etc.).
Therefore I’ve analysed the OpenHAB2 configuration, because that’s the thing I need to restore in case I want to recover from desaster.
So far I ended up in having tons of items, rules and a sitemap in text files and binding configs, things, items in the JSON DB. So for creating a backup of those, I have to save both.
First question: is there a way to store all configuration in either text files or JSON DB (not mixed)?
I’d prefer the JSON DB as storage location (because PaperUI can write that).
So how would I get rules and sitemaps into JSON DB?
Also is there a way to automatically move items from text files into JSON DB?
Second question: is there a way to export the complete OpenHAB2 configuration to a OpenHAB configuration file? I.e. a file, which can later be imported again and restores all binding configuration, things, items, rules, sitemaps, HabPanel pages, persistence, installed add-ons, etc.
Third question: How are you guys dealing with preparation for HW breaks?
You know, that a power-loss while writing to a file, might corrupt that file leaving you with nothing…