Plex instructions for repairing database on MacOS

Hi, in the support article “Repair a corrupt database” for MacOS, if I follow the instructions verbatim, the command: sqlite3 com.plexapp.plugins.library.db "DROP index ‘index_title_sort_naturalsort’"
has always failed with: Error: no such index: index_title_sort_naturalsort

I feel like I’m missing something obvious in the instructions, like it has to do with renaming the file database file with “original”. I’m missing a step here that’s preventing me from running the repair.

if anyone knows what I’m talking about/has any suggestions I’d be very grateful. It’s been driving me nuts and I’m hoping to avoid having to reinstall a fresh copy of PMS (I believe the corruption started before my oldest backup). Thanks much

Hi @MeatBall,

What are the symptoms you observe for a corrupt database on MacOS? I’m wondering because I think I’m having Plex database problems as well.

Thanks,
JMC

Hi, I think symptoms of A corrupted dB can manifest in a lot of different ways, like crashing would be big one. I’m not an expert but have run Into it a couple times through the years. The good part is it’s very easy to resolve as plex makes backups so if I’m doubt, shut didn’t PMS and restore a previous version.

The thing to be aware of is if you suspect it, restore an older version quickly. Plex keeps 5 (I think) previous versions but if you don’t move quickly enough, Pms will start backing up previous versions that were corrupted and you won’t have a clean version to restore from. That’s where you run into a situation where you try to repair it. Otherwise you have to delete the database and rebuild your libraries.

What are you seeing that makes you think yours is corrupted?

Sometimes Plex becomes unresponsive and other times it takes 2 or 3 tries to get a file playing. Or a combination of both, which is worse. I’ll try to play a file, it takes a long time and finally doesn’t work, then Plex is unresponsive, then I can reach it again and try to play the file, it won’t play after awhile, then I try again and finally the file may play. All told that can take 20-30 minutes when i’m just trying to watch a 20 minute show. It gets ridiculous.

So, because of that I started watching the console and I see Errors and Warnings about bad sql queries and slow queries so I’m wondering if something isn’t right about the database. I had started a thread here yesterday and someone responded with guidance so I’m going to check things out this morning.

certainly doesn’t hurt to restore an older version. try it and see if the issue repeats. What kind of console/SQL errors are you seeing?

I’ve been talking about it and taking steps over in this thread:

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