Jump to content

MediaInfo For Emby Plugin(HDR, Vision, Atmos, DTS:X)


Recommended Posts

Posted
27 minutes ago, robsch said:

So I am having an issue; 

Debian 11

Emby Server Version 4.8.10.0

MediaToolBox (Latest from Plugin Sections)

 

I have installed MediaInfoCLI (its in /usr/bin) and I have installed MKVToolNix (again, in /usr/bin). I can manually execute them, and they work just fine. So I go into Media Toolbox in Emby and I try to add the Executable FILE Paths and after I exit the page to do a lib scan, I come back and the paths do not save. (Or show saved?)  I wen to check the /var/lib/emby/plugins/configurations/Emby.MediaInfo.xml and I do not see any paths saved in that file either. I am not sure what the path tag is, otherwise I would add them by hand. Any idea of what is going on, or is this just an oddity?

 

 

<?xml version="1.0"?>
<PluginConfiguration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <EnableMediaInfo>true</EnableMediaInfo>
  <AutoRunLibraryScan>false</AutoRunLibraryScan>
  <RunMediaInfoOnNewItemAdded>true</RunMediaInfoOnNewItemAdded>
  <EnableMovies>true</EnableMovies>
  <EnableTVEpisodes>true</EnableTVEpisodes>
  <AddToItemTags>true</AddToItemTags>
  <ShowHD>false</ShowHD>
  <ShowBitrate>false</ShowBitrate>
  <ShowCodecFormat>false</ShowCodecFormat>
  <ShowAsUHD>false</ShowAsUHD>
  <ShowHDRFormat>true</ShowHDRFormat>
  <ShowRemux>false</ShowRemux>
  <AbbrAudioOutput>true</AbbrAudioOutput>
  <ShowDefaultTrack>true</ShowDefaultTrack>
  <ShowAudioBitDepth>false</ShowAudioBitDepth>
  <ShowAudioSampleRate>false</ShowAudioSampleRate>
  <UseRBJTechFormat>false</UseRBJTechFormat>
  <ExludeIdString />
  <MIreprocessList />
  <ResetEmbeddedTitles>false</ResetEmbeddedTitles>
  <RemoveTags>false</RemoveTags>
  <ResetProcessedList>true</ResetProcessedList>
  <VersionOverride>false</VersionOverride>
  <EnableHDRConvert>false</EnableHDRConvert>
  <RunBIFOnNewItemAdded>true</RunBIFOnNewItemAdded>
  <EnableHDRMovies>false</EnableHDRMovies>
  <EnableHDREpisodes>false</EnableHDREpisodes>
  <EnableHDRReprocess>false</EnableHDRReprocess>
  <BifReprocessList />
  <UseCustomBifInterval>false</UseCustomBifInterval>
  <BifInterval>10</BifInterval>
  <EnableSubKiller>false</EnableSubKiller>
  <RunSubKillerOnItemAdded>false</RunSubKillerOnItemAdded>
  <LibrariesToConvert>
    <string>3</string>
  </LibrariesToConvert>
  <ProcessedList />
  <MediaSourceProcessedList />
  <HDRProcessedMovieList />
  <HDRProcessedEpisodeList />
</PluginConfiguration>
 

 

 

if the paths are not in the config XML, then it's not saving the paths (for some reason)

Maybe try clicking a 'save' option for something else (empty) - it should pop up and say 'saved' - then check the XML ?

  • Thanks 1
Posted
1 hour ago, rbjtech said:

The log is simply stating that it cannot start the mkvpropedit executable - likely permissions caused by your last update.

Remember it's the two executables you specify in the plugin that do all the updating to the FILES - so emby only needs execute access to those files, but those executables need write access to the actual media files (to make the changes to the MKV track titles).

If you turn on debug logging in emby, the mediainfo plugin is very verbose in what it is doing which may give further clues, but it looks like permissions to me in the log.

This may help - 

https://github.com/Cheesegeezer/MediaInfoWiki/wiki/Various-OS-Installation-Help#5-docker

https://github.com/Cheesegeezer/MediaInfoWiki/wiki/Various-OS-Installation-Help#2-synology-nas

