Page 1 of 2

MKV playback stops halfway through

PostPosted: Fri Jan 13, 2012 8:46 pm
by M76
After updating to servio 0.6.1 any mkv file I try to play it starts normally but after about 20 minutes in, playback stops like it reached the end of the file. If I press info then the length is reported correctly. But seeking doesn't work on the files.

The TV is a D series Samsung P51D550

Here is the info of one file that stops playing:
  Code:
ffmpeg version 0.9, Copyright (c) 2000-2011 the FFmpeg developers
  built on Dec 13 2011 20:46:11 with gcc 4.4.2
  configuration: --enable-static --disable-shared --disable-ffplay --disable-ffs
erver --enable-memalign-hack --enable-libmp3lame --enable-librtmp --extra-libs='
-lrtmp -lpolarssl -lws2_32 -lwinmm' --arch=x86 --enable-runtime-cpudetect --enab
le-pthreads --target-os=mingw32 --cross-prefix=i686-mingw32- --pkg-config=pkg-co
nfig
  libavutil    51. 32. 0 / 51. 32. 0
  libavcodec   53. 42. 0 / 53. 42. 0
  libavformat  53. 24. 0 / 53. 24. 0
  libavdevice  53.  4. 0 / 53.  4. 0
  libavfilter   2. 53. 0 /  2. 53. 0
  libswscale    2.  1. 0 /  2.  1. 0

Seems stream 0 codec frame rate differs from container frame rate: 47.95 (48000/
1001) -> 48.00 (48/1)
Input #0, matroska,webm, from 'test.mkv':
  Duration: 00:41:33.95, start: 0.000000, bitrate: 4012 kb/s
    Stream #0:0(eng): Video: h264 (High), yuv420p, 1280x720, SAR 1:1 DAR 16:9, 2
3.98 fps, 48 tbr, 1k tbn, 47.95 tbc (default)
    Stream #0:1(eng): Audio: ac3, 48000 Hz, 5.1(side), s16, 448 kb/s (default)
At least one output file must be specified

Format                           : Matroska
Format version                   : Version 2
File size                        : 1.16 GiB
Duration                         : 41mn 33s
Overall bit rate                 : 4 013 Kbps
Writing application              : x264.exe
Writing library                  : mkv2rls x264-tv version built on 2011. febr. 17

Video
ID                               : 1
Format                           : AVC
Format/Info                      : Advanced Video Codec
Format profile                   : High@L3.1
Format settings, CABAC           : Yes
Format settings, ReFrames        : 5 frames
Codec ID                         : V_MPEG4/ISO/AVC
Duration                         : 41mn 33s
Bit rate                         : 3 485 Kbps
Width                            : 1 280 pixels
Height                           : 720 pixels
Display aspect ratio             : 16:9
Frame rate                       : 23.976 fps
Color space                      : YUV
Chroma subsampling               : 4:2:0
Bit depth                        : 8 bits
Scan type                        : Progressive
Bits/(Pixel*Frame)               : 0.158
Stream size                      : 1.01 GiB (87%)
Writing library                  : x264 core 120 r2120 0c7dab9
Encoding settings                : cabac=1 / ref=5 / deblock=1:0:0 / analyse=0x3:0x113 / me=umh / subme=8 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=1 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=18 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=2 / b_bias=0 / direct=3 / weightb=1 / open_gop=0 / weightp=2 / keyint=250 / keyint_min=23 / scenecut=40 / intra_refresh=0 / rc_lookahead=50 / rc=crf / mbtree=1 / crf=19.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / ip_ratio=1.40 / aq=1:1.00
Language                         : English
Default                          : Yes
Forced                           : No

Audio
ID                               : 2
Format                           : AC-3
Format/Info                      : Audio Coding 3
Mode extension                   : CM (complete main)
Codec ID                         : A_AC3
Duration                         : 41mn 33s
Bit rate mode                    : Constant
Bit rate                         : 448 Kbps
Channel(s)                       : 6 channels
Channel positions                : Front: L C R, Side: L R, LFE
Sampling rate                    : 48.0 KHz
Bit depth                        : 16 bits
Compression mode                 : Lossy
Stream size                      : 133 MiB (11%)
Language                         : English
Default                          : Yes
Forced                           : No

Re: MKV playback stops halfway through

PostPosted: Sat Jan 14, 2012 8:21 am
by Cerberus
check bitrate on the file, If bitrate peaks to high it will cause this to happen.

Re: MKV playback stops halfway through

