Jump to content


Photo

Moving Portable Emby Install breaks library reference.

Bug Portable Library

  • Please log in to reply
13 replies to this topic

#1 dbailey1114 OFFLINE  

dbailey1114

    Newbie

  • Members
  • 1 posts
  • Local time: 08:23 PM

Posted 17 November 2018 - 01:19 PM

Seems that if you move Emby (Portable) everything is fine, except this reference to the library information?

 

Everything else is detected in the correct new location, except this, and it only errors when you try to scan the library.

 
Program data path: D:\Emby\programdata
Application directory: D:\Emby\system
System.IO.DirectoryNotFoundException: Could not find a part of the path 'E:\Emby\programdata\root\default\Movies'.

Any Idea how I can fix this easily/quickly?


  • Napsterbater likes this

#2 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 126625 posts
  • Local time: 09:23 PM

Posted 17 November 2018 - 01:22 PM

Hi, you can't easily do that. You may be too remove that library and then add it back.

For newer installations this has been corrected. Thanks.

#3 Napsterbater OFFLINE  

Napsterbater

    Member

  • Members
  • 24 posts
  • Local time: 09:23 PM

Posted 17 November 2018 - 01:23 PM

Op, here, Was in wrong account when I posted.

 

This is a brand new install. Downloaded and installed yesterday, is there a newer version?


Edited by Napsterbater, 17 November 2018 - 01:24 PM.


#4 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 126625 posts
  • Local time: 09:23 PM

Posted 17 November 2018 - 01:25 PM

The next release I mean, sorry.

#5 Napsterbater OFFLINE  

Napsterbater

    Member

  • Members
  • 24 posts
  • Local time: 09:23 PM

Posted 17 November 2018 - 01:30 PM

Is there a manual database query/command that can be run? Literally just changing 1 Letter. E to D in that path.



#6 Napsterbater OFFLINE  

Napsterbater

    Member

  • Members
  • 24 posts
  • Local time: 09:23 PM

Posted 09 December 2018 - 09:29 PM

I am currently running the latest beta. And it seems the database is not updated?

So I'm guessing the only option I have is to delete the libraries and re add them.

Now my question is if I do that what happens to the watched status for the users? Will it carry over?

#7 Happy2Play OFFLINE  

Happy2Play

    Trial and Error

  • Moderators
  • 14051 posts
  • Local time: 06:23 PM
  • LocationWashington State

Posted 09 December 2018 - 10:23 PM

Library paths are set by the admin when they are added. You would have to remove and readd the library. If you were to manually update the database you would have to ensure you update library paths also (Emby-Server\programdata\root\default\each library\*.mblink). No real way to make libraries portable.

Watched status is tracked by providerid so changes will only affect items without providerids.
 

Is there a manual database query/command that can be run? Literally just changing 1 Letter. E to D in that path.

 

Not a database person but tested this and worked (ensure you backup db before editing)

UPDATE MediaItems SET Path = replace( Path, 'E:', 'D:' );

 


Edited by Happy2Play, 09 December 2018 - 10:24 PM.


#8 Napsterbater OFFLINE  

Napsterbater

    Member

  • Members
  • 24 posts
  • Local time: 09:23 PM

Posted 10 December 2018 - 12:45 AM

Thanks for the Reply, but I am no talking about the Path to where the Media Files themselves are located, I am talking about where Emby Keeps the Information about a particular library and options.xml and such.

 

As you can see in the first post I moved Emby as a whole (Installed as portable) but the Library folder locations were hardcoded in the database in prev versions of Emby, the beta has changed that but it doesn't seem to be retro active.

 

So It seems either I need to delete the library in Emby and readd it, which may not be an issue as long as play status is still kept, and if it is this is the simplest/safest way.

Or I need to update the reference to that location in the database.



#9 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 126625 posts
  • Local time: 09:23 PM

Posted 10 December 2018 - 01:05 AM

You could manually edit the db. But yes as you've seen, going forward with 3.6 there should be no more problems moving things around.


  • Napsterbater likes this

#10 Napsterbater OFFLINE  

Napsterbater

    Member

  • Members
  • 24 posts
  • Local time: 09:23 PM

Posted 10 December 2018 - 01:48 AM

Is there anyway Emby can update existing entries upon updating to the new version?

Because that seems like it would be very useful to everyone that is going to be updating with old entries that make emby not as portable as it should be.

Also, I never got an answer, if I delete the library and recreate it will the watched status all be reset?

#11 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 126625 posts
  • Local time: 09:23 PM

Posted 10 December 2018 - 01:51 AM

 

 

Because that seems like it would be very useful to everyone that is going to be updating with old entries that make emby not as portable as it should be.

 

this will actually happen on it's own over time, as new records get re-saved.

 

 

 

Also, I never got an answer, if I delete the library and recreate it will the watched status all be reset?

 

It depends. For movies and tv series, we store user data based on provider id's such as tmdb/tvdb, etc. Assuming these stay intact then so should your watch data. Other things like home videos, yes you may lose some watch data unless the library has exactly the same path as before.


  • Napsterbater likes this

#12 Happy2Play OFFLINE  

Happy2Play

    Trial and Error

  • Moderators
  • 14051 posts
  • Local time: 06:23 PM
  • LocationWashington State

Posted 10 December 2018 - 04:33 AM

If you have to delete the database and rebuild it you will loose all userdata.  You can export and import the tables or use the Server Configuration Backup Plugin to backup and restore userdata.



#13 Napsterbater OFFLINE  

Napsterbater

    Member

  • Members
  • 24 posts
  • Local time: 09:23 PM

Posted 11 December 2018 - 01:21 AM

this will actually happen on it's own over time, as new records get re-saved.
 

 
It depends. For movies and tv series, we store user data based on provider id's such as tmdb/tvdb, etc. Assuming these stay intact then so should your watch data. Other things like home videos, yes you may lose some watch data unless the library has exactly the same path as before.


So I took the leap and deleted my movies and TV libraries and simply recreated And re added them. Seems all watched status is in place.

But it does still seem like this should be something that should be updated in the database on the first time after an upgrade to this version, instead of having to wait an indeterminate amount of time before you can move your supposedly portable Envy installation.

#14 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 126625 posts
  • Local time: 09:23 PM

Posted 11 December 2018 - 01:38 AM

Thanks for the feedback.


  • Napsterbater likes this





Also tagged with one or more of these keywords: Bug, Portable, Library

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users