Jump to content


Photo

Mixed content type library broken?

emby

  • Please log in to reply
12 replies to this topic

#1 qta OFFLINE  

qta

    Member

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

Posted 23 November 2019 - 08:40 PM

Hi guys,

 

 

I have a mixed content type library, that was working before, I think before I upgraded to 4.3.0.26. Now, in the Library page, I see this (it is named "Shorts"):

 

5dd9d1232aca7_emby_lib_error.png

 

 

What happened? Emby still sees the content, and I can play them back, but I cannot do anything with this Library anymore: there is no three-dot menu, no options, no click is working...

Could you perhaps help me to clean it up, so I could recreate it? Or maybe how to fix it...?

 

Thanks



#2 Happy2Play OFFLINE  

Happy2Play

    Trial and Error

  • Moderators
  • 17137 posts
  • Local time: 12:47 PM
  • LocationWashington State

Posted 23 November 2019 - 09:45 PM

Have you done a full library scan?

 

Odd that you would still see the content.  But all the same discussion here.

 

https://emby.media/c...-tv-shows-lost/

 

 

You will probably have to look at the libraries options.xml directly.  Don't know your OS but you will need to look in your Emby programdata path.  In Windows it is "C:\Users\username\AppData\Roaming\Emby-Server\programdata\root\default\libraryname".  Is the path correct in the options.xml?

 

Example

  <PathInfos>
    <MediaPathInfo>
      <Path>C:\Users\user\Desktop\Videos\Movies - nfo</Path>
    </MediaPathInfo>
    <MediaPathInfo>
      <Path>C:\Users\user\Desktop\Videos\Kids Movies</Path>
    </MediaPathInfo>
  </PathInfos>


#3 qta OFFLINE  

qta

    Member

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

Posted 23 November 2019 - 10:28 PM

I'm on Linux...

