FAQ  •  Register  •  Login

New server - can't get transcoding working

<<

pointer2null

Streaming enthusiast

Posts: 25

Joined: Sat Jan 26, 2013 7:38 pm

Post Sun Jan 12, 2014 9:51 pm

New server - can't get transcoding working

I'm in the middle of upgrading my home server and I can't get transcoding working.

I'm using centos 6.3. I've managed to build all the required libraries and Serviio is running except for transcoding. The log says

  Code:
2014-01-12 21:41:02,654 WARN  [ProcessExecutor] Process /usr/local/bin/ffmpeg has a return code of 1! This is a possible error. Detailed output follows.
libavdevice  52.  5. 0 / 52.  5. 0
libavfilter   1. 80. 0 /  1. 80. 0
libswscale    0. 14. 1 /  0. 14. 1
libpostproc  51.  2. 0 / 51.  2. 0
Expected number for threads but found: auto
2014-01-12 21:41:12,666 WARN  [ServiioStatusService] IOException occured. Returning error code 500 to the REST layer. Message: Transcoded file '/tmp/Serviio/transcoding-temp-20-flv_player-MEDIUM.stf' cannot be found, FFmpeg execution probably failed
2014-01-12 21:41:13,159 WARN  [ProcessExecutor] Process /usr/local/bin/ffmpeg has a return code of 1! This is a possible error. Detailed output follows.
libavdevice  52.  5. 0 / 52.  5. 0
libavfilter   1. 80. 0 /  1. 80. 0
libswscale    0. 14. 1 /  0. 14. 1
libpostproc  51.  2. 0 / 51.  2. 0
Expected number for threads but found: auto
2014-01-12 21:41:23,155 WARN  [ServiioStatusService] IOException occured. Returning error code 500 to the REST layer. Message: Transcoded file '/tmp/Serviio/transcoding-temp-20-flv_player-MEDIUM.stf' cannot be found, FFmpeg execution probably failed
2014-01-12 21:41:23,695 WARN  [ProcessExecutor] Process /usr/local/bin/ffmpeg has a return code of 1! This is a possible error. Detailed output follows.
libavdevice  52.  5. 0 / 52.  5. 0
libavfilter   1. 80. 0 /  1. 80. 0
libswscale    0. 14. 1 /  0. 14. 1
libpostproc  51.  2. 0 / 51.  2. 0
Expected number for threads but found: auto


I'm not sure whats up with ffmpeg - it seems fine:
  Code:
[root@localhost rtmpdump]# /usr/local/bin/ffmpeg
ffmpeg version 0.7.12, Copyright (c) 2000-2011 the FFmpeg developers
  built on Jan 12 2014 17:40:26 with gcc 4.4.7 20120313 (Red Hat 4.4.7-4)
  configuration: --enable-gpl --enable-version3 --enable-shared --enable-nonfree --enable-postproc --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid --enable-x11grab --extra-cflags=-I/usr/local/include --extra-ldflags=-L/usr/local/lib
  libavutil    50. 43. 0 / 50. 43. 0
  libavcodec   52.123. 0 / 52.123. 0
  libavformat  52.111. 0 / 52.111. 0
  libavdevice  52.  5. 0 / 52.  5. 0
  libavfilter   1. 80. 0 /  1. 80. 0
  libswscale    0. 14. 1 /  0. 14. 1
  libpostproc  51.  2. 0 / 51.  2. 0
Hyper fast Audio and Video encoder
usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...

Use -h to get full help or, even better, run 'man ffmpeg'


I'm hoping this is a common issue and has an easy solution?


