Updated freenas.. settings lost

Running sonarr as a plugin on freenas and noticed there was an update earlier so ran the update and everything was fine.

Hadn’t updated the freenas software for a while so decided to do that just now. Freenas rebooted and now sonarr does not show any programmes in the series section, it appears my set up has reset itself.

The only setting remaining from before updating freenas is that of my indexer, nothing else exists.

Any explanation as to what has happened?

All settings and series are stored in the same database. As long as the FreeNAS plugin doesn’t delete its settings on upgrade and Sonarr’s App Data (logs, config, db) and actual app files (NzbDrone.exe) are separated then there should be no loss of data.

The fact that some of it is there (indexers), but series are not leads me to believe that the user that runs the plugin has changed so Sonarr is not able to find the settings and is loading settings from another user.

I’m not sure how FreeNAS plugins work, but if you’re able to connect via ssh/terminal and look for nzbdrone.db you should be able to get things under the correct user and running again (assuming it wasn’t removed).

Searching for nzbdrone.db shows it at 2 locations.

The first is at /var/db/sonarr…

root@sonarr_1:/var/db/sonarr # ls -la
total 183
drwxr-xr-x   6 media  media      14 May 22 11:08 .
drwxr-xr-x  11 root   wheel      14 Apr 27 21:37 ..
drwxr-xr-x   3 media  media       3 Apr 27 21:37 .mono
drwxrwxrwx   3 media  media       3 May 22 09:24 Backups
drwxr-xr-x   4 media  media      12 May  3 21:52 NzbDrone
-rw-r--r--   1 media  media     501 May 22 10:08 config.xml
drwxr-xr-x   2 media  media       3 Apr 27 21:37 logs
-rw-r--r--   1 media  media   13312 May 22 10:08 logs.db
-rw-r--r--   1 media  media   32768 May 22 10:08 logs.db-shm
-rw-r--r--   1 media  media  126840 May 22 11:25 logs.db-wal
-rw-r--r--   1 media  media  207872 May 22 11:08 nzbdrone.db
-rw-r--r--   1 media  media   32768 May 22 11:08 nzbdrone.db-shm
-rw-r--r--   1 media  media   76536 May 22 11:31 nzbdrone.db-wal
-rw-r--r--   1 media  media       4 May 22 10:08 nzbdrone.pid
root@sonarr_1:/var/db/sonarr #

but in this directory there is another called NzbDrone which shows…

root@sonarr_1:/var/db/sonarr/NzbDrone # ls -la
total 2578
drwxr-xr-x   4 media  media       12 May  3 21:52 .
drwxr-xr-x   6 media  media       14 May 22 11:08 ..
drwxr-xr-x  22 media  media       22 May  2 16:10 MediaCover
-rw-r--r--   1 media  media      501 Apr 27 21:57 config.xml
drwxr-xr-x   2 media  media        3 May  2 21:35 logs
-rw-r--r--   1 media  media  1326080 May  3 22:24 logs.db
-rw-r--r--   1 media  media    32768 Apr 27 21:57 logs.db-shm
-rw-r--r--   1 media  media  2009048 May  3 22:24 logs.db-wal
-rw-r--r--   1 media  media  2675712 May  3 21:58 nzbdrone.db
-rw-r--r--   1 media  media    32768 May  3 21:52 nzbdrone.db-shm
-rw-r--r--   1 media  media  3259312 May  3 22:33 nzbdrone.db-wal
-rw-r--r--   1 media  media        5 Apr 27 21:57 nzbdrone.pid
root@sonarr_1:/var/db/sonarr/NzbDrone #

is this how it should be?

No, that looks like something is changing Sonarr’s data folder and changed its mind where it should go at some point.

The DB in /var/db/sonarr/NzbDrone looks bigger, but /var/db/sonarr has a Backups folder.

Which path is Sonarr using when its running (check System: Status).

This is what the system info shows…

AppData directory /var/db/sonarr
Startup directory /usr/pbi/sonarr-amd64/share/sonarr/NzbDrone

Make a backup of /var/db/sonarr (just to be safe), then move the contents from /var/db/sonarr/NzbDrone to /var/db/sonarr and see if that restores the data thats now missing.

As i’m new to linux and not sure about backing up yet i just copied the sonarr directory contents to a new directory and then copied the NzbDrone dir contents to sonarr dir retaining permissions.

I started sonarr and the series list showed all my tv programs :slight_smile: i saw sonarr scanning the disk and once finished everything looks back to normal, calender showing this weeks programs has completed.

Many thanks :slight_smile:

1 Like