FAQ  •  Register  •  Login

Video won't stream to Mediabrowser

<<

smann

Serviio newbie

Posts: 2

Joined: Sat Nov 03, 2012 8:27 pm

Post Sat Nov 03, 2012 9:54 pm

Video won't stream to Mediabrowser

Good Afternoon Everyone!

This is my first post to the board so I'll try to be as clear and provide as much relevant information as I can to get off on the right foot!

I have a headless box running Centos 6. I've installed Serviio here. Following the guide at:
http://wiki.serviio.org/doku.php?id=how ... all:centos

Although some of my steps had top change as I was not able to get certain commands to work. Here are the steps I had to modify to get it working:
Step 8) I have iptables turned off as this is internal on my network, and I wanted to remove a layer of potential troubleshooting.
Step 9) Remove existing packages, and install essential build packages for later: Couldn't find liblamemp3, so I built this form the source on the Serviio download page, as well as rtmpdump.
Step 9) The ./configure for ffmpeg complain about not being able to find the librtmp until I ran: export PKG_CONFIG_PATH=”${PKG_CONFIG_PATH}:/usr/local/lib/pkgconfig”
Step 9) Installing FFmpeg from the source on the download page, the step to "make fprofiled" didn't work stating the the make "fprofiled" instruction didn't exist.

Reviewing the outputb from the configure step, all the libraries seemed enabled and there were no errors.
I proceeded to install ffmpeg, and then ran it from command line, it complained about missing libx264, I ran ldconfig and the error went away.

On a windows PC I ran the installer and xtracted the console, then added the libraries on my Nas for my various video files.

This indexed successfully and I could see them on my PS3. I selected and video and played it, and it worked fine.

I then ran the mediabrowser from the windows pc and was able to access the library, I could see videos and descriptions, but when I select the same video that played on the PS3, the loading symbol spins and nothing happens.

I ave done quit a bit of digging to try solve this and have collected the following information, but have hit a dead end. Hopefully someone else has seen this, or knows where I can look next.

1) When I hit play in the mediabrowser then ssh to my linux box and look in the tmp folder serviio is set to use, I see the "stf" file created and can watch it grow in size steadily.
2) top shows the serviio user running ffmpeg and that it is using it's fair share of memory and cpu, nothing out of the ordinary.
3) after a while the file stops growing, and the ffmpeg process ends, but the mediaplay still sits spinning.
4) When I grep the logs for the related info I see:
  Code:
./serviio.log:2012-11-03 16:08:16,291 DEBUG [VideoDeliveryEngine] Delivering file videofile.mkv' using transcoding
./serviio.log:2012-11-03 16:08:16,293 DEBUG [FFMPEGWrapper] Invoking FFmpeg to transcode video file: /mnt/media/videofile.mkv
./serviio.log:2012-11-03 16:08:16,294 DEBUG [ProcessExecutor] Starting /usr/local/bin/ffmpeg -i /mnt/media/videofile.mkv -y -copyts -c:v flv -b:v 1000k -maxrate:v 1000k -bufsize:v 1000k -vf scale=854:480 -r 24000/1001 -g 15 -c:a libmp3lame -b:a 192k -ar 44100 -ac 2 -map 0:0 -map 0:1 -sn -f flv /tmp/Serviio/transcoding-temp-11474-flv_player-MEDIUM.stf
./serviio.log:2012-11-03 16:08:16,797 DEBUG [VideoDeliveryEngine] Found Format profile for transcoded file videofile.mkv: FLV
./serviio.log:2012-11-03 16:08:16,797 DEBUG [VideoDeliveryEngine] Found Format profile for transcoded file videofile.mkv: FLV
./serviio.log:2012-11-03 16:08:16,797 DEBUG [VideoDeliveryEngine] Found Format profile for transcoded file videofile.mkv: FLV
./serviio.log:2012-11-03 16:14:39,767 WARN  [ProcessExecutor] Process /usr/local/bin/ffmpeg has a return code of 1! This is a possible error.

