Database Corruption - Plex SQLite Tool Missing

Server Version#: 1.24.5.5173
Player Version#: Irrelevant

I’ve been dealing with an issue related to content not playing consistently across devices, specifically in my movies library. My troubleshooting has led me to believe that I have a corrupt Plex DB. I am running Plex in an Unraid docker. I have tried to follow Spaceinvader One’s video on fixing a corrupt Plex DB but an experiencing something odd. When I attempt to dump and then re-add a new DB with my old DB’s settings, I can see the file start filling up with data via Krusader, but right before the new DB finishes compiling the file goes from 1.4gb down to 0, and I don’t receive any error indicating what’s going on. I do successfully run a PRAGMA integrity_check, and I’m getting an “Error: database disk image is malformed”, but the restoration commands seem to be failing.

Because I’ve been having this trouble, I decided to do a fresh install of Plex on my Mac and my PC to attempt copying the DB there and doing the recovery commands. However, on both my Mac and PC, when I install PMS I don’t have a Plex SQLite tool in the installation directory. I attempted to copy this EXE from a friend’s PMS installation, but it is unsuccessful. In fact, every time I attempt to run the PLex SQLite PRAGMA integrity_check, rather than doing the DB check it launches PMS on my PC. I’ve hit a rock wall and need some help from someone who may be able to dump/create a new db from my old one. I have been trying to get this to work for weeks with no progress whatsoever. I need someone to help me try and recover this DB.

Through a friend, I was able to attempt a fix of the database using the manual steps found here:

Unfortunately the repaired database file acted the same on PC as it did on Unraid, the file was created but with 0kb, while the original DB file was around 1.5gb. I am at a complete loss and hope a dev has some insight as to what I can do here.

How long ago did it first happen? Have you tried to restore a database backup?

The problem began a few months back and I honestly never thought this was a database issue until Spaceinvader’s video a few weeks ago. I began by exploring video codecs, library differences, transcoding vs direct play, indirect play, file sizes, etc and the database being the issue never crossed my mind because I never got an error log stating that was a potential source of the problem. Certain movies would play for one user but not another, then I’d attempt to have someone try a file on multiple platforms (Xbox, Roku, Apple TV) and the results were always wildly random/inconclusive, so database issues didn’t occur to me.

At the point the Spaceinvader video came out, I was able to run the PRAGMA integrity_check which revealed the "Database disk image is malformed error. The only backups present are from the past few days, I don’t have anything going back far enough to try.

This is the specific error I receive when running integrity_check

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