Jump to content

Backup Plugin not restoring library properly


Dibbes

Recommended Posts

PenkethBoy

Do you see contentype removed upon restore?

nope i dont - so something else going on with config backup plugin then i guess - see above

 

my options.xml did not change date/time from the copy i had

Link to comment
Share on other sites

Happy2Play

Okay it would appear the contenttype rewrite was from entering a library settings.  If I don't enter library settings contenttype remains eventhough UI is Mixed Content.

 

A plugin restore, or a database delete, or new install copying libraries from one install to another nukes contenttype.  But me if there is a contenttype.collection in library folder it will restore to the content type.

Link to comment
Share on other sites

PenkethBoy

.collection is redundant and not created for a new library created via the UI - so anybody that has created a new library since the .collection become redundant will see this If they rebuild their library - so needs fixing and testing before Stable goes out

 

yes i expect the contenttype gets deleted on an edit - as the contentytype is missing from a "true" mixed content library - and this is part of the problem

 

I dont see any amendment of a library xml file when copied to the test server (with server off) - on running up the server it just reads it and decides its a mixed library and adds the library to the ui

Link to comment
Share on other sites

Happy2Play

.collection is redundant and not created for a new library created via the UI - so anybody that has created a new library since the .collection become redundant will see this If they rebuild their library - so needs fixing and testing before Stable goes out

 

yes i expect the contenttype gets deleted on an edit - as the contentytype is missing from a "true" mixed content library - and this is part of the problem

 

I dont see any amendment of a library xml file when copied to the test server (with server off) - on running up the server it just reads it and decides its a mixed library and adds the library to the ui

I understand new libraries don't create it but am saying if you add it they maintain content type.  So to me there has to be something in the code about this.  But if this process only works for me, then I have no idea.

Link to comment
Share on other sites

PenkethBoy

i have not tried the .collection file - not saying it does not work - but is an option for users - but is only a workaround at best IMO

 

Yes there is a lot of code issues around this - the change was made without any testing as this would have come up before

 

Lets see what @@Luke comes back with as an answer/fix for the two or three different issues that have been uncovered - might be others we will have to see.

Link to comment
Share on other sites

Happy2Play

That is the issue since everything has changed so much over time there is going to be so many mixed variables.  Everything new will only be options.xml but all old libraries will have .collection and .mblink. and .xml.  So if never resaved/updated options.xml, collection files is required.

 

I still have libraries on my Stable build that have options.xml without contenttype.  But obviously the backups will work do to containing the .collection file.  So backwards compatibility has to be maintained for OLD systems.  The issue resides in the NEW format not being read properly.

Edited by Happy2Play
Link to comment
Share on other sites

PenkethBoy

backups will only work with libraries not created recently as they will not have a collection file

 

Its a massive mess that should have been tested for when brought in - mixed variables are in Luke's control

 

if you have libraries on stable that dont have a content type then thats another bug that should have been covered off if you bring in new options - basic stuff

 

I have a beta server with over 100 libraries - and a quick check shows that none of the options.xml files have been saved since june last year and all appear to have the content type within - dont think this server has been on beta though but interesting that they have the contenttype - was expecting them not to have it

Link to comment
Share on other sites

Happy2Play

backups will only work with libraries not created recently as they will not have a collection file

 

Its a massive mess that should have been tested for when brought in - mixed variables are in Luke's control

 

if you have libraries on stable that dont have a content type then thats another bug that should have been covered off if you bring in new options - basic stuff

 

I have a beta server with over 100 libraries - and a quick check shows that none of the options.xml files have been saved since june last year and all appear to have the content type within - dont think this server has been on beta though but interesting that they have the contenttype - was expecting them not to have it

If doesn't matter as required files exist and will alway be backed up.  Only thing broken is NEW options.xml with content type.

 

Now if the server were to clear the folder and rewrite a options.xml then that is another story.  

 

 

 

