Hi,
I’ve just made a mistake and remove /var/lib/plexmediaserver
Can I restore and what can I restore from the Preferences.xml and a fresh database folder backup ?
Regards.
Hi,
I’ve just made a mistake and remove /var/lib/plexmediaserver
Can I restore and what can I restore from the Preferences.xml and a fresh database folder backup ?
Regards.
You have the entire Plug-in Support/Databases directory as well as Preferences.xml ?
Hi ChuckPa,
Yep I’ve got this repository backup 
Meanwhile I’ve managed to restore my server, the most important thing for me are the status of watched / not watched.
I have to refresh all of my library to get back my fanart/folder as well.
Regards.
Here is how to take the watched status (view state) from one database (the original)
to another (the now-active one)
https://support.plex.tv/articles/201154527-move-viewstate-ratings-from-one-install-to-another/
Affter you’re done repopulating all the metadata (which you’re doing),
perform Emtpy Trash, clean bundles, optimize database
This will remove the old and now unused records from the database, leaving only the new current ones
Hi,
Much appreciated, time you’ve spent answering my problem.
I’ve done all tasks after repopulating the medata.
Clean bundles and optimize database were quite long but end well.
One last quick question, do I need to backup more than this folder:
Plug-in Support/Databases
and this file Preferences.xml
Because we have the power of Linux at our disposal, I usually opt for snapshot of everything.
Why waste all the CPU time generating everything again.
For those on a slow or metered internet connection, it does add up.
I usually do the following:
cd /var/lib/plexmediaserver
sudo tar cfz /nas/backups/plexsnapshot.tar .
It grabs everything, compressing all the bundles down to minimal space.
Restoration after a major failure is a snap – reverse the process.
this should be done with the caveat that plex should not be running, yes ?
trying to backup a database that is running, is a recipe for corruption, in my experience.
Database is backup via a Cron on PMS so that’s not a problem.
Indeed backup a running database isn’t a best practice.
Some Cache folder can also be excluded from the .tar.
Anyway making a .tar is a good solution, stopping the server first, even better.
sudo systemctl stop plexmediaserver
.... now perform backup
sudo systemctl start plexmediaserver
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.