Closed olluz closed 3 years ago
Which version of the tool are you running?
GUI v 1.0.3 Running version: 1.5.6b
Strange. Which Plex version are you running? Are there any anomalities in the log after it wrecks the DB? I can't diagnose this from afar but if you send me a corrupted database I can take a look at it.
Something in the line of:
Jun 24, 2021 23:38:07.117 [0x7f0054256b38] ERROR - Unknown metadata type: folder Jun 25, 2021 00:02:49.942 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, database corruption at line 67162 of [1b256d97b5] Jun 25, 2021 00:02:49.942 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, statement aborts at 14: [select grandparents.id from metadata_items INDEXED BY index_metadata_items_on_library_section_id_and_metadata_type_and_added_at join metadata_items as parents on metadata_items.parent_ Jun 25, 2021 00:02:49.942 [0x7f0055174b38] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed Jun 25, 2021 00:02:50.028 [0x7f0054365b38] INFO - AutoUpdate: no updates available Jun 25, 2021 00:02:56.492 [0x7f0054365b38] ERROR - SQLITE3:0x80000001, 11, database corruption at line 67162 of [1b256d97b5] Jun 25, 2021 00:02:56.492 [0x7f0054365b38] ERROR - SQLITE3:0x80000001, 11, statement aborts at 14: [select grandparents.id from metadata_items INDEXED BY index_metadata_items_on_library_section_id_and_metadata_type_and_added_at join metadata_items as parents on metadata_items.parent_ Jun 25, 2021 00:02:56.492 [0x7f0054365b38] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed Jun 25, 2021 00:02:57.263 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, database corruption at line 67162 of [1b256d97b5] Jun 25, 2021 00:02:57.263 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, statement aborts at 14: [select grandparents.id from metadata_items INDEXED BY index_metadata_items_on_library_section_id_and_metadata_type_and_added_at join metadata_items as parents on metadata_items.parent_ Jun 25, 2021 00:02:57.264 [0x7f0055174b38] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed Jun 25, 2021 00:02:59.447 [0x7f0054365b38] ERROR - Unknown metadata type: folder Jun 25, 2021 00:02:59.447 [0x7f0054365b38] ERROR - SQLITE3:0x80000001, 11, database corruption at line 67162 of [1b256d97b5] Jun 25, 2021 00:02:59.447 [0x7f0054365b38] ERROR - SQLITE3:0x80000001, 11, statement aborts at 7: [select distinct metadata_items.id from metadata_items where metadata_items.library_section_id in (1) and metadata_items.metadata_type=2 order by metadata_items.title_sort] database di Jun 25, 2021 00:02:59.448 [0x7f0054365b38] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed Jun 25, 2021 00:03:20.930 [0x7f0055174b38] INFO - AutoUpdate: no updates available Jun 25, 2021 00:03:21.275 [0x7f0054365b38] ERROR - Unknown metadata type: folder Jun 25, 2021 00:03:21.276 [0x7f0054365b38] ERROR - SQLITE3:0x80000001, 11, database corruption at line 67162 of [1b256d97b5] Jun 25, 2021 00:03:21.276 [0x7f0054365b38] ERROR - SQLITE3:0x80000001, 11, statement aborts at 7: [select distinct metadata_items.id from metadata_items where metadata_items.library_section_id in (1) and ((metadata_items.metadata_type=2 or metadata_items.metadata_type=18) and (metad Jun 25, 2021 00:03:21.276 [0x7f0054365b38] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed Jun 25, 2021 00:03:21.287 [0x7f0055174b38] ERROR - Unknown metadata type: folder Jun 25, 2021 00:03:21.287 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, database corruption at line 67162 of [1b256d97b5] Jun 25, 2021 00:03:21.287 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, statement aborts at 7: [select distinct metadata_items.id from metadata_items where metadata_items.library_section_id in (1) and ((metadata_items.metadata_type=2 or metadata_items.metadata_type=18) and (metad Jun 25, 2021 00:03:21.288 [0x7f0055174b38] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed Jun 25, 2021 00:14:50.339 [0x7f0055174b38] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring. Jun 25, 2021 00:14:50.339 [0x7f0055174b38] WARN - QueryParser: Invalid field 'libraryHubsOnly' found, ignoring. Jun 25, 2021 00:14:50.339 [0x7f0055174b38] WARN - QueryParser: Invalid field 'sectionID' found, ignoring. Jun 25, 2021 00:14:50.340 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, database corruption at line 67162 of [1b256d97b5] Jun 25, 2021 00:14:50.340 [0x7f0055174b38] ERROR - SQLITE3:0x80000001, 11, statement aborts at 10: [select distinct metadata_items.id as 'id', parents.id as 'parent_id', grandparents.id as 'grandparent_id', metadata_items.added_at as 'added_at', metadata_items.library_section_id as ' Jun 25, 2021 00:14:50.340 [0x7f0055174b38] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed
Can I send you the database to your private email address ? The one from your website ?
Yeah just send it to my private email, if possible also try to send a non-corrupted version. It would also be interesting if you could find out the Plex version you're using.
Okay here's an update on this:
The version you sent me that is not corrupt is already reporting Error: no such collation sequence: icu_root
on a PRAGMA integrity_check;
However I think theres a way to solve this without using their command line version (which would cause a really ugly configuration mess for the average user and likely tons of issues just waiting to be uncovered in the future...). It is probably the same fix as for #56 which involves deleting and then re-adding a trigger that causes the trouble because it's Plex's own messy creation that is not supported by the standard SQLite3 implementation and somehow wrecks havoc when absent.
1.5.7 should fix this. In your case I did run "C:\Program Files (x86)\Plex\Plex Media Server\Plex SQLite.exe" com.plexapp.plugins.library.db "PRAGMA integrity_check"
on the Database_before.zip DB before trying it out. It reported ok.
After using the new version with the fix the ratings did update and Plex did not cause any issues. Running the validation command again also promted an ok.
The reason of the corruption was probably two newly added triggers that had no mitigation yet. Could you confirm if 1.5.7 works on your side?
I've tested with v1.5.8 but it is still crashing the database
@olluz You should try this with v1.6.0 and GUI v1.0.4. Configure it like in this screenshot and let me know if it worked now without corruptions.
Thanks for you update. I've finally managed to test the version: And it works with the settings you provided. But how do I get TV Shows to show IMDB ratings ? If leve it like that then I will not have IMDB ratings. If I add the ID of the TV Show it will unfortunately, corrupt the database again. Is this setting not correct ?
@olivernovakovic Is this still happening btw? Or has this been resolved so far?
yes, it this is still the case for me :(
And you're using the native plex sqlite binary option? @olivernovakovic
Sorry for the late reply. I've tested it again with the plex sqlite binary option and can confirm: it's working now! Thanks a lot again for your help & support
Thanks for this tool and sorry for posting this as an issue.
What exactly I need to do/configure for this tool to not wreck my library ? I have opted-in with the ID. I've added v3 TMDB and v3 TVDB API keys. Is there anything else I need to do ? Do I need to set the new TV Show agent to TVDB or TMDB ?
After running this tool the database is corrupted.
Thanks