To recap my findings, all old libraries with new or old options.xml with .collection files restore fine.

New libraries with only options.xml w/contenttype fail to restore properly, they restore as Mixed Content.

Link to comment
Share on other sites

PenkethBoy

If doesn't matter as required files exist and will alway be backed up.  Only thing broken is NEW options.xml with content type.

 

No - if its a new library the collection files dont exist - so backup wont help you!

Link to comment
Share on other sites

Happy2Play

No - if its a new library the collection files dont exist - so backup wont help you!

Correct NEW is broke Old is not.  But if a collection file exists/add everything works.

Link to comment
Share on other sites

PenkethBoy

just tested on Stable - if you create a new library - only options.xml file added and it does have content type in the xml

 

so OLD same as New on that front - all comes down to when you created a library - which is nuts

 

Stable has the same problem as beta in not seeing content type and creating mixed libraries

Link to comment
Share on other sites

Happy2Play

Okay yes, 4.3.1.0 + is this way, anything older has three files.  So all OLDer library backups have the files needed.  So all my Emby 3+ libraries are good with 3 files

Edited by Happy2Play
  • Like 1
Link to comment
Share on other sites

Dibbes

Okay yes, 4.3.1.0 + is this way, anything older has three files.  So all OLDer library backups have the files needed.  So all my Emby 3+ libraries are good with 3 files

 

Unfortunately I only have two version 3.x libraries left... the rest is all newer...

Link to comment
Share on other sites

Happy2Play

I still can not make manual workaround, restoring a new library with manually added contenttype.collection not restore properly.

Link to comment
Share on other sites

Dibbes

Just testing the updated plugin and it seems that the libraries are now properly restored... Obviously it still scanning, but it's looking good!

 

One question though: when restoring to another server that already has a few libraries setup, shouldn't the libraries that are already not be removed?

Link to comment
Share on other sites

The plugin update wasn't related to this so the loss of content type should still be an issue.

Link to comment
Share on other sites

 

 

when restoring to another server that already has a few libraries setup, shouldn't the libraries that are already not be removed?

Not really sure what you're asking, but there's no error handling related to this. Ideally you should only restore libraries when no existing ones are in place.

Link to comment
Share on other sites

Dibbes

The plugin update wasn't related to this so the loss of content type should still be an issue.

 

I restored to a server that had a bunch of libraries already there and for some reason the libraries from the restore were all recognized properly... 

Link to comment
Share on other sites

Dibbes

Not really sure what you're asking, but there's no error handling related to this. Ideally you should only restore libraries when no existing ones are in place.

 

I don't live in an ideal world... sorry

Link to comment
Share on other sites

  • 2 weeks later...
IkeTaylor11

Is this still actively being worked on for a fix? I have had to restore my Emby server multiple times lately (for reasons not caused by Emby) and all libraries import as "Mixed Content". It defeats the entire purpose of restoring libraries at all. 

Link to comment
Share on other sites

  • 2 weeks later...
  • 1 month later...
Happy2Play

Still a issue but my work around works in my tests.  Make a .collection file per library that reflects the contentype listed in the xml.

 

boxsets.collection

playlists.collection

movies.collection

tvshows.collection

music.collection

 

Without these files everything is restored Mixed Content.

Edited by Happy2Play
added music
  • Like 1
  • Thanks 1
Link to comment
Share on other sites

  • 2 weeks later...
dcol

Still a issue but my work around works in my tests.  Make a .collection file per library that reflects the contentype listed in the xml.

 

boxsets.collection

playlists.collection

movies.collection

tvshows.collection

 

Without these files everything is restored Mixed Content.

Can you give an example as to where to put this collection file and what is in it?

Link to comment
Share on other sites

Happy2Play

Can you give an example as to where to put this collection file and what is in it?

 

In the perspective library folder.  It is a empty file.

 

example

5eced221d61ea_library.jpg

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...