5) WHen I take the command it is running and run it myself: /usr/local/bin/ffmpeg -i /mnt/media/videofile.mkv -y -copyts -c:v flv -b:v 1000k -maxrate:v 1000k -bufsize:v 1000k -vf scale=854:480 -r 24000/1001 -g 15 -c:a libmp3lame -b:a 192k -ar 44100 -ac 2 -map 0:0 -map 0:1 -sn -f flv /tmp/Serviio/test.stf

It starts and gives the following output:
  Code:
ffmpeg version N-42368-gbf53863 Copyright (c) 2000-2012 the FFmpeg developers
  built on Nov  3 2012 15:56:59 with gcc 4.4.6 20120305 (Red Hat 4.4.6-4)
  configuration: --enable-gpl --enable-libfaac --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libx264 --enable-nonfree --enable-postproc --enable-version3 --enable-x11grab --enable-libvpx --enable-librtmp --enable-libxvid
  libavutil      51. 64.100 / 51. 64.100
  libavcodec     54. 33.100 / 54. 33.100
  libavformat    54. 15.102 / 54. 15.102
  libavdevice    54.  1.100 / 54.  1.100
  libavfilter     3.  1.100 /  3.  1.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
Input #0, matroska,webm, from '/mnt/media/videofile.mkv':
  Metadata:
    creation_time   : 2012-10-31 23:12:29
  Duration: 00:21:21.28, start: 0.000000, bitrate: 3046 kb/s
    Stream #0:0(eng): Video: h264 (High), yuv420p, 1280x720, SAR 1:1 DAR 16:9, 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
    Stream #0:1: Audio: ac3, 48000 Hz, 5.1(side), s16, 384 kb/s (default)
[graph 0 input from stream 0:0 @ 0x29e2040] w:1280 h:720 pixfmt:yuv420p tb:1/1000 fr:24000/1001 sar:1/1 sws_param:flags=2
[output stream 0:0 @ 0x29e1ec0] No opaque field provided
[Parsed_scale_0 @ 0x294c520] w:1280 h:720 fmt:yuv420p sar:1/1 -> w:854 h:480 fmt:yuv420p sar:1280/1281 flags:0x4
[graph 1 input from stream 0:1 @ 0x29b0be0] tb:1/48000 samplefmt:s16 samplerate:48000 chlayout:0x60f
[auto-inserted resampler 0 @ 0x29b9bc0] chl:5.1(side) fmt:s16 r:48000Hz -> chl:stereo fmt:s16 r:44100Hz
[flv @ 0x297a040] impossible bitrate constraints, this will fail
Output #0, flv, to '/tmp/Serviio/test.stf':
  Metadata:
    encoder         : Lavf54.15.102
    Stream #0:0(eng): Video: flv1 ([2][0][0][0] / 0x0002), yuv420p, 854x480 [SAR 1280:1281 DAR 16:9], q=2-31, 1000 kb/s, 1k tbn, 23.98 tbc (default)
    Stream #0:1: Audio: mp3 ([2][0][0][0] / 0x0002), 44100 Hz, stereo, s16, 192 kb/s (default)
Stream mapping:
  Stream #0:0 -> #0:0 (h264 -> flv)
  Stream #0:1 -> #0:1 (ac3 -> libmp3lame)
Press [q] to stop, [?] for help
frame=   20 fps=0.0 q=31.0 size=     192kB time=00:00:00.83 bitrate=1886.3kbits/frame=   55 fps= 55 q=31.0 size=     415kB time=00:00:02.29 bitrate=1480.6kbits/



the last line repeats/increments as it processes, with the occasional:
  Code:
rame=  243 fps= 68 q=31.0 size=    1544kB time=00:00:10.13 bitrate=1248.1kbits/rc buffer underflow
[flv @ 0x33fc040] rc buffer underflow
    Last message repeated 25 times


