PaperUI, Control no longer showing items after power failure

  • Platform information:
    • Hardware: RaspberryPi
    • OS: Raspbian GNU/Linux 9 (stretch)_
    • Java Runtime Environment: Oracle Java
    • openHAB version: 2.2.0-1
  • Issue of the topic: Items missing from Control after power failure

Is there a way to repair / fix the links that the PaperUI control tab uses?
Due to a faulty UPS, my RPI restarted 3 times in quick succession. All seems to be working ok, with the exception of the Control tab in PaperUI.

Most of the items are now missing, however the locations remain. When I edit all the things that used to be in a location, and remove the location reference the Location heading disappears from the control tab. When I add a new Location, to an existing thing, or a new thing, this new location appears as a heading in the control tab, but the thing is not shown.

The odd bit, is that 6 Items still display correctly in the control tab, I can remove them from a location and add them back to the same location, but when I add them to one of the other locations they do not appear.

I cannot find a post that addresses my issue, but thought I could try something similar to the suggestion from Dim Angelos (5th post) in this thread All Things Added with Paper UI gone, but for the Control tab, and not the Things tab.

I have had this happen twice, before I had the UPS, and ended up having to rebuild the whole OH2 installation. Would prefer not to do that again if it can be avoided.

Can anyone help me?

Edit: Not sure if this will help, but I happened to go to the Habmin UI (I never use it, so not sure why I looked there) and saw that the Items that are still working in the control tab are shown differently to the others. The working items are shown in the white block. When I try click on the greyed out items, my cursor turns to a “No Entry” icon.


Could be damaged SD card.
Get a fresh one
Clean vanilla install
Copy the files to the new one. DO NOT DO A BACK UP AND RESTORE. As you will be copying the corrupt bits too.
Sounds much, but you’ll be done in an hour

Your file system is probably toast. Your jsondb is likely corrupted. During one of the power losses, it was probably writing out to it during one of the power outages.

You may not need to rebuild, though I would as there might be other corruptions, and your SD card is probably physically fine. This isn’t a wear issue. Note, this would have been a problem for any storage medium in a power loss. It is not SD card specific.

If you want to risk continuing without a rebuild, you can stop OH and look in /var/lib/openhab2/jsondb. You should see a number of files and a backup folder. Save a copy of the files in jsondb and copy over the most recent backups for each of those files from the backup folder (make sure the filenames match, the files in the backup folder have a timestamp prepended to the filename). Start OH back up and cross your fingers. If it still show the problem, work yourway backwards through the backups until it works or your run out of backups.

Thanks for the advice Rich & Vzorglub. Based on what you have said regarding data corruption, I wont waste time chasing repair attempts. I will rather restore an SD card image I made in November.