qta@htpc:~$ cat /var/lib/emby-server/root/default/Shorts/options.xml
<?xml version="1.0"?>
<LibraryOptions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <EnableArchiveMediaFiles>false</EnableArchiveMediaFiles>
  <EnablePhotos>true</EnablePhotos>
  <EnableRealtimeMonitor>true</EnableRealtimeMonitor>
  <EnableChapterImageExtraction>false</EnableChapterImageExtraction>
  <ExtractChapterImagesDuringLibraryScan>false</ExtractChapterImagesDuringLibraryScan>
  <DownloadImagesInAdvance>false</DownloadImagesInAdvance>
  <PathInfos>
    <MediaPathInfo>
      <Path>/mnt/Shorts</Path>
      <NetworkPath>\\OMV\export\Shorts\</NetworkPath>
    </MediaPathInfo>
  </PathInfos>
  <SaveLocalMetadata>false</SaveLocalMetadata>
  <SaveLocalThumbnailSets>false</SaveLocalThumbnailSets>
  <ImportMissingEpisodes>false</ImportMissingEpisodes>
  <EnableAutomaticSeriesGrouping>true</EnableAutomaticSeriesGrouping>
  <EnableEmbeddedTitles>false</EnableEmbeddedTitles>
  <EnableAudioResume>false</EnableAudioResume>
  <AutomaticRefreshIntervalDays>0</AutomaticRefreshIntervalDays>
  <PreferredMetadataLanguage />
  <MetadataCountryCode />
  <SeasonZeroDisplayName>Specials</SeasonZeroDisplayName>
  <MetadataSavers />
  <DisabledLocalMetadataReaders />
  <LocalMetadataReaderOrder>
    <string>Nfo</string>
  </LocalMetadataReaderOrder>
  <DisabledSubtitleFetchers />
  <SubtitleFetcherOrder>
    <string>Open Subtitles</string>
  </SubtitleFetcherOrder>
  <SkipSubtitlesIfEmbeddedSubtitlesPresent>false</SkipSubtitlesIfEmbeddedSubtitlesPresent>
  <SkipSubtitlesIfAudioTrackMatches>false</SkipSubtitlesIfAudioTrackMatches>
  <SubtitleDownloadLanguages />
  <RequirePerfectSubtitleMatch>false</RequirePerfectSubtitleMatch>
  <SaveSubtitlesWithMedia>true</SaveSubtitlesWithMedia>
  <ForcedSubtitlesOnly>false</ForcedSubtitlesOnly>
  <TypeOptions>
    <TypeOptions>
      <Type>Series</Type>
      <MetadataFetchers>
        <string>TheTVDB</string>
        <string>TheMovieDb</string>
      </MetadataFetchers>
      <MetadataFetcherOrder>
        <string>MyAnimeList</string>
        <string>Proxer</string>
        <string>AniSearch</string>
        <string>AniList</string>
        <string>AniDB</string>
        <string>TheTVDB</string>
        <string>TheMovieDb</string>
        <string>The Open Movie Database</string>
      </MetadataFetcherOrder>
      <ImageFetchers>
        <string>TheTVDB</string>
        <string>FanArt</string>
      </ImageFetchers>
      <ImageFetcherOrder>
        <string>Proxer</string>
        <string>MyAnimeList</string>
        <string>AniSearch</string>
        <string>AniList</string>
        <string>AniDB</string>
        <string>TheTVDB</string>
        <string>FanArt</string>
        <string>TheMovieDb</string>
      </ImageFetcherOrder>
      <ImageOptions />
    </TypeOptions>
    <TypeOptions>
      <Type>Season</Type>
      <MetadataFetchers />
      <MetadataFetcherOrder>
        <string>AniDB</string>
        <string>TheMovieDb</string>
      </MetadataFetcherOrder>
      <ImageFetchers>
        <string>TheTVDB</string>
      </ImageFetchers>
      <ImageFetcherOrder>
        <string>Proxer</string>
        <string>MyAnimeList</string>
        <string>AniSearch</string>
        <string>AniList</string>
        <string>AniDB</string>
        <string>TheTVDB</string>
        <string>FanArt</string>
      </ImageFetcherOrder>
      <ImageOptions />
    </TypeOptions>
    <TypeOptions>
      <Type>Episode</Type>
      <MetadataFetchers>
        <string>TheTVDB</string>
      </MetadataFetchers>
      <MetadataFetcherOrder>
        <string>AniDB</string>
        <string>TheTVDB</string>
        <string>The Open Movie Database</string>
        <string>TheMovieDb</string>
      </MetadataFetcherOrder>
      <ImageFetchers>
        <string>TheTVDB</string>
        <string>Screen Grabber</string>
      </ImageFetchers>
      <ImageFetcherOrder>
        <string>TheTVDB</string>
        <string>TheMovieDb</string>
        <string>The Open Movie Database</string>
        <string>Screen Grabber</string>
      </ImageFetcherOrder>
      <ImageOptions />
    </TypeOptions>
    <TypeOptions>
      <Type>Movie</Type>
      <MetadataFetchers>
        <string>TheMovieDb</string>
      </MetadataFetchers>
      <MetadataFetcherOrder>
        <string>TheMovieDb</string>
        <string>The Open Movie Database</string>
      </MetadataFetcherOrder>
      <ImageFetchers>
        <string>TheMovieDb</string>
        <string>FanArt</string>
        <string>Screen Grabber</string>
      </ImageFetchers>
      <ImageFetcherOrder>
        <string>TheMovieDb</string>
        <string>FanArt</string>
        <string>The Open Movie Database</string>
        <string>Screen Grabber</string>
      </ImageFetcherOrder>
      <ImageOptions />
    </TypeOptions>
  </TypeOptions>
  <CollapseSingleItemFolders>false</CollapseSingleItemFolders>
  <MinResumePct>5</MinResumePct>
  <MaxResumePct>90</MaxResumePct>
  <MinResumeDurationSeconds>180</MinResumeDurationSeconds>
  <ThumbnailImagesIntervalSeconds>-1</ThumbnailImagesIntervalSeconds>
</LibraryOptions>qta@htpc:~$

And one of the files on the path...

qta@htpc:~$ cat /mnt/Shorts/The.Story.of.Petroleum.1923.720p.BluRay.x264-fty.mkv.sha
37895cbe2806e9944a6c82321edd9a0919c9a015 *The.Story.of.Petroleum.1923.720p.BluRay.x264-fty.mkv
qta@htpc:~$

So the path is fine...

 

Also:

qta@htpc:~$ cat /var/lib/emby-server/root/default/Shorts/Shorts.mblink
/mnt/Shortsqta@htpc:~$

Tried to see what is the difference with other Library items, and the option file is nearly identical, have you made some changes in the library structure? I have seen some items in the release-notes about mixed libraries, as I have many other libraries, and every other is perfectly fine.

 

Is there any other entry anywhere that could get corrupt?



#4 Happy2Play OFFLINE  

