How to restore collection tags

Server Version#: 4.128.1
Player Version#:
<If providing server logs please do NOT turn on verbose logging, only debug logging should be enabled>

My storage space went offline for about a week and it looks like most of my Collection tags have been removed. I manually add tags that I use for smart playlists. I see a related post that explains what likely happened “bad automatic scan”. I have server backups. Can I restore them from that, and can I restore just the tags and not impact viewing history since then?

Enable Sync Watch State and Ratings for your account. Have your users enable it for theirs. It will help with future events, such as migrating to a new server.

Review:

Note: The “Move Viewstate…” document is slightly out of date. Instead of standard SQLite3, you need to use the Plex customized version included with Plex Media Server.

On Windows, the default location of Plex SQLite is:

  • PMS 32-bit: C:\Program Files (x86)\Plex\Plex Media Server\Plex SQLite.exe
  • PMS 64-bit: C:\Program Files\Plex\Plex Media Server\Plex SQLite.exe

For other platforms, see Locating the Plex SQLite Tool


Approach:

  1. Disable Settings → Library → Empty trash automatically after every scan.

  2. Stop Plex Media Server.

  3. Make a backup copy of the Plex database files (just in case something goes wrong).

  4. Export viewstate data from the source database.
    Instructions are in the “Move Viewstate…” document (Source Install).

  5. Restore a version of the database from when the collection tags still existed.
    Use the “Restore a Database…” document as a guide.

  6. Run Plex Media Server, make sure system is stable, tags restored, etc.

  7. Stop PMS, import previously exported viewstate data.
    Instructions are in the “Move Viewstate…” document (Destination Install).

  8. Run Plex. Check that system is stable, watch states are correct, etc.

1 Like

Great instructions! I’ll try this after work tonight and let you know. Very much appreciated!

Unfortunately, it looks like Plex cleaned up the backups that had my collection information in it. I only have backups going back about two weeks, and my storage spaces might have gone down before that. I have a CSV file with my collection information in it (created a while back using WebTools-ng). Is there any way to batch import those collections?

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