Closed mreid-tt closed 4 years ago
First: we don't support DSM 6 so DSM 6.2 isn't supported as well... Second: DS Video is a Synology SPK not one provided by us and it uses synologys FFMPEG build not the one we provide
@houndtt Is this issue only for EAC3 audio? Or does it affect other codecs as well?
I have ffmpeg on DS918+ w/ DSM 6.1.3-15152 Update 6 and its working fine for DTS and others, but I don't know if I have any video encoded w/ EAC3 audio.
If you have a sample file with EAC3 audio to test I'd be interested to see if its working on the package I'm running.
I believe a recent DSM update may have included an architecture change by Synology?
I don't have a "before picture" but, I believe VideoStation used to source the ffmpeg off the $PATH
?
Now it looks like Synology are embedding ffmpeg at /volume1/@appstore/VideoStation/bin/ffmpeg
.
As expected, I couldn't find anything in spksrc that hinted perhaps the packages used to make accommodations for this by - say - overriding Synology's choice of ffmpeg for VideoStation? Doing so might be inelegant, anyway.
$ /volume1/\@appstore/VideoStation/bin/ffmpeg -encoders | grep eac3
ffmpeg version 2.7.1 Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.9.3 (crosstool-NG 1.20.0) 20150311 (prerelease)
configuration: --prefix=/usr/pkg --incdir='${prefix}/include/ffmpeg' --arch=i686 --target-os=linux --cross-prefix=/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu- --enable-cross-compile --enable-optimizations --enable-pic --enable-gpl --enable-version3 --enable-nonfree --enable-libfaac --enable-encoders --enable-pthreads --disable-muxer=image2 --disable-muxer=image2pipe --disable-swscale-alpha --disable-ffplay --disable-ffserver --disable-doc --disable-devices --disable-bzlib --disable-altivec --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libmp3lame --disable-decoder=amrnb --disable-encoder=zmbv --disable-encoder=dca --disable-encoder=ac3 --disable-encoder=ac3_fixed --disable-encoder=eac3 --disable-decoder=eac3 --disable-encoder=truehd --disable-decoder=truehd --cc=/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc --enable-shared --disable-static --enable-yasm --enable-libx264 --enable-encoder=libx264
libavutil 54. 27.100 / 54. 27.100
libavcodec 56. 41.100 / 56. 41.100
libavformat 56. 36.100 / 56. 36.100
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 16.101 / 5. 16.101
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.100 / 1. 2.100
libpostproc 53. 3.100 / 53. 3.100
$
You may notice eac3 has been disabled in the build arguments by Synology.
After backing up the vendor's binary, I boldly attempted to ln
and then just plan mv
the SynoCommunity ffmpeg version 3.3.3 into the VideoStation package... neither worked, so I asked myself why....
A ps auxwf
while streaming yielded the arguments used by VideoStation to invoke ffmpeg for transcode. I tried to replicate the same invocation of the ffmpeg process from shell. I got Unrecognized option 'hls_seek_time'.
Perhaps this argument has been deprecated, and I can see that VideoStation is making assumptions about the ffmpeg version that aren't going to be easily reconciled.
I empathize with @cytec that it's not feasible to provide what @houndtt and I are looking for in a sustainable way. I - or someone else - might be motivated to compile an older version of ffmpeg with eac3 to attempt a drop-in replacement.
@ChrisAnonymous I can confirm the issue only happens with specifically eac3 files.
Check the media info in an episode or movie under VideoStation. It should tell you "eac" vs "ac3" or "aac-lc" or similar.
I had the exact same issue. Downgrading videostation to the previous version fixed the issue
@cr03 i guess the best way would be to report that to Synology so that they can fix it ;)
Team, thanks for all your feedback on this. As suggested this needs to be resolved by Synology and I have logged a ticket regarding same. The details of the ticket are as follows:
Problem Explanation:
Summary: Latest compatibility update for DSM 6.2 beta breaks third-party 'ffmpeg' engines
Detail: Prior to the latest udpate (Version: 2.3.5-1471), users were able to install third party engines like the one from SynoCommunity. It appears that Video Station now includes an older embedded ffmpeg at '/volume1/[at]appstore/VideoStation/bin/ffmpeg' which overides the one from SynoCommunity (https://synocommunity.com/package/ffmpeg).
From preliminary analysis the embedded version in Video Station is version 2.7.1 whereas the SynoCommunity version is v3.3.3. It is thought that in the previous architecture that Video Station used to source the ffmpeg off the $PATH or some other mechanism that allowed third party versions to be used. I am hoping that consideration can be given to allowing this setup once again.
Problem Reproduce Steps:
Launching Video Station and playing media files with esoteric media formats like EAC3 for audio results in an error "failed to play the video because the file format of the currently selected audio track is not supported". Prior to the latest update with the SynoCommunity ffmpeg install this worked flawlessly.
I'll update the team once I receive a response.
Same issues here, thanks for your research guys! Looking forward to the reply from Synology and a fix.
I also dropped a ticket at Synology Support. They answered that E-AC3 is currently not supported.
This is what i from Synology Support today
Maybe you have used 3rd party like ffmpeg? Please note we don't support e-ac-3 is because the copy right issue, those 3rd party package is against the copy right, we are suggest to remove it. Sorry for your inconvenience.
So i don't Synology is going to fix it in a future release.
Please note we don't support e-ac-3 is because the copy right issue, those 3rd party package is against the copy right, we are suggest to remove it.
I'm still awaiting my response from Synology (they initially asked for a debug log). If the above is correct then I would suggest that there be some sort of compromise. Synology operates on a whole community of open-source projects. Either the vendor allows their users the choice of decoder packages (much like they allow for a choice of web servers, interpreters, etc.) via some sort of selector to toggle the newly included stripped down decoder... or they allow for a paid option (much like they do for survelliance, anti-virus and file systems).
Here is reference about Dolby software patents claimed to be infringed: https://github.com/SynoCommunity/spksrc/issues/2952#issuecomment-336574101
@ymartin59 And what are you trying to tell with your comment? I don't see that see that your comment is contributing anything with value to this thread.
@ymartin59 I think you may have fumbled the link you wanted to paste -- it just links to this issue. Try again?
I made a ticket and the answer was "eac3 format was never officially supported", if I use "ffmpeg unofficial package may be broken because of updates of Video Station". I downgrade to VideoStation-x86_64-2.3.4-1468 (DS416play) and solved the problem for now. Waiting for a better solution.
Well I did the rollback to version 2.3.4-1468 and the EAC3 audio is once again transcoding. For those who are unsure about the process, the steps I took were as follows:
For me I use a Synology DS916+ so this was: (a) Checking https://www.synology.com/en-global/support/download/DS916+#packages (b) Identifying the previous version using https://www.synology.com/en-global/releaseNote/VideoStation?model=DS916%2B (c) Manually altering the download link on the packages page to https://global.download.synology.com/download/Package/spk/VideoStation/2.3.4-1468/VideoStation-x86_64-2.3.4-1468.spk
As an update to the ticket with Synology they closed it as a feature request with the following generic reply: "We have sent up your concerns with the ffmpeg process in DSM 6.2 beta and your desire to source the ffmpeg off the $PATH or some other mechanism that allowed third party versions to be used, to our features and development team."
I also did a bit of experimenting with the downgraded version following in the steps of @cr03. My output for the 'ffmpeg' in Video Station was as follows:
/var/packages/VideoStation/target/bin$ ffmpeg -encoders | grep eac3
ffmpeg version 2.7.1 Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.9.3 (crosstool-NG 1.20.0) 20150311 (prerelease)
configuration: --prefix=/usr --incdir='${prefix}/include/ffmpeg' --arch=i686 --target-os=linux --cross-prefix=/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu- --enable-cross-compile --enable-optimizations --enable-pic --enable-gpl --enable-shared --disable-static --enable-version3 --enable-nonfree --enable-libfaac --enable-encoders --enable-pthreads --disable-bzlib --disable-protocol=rtp --disable-muxer=image2 --disable-muxer=image2pipe --disable-swscale-alpha --disable-ffserver --disable-ffplay --disable-devices --disable-bzlib --disable-altivec --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libmp3lame --disable-vaapi --disable-decoder=amrnb --disable-encoder=zmbv --disable-encoder=dca --disable-encoder=ac3 --disable-encoder=ac3_fixed --disable-encoder=eac3 --disable-decoder=dca --disable-decoder=eac3 --disable-decoder=truehd --cc=/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc --enable-yasm --enable-libx264 --enable-encoder=libx264
libavutil 54. 27.100 / 54. 27.100
libavcodec 56. 41.100 / 56. 41.100
libavformat 56. 36.100 / 56. 36.100
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 16.101 / 5. 16.101
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.100 / 1. 2.100
libpostproc 53. 3.100 / 53. 3.100
I don't see any output in the ps auxwf | grep ffmpeg
which helps me understand which 'ffmpeg' was being used. Perhaps you guys can help?
root 24877 0.0 0.0 23116 972 pts/3 S+ 08:15 0:00 \_ grep --color=auto ffmpeg
root 24855 99.2 0.1 117124 14396 ? Rl 08:14 0:03 \_ /var/packages/VideoStation/target/bin/ffmpeg -ss 633.258 -i /volume1/video/[...].mkv -threads 0 -vcodec copy -vsync 2 -vbsf h264_mp4toannexb=repeatheader -acodec libmp3lame -ab 256k -ac 2 -f ssegment -segment_format mpegts -segment_list_type m3u8 -hls_seek_time 633258 -segment_time 8 -segment_time_delta 1.258 -segment_start_number 00079 -avoid_negative_ts 0 -break_non_keyframes 0 -map 0:0 -map 0:1 /tmp/VideoStation/HLS/[...]/slice-%05d.ts
Just downgraded to 2.3.4-1468, let's hope Synology is picking this up and it will work again with the next release.
Please close issue, if there is nothing we can do here.
Just as an update, I attempted to upgrade to Video Station version 2.3.6-1475 this morning but the problem with the EAC3 audio still persists. Rolled back to version 2.3.4-1468 and all is once again well with the world. Hopefully Synology will fix this soon.
Just to confirm what @houndtt pointed out, I could fix Video Station playback issues by downgrading manually from 2.3.6-1475 to 2.3.4-1468 . Synology wake up !
I know this issue was closed, but I have to say Videostation can not play DTS either AC3 originally, after install 3rd part FFMPEG from the community source, you get both DTS and AC3 works.
What I want to point is why DTS and AC3 can be played but EAC3 won't? Is there anything FFMPEG community edition can do the same thing to enable EAC3?
@kurtn2005 Because EAC3 is a codec that has licensefees. Synology is not willing to pay for that.
@repmeer correct me if I am worng, from my understanding, both DTS and AC3 are need license and original VideoStation can not streaming both of them, and this can be proved by the lead of compile parameters of original FFMPEG which comes with VideoStation, however, after install the community FFMPEG package, DTS and AC3 works, why they are enabled? Should be some things changed after install community edition, I beleive.
I assume it can be enable EAC3 with community edition as well.
Can somebody pls post a link to the community version of FFMPEG? Do I get it right that after the installation of ffmpef community edition I can update my video station again if I just want to play MKVs with AC3 and DTS?
For those who want to update to post-2.3.4 (for bugfixes) but still want to play EAC3 videos: Login to your NAS via SSH and copy these files to another location: volume1/@appstore/VideoStation/lib/libsynovte.so and volume1/@appstore/VideoStation/lib/ffmpeg/libavcodec.so.56 Update Video Station and replace the new versions of these files with the old ones you copied.
Thanks @HandyHarry! My files were in slightly different locations so my steps were as follows:
cp /volume1/@appstore/VideoStation/lib/libsynovte.so [backup location]
cp /volume1/@appstore/VideoStation/lib/ffmpeg/libavcodec.so.56 [backup location]
cd /volume1/@appstore/VideoStation/lib/
sudo mv libsynovte.so libsynovte.so.bak
cd /volume1/@appstore/VideoStation/lib/ffmpeg/
sudo mv libavcodec.so.56 libavcodec.so.56.bak
sudo cp [backup location]/libsynovte.so /volume1/@appstore/VideoStation/lib/
sudo cp [backup location]/libavcodec.so.56 /volume1/@appstore/VideoStation/lib/ffmpeg/
cd /volume1/@appstore/VideoStation/lib/
sudo chown VideoStation:VideoStation libsynovte.so
sudo chmod 644 libsynovte.so
cd /volume1/@appstore/VideoStation/lib/ffmpeg/
sudo chown VideoStation:VideoStation libavcodec.so.56
sudo chmod 644 libavcodec.so.56
So far so good. I would also recommend keeping the backup files in the backup location for future upgrades.
A totally noob question here - I understand that need to downgrade the Video Station to get the audio codecs working. I can do this manually but I believe that I have to uninstall the current version first. What will happen to all my libraries if I do this? Will it keep everything? Thanks in advance.
@kajolab Yes your library will preserved. Own observation
@repmeer thanks for a quick answer. But are you really sure? I have many TV shows, films and home videos and a number of playlists, too; quite a few manually edited. I know I am not going to lose the actual video files, it's everything around them I am worried about. Since I am at the latest ver. of Video Station I have to uninstall it first in order to go on. Would you, or anybody else here, be willing to reassure me?
Thanks once more!
Yes i am sure. As i said "own observation"
ok, then I go for it. I will post how it went, in case anybody finds it useful - not that you didn't say that already...
When you uninstall VideoStation you will find a check option to remove or not the library. Tested few days ago when I used houndtt solution and worked great.
@repmeer and @lgxmedia thanks guys! You were, of course, right. I kept everything but... was really scared for a while when the new(old) version installed successfully but got stuck att starting the service in about 5 or so minutes. Thanks again!
@houndtt Thank you for your guide, may I have these two files so that I can replace them directly without downgrading the VideoStation?
@houndtt I noticed that we may have different architecture of VideoStation so I did by myself, it works fine! Thanks a lot!
Version 2.3.8-1486 was released today. The issue hasn’t been resolved, but the above solution still works. You do have to replace the files again after the update though.
@ymartin59 Back from my trip and interested, too. What issues have you identified?
Anyone can provide your old libsynovte.so and libavcodec.so.56 here? I cannot downgrade my video station.
updata: download video station 2.3.4-1468 from https://archive.synology.com/download/Package/spk/VideoStation/2.3.4-1468/ and unpack it and the within there is package.tgz file, unpack it you can find the lib/libsynovte.so and lib/ffmpeg/libavcodec.so.56, upload and replace,just work fine.
I downgraded my videostation to 2.3.4-1468 on my ds218+. But it won't play any e-ac3. Something else I can try?
@Casburggraaf what is your ffmpeg package version ? next update should be published soon
Same I did the update the file by just downloading and unzipping the package and it's still not reading eac3
@houndtt @ymartin59 @m4tt075 I know you are all working on this, thank you for your efforts. On a DS 918+, @houndtt's fix works to get Video Station on post 1468 builds working (copied the files from my 412+ running 1468VS onto the 918+ no isssue) I have some concerns though. I'm a basic linux user, minimal skills. But I noticed that even with hound's fix, ps -ef | grep ffmpeg shows that video station still uses its native ffmpeg and not the one I manually installed (3.4-1 from cytec). Is there anything I can do to force VideoStation to use the newer one, or am I just locked into the one that now ships with VideoStation.
With ffmpeg 3.4.1-9 just released, can you update Video Station to 2.3.8-1486, or do you still need to keep Video Station at 2.3.4-1468? [DS215j]
@Specials, I'm currently running Video Station 2.3.8-1486. The only trick is to manually replace the install with the two older codec files per the tip that @HandyHarry brought to the table. See https://github.com/SynoCommunity/spksrc/issues/2952#issuecomment-351269151
Hey guys, I just tried the update to the latest version 2.4.0-1505. This version as with previous ones does not allow EAC3 playback. Unfortunately, this version has a new codec file at the location /volume1/@appstore/VideoStation/lib/ffmpeg/libavcodec.so.57
.
Replacing it with the older libavcodec.so.56 file causes the package to fail to launch. Replacing just the /volume1/@appstore/VideoStation/lib/libsynovte.so
alone allows the package to launch but goes into a loop when trying to play EAC3 encoded videos.
Without a working codec, I am thus going to have to downgrade to Video Station 2.3.8-1486.
@houndtt Confused. Our ffmpeg
version has just been upgraded and ships with libavcodec.so.57 now. I don't know whether your workaround still applies, but at least the versions should match.
@m4tt075 Interesting. The workaround from @HandyHarry suggested that we needed to use the previous versions of libsynovte.so and libavcodec.so.56 from Video Station. Are you saying that I can use the version of libavcodec.so.57 supplied with ffmpeg
instead?
Based on what I've seen there is a version at /volume1/@appstore/ffmpeg/lib/libavcodec.so.57
. I don't see a version of libsynovte.so in your build so I guess we will still have to use the previous version from Video Station?
Going to try it out with the current and the previous versions of libsynovte.so and see what happens...
Update:
So for this experiment I have installed ffmpeg version 3.4.1-9 as well as Video Station 2.4.0-1505. On launch the installation is able to play AC3, DTS but not EAC3.
/volume1/@appstore/VideoStation/lib/ffmpeg/
. This results in Video Station unable to launch with 'Operation Failed'.Based on the above the libavcodec.so.57 file from ffmpeg
does not seem compatible as a replacement for the one in Video Station.
So @houndtt what is the current recommendation for the current installation of VideoStation?
@mlinton, best to stay with Video Station 2.3.8-1486 if you need EAC3.
@houndtt Sorry for the late reply. Yes, what you tested is what I hoped would be worthwhile. Unfortunate it did not work out. No other idea then...
For new Package Requests, see the guidelines
Setup
Package Name: FFmpeg _Package Version:_3.3.3-7
_NAS Model:_DS916+ _NAS Architecture:_Intel _DSM version:_6.1.3-15152 Update 6
Expected behavior
Playback of video with Dolby tracks in DS Video work without issue
Actual behavior
Playback error "failed to play the video because the file format of the currently selected audio track is not supported" (for EAC3).
Steps to reproduce
_1._Launch DS Video _2._Select video with EAC3 audio _3._Play
Package log
Check Package Center or
/usr/local/{package}/var/
Other logs (attempted a re-install)
E.g.
/var/log/messages
or/var/log/synopkg.log