Happy2Play

    Trial and Error

  • Moderators
  • 17137 posts
  • Local time: 12:47 PM
  • LocationWashington State

Posted 23 November 2019 - 10:37 PM

Please try remove the trailing slash in the network path as discussed in the other topic.  Shut down Emby, edit the options.xml, restart Emby, perform a library scan.

 

I haven't tested the combination of that with folder and network paths with trailing slashes though.

 

Note the .mblinks have been deprecated.


Edited by Happy2Play, 23 November 2019 - 10:40 PM.


#5 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 146226 posts
  • Local time: 03:47 PM

Posted 23 November 2019 - 11:44 PM

Did you try running a scan?



#6 qta OFFLINE  

qta

    Member

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

Posted 24 November 2019 - 07:04 AM

I did what @Happy2Play suggested, but still nothing has changed: I edited the paths and removed the trailing slash, and restarted Emby, then ran a Library scan.

 

I have read the linked topic, and my issue is a bit different: I cannot click on this library in any way, shape or form, there is no little tree-dot menu, cannot click on the name, etc... it seems internally something got borked.


Edited by qta, 24 November 2019 - 07:54 AM.


#7 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 146226 posts
  • Local time: 03:47 PM

Posted 24 November 2019 - 11:54 AM

Yes that is quite strange. If you right click it, do you get a menu?

#8 qta OFFLINE  

qta

    Member

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

Posted 24 November 2019 - 12:58 PM

No, on that particular one, I get the Browser context menu, others give me the Emby context menu.



#9 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 146226 posts
  • Local time: 03:47 PM

Posted 24 November 2019 - 03:42 PM

Can you provide me with this info here?

https://emby.media/c...e-3#entry809063

 

Thanks.



#10 qta OFFLINE  

qta

    Member

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

Posted 24 November 2019 - 05:38 PM

I only have the Emby config backup plugin generated last 10 dumps, which does not contain everything I believe, but if you can use the oldest one, I can upload it somewhere.

 

I was fiddling with debug logs, and also looked into the library.db file with SQLite:

 

I remember once /var/lib/emby was renamed /var/lib/emby-server. Then I created a symbolic link between the two, to continue to use Emby and everything was great. And now I have seen in the debug logs that the only options.xml that was parsed back with the /var/lib/emby folder was the Shorts library (only one, so correlates very well with the issue). And peeking into the DB (I made a dump and grepped a bit) I see many rows have this old folder in it (and not just this library, but others as well), so I presume that over time, this totally blew the DB away, and now is the time that you guys were not expecting this at all.

 

I think I will start over, the library for me is nothing sort of golden territory, so no big deal redoing everything from scratch. Not that I need to do it often, this is my biggest problem in this year using Emby :D

 

Thanks anyway, I think this does not require too much digging deep, as it might be a mess.



#11 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 146226 posts
  • Local time: 03:47 PM

Posted 24 November 2019 - 05:52 PM

Ah yes sounds like you're right. Thanks for the feedback.

#12 qta OFFLINE  

qta

    Member

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

Posted 24 November 2019 - 06:32 PM

Hi,

 

I figured I will doctor a little with the DB if I will dump it, to see maybe if I can fix it...

 

What I did:

  • Stopped emby-server
  • Made sure /var/lib/emby-server is the only folder there, I removed /var/lib/emby softlink
  • Edited /etc/passwd for emby, fixed his home folder, and made him loginable, gave him a password as well
  • Used sqlite3 to dump the whole DB, and started searching for '/var/lib/emby' marks, notied the database
  • Switched to emby user
  • For each DB I found, I dumped the DB to a file, and used sed to replace all occurrences of this folder, then dropped the table and reloaded the fixed one from the file (I had to fix two tables: MediaItems and TypedBaseItems only)
  • Started emby-server

Now I have my Library back :D

And I hope everything will be smooth in the future. Definitely the issue was I was using Emby for 2 years now, and a lot has changed, and I also fiddled with the config in ways you guys did not expect it.

 

 

Thanks



#13 Happy2Play OFFLINE  

Happy2Play

    Trial and Error

  • Moderators
  • 17137 posts
  • Local time: 12:47 PM
  • LocationWashington State

Posted 24 November 2019 - 06:37 PM

FYI MediaItems table replaced TypeBaseItems I believe in v4.  So old databases can be bloated with all tables that are depreciated.


Edited by Happy2Play, 24 November 2019 - 06:38 PM.






Also tagged with one or more of these keywords: emby

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users