PostPosted: Sat Jan 14, 2012 9:13 am
by M76
I've checked with bitrate viewer and the highest peak is at 4:17 in, but playback stops at 19:45 with this specific file, and there are no unusually high peaks around that time. Playback always seem to stop approx between 15 and 20 minutes , with different files (all mkvs) so I don't think it is bitrate related. Even with a file where there is no peak over 8000kpbs.

Re: MKV playback stops halfway through

PostPosted: Mon Jan 16, 2012 7:24 pm
by M76
I've tried again with debug logging enabled, but I can't see anything unusual in the log. I don't even know what am I looking for, there is so much garbage in the log.

Re: MKV playback stops halfway through

PostPosted: Mon Jan 16, 2012 7:42 pm
by Cerberus
M76 wrote:I've tried again with debug logging enabled, but I can't see anything unusual in the log. I don't even know what am I looking for, there is so much garbage in the log.


its not garbage it actually tells us alot about your system.

Re: MKV playback stops halfway through

PostPosted: Mon Jan 16, 2012 9:42 pm
by M76
Cerberus wrote:
M76 wrote:I've tried again with debug logging enabled, but I can't see anything unusual in the log. I don't even know what am I looking for, there is so much garbage in the log.


its not garbage it actually tells us alot about your system.


I know its not garbage, but completely irrelevant information to this problem, and I don't know what to look for, or should I post the whole 80mbytes of log? I can't even find where the playback starts, not to mention stops. Because there are thousands of lines of library updates written into the log even during playback.

Re: MKV playback stops halfway through

PostPosted: Mon Jan 16, 2012 9:44 pm
by Cerberus
yep attach the whole log.

Re: MKV playback stops halfway through

PostPosted: Tue Jan 17, 2012 5:55 pm
by M76
I restarted the service with the library refresh option turned off, and started a clean log. There are still some online feed updates in the beginning, but the playback is towards the end of the file.

Re: MKV playback stops halfway through

PostPosted: Tue Jan 17, 2012 9:16 pm
by Cerberus
M76 wrote:I restarted the service with the library refresh option turned off, and started a clean log. There are still some online feed updates in the beginning, but the playback is towards the end of the file.


log looks normal file is requested and is sent by serviio, no errors or discconnects are shown from serviio's point of view.

Re: MKV playback stops halfway through

PostPosted: Wed Jan 18, 2012 5:18 pm
by M76
Still somehow it jumps back into the browser without pressing any buttons. Even the play time is reported correctly.

Re: MKV playback stops halfway through

PostPosted: Wed Jan 18, 2012 5:30 pm
by Cerberus
M76 wrote:Still somehow it jumps back into the browser without pressing any buttons. Even the play time is reported correctly.


http://wiki.serviio.org/doku.php?id=mkvfix <-- run that over your files that wont work i did with a few today and got them to play.

Re: MKV playback stops halfway through

PostPosted: Sun Jan 22, 2012 5:24 pm
by M76
So, here's the thing:

I tried lots of mkv's all stopped playing at some point, and seeking didn't work on any of them.

But

After downgrading to 6.0.1, all mkv's work like a charm, they play till the end, and even seeking is possible.

So

I think its time you stopped insisting that the problem is with the files.

What is known:

1: The bug was introduced in 6.1
2: Even the debug log doesn't show anything why this is happening.
3: Its random because every file stops at different timestamps, with some it plays for 20-30 minutes before jumping back to the browser, with others it stops after 3-4 minutes even.
4: But its also constant because it always stops at the same exact time if I play the same file again.

Re: MKV playback stops halfway through

PostPosted: Sun Jan 22, 2012 5:47 pm
by Cerberus
M76 wrote:After downgrading to 6.0.1, all mkv's work like a charm, they play till the end, and even seeking is possible.


ok that would mke sense and tie in with some issues im seeing

I think its time you stopped insisting that the problem is with the files.


excuse me !!! who insisted it was the files???

1: The bug was introduced in 6.1


yer i agree if it what im see thats correct

2: Even the debug log doesn't show anything why this is happening.


yep it does but only if you know what your looking for.

3: Its random because every file stops at different timestamps, with some it plays for 20-30 minutes before jumping back to the browser, with others it stops after 3-4 minutes even.
4: But its also constant because it always stops at the same exact time if I play the same file again.
[/quote]

nope there no consistancy to it, and seems to be an ffmpeg issue but more testing is require on latest beta to see if we have solved this issue.

Re: MKV playback stops halfway through

PostPosted: Sun Jan 22, 2012 10:43 pm
by Zainaghi
Hello I´m new here. I´m facing the same problem (Serviio v 0.6.1). I have a BD D5100 and the movies (.mkv and .avi) stop and the player skip to the menu where are listed the movies available on server. The problem could occur at any moment. When the movie is restarted the problem not happens at the same time before but latter. Today I faced the problem twice at 17' and 51'. What information more I need to send to help you? Thank you very much.

