Jump to content

Chromecast hangs on files that have no audio track


MattJM

Recommended Posts

Hello,

I am really enjoying the functionality of Emby server. It has all the features I want and the interface is the best of all the media servers I've seen.

I'm running it via the docker container and it works great, but I noticed one problem: I have many videos that are taken with a DJI drone, and by default there is no audio recorded by the device. These videos will play fine in the web interface and mobile app, but when I try to chromecast them, they will not play (video just hangs at 0:00 with black screen). At first I thought it was a video transcoding issue but the log revealed the following:

2020-11-16 07:45:13.898 Error HttpServer: Error processing request
    *** Error Report ***
    Version: 4.5.2.0
    Command line: /app/emby/EmbyServer.dll -programdata /config -ffdetect /app/emby/ffdetect -ffmpeg /app/emby/ffmpeg -ffprobe /app/emby/ffprobe -restartexitcode 3
    Operating system: Linux version 4.14.0-0.bpo.3-amd64 (debian-kernel@lists.debian.org) (gcc version 6.3.0 20170516 (Debian 6.3.0-18)) #1 SMP Debian 4.14.13-1~bpo9+1 (201
    Framework: .NET Core 3.1.7
    OS/Process: x64/x64
    Runtime: app/emby/System.Private.CoreLib.dll
    Processor count: 24
    Data path: /config
    Application path: /app/emby
    System.Exception: System.Exception: Audio stream index '0' not found in input.
    
       at Emby.Server.MediaEncoding.Encoder.TranscodingCommandBuilder.MapStreams(EncodingJobInfo state, InputFile input, OutputFile output, Boolean allAudioStreams)
       at Emby.Server.MediaEncoding.Encoder.TranscodingCommandBuilder.GetProgressiveVideoFullCommandLine(EncodingJobInfo state, String outputPath)
       at Emby.Server.MediaEncoding.Api.BaseStreamingService.StartFfMpeg(StreamState state, String outputPath, CancellationTokenSource cancellationTokenSource, Boolean acquireResources)
       at Emby.Server.MediaEncoding.Api.Progressive.BaseProgressiveStreamingService.GetStreamResult(StreamState state, IDictionary`2 responseHeaders, Boolean isHeadRequest, CancellationTokenSource cancellationTokenSource)
       at Emby.Server.MediaEncoding.Api.Progressive.BaseProgressiveStreamingService.ProcessRequest(StreamRequest request, Boolean isHeadRequest)
       at Emby.Server.Implementations.Services.ServiceController.GetTaskResult(Task task)
       at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync(HttpListenerHost appHost, IRequest httpReq, IResponse httpRes, RestPath restPath, String responseContentType, CancellationToken cancellationToken)
       at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler(IRequest httpReq, ReadOnlyMemory`1 urlString, ReadOnlyMemory`1 localPath, CancellationToken cancellationToken)
    Source: Emby.Server.MediaEncoding
    TargetSite: Void MapStreams(Emby.Server.MediaEncoding.Encoder.EncodingJobInfo, Emby.Ffmpeg.Model.Input.InputFile, Emby.Ffmpeg.Model.Output.OutputFile, Boolean)

 

I think there could be a somewhat straightforward workaround by modifying the ffmpeg call... Something like the solution described here: https://superuser.com/questions/1457683/ffmpeg-ignore-audio-export-if-no-stream-present

 

I don't know where to go from here but suggestions welcome! I'm not opposed to modifying the docker container if this is the type of thing that would cause issues in other cases... I thought about creating a bash alias to modify what happens when ffmpeg is called but I don't think it would actually work if the command is built by the app anyway.

 

Thanks in advance for any help, and please let me know if more information is required.

 

Matt

Link to comment
Share on other sites

Hi... I just realized I mistakenly posted this in the Android forum, probably should have gone in the Linux one. Sorry, not sure how to fix.

Link to comment
Share on other sites

Thanks so much for your quick reply, Luke.


I've attached the server log. I don't think it generated an ffmpeg log for instances where the chromecast playing failed, as far as I can tell? I did, however, attach a log for when the file played successfully (I assume that's what it's from) in case that's useful.

All the best

Matt

ffmpeg-transcode-40adfa58-cb0d-4184-a3c4-e0449c1768e0_1.txt embyserver.txt

Link to comment
Share on other sites

Hi Luke,

Thanks for the reply.

I haven't altered any of the files or the metadata. I have however taken the docker container up and down a few times.

I tried refreshing the metadata - still no luck. Does metadata encompass file properties? Or just information like dates, names, etc.?

I have made some more observations though:

- the 1080p files produced by the drone, with no audio, will now play with no problem on the chromecast (not sure if I did anything different to make this happen??)

- 2.7k files will still not play

- likely unrelated - but I have some MTS files (h264) produced by a Sony camcorder and these do not cast video, but the audio plays (while the Emby splash screen is shown).

I would guess that these are all media related issues. All the files I have tested to date play fine on android and web interface... it's just that pesky chromecast (I've tried it on ultra, the new android tv, and a Nest display - same results on each).

It seems possible that, as you've mentioned in other posts, Emby isn't transcoding files that should be transcoded for chromecast. Although I've looked through their supported media on the ultra and it really seems like the files should play direct with no problems. It's quite confusing.

I wonder (in my naiive view not knowing at all how the back end of Emby works) if it would be a straightforward solution to offer a "force transcode" under the chromecast playback dropdown menu. I have indeed tried lowering the playback quality for chromecast (down to 1080 5 mpbs) and it doesn't seem to solve my issues.

I guess the other solution would be to remux... But I like the idea of not having to do extra work on an ongoing basis!

Please let me know if it would be useful to have more information/tests or additional logs.

Thanks again,

Matt

Link to comment
Share on other sites

  • 1 month later...

Hi - sorry for the delay, but finally, here's some examples of the types of videos that cause problems.

Interestingly, Jellyfin is able to play these on the chromecast without issue, but it struggles with other completely different videos. Really rather baffling to me. I run everything via docker and it is a server with 192 GB RAM and 24 cores (2 ghz xeon e5 2620) so I'm sure the hardware should be able to handle it.

Hope this is helpful!

All the best for the holidays,

Matt

00199.MTS

Link to comment
Share on other sites

On 12/24/2020 at 12:10 PM, MattJM said:

Hi - sorry for the delay, but finally, here's some examples of the types of videos that cause problems.

Interestingly, Jellyfin is able to play these on the chromecast without issue, but it struggles with other completely different videos. Really rather baffling to me. I run everything via docker and it is a server with 192 GB RAM and 24 cores (2 ghz xeon e5 2620) so I'm sure the hardware should be able to handle it.

Hope this is helpful!

All the best for the holidays,

Matt

00199.MTS 102.56 MB · 1 download

Hi, this one seems to be working for me. Can you attach the ffmpeg log? thanks.

Link to comment
Share on other sites

  • 3 months later...
MattJM

Hi again Luke,

Finally got a chance to get back into this.

So, same problem as before. It's just for the drone footage that has no audio track - and sorry to say there is no ffmpeg log, it doesn't make it that far. Relevant chunk of server log attached as text file. Specifically, an example of where it fails is pasted below.

I'm running version 4.5.4.0 in a docker container. Works fine on everything (Android, Windows) except chromecast.

Thanks again for any insight. Strange that the file would work on your end but not in my case...

Matt

 

*** Error Report ***
    Version: 4.5.4.0
    Command line: /system/EmbyServer.dll -programdata /config -ffdetect /bin/ffdetect -ffmpeg /bin/ffmpeg -ffprobe /bin/ffprobe -restartexitcode 3
    Operating system: Linux version 4.19.0-12-amd64 (debian-kernel@lists.debian.org) (gcc version 8.3.0 (Debian 8.3.0-6)) #1 SMP Debian 4.19.152-1 (2020-10-18)
    Framework: .NET Core 3.1.8
    OS/Process: x64/x64
    Runtime: system/System.Private.CoreLib.dll
    Processor count: 24
    Data path: /config
    Application path: /system
    System.Exception: System.Exception: Audio stream index '0' not found in input.

  at Emby.Server.MediaEncoding.Encoder.TranscodingCommandBuilder.MapStreams(EncodingJobInfo state, InputFile input, OutputFile output, Boolean allAudioStreams)
       at Emby.Server.MediaEncoding.Encoder.TranscodingCommandBuilder.GetProgressiveVideoFullCommandLine(EncodingJobInfo state, String outputPath)
       at Emby.Server.MediaEncoding.Api.Progressive.VideoService.GetCommandLineArguments(String outputPath, StreamState state)
       at Emby.Server.MediaEncoding.Api.BaseStreamingService.StartFfMpeg(StreamState state, String outputPath, CancellationTokenSource cancellationTokenSource, Boolean acquireResources)
       at Emby.Server.MediaEncoding.Api.Progressive.BaseProgressiveStreamingService.GetStreamResult(StreamState state, IDictionary`2 responseHeaders, Boolean isHeadRequest, CancellationTokenSource cancellationTokenSource)
       at Emby.Server.MediaEncoding.Api.Progressive.BaseProgressiveStreamingService.ProcessRequest(StreamRequest request, Boolean isHeadRequest)
       at Emby.Server.Implementations.Services.ServiceController.GetTaskResult(Task task)
       at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync(HttpListenerHost appHost, IRequest httpReq, IResponse httpRes, RestPath restPath, String responseContentType, CancellationToken cancellationToken)
       at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler(IRequest httpReq, ReadOnlyMemory`1 urlString, ReadOnlyMemory`1 localPath, CancellationToken cancellationToken)
    Source: Emby.Server.MediaEncoding
    TargetSite: Void MapStreams(Emby.Server.MediaEncoding.Encoder.EncodingJobInfo, Emby.Ffmpeg.Model.Input.InputFile, Emby.Ffmpeg.Model.Output.OutputFile, Boolean)

emby_log.txt

Link to comment
Share on other sites

Ok that error I recognize and should be resolved in the upcoming 4.6 release. Thanks.

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