There was an unexpected error loading the dashboard

How do I fix this, this is happening on my iMac and ATV4
I can’t see my tv shows or movies unless I know the specific one and do a search on it. with the ATV4. can’t see the playlist. with my web I don’t see the dashboard but able to see the playlist on the left-hand side.

it could be a timeout of the request to load the dashboard content.
A database optimization has been seen to resolve this for some users - see this support page
https://support.plex.tv/hc/en-us/articles/201420066-How-can-I-make-On-Deck-appear-faster-

If this does not resolve the problem, then would need plex web app log and also Plex media server.log
See
https://support.plex.tv/hc/en-us/articles/201643703-Reporting-issues-with-Plex-Media-Server
https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files
https://support.plex.tv/hc/en-us/articles/201611836-Plex-Web-App-Logs

I am not sure which logs you need to see, there are a few in the folder! This is not just happening on my server also happening to someone else I know right after the latest update. after that poof no folder or anything on the apple tv and web just has this error on it. The reason I got the apple tv is that it had plex on it.

@dishers said:

I am not sure which logs you need to see, there are a few in the folder! This is not just happening on my server also happening to someone else I know right after the latest update. after that poof no folder or anything on the apple tv and web just has this error on it. The reason I got the apple tv is that it had plex on it.

The screenshot is of plex web returning this error and that is what we are dealing with here and not Apple TV.

The linked support pages inprovided links for explain how to enable debug logging for plex media server and restart the server and akso how to enable logging for the plex web app.

Once all logging is enabled and server restarted and when problem arises then there are two sets of logs to get. The Plex Media Server.log file and the plex web app log and these together with a screenshot showing the error and url and time of error

I have the same issue. Anyone find a way to fix it?

@ElusiveX said:
I have the same issue. Anyone find a way to fix it?

It could be several reasons for this to happen. Database fragmentation leading to excessive times to return results (needs database optimization), database corruptions. Other reasons - would need the logs to establish the cause

See my earlier post https://forums.plex.tv/discussion/comment/1166086/#Comment_1166086

how would I optimize the database?

@dishers said:
how would I optimize the database?

See this support page https://support.plex.tv/hc/en-us/articles/200392106
It is referenced from here https://support.plex.tv/hc/en-us/articles/201420066-How-can-I-make-On-Deck-appear-faster-

Message says There was a problem optimizing the database

@dishers said:
Message says There was a problem optimizing the database

Sounds like there may be database corruption. To find out what the issue is and if it is database corruption,
Enable Debug Logging, restart the server and then do the optimize and when you get the error find the Plex Media Server.log and attach it here.

See these support pages
https://support.plex.tv/hc/en-us/articles/201643703-Reporting-issues-with-Plex-Media-Server
https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files

I hope I did this correct.

@dishers said:
I hope I did this correct.

There is database corruption

