OH3 fails to startup

After some successfull testing of OH3, I tried to clean the cache (stopped openhab, openhab-cli clean-cache), restarting openhab results in the following:

2020-11-17 15:09:04.793 [SCHWERWIEGEND] [org.apache.karaf.main.Main] - Could not launch framework
java.lang.RuntimeException: Error initializing storage.
	at org.eclipse.osgi.internal.framework.EquinoxContainer.<init>(EquinoxContainer.java:70)
	at org.eclipse.osgi.launch.Equinox.<init>(Equinox.java:31)
	at org.eclipse.osgi.launch.EquinoxFactory.newFramework(EquinoxFactory.java:24)
	at org.apache.karaf.main.Main.launch(Main.java:256)
	at org.apache.karaf.main.Main.main(Main.java:178)
Caused by: java.io.FileNotFoundException: /var/lib/openhab/cache/org.eclipse.osgi/.manager/.fileTableLock (Keine Berechtigung)
	at java.base/java.io.RandomAccessFile.open0(Native Method)
	at java.base/java.io.RandomAccessFile.open(RandomAccessFile.java:345)
	at java.base/java.io.RandomAccessFile.<init>(RandomAccessFile.java:259)
	at java.base/java.io.RandomAccessFile.<init>(RandomAccessFile.java:214)
	at org.eclipse.osgi.internal.location.Locker_JavaNio.lock(Locker_JavaNio.java:36)
	at org.eclipse.osgi.storagemanager.StorageManager.lock(StorageManager.java:388)
	at org.eclipse.osgi.storagemanager.StorageManager.open(StorageManager.java:701)
	at org.eclipse.osgi.storage.Storage.getChildStorageManager(Storage.java:1776)
	at org.eclipse.osgi.storage.Storage.getInfoInputStream(Storage.java:1793)
	at org.eclipse.osgi.storage.Storage.<init>(Storage.java:132)
	at org.eclipse.osgi.storage.Storage.createStorage(Storage.java:85)
	at org.eclipse.osgi.internal.framework.EquinoxContainer.<init>(EquinoxContainer.java:68)
	... 4 more

Is there anything besides completly reinstall I could do about that?

This definitely looks like a bug and an issue should be filed. I think it should be filed on openhab-core. For some reason it looks like at least after the first time OH 3 starts, it expects there to always be that lock file in the cache. When you cleared the cache that file was deleted. Clearly OH should recreate that file when it doesn’t exist.

In the mean time, try manually creating an empty version of that file and see if OH get’s past that error. On Linux you can use the touch command. Make sure the ownership and permissions are for the openhab user.


Using openhabian-config menu 14 , (fix permissions) enabled a start again.


How can I run this in windows?

you can’t. openHABian is a Raspbian based image, so all tools that come with openHABian (such as openhabian-config) can only be run within openHABian.

Maybe it would be better if you tell us the problem you’re having.

And in a new thread, please. This issue you cannot have on Windows.
How to ask a good question / Help Us Help You - Tutorials & Examples - openHAB Community