I'm lost with all that I cannot remember how I installed the 2 tools on my synology but I remember it was turbo complicated. why does it have to be like that 10 years after dts x introduction we need that effort to get emby recognizing it. 

and there was only an upgrade it didn't change anything. xxxx

the log is there maybe you can take a look? it's very short but for me it's old Greek

embyserver.txt

Posted
2 minutes ago, supermood said:

I'm lost with all that I cannot remember how I installed the 2 tools on my synology but I remember it was turbo complicated. why does it have to be like that 10 years after dts x introduction we need that effort to get emby recognizing it. 

and there was only an upgrade it didn't change anything. xxxx

the log is there maybe you can take a look? it's very short but for me it's old Greek

embyserver.txt 74.86 kB · 0 downloads

you pretty much nailed it on your first post

does 

/bin/mkvpropedit exist ?

/run/s6-rc:s6-rc-init:ofIEHG/servicedirs/svc-emby does this exist ?

I would set it up again as you did the first time - I have two links in my post above that may help.   I don't run emby on docker nor synology I'm afraid - so I'm not in a position to help with regards to the OS install.

 

2024-11-21 16:17:19.019 Warn Media Info: Please check your Folder Path and FileName: Filename must be Correct
2024-11-21 16:17:19.019 Warn Media Info: MEDIAINFO CANNOT CONTINUE
2024-11-21 16:17:19.021 Error Media Info: An error occurred trying to start process '/bin/mkvpropedit' with working directory '/run/s6-rc:s6-rc-init:ofIEHG/servicedirs/svc-emby'. No such file or directory

  • Like 1
Posted
4 minutes ago, rbjtech said:

you pretty much nailed it on your first post

does 

/bin/mkvpropedit exist ?

/run/s6-rc:s6-rc-init:ofIEHG/servicedirs/svc-emby does this exist ?

I would set it up again as you did the first time - I have two links in my post above that may help.   I don't run emby on docker nor synology I'm afraid - so I'm not in a position to help with regards to the OS install.

 

2024-11-21 16:17:19.019 Warn Media Info: Please check your Folder Path and FileName: Filename must be Correct
2024-11-21 16:17:19.019 Warn Media Info: MEDIAINFO CANNOT CONTINUE
2024-11-21 16:17:19.021 Error Media Info: An error occurred trying to start process '/bin/mkvpropedit' with working directory '/run/s6-rc:s6-rc-init:ofIEHG/servicedirs/svc-emby'. No such file or directory

I don't know if the files are existing they are not in the docker container. I cannot remember at all how I did it there was a homepage from someone with a description linked here in one of the 10k sites searching the site alone would drive me crazy. I will go on without the Plugin 

  • Like 1
Posted (edited)

Update : I was able to save the path when I made a change to another option. Progress!

However, I now I get some errors in my logs, and am wondering if network paths, and mounted storage arrays cause a problem?  Though I can run mediainfo from a shell and it gives me the full output. In the logs, I get :

2024-11-21 10:39:23.240 Warn Media Info: Please check your Folder Path and FileName: Filename must be Correct
2024-11-21 10:39:23.240 Warn Media Info: MEDIAINFO CANNOT CONTINUE
2024-11-21 10:39:23.242 Error Media Info: The FileName property should not be a directory unless UseShellExecute is set.
 
This makes me wonder if this is a permission that I need to set on Emby?  Though I have emby running off an Emby user that has essentially root access.  (Its in the :wheel) group. When I ssh in as the emby user I can run:
 
 mkvinfo /data/video/demo-robs/Alita\ -\ Battle\ Angel\ \(2019\)\ \[2160p\]/Alita\ -\ Battle\ Angel\ \(2019\)\ \[Demo\]\ -\ UHD\ Blu-ray.2160p.HDR.TrueHD\ Atmos.8ch.mkv
+ EBML head
|+ EBML version: 1
|+ EBML read version: 1
|+ Maximum EBML ID length: 4
|+ Maximum EBML size length: 8
|+ Document type: matroska, blah, blah, blah.
 