Apr 19, 2016 09:52:16 [0x7000011fa000] ERROR - SQLITE3:0x7000005b12c0, 11, database corruption at line 67420 of [8a8ffc862e]
Apr 19, 2016 09:52:16 [0x7000011fa000] ERROR - SQLITE3:0x7000005b12c0, 11, statement aborts at 16: [select metadata_items.id from metadata_item_settings join metadata_items on metadata_items.guid=metadata_item_settings.guid and metadata_item_settings.account_id=? where  view_offset>0
Apr 19, 2016 09:52:16 [0x7000011fa000] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed

and

Apr 19, 2016 09:52:19 [0x7000011fa000] ERROR - SQLITE3:0x7000005b12c0, 11, database corruption at line 67420 of [8a8ffc862e]
Apr 19, 2016 09:52:19 [0x7000011fa000] ERROR - SQLITE3:0x7000005b12c0, 11, statement aborts at 16: [select metadata_items.id from metadata_item_settings join metadata_items on metadata_items.guid=metadata_item_settings.guid and metadata_item_settings.account_id=? where  view_offset>0
Apr 19, 2016 09:52:19 [0x7000011fa000] ERROR - Soci Exception handled: sqlite3_statement_backend::loadRS: database disk image is malformed

Optimization failed and most likely to do with the corruption

Apr 19, 2016 09:53:22 [0x700000de2000] DEBUG - Database optimization: Rebuilding full text search tables.
Apr 19, 2016 09:53:23 [0x700000de2000] WARN - Held transaction for too long (/Users/admin/jenkins/pms-r-build/BUILD_TAG/darwin-x86_64/Library/FullTextSearch.cpp:16): 1.300000 seconds
Apr 19, 2016 09:53:24 [0x700000de2000] WARN - Held transaction for too long (/Users/admin/jenkins/pms-r-build/BUILD_TAG/darwin-x86_64/Library/FullTextSearch.cpp:26): 0.500000 seconds
Apr 19, 2016 09:53:25 [0x700000de2000] WARN - Held transaction for too long (/Users/admin/jenkins/pms-r-build/BUILD_TAG/darwin-x86_64/Library/FullTextSearch.cpp:35): 1.580000 seconds
Apr 19, 2016 09:53:26 [0x700000de2000] WARN - Held transaction for too long (/Users/admin/jenkins/pms-r-build/BUILD_TAG/darwin-x86_64/Library/FullTextSearch.cpp:45): 0.700000 seconds
Apr 19, 2016 09:53:26 [0x700000de2000] DEBUG - Database optimization: starting.
Apr 19, 2016 09:53:27 [0x700000de2000] ERROR - SQLITE3:0x7000005b12c0, 1555, abort at 6 in [INSERT INTO vacuum_db.'metadata_item_views' SELECT * FROM main.'metadata_item_views';]: UNIQUE constraint failed: metadata_item_views.id
Apr 19, 2016 09:53:27 [0x700000de2000] ERROR - SQLITE3:0x7000005b12c0, 19, statement aborts at 2: [vacuum] UNIQUE constraint failed: metadata_item_views.id
Apr 19, 2016 09:53:27 [0x700000de2000] ERROR - Soci Exception handled: sqlite3_statement_backend::loadOne: UNIQUE constraint failed: metadata_item_views.id
Apr 19, 2016 09:53:27 [0x70000073b000] DEBUG - Completed: [127.0.0.1:60988] PUT /library/optimize (7 live) GZIP 5384ms 441 bytes 500 (pipelined: 13)

Have a look at the Repair Corrupt Database support page to see if the corruption can be repaired
https://support.plex.tv/hc/en-us/articles/201100678-Repair-a-Corrupt-Database

Other options to consider is restore the database from a good backup
See https://support.plex.tv/hc/en-us/articles/202485658

The database file is
/Users/sarahdisher/Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db

working now, thank you so much for helping me out. Cheers

I am also having the same issue. But it occurred after last update. I went to repair the corrupt database but is was missing 1 of the 2 files. I went ahead with getting the other db file to show up, but I didnt have any backups and this happened after it said it was backing up o update. S where did they go then?

@satori83 said:
I am also having the same issue. But it occurred after last update. I went to repair the corrupt database but is was missing 1 of the 2 files. I went ahead with getting the other db file to show up, but I didnt have any backups and this happened after it said it was backing up o update. S where did they go then?

Some detail please - preferably starting from the beginning by providing log file Plex Media Server.log and indication as to which file is missing. The database should get automatically backed up by Scheduled Tasks every 3 days - if there is corruption that it would not back it up but you should have back up from before that.

it said it was backing up o update. S where did they go then?

what said ? where ? and what is o and S ? and which files are you referring to?

I am actually having the same error since the last update. DB optimization doesn’t seem to do anything.

Same error on web console and Apple TV is timing out.

@darkansi@gmail.com said:
I am actually having the same error since the last update. DB optimization doesn’t seem to do anything.

Same error on web console and Apple TV is timing out.

Could be database corruption

Get a Plex Media Server.log with debug logging enabled and server restarted after that and then reproduce the problem
See https://support.plex.tv/hc/en-us/articles/201643703-Reporting-issues-with-Plex-Media-Server
https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files

I had same error when clicking on Program Guide. So I enabled logging. Of course after enabling logging the Program Guide loaded without error. Any suggestions?

@hockney said:
I had same error when clicking on Program Guide. So I enabled logging. Of course after enabling logging the Program Guide loaded without error. Any suggestions?

Plex Media Server log files covering the time when the issue arose and now may help

Plex Media Server.5.log is the oldest log file
Plex Media Server.4.log is the one after that
and Plex Media Server.log is the latest log file
So 6 log files are available - if they go back to time of problem, please zip these logs and attach and indicate when the problem arose

See my previous post re location of log files

@hockney said:
I had same error when clicking on Program Guide. So I enabled logging. Of course after enabling logging the Program Guide loaded without error. Any suggestions?

One more thing - this error arises mostly when the database needs to be optimized. Scheduled Tasks do get the database optimized - so this may have happened