SageTV Community

SageTV Community (http://forums.sagetv.com/forums/index.php)
-   SageTV Software (http://forums.sagetv.com/forums/forumdisplay.php?f=6)
-   -   Imported Videos with 0:00:00 Length (http://forums.sagetv.com/forums/showthread.php?t=66952)

phantomii 02-14-2022 11:50 AM

Imported Videos with 0:00:00 Length
 
So, I went to watch an imported video last night and saw an old and recurring issue. It had a total play length of 0:00:00 and as a result causes navigation issues. So I looked through my imports and determined that this began around December 26th, 2021 as all videos imported after that date had the 0:00:00 length. So I saw a note about doing a full rescan of the Library under setup so I tried that. Now my entire library (3000) items seem to have converted to a reported length of 0:00:00.

I have had this before and was only ever able to fix this with a clean install. I absolutely do not want to do that now. Any thought on steps to fix this?

John

MattHelm 02-14-2022 01:30 PM

Are you running BMT?

wayner 02-14-2022 02:59 PM

Sometimes this can be caused by issues of the Create date of the file. I have a transcode process where I would use Handbrake to transcode a file and I had this issue as the new file had a different. To fix it I used a program to change the file create date to the original airing time of the show. But this isn't easy to do after the fact. Try searching these forums for file creation date or something like that.

And maybe this will help https://forums.sagetv.com/forums/showthread.php?t=29312

egeller 02-14-2022 07:06 PM

Are you on Windows or Linux / Unraid?
What plug-ins do you have installed?
Is one of the plugins a SageTVTranscoder plug-in from jvl711?
Is one "Media Format Parser Plugin Windows" either x32or x64?

I ask because I spent a couple of days, last week, testing, and chasing down the same symptoms you describe.

I found that, on Linux, the Media Format Parser plugin is not available. When I installed the Transcoder plugin, I got the symptoms you describe. Reverting to the original Sage version of ffmpeg fixes the problem, but I had to uninstall the Transcoder plugin until the Media Format Parser is available for Linux.

Both functions use ffmpeg. The original Media Format Parsing does not seem to like the updated ffmpeg version. I kept seeing error messages when SageTV attempted format detection.

When you "Scan Imported Media" there should be error messages in the SageTV log that will help diagnose what the issue is, if it is not what I have describe here.

phantomii 02-15-2022 06:53 AM

I am running an unraid docker for SageTV. I believe I installed the SageTVTranscoder plug-in around the time this started so that is likely. With Docker it updates the version every time it restarts I believe. So I uninstalled the SageTVTranscoder plug-in but am unsure how to roll back the ffmpeg version if I need to do so. It would appear that uninstalling the SageTVTranscoder plug-in did not by itself fix the problem as I did the rescan and still have the issue. Other thoughts?

egeller 02-15-2022 12:23 PM

Quote:

Originally Posted by phantomii (Post 633401)
I am running an unraid docker for SageTV. I believe I installed the SageTVTranscoder plug-in around the time this started so that is likely. With Docker it updates the version every time it restarts I believe. So I uninstalled the SageTVTranscoder plug-in but am unsure how to roll back the ffmpeg version if I need to do so. It would appear that uninstalling the SageTVTranscoder plug-in did not by itself fix the problem as I did the rescan and still have the issue. Other thoughts?

yep,a few. Uninstalling the transcoder plug-in SHOULD have renamed the ffmpeg versions for you and undo what it had done. However, in my testing I did see occurrences where it did not.

First, my weapon of choice for looking at a Linux file system is WinSCP. It is open source (free) and used by IT professionals everywhere. However, Unraid also has it's tools that let you look at files via a browser.

Here is how to roll back the ffmpeg versions manually:
On Unraid, Check the folder /mnt/user/appdata/sagetv/server/ or whatever folder your SageTV lives in.

ffmpeg, in that folder, needs to be 7821 KB, not 23,494 KB.
If it is not, there is probably a file named "ffmpeg.nnn" that is 7821 KB. The nnn will be a 3-digit number.
Rename the existing ffmpeg to ffmpeg.new
Rename the "ffmpeg.nnn" to ffmpeg.
Rescan imported media and see if that works.

I found that I did not need to restart SageTV after making the changes I have noted here. Your mileage may vary.

If it still does not work, check the SageTV log, sagetv_0.txt in the same folder. Look for "libraryimporter" in the log to find messages related to the Scan Imported Media. For each file it scans there will be a block of lines in the log. Bring them back here, and I can take a look at them.

wayner 02-15-2022 01:05 PM

Will this change stick after SageTV is upgraded as the docker will install the latest version upon restart?

phantomii 02-15-2022 05:32 PM

So it appears that I have the 7.8 M ffmpeg file. I reinstalled the SageTVTranscoder plug-in and confirmed it was ~23 M then uninstalled it and confirmed it returned to 7.8 M. Tried a rescan both with, and without the SageTVTranscoder plug-in and still have zero length imports. I looked at the file and see no errors on or around any of the LibraryImporter. Here are a couple lines:

Tue 2/15 18:16:11.635 [LibraryImporter@3aa2391b] Reimporting metadata for mediafile because it changed:MediaFile[id=74517 A[4853659,74518,"The First Purge",0@1019.17:42,0,V] mask=V host=MediaServer encodedBy= format=MATROSKA 0:00:00 0 kbps [{PropertiesWrittenBy=CMT}] /unraid/dvd_videos/The First Purge.mkv, Seg0[Fri 10/19 17:42:18.999-Fri 10/19 17:42:19.000]]
Tue 2/15 18:16:11.636 [LibraryImporter@3aa2391b] Now using external format detector for: /unraid/dvd_videos/The First Purge.mkv
Tue 2/15 18:16:11.643 [LibraryImporter@3aa2391b] File Format Parsed /unraid/dvd_videos/The First Purge.mkv=MATROSKA 0:00:00 0 kbps [{PropertiesWrittenBy=CMT}]
Tue 2/15 18:16:11.646 [LibraryImporter@3aa2391b] Reimporting metadata for mediafile because it changed:MediaFile[id=74523 A[4853660,74524,"The Flowers of War",0@0322.01:39,0,V] mask=V host=MediaServer encodedBy= format=Quicktime 0:00:00 0 kbps [{PropertiesWrittenBy=CMT}] /unraid/dvd_videos/The Flowers of War.m4v, Seg0[Thu 3/22 1:39:53.999-Thu 3/22 1:39:54.000]]
Tue 2/15 18:16:11.647 [LibraryImporter@3aa2391b] Now using external format detector for: /unraid/dvd_videos/The Flowers of War.m4v
Tue 2/15 18:16:11.653 [LibraryImporter@3aa2391b] File Format Parsed /unraid/dvd_videos/The Flowers of War.m4v=Quicktime 0:00:00 0 kbps [{PropertiesWrittenBy=CMT}]

egeller 02-15-2022 09:11 PM

Quote:

Originally Posted by phantomii (Post 633419)
So it appears that I have the 7.8 M ffmpeg file. I reinstalled the SageTVTranscoder plug-in and confirmed it was ~23 M then uninstalled it and confirmed it returned to 7.8 M. Tried a rescan both with, and without the SageTVTranscoder plug-in and still have zero length imports. I looked at the file and see no errors on or around any of the LibraryImporter.

I am puzzled. Please try this
  1. Restart SageTV.
  2. Execute a Scan Imported Media.
  3. Capture your sage_0.txt log file and post it here. You may need to zip it up first, before you attach it.

I'd like to look at the entire log file, right after a reboot, and after a media scan.

By the way, If someone asked me to do this, I'd redact my log file of some of the trashy video files that might appear. Feel free to redact.

I am looking for what versions of Jar files are loaded, and any extraneous error messages that, at first I thought were unrelated.

Linux gearhead comment
On my system I noticed, at one point, that the eXecutable bit was not set ON for ffmpeg, so I set it ON. Since I found it off, I assumed SageTV and Java was using it even though it was not on. The programmer in me could not allow an executable bit set OFF for a program. I wonder if that is making any difference.

egeller 02-15-2022 09:27 PM

Quote:

Originally Posted by wayner (Post 633409)
Will this change stick after SageTV is upgraded as the docker will install the latest version upon restart?

I think the answer is yes, but I am not sure.

The latest version check at restart is for the version of Sage.jar. From my experience, with my testing last week, a reboot did not touch ffmpeg, if that's what you're asking.

If you are already on the latest version, then nothing gets touched.

If you are not, then that's a question that can be answered by whoever built the docker. I could take a guess, but I'd get something wrong. Sage.jar seems to get updated. Plugins do not seem to get touched. Beyond that, I have never asked the question.

jusjoken 02-15-2022 09:58 PM

Quote:

Originally Posted by egeller (Post 633433)
I think the answer is yes, but I am not sure.

The latest version check at restart is for the version of Sage.jar. From my experience, with my testing last week, a reboot did not touch ffmpeg, if that's what you're asking.

If you are already on the latest version, then nothing gets touched.

If you are not, then that's a question that can be answered by whoever built the docker. I could take a guess, but I'd get something wrong. Sage.jar seems to get updated. Plugins do not seem to get touched. Beyond that, I have never asked the question.

Basically, if the file is included in the installer then it will be replaced. It will not touch the properties or files installed by plugins unless they replace an existing SageTV installed file.

K

phantomii 02-16-2022 05:54 AM

1 Attachment(s)
Quote:

Originally Posted by egeller (Post 633431)
I am puzzled. Please try this
  1. Restart SageTV.
  2. Execute a Scan Imported Media.
  3. Capture your sage_0.txt log file and post it here. You may need to zip it up first, before you attach it.

I'd like to look at the entire log file, right after a reboot, and after a media scan.

By the way, If someone asked me to do this, I'd redact my log file of some of the trashy video files that might appear. Feel free to redact.

I am looking for what versions of Jar files are loaded, and any extraneous error messages that, at first I thought were unrelated.

Linux gearhead comment
On my system I noticed, at one point, that the eXecutable bit was not set ON for ffmpeg, so I set it ON. Since I found it off, I assumed SageTV and Java was using it even though it was not on. The programmer in me could not allow an executable bit set OFF for a program. I wonder if that is making any difference.


Here is the file. Let me know what you think. I am also unsure what to do with the Executable bit. Not a big Linux guy but learning!

egeller 02-16-2022 07:49 AM

Quote:

Originally Posted by phantomii (Post 633442)
Here is the file. Let me know what you think. I am also unsure what to do with the Executable bit. Not a big Linux guy but learning!

Cases like these require a poultice of goat offal and bat guano.

I was able to reproduce the symptoms on my Test system. The only change I made was to set the eXecutable bit OFF for ffmpeg. Needless to say, I set it back ON and rescanned. The problem then disappeared.

Let me know what tools you are using to access the Linux file system and maybe I can guide you through checking to see if that is your problem. One you verify the bit is OFF, then I can help you fix it.

For WinSCP, assuming you're logged in as root, you can fix it by finding the file and right-mouse clicking it, choose "Properties" then check the 3 "X" checkboxes.

You can also do it through Putty or, as Unraid calls it, the Console or Terminal from the >_ icon in the top left of the Unraid browser window. Navigating to the correct directory differs, depending on if you are inside the SageTV docker or if you access the Terminal, from the >_ icon. Navigating to the correct directory is done via the
cd
command.
Checking it is
ls -l ffmpeg
the permissions should be
rwxr-xr-x
Fixing it is a Linux command
chmod 755 ffmpeg
once you navigate to the correct directory.


After the eXecutable bit is set ON, you can rescan and see if that fixes it.

phantomii 02-16-2022 08:06 AM

Through the Unraid Console I did these things! I think it looked correct before I ran the commands?

# ls -l ffmpeg
-rwxr-xr-x 1 sagetv users 8129632 Jan 5 18:14 ffmpeg

# chmod 755 ffmpeg

# ls -l ffmpeg
-rwxr-xr-x 1 sagetv users 8129632 Jan 5 18:14 ffmpeg

phantomii 02-16-2022 08:10 AM

I also saw this command in another post to determine if there were permission issues. So I ran this and here are the results:

# ./ffmpeg
./ffmpeg: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.27' not found (required by ./ffmpeg)


Does this provide any insight?

I did look in the /lib/x86_64-linux-gnu/ folder and I do see a file called "libm.so.6".....

egeller 02-16-2022 08:59 AM

Quote:

Originally Posted by phantomii (Post 633444)
Through the Unraid Console I did these things! I think it looked correct before I ran the commands?

Yes, it did. Now I'm perplexed

phantomii 02-16-2022 09:33 AM

Quote:

Originally Posted by egeller (Post 633447)
Yes, it did. Now I'm perplexed

So I looked a bit more into the:

./ffmpeg: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.27' not found (required by ./ffmpeg) error that I saw.

And it appears to me that the version of whatever this folder is looks to be 2.23 versus the 2.27 required. Not sure why this would be the case as I assume these come in through with the Docker Container and it does not seem logical it could have been downgraded??? Unless version 2.23 came with the docker and some ffmpeg updates require 2.27?

jusjoken 02-16-2022 09:49 AM

Quote:

Originally Posted by phantomii (Post 633448)
So I looked a bit more into the:

./ffmpeg: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.27' not found (required by ./ffmpeg) error that I saw.

And it appears to me that the version of whatever this folder is looks to be 2.23 versus the 2.27 required. Not sure why this would be the case as I assume these come in through with the Docker Container and it does not seem logical it could have been downgraded??? Unless version 2.23 came with the docker and some ffmpeg updates require 2.27?

What docker are you using?

I ask as the new dockers are all running ubuntu 20.04 which includes GLIBC 2.28 so in theory you would not get the error you show here.

K

phantomii 02-16-2022 10:00 AM

Quote:

Originally Posted by jusjoken (Post 633449)
What docker are you using?

I ask as the new dockers are all running ubuntu 20.04 which includes GLIBC 2.28 so in theory you would not get the error you show here.

K

I am using a Docker from about a year back which was just as things were moving to Github from the old hosting place for images and Plugins. If I need to update can I do so by replacing the Docker with a new one and copying my wiz and properties files over after install?

Also, I have separate SageTV and OpenDCT Dockers today. Are they all merged in the new Dockers? Thought I heard something about that sometime back but have avoided upgrading as everything was working.....

egeller 02-16-2022 12:13 PM

Quote:

Originally Posted by phantomii (Post 633451)
I am using a Docker from about a year back which was just as things were moving to Github from the old hosting place for images and Plugins. If I need to update can I do so by replacing the Docker with a new one and copying my wiz and properties files over after install?

Also, I have separate SageTV and OpenDCT Dockers today. Are they all merged in the new Dockers? Thought I heard something about that sometime back but have avoided upgrading as everything was working.....

I do not think the Docker is the issue, unless there is something in the path definition that is done differently. I do not suspect that, but am looking into it.

Your Sage version, from your log, is "SageTV V9.2.8.1". That is the same version I have on my test system and I am probably running a different docker than you there. I am running sagetvopen-sagetv-server-java11 on my test machine.

My production machine still runs the stuckless-sagetv-server-java11 docker. I was seeing the same format detection symptoms on both servers. I resolved them on test, then applied changes to production.

By the way, installing a new SageTV docker does not involved new file directories, unless you choose to do that. As long as you understand that you can only run 1 version of Opendct-docker or SageTV-docker at a time, it is a simple process of defining the new docker to point to your existing file structure. Using the combined Opendct-SageTV docker is also optional. On my test system I run them separately.

I am still wading through your log and comparing it to mine. I have not found anything yet. Based on what you found with /mnt/.../sagetv/server/ffmpeg, it should be workiing, I think.


All times are GMT -6. The time now is 02:57 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2022, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.