mkvpropedit /data/video/demo-robs/Alita\ -\ Battle\ Angel\ \(2019\)\ \[2160p\]/Alita\ -\ Battle\ Angel\ \(2019\)\ \[Demo\]\ -\ UHD\ Blu-ray.2160p.HDR.TrueHD\ Atmos.8ch.mkv
Error: Nothing to do.
 
So both mkvpropedit and mkvinfo work just fine
 
I did check in Emby for something to allow for shell access, or OS level rights, and didn't see anything... Anny thoughts?
 
Thanks
 

embyserver (1).txt

Edited by robsch
Posted (edited)
28 minutes ago, robsch said:

Update : I was able to save the path when I made a change to another option. Progress!

However, I now I get some errors in my logs, and am wondering if network paths, and mounted storage arrays cause a problem?  Though I can run mediainfo from a shell and it gives me the full output. In the logs, I get :

2024-11-21 10:39:23.240 Warn Media Info: Please check your Folder Path and FileName: Filename must be Correct
2024-11-21 10:39:23.240 Warn Media Info: MEDIAINFO CANNOT CONTINUE
2024-11-21 10:39:23.242 Error Media Info: The FileName property should not be a directory unless UseShellExecute is set.
 
This makes me wonder if this is a permission that I need to set on Emby?  Though I have emby running off an Emby user that has essentially root access.  (Its in the :wheel) group. When I ssh in as the emby user I can run:
 
 mkvinfo /data/video/demo-robs/Alita\ -\ Battle\ Angel\ \(2019\)\ \[2160p\]/Alita\ -\ Battle\ Angel\ \(2019\)\ \[Demo\]\ -\ UHD\ Blu-ray.2160p.HDR.TrueHD\ Atmos.8ch.mkv
+ EBML head
|+ EBML version: 1
|+ EBML read version: 1
|+ Maximum EBML ID length: 4
|+ Maximum EBML size length: 8
|+ Document type: matroska, blah, blah, blah.
 
mkvpropedit /data/video/demo-robs/Alita\ -\ Battle\ Angel\ \(2019\)\ \[2160p\]/Alita\ -\ Battle\ Angel\ \(2019\)\ \[Demo\]\ -\ UHD\ Blu-ray.2160p.HDR.TrueHD\ Atmos.8ch.mkv
Error: Nothing to do.
 
So both mkvpropedit and mkvinfo work just fine
 
I did check in Emby for something to allow for shell access, or OS level rights, and didn't see anything... Anny thoughts?
 
Thanks
 

embyserver (1).txt 4.58 kB · 1 download

what do you have for the exe paths (in the XML) - this is the full path to the executable, not just the folder.  it sounds like you may have just used the folder ?

For Windows - an example is :-

ie  <emby_folder>\programdata\plugins\configurations\Emby.MediaInfo.xml

  <MediaInfoCLIPath>C:\MediaInfoCLI\MediaInfoCLI.exe</MediaInfoCLIPath>
  <MKVPropEditPath>C:\MKVToolNix\mkvpropedit.exe</MKVPropEditPath>

 

Edited by rbjtech
Posted
4 minutes ago, rbjtech said:

what do you have for the exe paths (in the XML) - this is the full path to the executable, not just the folder.  it sounds like you may have just used the folder ?

For Windows - this is :-

ie  <emby_folder>\programdata\plugins\configurations\Emby.MediaInfo.xml

  <MediaInfoCLIPath>C:\MediaInfoCLI\MediaInfoCLI.exe</MediaInfoCLIPath>
  <MKVPropEditPath>C:\MKVToolNix\mkvpropedit.exe</MKVPropEditPath>

 

You are correct, I just had /usr/bin for both. I just changed it to

/usr/bin/mediainfo

/usr/bin/mkvpropedit

and restarted emby server. I just ran a lib scan, and then ran the Media Info task and got the same thing. I also (for S&G) went into the GUI config and it still just has /usr/bin, annd the config file has the path as well now. So if I open the GUI, it changes it back.

So I did the same thing, and this time, did NOT check the at all, and just ran the task, and again, same errors.

 

 

