Slow Query time - unable to scan or play media

Plex is installed on an NAS which seems unable to fix the file directly so I’m having to transfer the db file to a desktop computer that doesn’t have plex installed to try and fix the file from there.

What might be the solution is to install Plex Server on the desktop (without running) so I can access the sql repair file

1 Like

Precisely. Sorry, I forgot to mention this.

1 Like

Right, finally got the longer sql to execute on the file but only seemed to take it down about 1mb and I ran the test query and results are the same, still got one file with over 1m extras.
As an alternative is there a way to purge all records of that file inc extras, titles and things. If there is I can go through each record with high extras move the file, purge the record and then put the file back. Doing it that way it could potentially just shrink the database as the records are gone and then refresh metadata properly once the file is replaced as it will re download the data. Longwinded way round but main one is the 1m extras one.

@John-C-B
Did you run this query for me ? and establish which version of Plex Media Server was running on the 24th October ?

Before running the sql.txt sqlite3 transaction - did you actually run the step 2 action quoted in this linked post Slow library performance due to increasingly growing database - #28 by shayanzadeh

which would be
DELETE FROM metadata_relations WHERE metadata_item_id = '45323';

1 Like

Yep, you got it, I didn’t even see step 2 but I’ve now run all commands (eliminated all others on my list as well). Database has now gone from 3.4gb to around 350mb and does seem to be running faster now.

Thanks

1 Like

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