My Music Library disappeared in Plex, for seemingly no reason at all?

I’m using the latest version of Plex Media Server on Windows 11 (all latest updates). There was a PMS software update in the past few days (which might have been released longer ago, I just didn’t notice it until earlier this week). It may or may not be related, but all of the albums in my Music library disappeared in Plex this morning (I only use Plex for music, not TV or video) so that when I search my library, nothing is found. The files are still on the SSD, but Plex thinks my Music Library is empty. I tried restarting my PC, no difference. I don’t use any other apps that access the drive where the music is stored, and there’s nothing on the drive except my music library, and I haven’t touched anything on it in weeks – no songs added to library, no files modified on drive, etc. It was working fine last night, now this morning Plex thinks the library is empty.

Right now I chose to re-scan the library, which seems like it’s going to take hours (I hope it doesn’t have to do Sonic Analysis again too!!!).

I’m wondering

  1. Why this might happen, so I can prevent it in the future? Is there some way to restore a lost library quickly, within minutes not hours?

  2. Why does it need to re-scan the library? I feel like in this situation, there should be a backup file or something that it references, so that it can see that the library is the exact same as it was yesterday when everything was working. File modification dates haven’t changed in several weeks? Use the existing database.

With 80,000 songs to scan, this kind of bug is supremely annoying.

In that case just restore your library from a backup, and you wont need to rescan.

There are a number of reasons you could have emptied your database, the most common is the drive was inaccessible when the scan was performed and you had the empty trash option enabled during library scan.

Damn, is emptying the trash after scan the default? That option was enabled, but I don’t think there’s any reason I would have enabled it intentionally.

Yes there was a moment where the drive was unmounted while PMS was running (but not playing any music). So I guess that’s what happened.

To backup the library, is that something that I have to do manually, or does PMS have an option to do daily backups automatically or whatever?

Is there any chance I can cancel this scan and restore it from yesterday’s library, or is that gone if I didn’t specifically initiate a backup?

Updates are done automatically, every night.
https://support.plex.tv/articles/202485658-restore-a-database-backed-up-via-scheduled-tasks/

You should keep this checkbox cleared, if your media are stored outside your server machine. Be it on external hard drives or network file shares.

Yes see Otto’s link above, its a simple process

Thanks! I was able to restore the backup from yesterday. Whew!

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.