embyserver (2).txt

Posted
2 minutes ago, supermood said:

https://github.com/SimCity/emby-mediainfo-plugin-prereq?tab=readme-ov-file

maybe this will help it saved mee some months ago. but now i still have the mod but no functuionality

 

I'll throw it on my docker server and see if I can make it work there.  Right now I have it on dedicated hardware, and kind of old school that way. 🙄 But if I can make it work in my docker, at least I can get a working version to help as a blueprint.

  • Like 1
Posted (edited)
5 minutes ago, robsch said:

You are correct, I just had /usr/bin for both. I just changed it to

/usr/bin/mediainfo

/usr/bin/mkvpropedit

and restarted emby server. I just ran a lib scan, and then ran the Media Info task and got the same thing. I also (for S&G) went into the GUI config and it still just has /usr/bin, annd the config file has the path as well now. So if I open the GUI, it changes it back.

So I did the same thing, and this time, did NOT check the at all, and just ran the task, and again, same errors.

 

 

embyserver (2).txt 4.57 kB · 0 downloads

hmmm - is this the DLL version or the Plugin catalogue version ?

You ould try and force the path to stay/be used.  For that, you'll need to shutdown emby - edit the xml manually (with the full path) and then start emby again - and see if it sticks..

it 'might' be a browser cache thing ..

Edited by rbjtech
Posted
3 minutes ago, rbjtech said:

hmmm - is this the DLL version or the Plugin catalogue version ?

You ould try and force the path to stay/be used.  For that, you'll need to shutdown emby - edit the xml manually (with the full path) and then start emby again - and see if it sticks..

it 'might' be a browser cache thing ..

It is the Plugin Catalogue version. I'll try the manual edit / shutdown method.

Is the catalog or the dll the preferred method. (Well, for Linux)

Posted
38 minutes ago, robsch said:

It is the Plugin Catalogue version. I'll try the manual edit / shutdown method.

Is the catalog or the dll the preferred method. (Well, for Linux)

!!Update & Solved!!

So I did some digging on the OS level. The version of mediainfo and mkvpropedit were symlinks to the actual binaries where were in /bin.

As soon as I changed it to /bin/mediainfo and /bin/mkvpropedit (in the GUI), it worked like a champ.

 

For anyone using a *nix, check your paths and make sure they are not symlinked to an path!

 

 

  • Thanks 1
Posted

and one hint from me it's also running again :)

auto update the emby docker with synology tools and 10 restarts are not enough if you have the moded version. I needed a repull and recreate via portainer

  • Thanks 1
Posted

Can you explain the current logic behind detecting tracks as commentary?

For example, it worked here for Spinal Tap:

image.png.035933d500b24888da8f959cd5628abd.png

But not for The Crow:

image.png.e4c0a1bbaf0b874fb3dea6bc13784e93.png

 

I would imagine it looks for stereo tracks, that are not default or something along those lines?

Posted
57 minutes ago, lardners said:

Can you explain the current logic behind detecting tracks as commentary?

For example, it worked here for Spinal Tap:

image.png.035933d500b24888da8f959cd5628abd.png

But not for The Crow:

image.png.e4c0a1bbaf0b874fb3dea6bc13784e93.png

 

I would imagine it looks for stereo tracks, that are not default or something along those lines?

 

Hi - See - https://emby.media/community/index.php?/topic/126561-support-for-mkv-commentary-flag/

 

Unfortunately, even MediaInfo does not support the commentary 'flag' - or I would have used that in parallel for detection.

If Emby ever supports the commentary MKV flag (via ffmpeg) - then I'll update the plugin to work with it - but this is the only option thus far.

btw - I should actually update this to provide the option to keep the actual full text ie 'Commentary By the Director Joe Blogs' and put that in the brackets rather than just the word Commentary - but I guess it's better than nothing.

 

Posted
50 minutes ago, rbjtech said:

 

Hi - See - https://emby.media/community/index.php?/topic/126561-support-for-mkv-commentary-flag/

 

Unfortunately, even MediaInfo does not support the commentary 'flag' - or I would have used that in parallel for detection.

