Unable to access Libraries after server update

Server Version#: 1.26.0.5715
Player Version#: 4.76.1
I updated my ubuntu server and plex install last night. When I try to go to one of my libraries, doesn’t matter which player, it fails to load.

In the console, I see two errors, that each happen twice.
Unknown metadata type: folder
Exception handled: std::bad_cast

Do you also have a synology as your media source?

I am doing maintenance on them both this morning and my movies library was not accessible. TV and music were fine.

Ended up hard rebooting the synology first, waiting a couple minutes, then hard rebooting my plex server. Just an idea if you have a synology.

I do use a Synology for my media storage. I logged into the vm the plex server is on and the NFS connection works and I was able to access all the files. I tried rebooting both and still the same issue.

The Console errors are meaningless.

What’s really needed are the PMS log files

  1. Stop Plex
  2. Manually make a tar.gz of /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Logs (as root)
  3. Attach the tarball here

Plex Media Server Logs_2022-04-23_14-18-24.zip (1.8 MB)
Here is the log files downloaded from inside plex which I assume are the same.

Thanks. Roll back to a previous version for now. Expect it to take time to downgrade (just like it did upgrading).

I’m testing this now myself and not having anything good come of this Beta release.
I’ve reported my findings to Engineering. They will probably look at it on Monday

Can you report back here if the downgrade fixes it?

I’m worried about this:

Apr 23, 2022 14:13:06.242 [0x7fa91a11ed48] ERROR - Exception thrown during migrations, aborting: sqlite3_statement_backend::loadOne: database disk image is malformed

My concern is that this implies the database file itself has been damaged, which is possibly why the migration didn’t succeed in the first place, and a down-migration is equally unlikely to repair it.

I would be inclined to perform the Check for Corruption steps from here: Repair a Corrupted Database | Plex Support

I would also be inclined to check the backups (instructions here) using the same Check for Corruption instructions.


@ChuckPa, what do you think about a suggestion to Engineering - perform a PRAGMA integrity_check before any migration? Perform a PRAGMA integrity_check periodically and raise an alert if there’s an issue?

I assume the server already does this since you can get “Database corruption detected” push notifications.

1 Like

@Volts

My development system has a small DB (197MB), known not damaged, and it still failed,

I don’t have any specific instructions yet for anyone. I’m trying to figure out how to undo whatever happened in 1.26.0 upgrade.

1 Like

Oh right - I forgot about those. I haven’t seen anybody mention those notifications in a long while. Is it also displayed anywhere in the UI?

I just downgraded my TS-128A system back to 1.25.6.

It thrashed for several minutes but came back up otherwise without a hitch

1 Like

I haven’t seen it anywhere in the UI. That would be a great addition. There might already be a websocket event for it? I’m not about to corrupt my own database to find out lol.

any recommendations on how to downgrade? I upgraded via apt update and apt upgrade on my ubuntu system.

@strick

Do you have a previous DEB file?

If so, dpkg -r plexmediaserver (removes current pkg but leaves data)
then follow with dpkg -i older-file.DEB

I am making progress with this issue

It appears If the database is bloated then it will take a fair amount of extra time for PMS to do all the required cleanup.

After the 3rd restart (3 hours so far to this point),

  1. The SHM & WAL files have been properly integrated back into the DB at shutdown
  2. Performing DB optimization (very slow – which indicates a lot of bloat being handled)

And adding to @ChuckPa here:

If you shut down PMS, could you then show us the output of an ll command from the Databases directory?

If I run apt-cache madison plexmediaserver
I get
plexmediaserver | 1.26.0.5715-8cf78dab3 | https://downloads.plex.tv/repo/deb public/main amd64 Packages
I didn’t install from a deb file. I just added the plex repository and installed with apt install plexmediaserver a long time ago.
Are you saying multiple restarts after downgrading is what worked?

Here’s what I recommend:

  1. Make certain PMS is CPU-idle (nothing happening)
  2. Stop PMS
  3. sudo dpkg -r plexmediaserver to remove the package but not data
  4. Obtain a directory listing ls -la of the “Databases” directory.
  5. Now install this package
  1. Watching the CPU and disk i/o wait for it to become quiescent (it has DB work to do)

  2. Now open it and confirm everything is working OK.

  3. Now you can install public (1.25.9) or beta (1.26.0) again and Start PMS.
    – AND WAIT again until the system is completely quiet. (no disk i/o)

  4. Observe Plex/web loads and is there.

  5. Optimize the DB (this will likely take time)

  6. Restart

  7. Confirm it’s behaving well again

  8. Upgrade to 1.26.0 – again wait until the DB work completes

  9. To check the process status - ps -ef | grep -i plexm will return multiple processes when the server and different subsystems are fully running.

  10. Obtain one final listing of the databases directory

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