Abruptly, my Plex Media Server on macOS no longer recognizes new content. The server logs (“Plex Media Server.log” and “Plex Media Scanner Matcher.log”) appear to show the new content being recognized and added but it remains invisible to clients, and running “Scan Library Files” from Plex Web shows it being found again and seemingly added again, but the addition must be failing.
I’ve “optimized” the DB and I’ve done a DB repair as described in the support document but the new misbehavior remains unchanged.
Existing content seems to play fine in clients but nothing new can be added.
There still seems to be database corruption. I found this in “Plex Media Server.log”:
Apr 12, 2022 15:57:45.511 [0x306df2000] ERROR - SQLITE3:(nil), 11, database corruption at line 66843 of [1b256d97b5]
Apr 12, 2022 15:57:45.511 [0x306df2000] ERROR - SQLITE3:(nil), 11, database corruption at line 66993 of [1b256d97b5]
Apr 12, 2022 15:57:45.511 [0x306df2000] ERROR - SQLITE3:(nil), 11, statement aborts at 9: [REPLACE INTO ‘main’.‘fts4_metadata_titles_icu_segdir’ VALUES(?,?,?,?,?,?)] database disk image is malformed
Apr 12, 2022 15:57:45.511 [0x306df2000] ERROR - SQLITE3:(nil), 11, statement aborts at 163: [update metadata_items set extra_data=? where metadata_type=? and library_section_id=? and id=?] database disk image is malformed
Apr 12, 2022 15:57:45.512 [0x306df2000] ERROR - Exception inside transaction (inside=1) (/data/jenkins/server/1787171776/Library/MetadataCollection.cpp:479): sqlite3_statement_backend::loadOne: database disk image is malformed
Apr 12, 2022 15:57:45.512 [0x306df2000] WARN - Caught exception while scanning Movies: sqlite3_statement_backend::loadOne: database disk image is malformed
Even though I repaired the DB as described in the support article.
If reparing a corrupted database fails, your best shot is to attempt restoring a database backup (use the following support article; TimeMachine backups of the database aren’t always safe to restore).