If Emby ever supports the commentary MKV flag (via ffmpeg) - then I'll update the plugin to work with it - but this is the only option thus far.

btw - I should actually update this to provide the option to keep the actual full text ie 'Commentary By the Director Joe Blogs' and put that in the brackets rather than just the word Commentary - but I guess it's better than nothing.

 

Ah ok, I understand how it works now. The Crow never had the word 'commentary' in the secondary track title (before being processed by Mediainfo), but Spinal Tap did.

Thank you

  • 2 weeks later...
Posted

hi experts what could be the reason that all my tags (like dts x) are overwritten constantly, sometimes after a week or so. seems like I have a wrong setting somewhere in lib settings?

the Plugin works perfectly, after running it I have 40 movies with a dts x tag. but it cannot be the idea to run it (complete refresh) every week? 

many thanks!! 

Posted (edited)
22 hours ago, supermood said:

hi experts what could be the reason that all my tags (like dts x) are overwritten constantly, sometimes after a week or so. seems like I have a wrong setting somewhere in lib settings?

the Plugin works perfectly, after running it I have 40 movies with a dts x tag. but it cannot be the idea to run it (complete refresh) every week? 

many thanks!! 

If it's just the tags that are getting overwritten (the track titles remain) then something in emby is resetting them - likely a metadata refresh schedule ?    Check the per library settings or maybe an external app is forcing a metadata refresh ?

Edited by rbjtech
Posted
1 hour ago, rbjtech said:

If it's just the tags that are getting overwritten (the track titles remain) then something in emby is resetting them - likely a metadata refresh schedule ?    Check the per library settings or maybe an external app is forcing a metadata refresh ?

thanks rbjtech!!

yes trsck titles remain. no external tool here. 

that was basically my thought. didn't know that metadata refresh is overwriting it did this sometimes even manually but now I remember after using the addon I have to scan the kjbrary not refreshing metadata :(

also have to check if there's a schedule for it. I'm an idiot! 

thanks! 

 

  • Like 1
Posted
On 12/9/2024 at 1:34 PM, rbjtech said:

If it's just the tags that are getting overwritten (the track titles remain) then something in emby is resetting them - likely a metadata refresh schedule ?    Check the per library settings or maybe an external app is forcing a metadata refresh ?

can you think of something else? no schedule no manual update but again half of the tags are gone after some days :(

Posted
42 minutes ago, supermood said:

can you think of something else? no schedule no manual update but again half of the tags are gone after some days :(

Can you give an example ?

What do you mean by half the tags ?

Are you using a media manger outside of emby perhaps (TMM) ?

Are you using NFO files ?

The plugin does not remove tags, only add, so I believe something is refreshing the metadata..

 

Posted
1 hour ago, rbjtech said:

Can you give an example ?

What do you mean by half the tags ?

Are you using a media manger outside of emby perhaps (TMM) ?

Are you using NFO files ?

The plugin does not remove tags, only add, so I believe something is refreshing the metadata..

 

thanks! yes examples are always my harry potter collection. they have dts x sound and therefore they have an dts x tags - after running the addon.

but 3 days later only one of them has the tag. the list that opens after pressing movies - tags - dts x is very short again. 

no external tool at all. and yes. nfo files. I know the tool doesn't remove the tags but I cannot find a setting that does so I thought I ask here.  

without the tool I would have never looked at the tags at all ;)

 

 

Posted
12 hours ago, supermood said:

thanks! yes examples are always my harry potter collection. they have dts x sound and therefore they have an dts x tags - after running the addon.

but 3 days later only one of them has the tag. the list that opens after pressing movies - tags - dts x is very short again. 

no external tool at all. and yes. nfo files. I know the tool doesn't remove the tags but I cannot find a setting that does so I thought I ask here.  

without the tool I would have never looked at the tags at all ;)

 

 

think I found the issue!! many thanks rbjtech!! 

  • Like 1
Posted
49 minutes ago, supermood said:

think I found the issue!! many thanks rbjtech!! 

Great - if it was the issue, then post here as it may help others :)

  • Like 1
  • Agree 1

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...