Would it be an idea to add an official backup/restore functionality on the Plex Server, so that it is possible to click BACKUP for instance from Server Settings and generate a complete, compressed backup file of all the metadata and related information needed on the server in case of a crash or server migration?
And a corresponsing restore function that can either replace or merge existing data?
Would be especially good for PlexPass users who may run "experimental" builds and may be concerned about downgrading after database upgrades. With a complete backup at the push of a button, one could relatively easily backup, upgrade, revert and then restore the old data in case of trouble.
This would be a great function. I know my database gets backed up regularly by Backblaze but I wouldn't mind knowing there's a nice zip film regularly exported with everything in it.
Seems like a pretty popular request. Would be super cool to learn what the developers think about this. Feasible, on the roadmap, or way off? Anyone up to grabbing the bait? ;-)
Seems like a pretty popular request. Would be super cool to learn what the developers think about this. Feasible, on the roadmap, or way off? Anyone up to grabbing the bait? ;-)
It is definitely possible, someone could easily do it themselves. As to popularity, it is currently far below many other requests.
It is definitely possible, someone could easily do it themselves. As to popularity, it is currently far below many other requests.
Is there a page in the Wiki that explains this? Personally, I don't care if it comes off the shelf or that I manually have to add a Cron job to backup every night. But I do want to know for sure that I have all the locations and dependencies of the database files. I haven't seen any official statement on how to backup an entire database, artwork etc. included, so that it can be restored after a huge crash.
I am interested in this, since I am going to implement remote backup on a much less powerful NAS (unfortunately blocking a full system backup). Ideally I can include a zip-file along with all the media files to be backed up to the other site, allowing a quick restore after a significant crash/problem.
Is there a page in the Wiki that explains this? Personally, I don't care if it comes off the shelf or that I manually have to add a Cron job to backup every night. But I do want to know for sure that I have all the locations and dependencies of the database files. I haven't seen any official statement on how to backup an entire database, artwork etc. included, so that it can be restored after a huge crash.
I am interested in this, since I am going to implement remote backup on a much less powerful NAS (unfortunately blocking a full system backup). Ideally I can include a zip-file along with all the media files to be backed up to the other site, allowing a quick restore after a significant crash/problem.
Jaap
this is my cron script, it runs weekly.
#!/bin/bash
# consts
SOURCEDIR=/var/lib/plexmediaserver/
BACKUPDIR=/Volumes/Dump/PlexBackup
FINALDIR=/Volumes/Data/Backups/Media
FILENAME=/Volumes/Dump/Backups/PlexBackup.$(date +%Y%m%d)
KEEPDAYS=15
USER=abc
# Create dirs and rsync stuff
test -d $BACKUPDIR || mkdir -p $BACKUPDIR
test -d $FINALDIR || mkdir -p $FINALDIR
rsync -a --delete $SOURCEDIR $BACKUPDIR
# bundle it all up, and move it somewhere safe
tar -cjf ${FILENAME}.tar.bz2 $BACKUPDIR
su $USER -c "cp $FILENAME.tar.bz2 $FINALDIR"
#delete the really old stuff
find /Volumes/Dump/Backups -name 'PlexBackup.*' -atime +$KEEPDAYS -delete
su $USER -c "find $FINALDIR -name 'PlexBackup.*' -atime +$KEEPDAYS -delete"
needs some simplifying, $SOURCEDIR is everything you need. (my .bz2 is 101Gb which is why I don't do this daily - I rarely make a large amount of manual changes to metadata/art, if do, I just manually run the script)
Is there a page in the Wiki that explains this? Personally, I don't care if it comes off the shelf or that I manually have to add a Cron job to backup every night. But I do want to know for sure that I have all the locations and dependencies of the database files. I haven't seen any official statement on how to backup an entire database, artwork etc. included, so that it can be restored after a huge crash.
I am interested in this, since I am going to implement remote backup on a much less powerful NAS (unfortunately blocking a full system backup). Ideally I can include a zip-file along with all the media files to be backed up to the other site, allowing a quick restore after a significant crash/problem.
Updated original post to also include an option to backup only the seen/unseen and how far into each item watched data. Seems like a good way to start fresh without losing the important stuff of which episodes/movies have been seen, and how far into each one..
+1 Yes definitely.. my database is growing and I am planning on creating backup of it manually, but would be a plus when PMS has its own backup feature.
3) change section path (an easy way. its just a sql query i guess)
4) store/read metadata to media folder (for easier migration)
5) autobackup data every NN hours to a predifined unc path
That's a good summary. With the decreasing stability in newer Plex Media Server releases I believe the need for proper backup/resture is now more relevant than ever. I am especially worried about the seen/unseen status throughout the libraries. Doing a re-scan of most metadata is time consuming and a hassle, but losing track of what has been watched and how far is simply impossible. For these reasons I would really appreciate some sort of comment on this from the Plex team