This continues on for a while, which is what I assume the serviio process also does, and as I observed before, the file steadily increased in size as the frames are processed.

However the process ends with and error:

  Code:
rc buffer underflow
[libmp3lame @ 0x17df320] Trying to remove 1152 samples, but que empty
    Last message repeated 11 times
[libmp3lame @ 0x17df320] lame: output buffer too small (buffer index: 10031, free bytes: 761)
Audio encoding failed


I suspect that error is the reason serviio get the "./serviio.log:2012-11-03 16:14:39,767 WARN [ProcessExecutor] Process /usr/local/bin/ffmpeg has a return code of 1! This is a possible error." message in the log

In order to see if this was something an update would fix, I remove lame, rtmp and ffmpeg and installed them via YUM.
FFmpeg installed and all the modules were enabled, but it then complained of an invalid argument c:v, so I removed this and installed FFmpeg from the Serviio download page.

Trying all the above steos again, I recevied the same symptoms and errors in the log.

I don't know if I am having 2 problems or one here, if this is both a streaming problem and an audio problem, or if the audio problem is causing the streaming problem.

If I can provide any more detail, or if there are additional log entries I should find and attach, please let me know.

Thanks!

Steve

Edit to add that the media browser will play audio (mp3 so far) and pictures, so it it seems the serving of files works, just not trancoding for the mediabrowser.


ffmpeg -i output:

  Code:
ffmpeg version N-42368-gbf53863 Copyright (c) 2000-2012 the FFmpeg developers
  built on Nov  3 2012 15:56:59 with gcc 4.4.6 20120305 (Red Hat 4.4.6-4)
  configuration: --enable-gpl --enable-libfaac --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libx264 --enable-nonfree --enable-postproc --enable-version3 --enable-x11grab --enable-libvpx --enable-librtmp --enable-libxvid
  libavutil      51. 64.100 / 51. 64.100
  libavcodec     54. 33.100 / 54. 33.100
  libavformat    54. 15.102 / 54. 15.102
  libavdevice    54.  1.100 / 54.  1.100
  libavfilter     3.  1.100 /  3.  1.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
Input #0, matroska,webm, from '/mnt/media//Tv Shows/30 Rock/Season 07/30.Rock.S07E05.HD.TV-DIMENSION.mkv':
  Metadata:
    creation_time   : 2012-10-31 23:12:29
  Duration: 00:21:21.28, start: 0.000000, bitrate: 3046 kb/s
    Stream #0:0(eng): Video: h264 (High), yuv420p, 1280x720, SAR 1:1 DAR 16:9, 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
    Stream #0:1: Audio: ac3, 48000 Hz, 5.1(side), s16, 384 kb/s (default)
At least one output file must be specified


To be thorough, I downloaded the water world 1080p sample from the List of test media files post.
I ran this from the MediaBrowser and it again hung, with the same "impossible bit rate error" and quitting with the "[libmp3lame @ 0x17df320] lame: output buffer too small (buffer index: 10031, free bytes: 761)
Audio encoding failed" error.

EDIT: I tried an hd and an sd video, and as the file was being converted I took a copy of it and opened it with VLC Media player, the generated FLV files from ffmpeg play fine with audio all the way through. It looks like I've been heading down the wrong path and this may purely be an flv streaming issue back to the browser. Not sure how to diagnose this or what info I can provide.
<<

smann

Serviio newbie

Posts: 2

Joined: Sat Nov 03, 2012 8:27 pm

Post Sun Nov 04, 2012 12:22 am

Re: Video won't stream to Mediabrowser

I stumbled on another post where users were having similar issues.
viewtopic.php?f=5&t=6888&start=20

The "try another browser" fix worked, IE9 owes me 4 hours of my life back. :)

Return to Serviio Support & Help

Who is online

Users browsing this forum: Google [Bot] and 25 guests

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.