There was an issue loading your database error after restore

I’m trying to restore from backups from an Ubuntu Core (current version) to a Windows Cored (current version). I get an error “There was an issue loading your database”. Any ideas?

Look into the logs on the Windows machine and see if there is some more information about why it is failing.

Here are my logs. I even launched the Roon process as administrator. Not sure to what’s going on.

11/22 20:35:37 Info: Starting Roon v1.8 (build 831) stable on windows
11/22 20:35:37 Info: [URI] Checking that FriendlyAppName == Roon
11/22 20:35:37 Info: Registering for URI scheme: Roon, roon
11/22 20:35:37 Info: URI scheme executable path remains “C:\Users\admin\AppData\Local\Roon\Application\Roon.exe” “%1”
11/22 20:35:37 Trace: Checking if we are already running
11/22 20:35:37 Trace: Nope, we are the only one running
11/22 20:35:37 Info: Is 64 bit? True
11/22 20:35:37 Trace: [orbit] init seq=288, pending=47, spcount=7, uidcount=2
11/22 20:35:38 Critical: Failed to restore backup. Your databaes may be in a corrupt state. This can most likley be recovered by Roon Support. System.Exception: FAILED TO MOVE EXISTING DIR TO RESTOREOLDDIR: C:\Users\admin\AppData\Local\Roon\Database => C:\Users\admin\AppData\Local\Roon.restore_old\Database —> System.IO.IOException: Access to the path ‘C:\Users\admin\AppData\Local\Roon\Database’ is denied.
at System.IO.Directory.InternalMove(String sourceDirName, String destDirName, Boolean checkHost)
at Sooloos.Client.ApplicationCommon.Init2(String[] argv, Boolean supportupdates, String lockname)
— End of inner exception stack trace —
at Sooloos.Client.ApplicationCommon.Init2(String[] argv, Boolean supportupdates, String lockname)

Why, that is not needed as Roon is installed in a users directory. By doing so it is more likely to create issues than to solve some. You need to install and use Roon with the same user account.

In short: Access denied.

I checked the permissions and they are okay. I even copied all backup folders to a local drive and then did the restore. I’ll perform a force permissions inheritance…

below is the error I see when it tried to load the DB. I triple checked permissions… I even pushed them down to each subfolder/file.

11/22 21:48:10 Critical: Library.EndMutation: System.NullReferenceException: Object reference not set to an instance of an object.
at Sooloos.Broker.Metadata.Module.GetCachedTrackLite(Sooid mediasooid, Nullable1 max_age) at Sooloos.Broker.Music.Library.GetTrackLite(Nullable1 opt_brokerid, Int64 mediaid)
at Sooloos.Broker.Music.PlaylistItem…ctor(LibraryMutationEnv env, LoadPlaylistItem item)
at Sooloos.Broker.Music.Playlist.<>c__DisplayClass61_0.<.ctor>b__0(LoadPlaylistItem item, Int32 i)
at System.Linq.Enumerable.d__52.MoveNext() at System.Collections.Generic.List1…ctor(IEnumerable1 collection) at System.Linq.Enumerable.ToList[TSource](IEnumerable1 source)
at Sooloos.Broker.Music.Playlist…ctor(LibraryMutationEnv env, LoadPlaylist playlist)
at Sooloos.Broker.Music.PlaylistManager.Load()
at Sooloos.Broker.Music.Library.EndMutation()
11/22 21:48:10 Trace: [library] endmutation in 2086ms
11/22 21:48:10 Info: [music] first pass through media thread is done
11/22 21:48:10 Info: [loadstatus] IsLibraryLoadFailed False => True
11/22 21:48:10 Critical: scx: LevelDb.Exception: IO error: C:\Users\admin\AppData\Local\Roon\Database\Core\c88a3839d9954008b3fa30fca934cdc3\broker_2.db\018767.ldb: Reached the end of the file.

at LevelDb.Database._CheckError(IntPtr err)
at LevelDb.Database.d__39.MoveNext()
at LevelDb.KeySpace.d__26.MoveNext()
at Sooloos.Broker.Metadata.MetadataObjectDatabase.MigrateIfNeeded(KeySpace ks)
at Sooloos.Broker.Metadata.Module.Init(Database db)
at Sooloos.Broker.State._InitMediaThreadAsync()
at Sooloos.SynchronizationContextThread._Dispatch(SendOrPostWrapper& ret)

This means you can no longer start Roon? You are now unable to load a backup?

Correct. Roon does not start after performing a restore. The restore percentage / progress completes but I get the ‘There was an issue loading your database’ when opening Roon after the restore.

So this is after you changed permission and used Roon to successfully (as reported by Roon) load a backup?

Sorry but as just another user, I’m out of ideas. Messing around with rights and permissions in system folders (‘C:\Users’) controlled by Windows should not have been needed in the first place. Maybe it’s best you start all over. Did you follow the guides?

If your old core is still available, you can also try to create an on-demand backup just for the purpose of moving your core.

If I could just restore my tags I’ll be okay. Is there a way just to restore those? I’ll also put back in my old M.2 SSD disk with my Linux Roon Core … I can manually run a backup again… And try another restore. I kept my old disk so easily done.

Also,

If I remove C:\Users\admin\AppData\Local\Roon\Database\Core\c88a3839d9954008b3fa30fca934cdc3\broker_2.db\018767.ldb: Reached the end of the file. from the restore it boots, however, my tags are gone… hahaha… This is the only thing I really want…

Do you use the same Roon account on both machines, the old core and the new one?

grafik

yes. My Roon account is the same and is authenticated properly. I also authenticated to my Qobuz account.

I installed my old M.2 SSD disk and performing a backup to the local storage. Once done I’ll try another restore. brb…

I got it to work. I did a new backup to the local disk… Then copied it to my new host and it restored just fine. My previous scheduled backups show successful, however, they where over the LAN. Maybe something happened when storing on the remote Linux NAS… Going forward I’ll backup to my local disk… Thanks!

1 Like