Jump to content

New installation - videos won't play


Recommended Posts

Posted (edited)

I've just installed Emby for the first time on a Centos 7 64-bit box.

 

I've created a media folder in the root and copied some photos and home movie files to subfolders within that. Obviously I want to see my creation working! I've change the ownership of the folders and files to Emby.

 

Connecting from a browser either on the server itself or on a windows machine I can see the media. I can look at the photos but I can't play the movies which are all AVI files.

 

All I get on the browser is "There was an error playing the video" although the screen seems to have captured all of the details of the file. I have tried several files all with the same result.

 

The log file for one of these attempts is:

{"Protocol":"File","Id":"9d75eccf0b17b4f7ec07392b31832acb","Path":"/embymedia/homemovies/Raw Video/Clare - 25 Dec 2002 - 16 Dec 17.avi","Type":"Default","Container":"avi","Name":"PCM_S16LE","ETag":"dd85e5bc87a956c92ad46115c54229af","RunTimeTicks":13226400000,"ReadAtNativeFramerate":false,"SupportsTranscoding":true,"SupportsDirectStream":true,"SupportsDirectPlay":true,"RequiresOpening":false,"RequiresClosing":false,"VideoType":"VideoFile","MediaStreams":[{"Codec":"mjpeg","CodecTag":"MJPG","TimeBase":"1/25","CodecTimeBase":"1/25","IsInterlaced":false,"BitRate":14374761,"BitDepth":8,"RefFrames":1,"IsDefault":false,"IsForced":false,"Height":544,"Width":720,"AverageFrameRate":25,"RealFrameRate":25,"Type":"EmbeddedImage","AspectRatio":"4:3","Index":0,"IsExternal":false,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"PixelFormat":"yuvj422p","Level":-99,"IsAnamorphic":false},{"Codec":"pcm_s16le","TimeBase":"1/44100","CodecTimeBase":"1/44100","DisplayTitle":"PCM_S16LE 2 ch","IsInterlaced":false,"BitRate":1411200,"BitDepth":16,"Channels":2,"SampleRate":44100,"IsDefault":false,"IsForced":false,"Type":"Audio","Index":1,"IsExternal":false,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Level":0}],"PlayableStreamFileNames":[],"Formats":[],"Bitrate":15046494,"RequiredHttpHeaders":{}}/bin/ffmpeg -fflags +genpts -i file:"/embymedia/homemovies/Raw Video/Clare - 25 Dec 2002 - 16 Dec 17.avi" -map -0:v -map 0:1 -map -0:s -codec:v:0 libx264 -force_key_frames "expr:gte(t,n_forced*5)" -copyts -avoid_negative_ts disabled -start_at_zero -pix_fmt yuv420p -preset superfast -crf 23 -b:v 277861527 -maxrate 277861527 -bufsize 555723054 -vsync -1 -profile:v high -level 41 -map_metadata -1 -threads 0 -codec:a:0 libmp3lame -ac 2 -ab 1411200 -af "aresample=async=1" -y "/var/lib/emby-server/transcoding-temp/20325256b8f7a0d788d38d5a21860254.mkv"ffmpeg version 2.6.8 Copyright (c) 2000-2016 the FFmpeg developers  built with gcc 4.8.5 (GCC) 20150623 (Red Hat 4.8.5-4)  configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic' --enable-bzlib --disable-crystalhd --enable-gnutls --enable-ladspa --enable-libass --enable-libcdio --enable-libdc1394 --enable-libfaac --enable-nonfree --enable-libfdk-aac --enable-nonfree --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libx265 --enable-libxvid --enable-x11grab --enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect  libavutil      54. 20.100 / 54. 20.100  libavcodec     56. 26.100 / 56. 26.100  libavformat    56. 25.101 / 56. 25.101  libavdevice    56.  4.100 / 56.  4.100  libavfilter     5. 11.102 /  5. 11.102  libavresample   2.  1.  0 /  2.  1.  0  libswscale      3.  1.101 /  3.  1.101  libswresample   1.  1.100 /  1.  1.100  libpostproc    53.  3.100 / 53.  3.100[mjpeg @ 0x25d0d20] Changeing bps to 8Guessed Channel Layout for  Input Stream #0.1 : stereoInput #0, avi, from 'file:/embymedia/homemovies/Raw Video/Clare - 25 Dec 2002 - 16 Dec 17.avi':  Duration: 00:22:02.64, start: 0.000000, bitrate: 15046 kb/s    Stream #0:0: Video: mjpeg (MJPG / 0x47504A4D), yuvj422p(pc, bt470bg/unknown/unknown), 720x544, 14374 kb/s, 25 fps, 25 tbr, 25 tbn, 25 tbc    Stream #0:1: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, 2 channels, s16, 1411 kb/sStream map '0:v' matches no streams.

The only obvious 'error' I can see is the last line 'matches no streams' but that doesn't really help me.

Any suggestions, please?




			
				


	Edited  by jmangan
	
	

			
		
Posted

Hi, I would try updating your ffmpeg, then refresh the media in the web app with the new ffmpeg. then try to play again.

Alternative311
Posted

I have this similar issue. Only with certain movies.

Posted

I have this similar issue. Only with certain movies.

 

Hi there, sorry to hear about this. Please provide the information requested in how to report a media playback issue, and then we'll take a look. Thanks !

Posted

Luke, I built this over the weekend and have run 'yum update' more times than I can count.

 

It should be up to date shouldn't it?

 

Not sure what you mean by this, "refresh the media in the web app with the new ffmpeg". The ffmpeg is on the server, isn't it, so won't the browser automatically 'see' the new ffmpeg?

 

Thanks.

Posted

Luke, I built this over the weekend and have run 'yum update' more times than I can count.

 

It should be up to date shouldn't it?

 

Not sure what you mean by this, "refresh the media in the web app with the new ffmpeg". The ffmpeg is on the server, isn't it, so won't the browser automatically 'see' the new ffmpeg?

 

Thanks.

 

It says version 2.6.8, they are up to 3.X now.

 

The server will not automatically re-probe your media with the new ffmpeg because this process can take a long time for some users, so that's why the manual refresh would be needed with the new version.

Posted

Luke, like I said I am new to this so I am probably missing something blindingly simple but I have the epel, elrepo and nux-dextop repos enabled but when I run

'yum provides ffmpeg' I only see versions from '2.2.1-1' to '2.6.8-3'

 

If i run a 'yum update' I get no packages to update.

 

I'm on CentOS 7.2.1511 (Core) 64-bit

 

Thanks.

Posted

Luke, sorry I seem to be flailing around like a beached whale here.

 

I downloaded ffmpeg-git-64bit-static.tar.xz since the git build is recommended.

 

I unpacked and moved the content to /usr/share/ffmpeg3/ (to avoid over-writing what is already there).

 

Then I modified Playback -> Transcoding as shown in the attached file (this was the only path I could see).

 

Then I restarted emby-server for good measure and re-scanned the libraries.

 

Now I still get the video error message but there is no related transcoding log at all so I have attached the server log.

 

Thanks for your patience.

 

 

 

  

ffmpeg3path.rtf

Server-63609914161.txt

Posted

i cannot read that rtf file, but i can see this in the log

2016-09-19 20:36:26.5681 Error ServiceStackHost: ServiceBase<TRequest>::Service Exception
	*** Error Report ***
	Version: 3.0.7200.0
	Command line: /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /bin/ffmpeg -ffprobe /bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
	Operating system: Unix 3.10.0.327
	Processor count: 2
	64-Bit OS: True
	64-Bit Process: True
	Program data path: /var/lib/emby-server
	Mono: 4.4.2 (Stable 4.4.2.11/f72fe45 Mon Aug  8 22:33:00 UTC 2016)
	Application Path: /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe
	Access to the path "/usr/share/ffmpeg3/transcoding-temp" is denied.
	System.UnauthorizedAccessException

it appears you configured the transcoding temp path but the server does not have write access to it.

Posted

Not where I would have chosen to store ffmpeg, but...

 

Run "sudo chown -R emby:emby /usr/share/ffmpeg3"

 

You're getting permission problems according to your logs.

  • Like 1
Posted

Yes, I realised just after posting that wasn't the best place so I renamed the originals in /usr/bin and copied the new ones in there. 

 

Restarted server, re-scanned library.

 

Now I get this:

http://datastore.mangan.local:8096/emby/videos/9d75eccf0b17b4f7ec07392b31832acb/stream.mkv?DeviceId=01bac5a56f799880da7b3d393782cbac6a2db65d&MediaSourceId=9d75eccf0b17b4f7ec07392b31832acb&VideoCodec=h264&AudioCodec=mp3,aac&AudioStreamIndex=1&VideoBitrate=238588800&AudioBitrate=1411200&MaxAudioChannels=6&Level=51&Profile=high&PlaySessionId=7a4400a6e26843058fb2419dcec59ce0&api_key=fc712f92161e44599d39c8ae333b8cf6&CopyTimestamps=true&EnableSubtitlesInManifest=false&Tag=dd85e5bc87a956c92ad46115c54229af

{"Protocol":"File","Id":"9d75eccf0b17b4f7ec07392b31832acb","Path":"/embymedia/homemovies/Raw Video/Clare - 25 Dec 2002 - 16 Dec 17.avi","Type":"Default","Container":"avi","Name":"PCM_S16LE","ETag":"dd85e5bc87a956c92ad46115c54229af","RunTimeTicks":13226400000,"ReadAtNativeFramerate":false,"SupportsTranscoding":true,"SupportsDirectStream":true,"SupportsDirectPlay":true,"RequiresOpening":false,"RequiresClosing":false,"VideoType":"VideoFile","MediaStreams":[{"Codec":"mjpeg","CodecTag":"MJPG","TimeBase":"1/25","CodecTimeBase":"1/25","IsInterlaced":false,"BitRate":14374761,"BitDepth":8,"RefFrames":1,"IsDefault":false,"IsForced":false,"Height":544,"Width":720,"AverageFrameRate":25,"RealFrameRate":25,"Type":"EmbeddedImage","AspectRatio":"4:3","Index":0,"IsExternal":false,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"PixelFormat":"yuvj422p","Level":-99,"IsAnamorphic":false},{"Codec":"pcm_s16le","TimeBase":"1/44100","CodecTimeBase":"1/44100","DisplayTitle":"PCM_S16LE 2 ch","IsInterlaced":false,"BitRate":1411200,"BitDepth":16,"Channels":2,"SampleRate":44100,"IsDefault":false,"IsForced":false,"Type":"Audio","Index":1,"IsExternal":false,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Level":0}],"PlayableStreamFileNames":[],"Formats":[],"Bitrate":15046494,"RequiredHttpHeaders":{}}

/bin/ffmpeg -fflags +genpts -i file:"/embymedia/homemovies/Raw Video/Clare - 25 Dec 2002 - 16 Dec 17.avi" -map -0:v -map 0:1 -map -0:s -codec:v:0 libx264 -force_key_frames "expr:gte(t,n_forced*5)" -copyts -avoid_negative_ts disabled -start_at_zero -pix_fmt yuv420p -preset superfast -crf 23 -b:v 238588800 -maxrate 238588800 -bufsize 477177600 -vsync -1 -profile:v high -level 41 -map_metadata -1 -threads 0 -codec:a:0 libmp3lame -ac 2 -ab 1411200 -af "aresample=async=1" -y "/var/lib/emby-server/transcoding-temp/afd7afd5b4b0ef586da11b894fefa080.mkv"


ffmpeg version N-81696-gd38dff8e-static http://johnvansickle.com/ffmpeg/ Copyright © 2000-2016 the FFmpeg developers
built with gcc 5.4.1 (Debian 5.4.1-2) 20160904
configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --enable-libmp3lame --enable-libx264 --enable-libx265 --enable-libwebp --enable-libspeex --enable-libvorbis --enable-libvpx --enable-libfreetype --enable-fontconfig --enable-libxvid --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvo-amrwbenc --enable-gray --enable-libopenjpeg --enable-libopus --enable-libass --enable-gnutls --enable-libvidstab --enable-libsoxr --enable-frei0r --enable-libfribidi --disable-indev=sndio --disable-outdev=sndio --enable-librtmp --enable-libmfx --enable-libzimg --cc=gcc-5
libavutil 55. 29.100 / 55. 29.100
libavcodec 57. 57.100 / 57. 57.100
libavformat 57. 49.100 / 57. 49.100
libavdevice 57. 0.102 / 57. 0.102
libavfilter 6. 62.100 / 6. 62.100
libswscale 4. 1.100 / 4. 1.100
libswresample 2. 1.100 / 2. 1.100
libpostproc 54. 0.100 / 54. 0.100
Guessed Channel Layout for Input Stream #0.1 : stereo
Input #0, avi, from 'file:/embymedia/homemovies/Raw Video/Clare - 25 Dec 2002 - 16 Dec 17.avi':
Duration: 00:22:02.64, start: 0.000000, bitrate: 15046 kb/s
Stream #0:0: Video: mjpeg (MJPG / 0x47504A4D), yuvj422p(pc, bt470bg/unknown/unknown), 720x544, 14374 kb/s, 25 fps, 25 tbr, 25 tbn, 25 tbc
Stream #0:1: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, 2 channels, s16, 1411 kb/s
Stream map '0:v' matches no streams.
To ignore this, add a trailing '?' to the map.

 

So it seems to be using the new ffmpeg but I'm still getting the same error (or so it appears to me).

Posted

can you provide a sample file for testing? there's something odd about this. thanks.

Posted

Also word of warning regarding overwriting the executable in /usr/bin - that'll get overwritten every time you update the system installed package.

 

Instead place it in here: /var/lib/emby-server/ffmpeg/

Posted

Luke, the smallest file I am trying to view is ~300MB so I will set up a dropbox or some such and send you the details.

 

dcrdev, good point. I've copied the new ffmpeg to the folder you suggested (which existed but was empty?) and updated the Playback -> Transcoding -> Transcoding temporary path to reflect that. I also renamed the original files in /usr/bin but now the transcoding logs show that I am using the original files again?

 

Thanks for your help so far. Much appreciated and can't wait to get this workig properly. Just hoping the problem isn't something dumb I've done.

 

I'll try to find time tomorrow to rip a DVD and see if a different file format makes any difference.

Posted (edited)

Luke, the smallest file I am trying to view is ~300MB so I will set up a dropbox or some such and send you the details.

 

dcrdev, good point. I've copied the new ffmpeg to the folder you suggested (which existed but was empty?) and updated the Playback -> Transcoding -> Transcoding temporary path to reflect that. I also renamed the original files in /usr/bin but now the transcoding logs show that I am using the original files again?

 

Thanks for your help so far. Much appreciated and can't wait to get this workig properly. Just hoping the problem isn't something dumb I've done.

 

I'll try to find time tomorrow to rip a DVD and see if a different file format makes any difference.

 

Peculiar from start to finish do this:

# Just in case you wiped anything before (optional) 
sudo yum -y reinstall ffmpeg

sudo rm -rf /var/lib/emby-server/ffmpeg/*
sudo wget https://johnvansickle.com/ffmpeg/builds/ffmpeg-git-64bit-static.tar.xz -O /var/lib/emby-server/ffmpeg/20160919.tar.xz
sudo tar -xvf /var/lib/emby-server/ffmpeg/20160919.tar.xz -C /var/lib/emby-server/ffmpeg/
sudo mv /var/lib/emby-server/ffmpeg/ffmpeg-git-20160919-64bit-static /var/lib/emby-server/ffmpeg/20160919
sudo chown -R emby:emby /var/lib/emby-server/ffmpeg/

---------
Set ffmpeg path to /var/lib/emby-server/ffmpeg/20160919/ffmpeg in Emby
---------
sudo systemctl restart emby-server 

Also you don't need to be setting the transcoding temporary path unless you absolutely want to - leave it blank, you only need to set the ffmpeg path.

 

Edit:

Infact you might as well start with my configuration (paste the entire line into the terminal):

sudo rm -rf /var/lib/emby-server/config/encoding.xml && sudo wget https://www.dcrdev.com/encoding.xml -O /var/lib/emby-server/config/encoding.xml && sudo chown emby:emby /var/lib/emby-server/config/encoding.xml && sudo systemctl restart emby-server
Edited by dcrdev
Posted

I think this issue is limited to certain avi fyi.

Posted

dcrdev, okay I have part ripped a DVD (*.mkv) and that appears to play fine so it may be something odd about my .avi files.

 

I followed you instructions above until I got to:

 

Set ffmpeg path to /var/lib/emby-server/ffmpeg/20160919/ffmpeg in Emby

 

This is what I thought I was doing "setting the transcoding temporary path" following Luke's posting at 4:35pm yesterday: "then customize the path under playback -> transcoding"

 

Obviously I misunderstood something. Where and how should I set the ffmpeg path?

 

Thanks for the use of your config file but, at the moment, I am treating this as a learning exercise as much as getting things working so I would like to know what was wrong and how to fix it. At least until your patience with me runs out ;-)

 

I'm uploading a sample file (which plays in VLC) to Google Drive and I will add another post with the link when I get that done.

 

Thanks again.

Posted

There is a sample .avi here:

 

https://drive.google.com/drive/folders/0B72qsrqs3NjucktNWS1ZSTB3Vjg?usp=sharing

 

There is an associated .nfo file as well. Oddly most of the other files in the directory have associated .scn files although there are a couple of .nfo

 

It's so long since I copied them I can't remember why there is any difference. As I said above it plays in VLC so I don't think ti is corrupt and I have had the same problem with all of the half dozen I have tried so far.

 

Maybe Luke is correct and there is just an issue with certain AVI files in which case I would be grateful for any suggestions. about what to do.

Posted

dcrdev, okay I have part ripped a DVD (*.mkv) and that appears to play fine so it may be something odd about my .avi files.

 

I followed you instructions above until I got to:

 

Set ffmpeg path to /var/lib/emby-server/ffmpeg/20160919/ffmpeg in Emby

 

This is what I thought I was doing "setting the transcoding temporary path" following Luke's posting at 4:35pm yesterday: "then customize the path under playback -> transcoding"

 

Obviously I misunderstood something. Where and how should I set the ffmpeg path?

 

Thanks for the use of your config file but, at the moment, I am treating this as a learning exercise as much as getting things working so I would like to know what was wrong and how to fix it. At least until your patience with me runs out ;-)

 

I'm uploading a sample file (which plays in VLC) to Google Drive and I will add another post with the link when I get that done.

 

Thanks again.

 

See annotations below:

57e1a43e21544_Untitled.png

Posted

I meant customize the ffmpeg path, sorry, not the temporary path. I am sorry that I was not specific enough.

Posted

I don't have that. The first line under the 'Enable throttling' option is Transcoding temporary path.

 

Weird.

Posted

Also just tried your avi and wow that is massive (300MB) for 3 minutes - doesn't work for me either. I examined the file using vlc and it appears to be using a codec called mjpg (or Motion JPEG), I've never seen that used before but if it is just a series of jpg images that would go a long way to explaining the file size.

 

@@Luke can probably figure out why it's not working in Emby, but I would just encode it to another format as you're basically wasting disk space with that format.

Posted

I don't have that. The first line under the 'Enable throttling' option is Transcoding temporary path.

 

Weird.

 

Select "Use custom version" from the "Ffmpeg version:" dropdown, then you'll see it.

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