(p.s. the instructions on http://wiki.serviio.org/doku.php?id=how ... all:centos don't work - there are various packages that cannot be found and ffmpeg will not build from the git repo)
<<

npuser

DLNA master

Posts: 172

Joined: Mon Feb 06, 2012 3:44 am

Location: Michigan

Post Sun Jan 12, 2014 11:56 pm

Re: New server - can't get transcoding working

  Code:
Transcoded file '/tmp/Serviio/transcoding-temp-20-flv_player-MEDIUM.stf' cannot be found


Could please delete the folder "serviio" inside /tmp and let serviio recreated it on next transcoding job? Looks like a screwy permission in /tmp/serviio folder.

thanks
NPuser
<<

will

DLNA master

Posts: 2138

Joined: Mon Aug 30, 2010 11:18 am

Location: UK

Post Mon Jan 13, 2014 6:12 pm

Re: New server - can't get transcoding working

Its nothing to do with permsisions, its because ffmpeg is too old and as such doesn't understand the options that serviio is calling it with.

  Code:
2014-01-12 21:41:23,695 WARN  [ProcessExecutor] Process /usr/local/bin/ffmpeg has a return code of 1! This is a possible error. Detailed output follows.
libavdevice  52.  5. 0 / 52.  5. 0
libavfilter   1. 80. 0 /  1. 80. 0
libswscale    0. 14. 1 /  0. 14. 1
libpostproc  51.  2. 0 / 51.  2. 0
Expected number for threads but found: auto



You will need to build it from source unless you can find a newer one. Which packages couldn't yum find?
Will

ServiiDroid (Android Console) Developer: Download | Home | Support
ServiiGo (Android 3G/4G/WiFi Playback App) Developer: Download | Home | Support
<<

pointer2null

Streaming enthusiast

Posts: 25

Joined: Sat Jan 26, 2013 7:38 pm

Post Mon Jan 13, 2014 7:02 pm

Re: New server - can't get transcoding working

Thanks for the replies. I'dd do both to be sure.

Will, on a clean VM (only guest additions installed)

  Code:
[root@localhost gary]# yum remove x264 ffmpeg -y
Loaded plugins: fastestmirror, refresh-packagekit, security
Setting up Remove Process
No Match for argument: x264
Loading mirror speeds from cached hostfile
 * base: mirrors.manchester.m247.com
 * extras: mirrors.melbourne.co.uk
 * rpmforge: www.mirrorservice.org
 * updates: mirrors.manchester.m247.com
base                                                                                                                                                                                         | 3.7 kB     00:00     
extras                                                                                                                                                                                       | 3.4 kB     00:00     
rpmforge                                                                                                                                                                                     | 1.9 kB     00:00     
updates                                                                                                                                                                                      | 3.4 kB     00:00     
Package(s) x264 available, but not installed.
No Match for argument: ffmpeg
Package(s) ffmpeg available, but not installed.
No Packages marked for removal
[root@localhost gary]# yum install git libfaac-devel libmp3lame-devel libtheora-devel \
> libva-devel libvdpau-devel libvorbis-devel libX11-devel libXfixes-devel texi2html yasm \
> libxvidcore-devel  libXext-devel libXfixes-devel librtmp-devel
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * base: mirror.synergyworks.co.uk
 * extras: centos.mirroring.pulsant.co.uk
 * rpmforge: www.mirrorservice.org
 * updates: mirror.mhd.uk.as44574.net
Setting up Install Process
Package git-1.7.1-3.el6_4.1.x86_64 already installed and latest version
No package libfaac-devel available.
No package libmp3lame-devel available.
Resolving Dependencies
--> Running transaction check
....


Then the other libs are ok until rtmpdump:

  Code:
[root@localhost gary]# cd /usr/src
[root@localhost src]# git clone git://git.ffmpeg.org/rtmpdump
Initialized empty Git repository in /usr/src/rtmpdump/.git/
remote: Counting objects: 2531, done.
remote: Compressing objects: 100% (892/892), done.
remote: Total 2531 (delta 1910), reused 2149 (delta 1638)
Receiving objects: 100% (2531/2531), 769.61 KiB | 754 KiB/s, done.
Resolving deltas: 100% (1910/1910), done.
[root@localhost src]# cd rtmpdump
[root@localhost rtmpdump]# make SYS=posix
make[1]: Entering directory `/usr/src/rtmpdump/librtmp'
gcc -Wall   -DRTMPDUMP_VERSION=\"v2.4\" -DUSE_OPENSSL  -O2 -fPIC   -c -o rtmp.o rtmp.c
rtmp.c:60:25: error: openssl/ssl.h: No such file or directory
rtmp.c:61:25: error: openssl/rc4.h: No such file or directory
rtmp.c:62:25: error: openssl/md5.h: No such file or directory
rtmp.c:63:25: error: openssl/bio.h: No such file or directory
rtmp.c:64:28: error: openssl/buffer.h: No such file or directory
rtmp.c:66: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
In file included from rtmp.c:150:
handshake.h:66:25: error: openssl/sha.h: No such file or directory
handshake.h:67:26: error: openssl/hmac.h: No such file or directory
handshake.h:70:2: error: #error Your OpenSSL is too old, need 0.9.8 or newer with SHA256
In file included from rtmp.c:150:
handshake.h:76: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
In file included from handshake.h:86,
                 from rtmp.c:150:
dh.h:167:24: error: openssl/bn.h: No such file or directory
dh.h:168:24: error: openssl/dh.h: No such file or directory
In file included from handshake.h:86,
                 from rtmp.c:150:
dh.h:170: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
In file included from handshake.h:86,
                 from rtmp.c:150:
dh.h:197: error: expected ‘)’ before ‘y’
dh.h:247: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
dh.h:280: error: expected ‘)’ before ‘*’ token
dh.h:314: error: expected ‘)’ before ‘*’ token
dh.h:350: error: expected ‘)’ before ‘*’ token
In file included from rtmp.c:150:
handshake.h:116: error: expected declaration specifiers or ‘...’ before ‘RC4_handle’
handshake.h:116: error: expected declaration specifiers or ‘...’ before ‘RC4_handle’
handshake.h: In function ‘InitRC4Encryption’:
handshake.h:118: error: ‘SHA256_DIGEST_LENGTH’ undeclared (first use in this function)
handshake.h:118: error: (Each undeclared identifier is reported only once
handshake.h:118: error: for each function it appears in.)
handshake.h:120: error: ‘HMAC_CTX’ undeclared (first use in this function)
handshake.h:120: error: expected ‘;’ before ‘ctx’
handshake.h:122: error: ‘rc4keyIn’ undeclared (first use in this function)
handshake.h:122: error: ‘RC4_KEY’ undeclared (first use in this function)
handshake.h:123: error: ‘rc4keyOut’ undeclared (first use in this function)
handshake.h:125: warning: implicit declaration of function ‘HMAC_CTX_init’
handshake.h:125: error: ‘ctx’ undeclared (first use in this function)
handshake.h:125: warning: implicit declaration of function ‘HMAC_Init_ex’
handshake.h:125: warning: implicit declaration of function ‘EVP_sha256’
handshake.h:126: warning: implicit declaration of function ‘HMAC_Update’
handshake.h:127: warning: implicit declaration of function ‘HMAC_Final’
handshake.h:127: warning: implicit declaration of function ‘HMAC_CTX_cleanup’
handshake.h:132: warning: implicit declaration of function ‘RC4_set_key’
handshake.h:118: warning: unused variable ‘digest’
handshake.h: In function ‘HMACsha256’:
handshake.h:269: error: ‘HMAC_CTX’ undeclared (first use in this function)
handshake.h:269: error: expected ‘;’ before ‘ctx’
handshake.h:271: error: ‘ctx’ undeclared (first use in this function)
handshake.h: In function ‘CalculateDigest’:
handshake.h:282: error: ‘SHA256_DIGEST_LENGTH’ undeclared (first use in this function)
handshake.h:283: warning: unused variable ‘message’
handshake.h: In function ‘VerifyDigest’:
handshake.h:297: error: ‘SHA256_DIGEST_LENGTH’ undeclared (first use in this function)
handshake.h:297: warning: unused variable ‘calcDigest’
handshake.h: In function ‘HandShake’:
handshake.h:703: error: ‘RC4_handle’ undeclared (first use in this function)
handshake.h:703: error: expected ‘;’ before ‘keyIn’
handshake.h:704: error: expected ‘;’ before ‘keyOut’
handshake.h:772: warning: implicit declaration of function ‘DHInit’
handshake.h:772: warning: assignment makes pointer from integer without a cast
handshake.h:783: warning: implicit declaration of function ‘DHGenerateKey’
handshake.h:790: warning: implicit declaration of function ‘DHGetPublicKey’
handshake.h:806: error: ‘SHA256_DIGEST_LENGTH’ undeclared (first use in this function)
In file included from rtmp.c:150:
handshake.h:893: warning: implicit declaration of function ‘DHComputeSharedSecretKey’
handshake.h:907: error: ‘keyIn’ undeclared (first use in this function)
handshake.h:907: error: ‘keyOut’ undeclared (first use in this function)
handshake.h:907: error: too many arguments to function ‘InitRC4Encryption’
handshake.h:847: warning: unused variable ‘digestResp’
handshake.h:1049: warning: implicit declaration of function ‘RC4’
handshake.h:983: warning: unused variable ‘digest’
handshake.h:982: warning: unused variable ‘signature’
handshake.h: In function ‘SHandShake’:
handshake.h:1077: error: ‘RC4_handle’ undeclared (first use in this function)
handshake.h:1077: error: expected ‘;’ before ‘keyIn’
handshake.h:1078: error: expected ‘;’ before ‘keyOut’
handshake.h:1160: warning: assignment makes pointer from integer without a cast
handshake.h:1195: error: ‘SHA256_DIGEST_LENGTH’ undeclared (first use in this function)
handshake.h:1277: error: ‘keyIn’ undeclared (first use in this function)
handshake.h:1277: error: ‘keyOut’ undeclared (first use in this function)
handshake.h:1277: error: too many arguments to function ‘InitRC4Encryption’
handshake.h:1214: warning: unused variable ‘digestResp’
handshake.h:1341: warning: unused variable ‘digest’
handshake.h:1340: warning: unused variable ‘signature’
rtmp.c: In function ‘RTMP_TLS_Init’:
rtmp.c:243: warning: implicit declaration of function ‘SSL_load_error_strings’
rtmp.c:244: warning: implicit declaration of function ‘SSL_library_init’
rtmp.c:245: warning: implicit declaration of function ‘OpenSSL_add_all_digests’
rtmp.c:246: error: ‘RTMP_TLS_ctx’ undeclared (first use in this function)
rtmp.c:246: warning: implicit declaration of function ‘SSL_CTX_new’
rtmp.c:246: warning: implicit declaration of function ‘SSLv23_method’
rtmp.c:247: warning: implicit declaration of function ‘SSL_CTX_set_options’
rtmp.c:247: error: ‘SSL_OP_ALL’ undeclared (first use in this function)
rtmp.c:248: warning: implicit declaration of function ‘SSL_CTX_set_default_verify_paths’
rtmp.c: In function ‘RTMP_TLS_AllocServerContext’:
rtmp.c:258: error: ‘RTMP_TLS_ctx’ undeclared (first use in this function)
rtmp.c:281: warning: implicit declaration of function ‘SSLv23_server_method’
rtmp.c:281: warning: assignment makes pointer from integer without a cast
rtmp.c:282: warning: implicit declaration of function ‘SSL_CTX_use_certificate_chain_file’
rtmp.c:283: warning: implicit declaration of function ‘SSL_CTX_free’
rtmp.c:286: warning: implicit declaration of function ‘SSL_CTX_use_PrivateKey_file’
rtmp.c:286: error: ‘SSL_FILETYPE_PEM’ undeclared (first use in this function)
rtmp.c: In function ‘RTMP_Init’:
rtmp.c:327: error: ‘RTMP_TLS_ctx’ undeclared (first use in this function)
rtmp.c: In function ‘RTMP_TLS_Accept’:
rtmp.c:958: warning: implicit declaration of function ‘SSL_new’
rtmp.c:958: warning: assignment makes pointer from integer without a cast
rtmp.c:959: warning: implicit declaration of function ‘SSL_set_fd’
rtmp.c:960: warning: implicit declaration of function ‘SSL_accept’
rtmp.c: In function ‘RTMP_Connect1’:
rtmp.c:977: error: ‘RTMP_TLS_ctx’ undeclared (first use in this function)
rtmp.c:979: warning: implicit declaration of function ‘SSL_connect’
rtmp.c: In function ‘b64enc’:
rtmp.c:2457: error: ‘BIO’ undeclared (first use in this function)
rtmp.c:2457: error: ‘bmem’ undeclared (first use in this function)
rtmp.c:2457: error: ‘b64’ undeclared (first use in this function)
rtmp.c:2457: warning: left-hand operand of comma expression has no effect
rtmp.c:2458: error: ‘BUF_MEM’ undeclared (first use in this function)
rtmp.c:2458: error: ‘bptr’ undeclared (first use in this function)
rtmp.c:2460: warning: implicit declaration of function ‘BIO_new’
rtmp.c:2460: warning: implicit declaration of function ‘BIO_f_base64’
rtmp.c:2461: warning: implicit declaration of function ‘BIO_s_mem’
rtmp.c:2462: warning: implicit declaration of function ‘BIO_push’
rtmp.c:2463: warning: implicit declaration of function ‘BIO_write’
rtmp.c:2464: warning: implicit declaration of function ‘BIO_flush’
rtmp.c:2466: warning: implicit declaration of function ‘BIO_get_mem_ptr’
rtmp.c:2475: warning: implicit declaration of function ‘BIO_free_all’
rtmp.c: In function ‘PublisherAuth’:
rtmp.c:2521: error: ‘MD5_DIGEST_LENGTH’ undeclared (first use in this function)
rtmp.c:2522: error: ‘MD5_CTX’ undeclared (first use in this function)
rtmp.c:2522: error: expected ‘;’ before ‘md5ctx’
rtmp.c:2599: warning: implicit declaration of function ‘MD5_Init’
rtmp.c:2599: error: ‘md5ctx’ undeclared (first use in this function)
rtmp.c:2600: warning: implicit declaration of function ‘MD5_Update’
rtmp.c:2603: warning: implicit declaration of function ‘MD5_Final’
rtmp.c:2715: warning: unused variable ‘hash3’
rtmp.c:2715: warning: unused variable ‘hash2’
rtmp.c:2715: warning: unused variable ‘hash1’
rtmp.c:2521: warning: unused variable ‘md5sum_val’
rtmp.c: In function ‘RTMP_Close’:
rtmp.c:4235: warning: implicit declaration of function ‘DH_free’
rtmp.c: In function ‘RTMPSockBuf_Fill’:
rtmp.c:4268: warning: implicit declaration of function ‘SSL_read’
rtmp.c: In function ‘RTMPSockBuf_Send’:
rtmp.c:4311: warning: implicit declaration of function ‘SSL_write’
rtmp.c: In function ‘RTMPSockBuf_Close’:
rtmp.c:4327: warning: implicit declaration of function ‘SSL_shutdown’
rtmp.c:4328: warning: implicit declaration of function ‘SSL_free’
make[1]: *** [rtmp.o] Error 1
make[1]: Leaving directory `/usr/src/rtmpdump/librtmp'
make: *** [librtmp/librtmp.a] Error 2
[root@localhost rtmpdump]#


Installing openssl-devl fixes this.

I followed instructions here http://www.vimp.com/en/web/faq/items/howto-install-the-transcoding-tools-on-redhat-centos-etc.html to get the libraries. Looks like I cut and pasted the wrong version of ffmpeg as well :oops:

Update:

Now when I try with the source from the serviio site I get:

  Code:
[root@localhost ffmpeg]# ./configure --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
ERROR: librtmp not found

If you think configure made a mistake, make sure you are using the latest
version from Git.  If the latest version fails, report the problem to the
ffmpeg-user@ffmpeg.org mailing list or IRC #ffmpeg on irc.freenode.net.
Include the log file "config.log" produced by configure as this will help
solving the problem.

Return to Serviio Support & Help

Who is online

Users browsing this forum: No registered users and 20 guests

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