Re: MKV playback stops halfway through

PostPosted: Sun Jan 22, 2012 11:28 pm
by Zainaghi
Information about the file:

C:\Program Files\Serviio\lib>ffmpeg.exe -i "C:\Documents and Settings\The Fats\M
y Documents\My Videos\FILMES CONVERTIDOS\Toy Story 2.mkv
ffmpeg version 0.9, Copyright (c) 2000-2011 the FFmpeg developers
built on Dec 13 2011 20:46:11 with gcc 4.4.2
configuration: --enable-static --disable-shared --disable-ffplay --disable-ffs
erver --enable-memalign-hack --enable-libmp3lame --enable-librtmp --extra-libs='
-lrtmp -lpolarssl -lws2_32 -lwinmm' --arch=x86 --enable-runtime-cpudetect --enab
le-pthreads --target-os=mingw32 --cross-prefix=i686-mingw32- --pkg-config=pkg-co
nfig
libavutil 51. 32. 0 / 51. 32. 0
libavcodec 53. 42. 0 / 53. 42. 0
libavformat 53. 24. 0 / 53. 24. 0
libavdevice 53. 4. 0 / 53. 4. 0
libavfilter 2. 53. 0 / 2. 53. 0
libswscale 2. 1. 0 / 2. 1. 0

Seems stream 0 codec frame rate differs from container frame rate: 50.00 (50/1)
-> 50.00 (50/1)
Input #0, matroska,webm, from 'C:\Documents and Settings\The Fats\My Documents\M
y Videos\FILMES CONVERTIDOS\Toy Story 2.mkv':
Duration: 01:32:25.12, start: 0.000000, bitrate: 1969 kb/s
Stream #0:0: Video: h264 (High), yuv420p, 1280x720, SAR 1:1 DAR 16:9, 25 fps
, 50 tbr, 1k tbn, 50 tbc (default)
Stream #0:1: Audio: mp3, 48000 Hz, stereo, s16, 192 kb/s (default)
At least one output file must be specified

C:\Program Files\Serviio\lib>

Thanks,

Re: MKV playback stops halfway through

PostPosted: Mon Jan 23, 2012 7:59 am
by Cerberus
Zainaghi - yep this is a known issue and im currently trying to work out why it happen and it will hopefully be fixed in 0.6.2

Re: MKV playback stops halfway through

PostPosted: Mon Jan 23, 2012 9:16 am
by M76
Cerberus wrote:
yep it does but only if you know what your looking for.


Weren't you the one who said just a few posts ago that there is nothing in the log?

nope there no consistancy to it, and seems to be an ffmpeg issue but more testing is require on latest beta to see if we have solved this issue.


I 've played the same file five times and 5 out of 5 it stopped at the exact same moment, if that's not consistancy I don't know what is.

Re: MKV playback stops halfway through

PostPosted: Sun Jan 29, 2012 1:21 am
by Zainaghi
Cerberus, could be a hardware problem too? I´m asking this because I have the same problem using Samsung All Share software. My PC is a AMD X2 2.0 ghz / 2 Gb RAM / Asus M2N SLI. I´m using a wired connection trought a Dlink 524. Sometimes I need to restart the BD 2 or 3 times until to recognize the DLNA server. And once recognized is very difficult to get to the movies directory. I receive a message "Media Play cannot complet the action and will return to main menu" or "There is no movies files at the specified folder". What is the hardware´s responsabiliy to ensure DLNA´s working? Thanks in advance.

Re: MKV playback stops halfway through

PostPosted: Sun Jan 29, 2012 1:55 am
by Cerberus
Zainaghi wrote:Cerberus, could be a hardware problem too? I´m asking this because I have the same problem using Samsung All Share software. My PC is a AMD X2 2.0 ghz / 2 Gb RAM / Asus M2N SLI. I´m using a wired connection trought a Dlink 524. Sometimes I need to restart the BD 2 or 3 times until to recognize the DLNA server. And once recognized is very difficult to get to the movies directory. I receive a message "Media Play cannot complet the action and will return to main menu" or "There is no movies files at the specified folder". What is the hardware´s responsabiliy to ensure DLNA´s working? Thanks in advance.


well yes it could be a firmware issue but we should be able to work round that. As for the rest that sound more like a network issue than software/firmware.

Re: MKV playback stops halfway through

PostPosted: Thu Feb 02, 2012 5:49 pm
by M76
I've noticed that if I press info on the file, it reports a lower filesize than what it is actually. And it seems that the reported filesize is consistent with the position where playback stops.