Unable to encode videos due to memory allocation error
-
First off I love this plugin, just wish I could get it to work. I’ve installed FFMPEG on the server and the plugin sees it, however when I attempt to run the test inside wordpress it fails with a malloc with random error messages. But what’s more when I watch the resources on the server while the test runs it appears that it doesn’t even touch the resources. I shouldn’t be seeing those malloc errors as I have 4GB (This is a VPS) with 3GB of it free.
But when I run the test via the commandline it completes with no issues.
From wordpress:
ffmpeg version 0.10.15 Copyright (c) 2000-2014 the FFmpeg developers built on Aug 30 2014 15:49:19 with gcc 4.4.7 20120313 (Red Hat 4.4.7-3) configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --extra-cflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' --enable-bzlib --disable-crystalhd --enable-gnutls --enable-libass --enable-libcdio --enable-libcelt --enable-libdc1394 --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libxvid --enable-x11grab --enable-avfilter --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect libavutil 51. 35.100 / 51. 35.100 libavcodec 53. 61.100 / 53. 61.100 libavformat 53. 32.100 / 53. 32.100 libavdevice 53. 4.100 / 53. 4.100 libavfilter 2. 61.100 / 2. 61.100 libswscale 2. 1.100 / 2. 1.100 libswresample 0. 6.100 / 0. 6.100 libpostproc 52. 0.100 / 52. 0.100 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/newtheouterhaven/public_html/wp-content/plugins/video-embed-thumbnail-generator/images/sample-video-h264.mp4': Metadata: major_brand : isom minor_version : 512 compatible_brands: isomiso2avc1mp41 encoder : Lavf55.33.100 Duration: 00:00:01.02, start: 0.000000, bitrate: 123 kb/s Stream #0:0(eng): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], 109 kb/s, 23.98 fps, 23.98 tbr, 11988 tbn, 47.95 tbc Metadata: handler_name : VideoHandler Stream #0:1(eng): Audio: aac (mp4a / 0x6134706D), 48000 Hz, stereo, s16, 2 kb/s Metadata: handler_name : [buffer @ 0xa64240] w:1920 h:1080 pixfmt:yuv420p tb:1/1000000 sar:1/1 sws_param: [scale @ 0xa5ab40] w:1920 h:1080 fmt:yuv420p -> w:1280 h:720 fmt:yuv420p flags:0x4 Incompatible sample format 's16' for codec 'aac', auto-selecting format 'flt' [libx264 @ 0xa7a540] using SAR=1/1 [libx264 @ 0xa7a540] using cpu capabilities: none! [libx264 @ 0xa7a540] profile High, level 3.1 [libx264 @ 0xa7a540] 264 - core 120 r2151 a3f4407 - H.264/MPEG-4 AVC codec - Copyleft 2003-2011 - https://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 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=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=23 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtree=1 bitrate=2700 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00 Output #0, mp4, to '/home/newtheouterhaven/public_html/wp-content/uploads/2014/12/sample-video-h264-720.mp4': Metadata: major_brand : isom minor_version : 512 compatible_brands: isomiso2avc1mp41 encoder : Lavf53.32.100 Stream #0:0(eng): Video: h264 (![0][0][0] / 0x0021), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], q=-1--1, 2700 kb/s, 2997 tbn, 23.98 tbc Metadata: handler_name : VideoHandler Stream #0:1(eng): Audio: aac (@[0][0][0] / 0x0040), 48000 Hz, stereo, flt, 112 kb/s Metadata: handler_name : Stream mapping: Stream #0:0 -> #0:0 (h264 -> libx264) Stream #0:1 -> #0:1 (aac -> aac) Press [q] to stop, [?] for help [h264 @ 0x13fdec0] get_buffer() failed (-12 2 (nil)) [h264 @ 0x13fdec0] decode_slice_header error [h264 @ 0x13fdec0] no frame! x264 [error]: malloc of size 1053824 failed Video encoding failed From commandline: nice /usr/bin/ffmpeg -y -i "/home/newtheouterhaven/public_html/wp-content/plugins/video-embed-thumbnail-generator/images/sample-video-h264.mp4" -acodec aac -strict experimental -b:a 112k -s 1280x720 -vcodec libx264 -profile:v high -pix_fmt yuv420p -b:v 2700k -threads 1 "/home/newtheouterhaven/public_html/wp-content/uploads/2014/12/sample-video-h264-720.mp4" ffmpeg version 0.10.15 Copyright (c) 2000-2014 the FFmpeg developers built on Aug 30 2014 15:49:19 with gcc 4.4.7 20120313 (Red Hat 4.4.7-3) configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --extra-cflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' --enable-bzlib --disable-crystalhd --enable-gnutls --enable-libass --enable-libcdio --enable-libcelt --enable-libdc1394 --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libxvid --enable-x11grab --enable-avfilter --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect libavutil 51. 35.100 / 51. 35.100 libavcodec 53. 61.100 / 53. 61.100 libavformat 53. 32.100 / 53. 32.100 libavdevice 53. 4.100 / 53. 4.100 libavfilter 2. 61.100 / 2. 61.100 libswscale 2. 1.100 / 2. 1.100 libswresample 0. 6.100 / 0. 6.100 libpostproc 52. 0.100 / 52. 0.100 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/newtheouterhaven/public_html/wp-content/plugins/video-embed-thumbnail-generator/images/sample-video-h264.mp4': Metadata: major_brand : isom minor_version : 512 compatible_brands: isomiso2avc1mp41 encoder : Lavf55.33.100 Duration: 00:00:01.02, start: 0.000000, bitrate: 123 kb/s Stream #0:0(eng): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], 109 kb/s, 23.98 fps, 23.98 tbr, 11988 tbn, 47.95 tbc Metadata: handler_name : VideoHandler Stream #0:1(eng): Audio: aac (mp4a / 0x6134706D), 48000 Hz, stereo, s16, 2 kb/s Metadata: handler_name : [buffer @ 0x170b240] w:1920 h:1080 pixfmt:yuv420p tb:1/1000000 sar:1/1 sws_param: [scale @ 0x1701b40] w:1920 h:1080 fmt:yuv420p -> w:1280 h:720 fmt:yuv420p flags:0x4 Incompatible sample format 's16' for codec 'aac', auto-selecting format 'flt' [libx264 @ 0x1721540] using SAR=1/1 [libx264 @ 0x1721540] using cpu capabilities: none! [libx264 @ 0x1721540] profile High, level 3.1 [libx264 @ 0x1721540] 264 - core 120 r2151 a3f4407 - H.264/MPEG-4 AVC codec - Copyleft 2003-2011 - https://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 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=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=23 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtree=1 bitrate=2700 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00 Output #0, mp4, to '/home/newtheouterhaven/public_html/wp-content/uploads/2014/12/sample-video-h264-720.mp4': Metadata: major_brand : isom minor_version : 512 compatible_brands: isomiso2avc1mp41 encoder : Lavf53.32.100 Stream #0:0(eng): Video: h264 (![0][0][0] / 0x0021), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], q=-1--1, 2700 kb/s, 2997 tbn, 23.98 tbc Metadata: handler_name : VideoHandler Stream #0:1(eng): Audio: aac (@[0][0][0] / 0x0040), 48000 Hz, stereo, flt, 112 kb/s Metadata: handler_name : Stream mapping: Stream #0:0 -> #0:0 (h264 -> libx264) Stream #0:1 -> #0:1 (aac -> aac) Press [q] to stop, [?] for help frame= 24 fps= 9 q=5.0 Lsize= 16kB time=00:00:00.91 bitrate= 138.5kbits/s video:13kB audio:0kB global headers:0kB muxing overhead 13.999713% [libx264 @ 0x1721540] frame I:1 Avg QP: 4.71 size: 4740 [libx264 @ 0x1721540] frame P:7 Avg QP:10.30 size: 1041 [libx264 @ 0x1721540] frame B:16 Avg QP:11.73 size: 55 [libx264 @ 0x1721540] consecutive B-frames: 8.3% 8.3% 0.0% 83.3% [libx264 @ 0x1721540] mb I I16..4: 96.4% 0.2% 3.4% [libx264 @ 0x1721540] mb P I16..4: 0.1% 0.0% 0.0% P16..4: 1.3% 0.1% 0.1% 0.0% 0.0% skip:98.4% [libx264 @ 0x1721540] mb B I16..4: 0.0% 0.0% 0.0% B16..8: 0.6% 0.0% 0.0% direct: 0.0% skip:99.4% L0: 7.7% L1:92.3% BI: 0.0% [libx264 @ 0x1721540] final ratefactor: -5.02 [libx264 @ 0x1721540] 8x8 transform intra:0.2% inter:31.7% [libx264 @ 0x1721540] coded y,uvDC,uvAC intra: 2.5% 0.0% 0.0% inter: 0.3% 0.0% 0.0% [libx264 @ 0x1721540] i16 v,h,dc,p: 97% 0% 2% 0% [libx264 @ 0x1721540] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 0% 29% 71% 0% 0% 0% 0% 0% 0% [libx264 @ 0x1721540] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 40% 18% 17% 4% 3% 6% 3% 6% 2% [libx264 @ 0x1721540] i8c dc,h,v,p: 100% 0% 0% 0% [libx264 @ 0x1721540] Weighted P-Frames: Y:0.0% UV:0.0% [libx264 @ 0x1721540] ref P L0: 92.5% 0.5% 6.2% 0.8% [libx264 @ 0x1721540] ref B L0: 58.1% 41.9% [libx264 @ 0x1721540] ref B L1: 96.8% 3.2% [libx264 @ 0x1721540] kb/s:103.13
[Please use the code buttons for posting code or error logs]
At a lose here.
https://www.ads-software.com/plugins/video-embed-thumbnail-generator/
- The topic ‘Unable to encode videos due to memory allocation error’ is closed to new replies.