OH3 error creating /var/lib/openhab2/tmp/bundles question

Hello All, I was receiving this error:

2021-04-10 09:37:29.796 [ERROR] [org.apache.felix.fileinstall        ] - Cannot create folder /var/lib/openhab2/tmp/bundles. Is the folder write-protected?
2021-04-10 09:37:29.798 [ERROR] [org.apache.felix.configadmin        ] - [org.osgi.service.cm.ManagedServiceFactory, id=38, bundle=10/mvn:org.apache.felix/org.apache.felix.fileinstall/3.6.4]: Unexpected problem updating configuration org.apache.felix.fileinstall.fc092e7a-5ff2-483a-908f-41330800a177
java.lang.RuntimeException: Cannot create folder: /var/lib/openhab2/tmp/bundles
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.prepareDir(DirectoryWatcher.java:647) ~[?:?]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.prepareTempDir(DirectoryWatcher.java:627) ~[?:?]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.<init>(DirectoryWatcher.java:179) ~[?:?]
        at org.apache.felix.fileinstall.internal.FileInstall.updated(FileInstall.java:248) ~[?:?]
        at org.apache.felix.fileinstall.internal.FileInstall$ConfigAdminSupport$Tracker.updated(FileInstall.java:378) ~[?:?]
        at org.apache.felix.cm.impl.helper.ManagedServiceFactoryTracker.updated(ManagedServiceFactoryTracker.java:159) ~[bundleFile:?]
        at org.apache.felix.cm.impl.helper.ManagedServiceFactoryTracker.provideConfiguration(ManagedServiceFactoryTracker.java:93) [bundleFile:?]
        at org.apache.felix.cm.impl.ConfigurationManager$ManagedServiceFactoryUpdate.provide(ConfigurationManager.java:1253) [bundleFile:?]
        at org.apache.felix.cm.impl.ConfigurationManager$ManagedServiceFactoryUpdate.run(ConfigurationManager.java:1197) [bundleFile:?]
        at org.apache.felix.cm.impl.UpdateThread.run0(UpdateThread.java:138) [bundleFile:?]
        at org.apache.felix.cm.impl.UpdateThread.run(UpdateThread.java:105) [bundleFile:?]
        at java.lang.Thread.run(Thread.java:834) [?:?]

I did get rid of the error by creating:
/var/lib/openhab2/tmp/bundles and /usr/share/openhab2/addons.

I am curious if anyone possibly knows what could be causing openhab to look for these directories? I am running OH3 and I restored my OH2 backup. Everything is working fine even with this error.
I was trying to figure this out before moving from my files setup to a gui based setup.

Thanks!

That sound like an OS permissions error for the user running OH.

I would extract the backup into a temporary folder and then search in the content of the extracted files if /openhab2/ is being used in them.

Either

or

because of the parent directory /var/lib/openhab2 is not available and directories are not created recursively.

OH 3 users opehab directories and not openhab2.

If you restored OH2 backup I would guess they still refer to openhab2 ?

Cheers
Mark

Thanks for all the answers! I do believe something in my backup is referring to openhab2. This is what I am trying to find.

I may have to just restore bindings and things manually one at a time. This will immediately point out the problem when it hits.

Hi Danny did you find the issue?