Error During Video Encoding [solved]

edited April 2015 in Bugs and Errors
When I upload a video on my site it says it was successful, but then I get an email saying 'The temp H.264 file was not created. The id of the video is: 5' and the video is nowhere to be found on the site.

Here is my log file, I see that I am not the only one with this issue but I can't seem to fix my issue. Someone please help me resolve this because this script is exactly what I am looking for.






// Converter Called...
Values passed to encoder:
Array
(
[0] => /home/matmal14/gamelooter.com/test/cc-core/system/encode.php
[1] => --video=5
)

Validating requested video...
Establishing variables...
Verifying raw video exists...
Verifying raw video was valid size...

Preparing for: H.264 Encoding...
H.264 Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/hsfyPhMGCrlJHISyx8jg.mp4 -vcodec libx264 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -vb 800k -acodec libfaac -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/hsfyPhMGCrlJHISyx8jg_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/hsfyPhMGCrlJHISyx8jg.log 2>&1
Verifying H.264 video was created...
The temp H.264 file was not created. The id of the video is: 5






==================================================================
H.264 ENCODING
==================================================================

H.264 Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/hsfyPhMGCrlJHISyx8jg.mp4 -vcodec libx264 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -vb 800k -acodec libfaac -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/hsfyPhMGCrlJHISyx8jg_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/hsfyPhMGCrlJHISyx8jg.log 2>&1

H.264 Encoding Output:


ffmpeg version 0.8.16-4:0.8.16-0ubuntu0.12.04.1, Copyright (c) 2000-2014 the Libav developers
built on Sep 16 2014 18:33:49 with gcc 4.6.3
The ffmpeg program is only provided for script compatibility and will be removed
in a future release. It has been deprecated in the Libav project to allow for
incompatible command line syntax improvements in its replacement called avconv
(see Changelog for details). Please use avconv instead.
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/matmal14/gamelooter.com/test/cc-content/uploads/temp/hsfyPhMGCrlJHISyx8jg.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: isommp42
creation_time : 2014-04-24 23:49:36
Duration: 00:01:17.81, start: 0.000000, bitrate: 579 kb/s
Stream #0.0(und): Video: h264 (Constrained Baseline), yuv420p, 640x360 [PAR 1:1 DAR 16:9], 481 kb/s, 25 fps, 25 tbr, 25 tbn, 50 tbc
Stream #0.1(und): Audio: aac, 44100 Hz, stereo, s16, 95 kb/s
Metadata:
creation_time : 2014-04-24 23:49:36
Unknown encoder 'libfaac'

Comments

  • The script is complaining about libfaac is missing. Go to admin panel - settings - video and in both the h264 and mobile encoding option fields change libfaac to acc.

    Then purge your logs admin panel - dashboard - system logs and try your upload again.
  • // Converter Called...
    Values passed to encoder:
    Array
    (
    [0] => /home/matmal14/gamelooter.com/test/cc-core/system/encode.php
    [1] => --video=11
    )

    Validating requested video...
    Establishing variables...
    Verifying raw video exists...
    Verifying raw video was valid size...

    Preparing for: H.264 Encoding...
    H.264 Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/9rOPPwxH64hJEK6bUooV.mp4 -vcodec libx264 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -vb 800k -acodec acc -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/9rOPPwxH64hJEK6bUooV_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/9rOPPwxH64hJEK6bUooV.log 2>&1
    Verifying H.264 video was created...
    The temp H.264 file was not created. The id of the video is: 11








    ==================================================================
    H.264 ENCODING
    ==================================================================

    H.264 Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/9rOPPwxH64hJEK6bUooV.mp4 -vcodec libx264 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -vb 800k -acodec acc -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/9rOPPwxH64hJEK6bUooV_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/9rOPPwxH64hJEK6bUooV.log 2>&1

    H.264 Encoding Output:


    ffmpeg version 0.8.16-4:0.8.16-0ubuntu0.12.04.1, Copyright (c) 2000-2014 the Libav developers
    built on Sep 16 2014 18:33:49 with gcc 4.6.3
    The ffmpeg program is only provided for script compatibility and will be removed
    in a future release. It has been deprecated in the Libav project to allow for
    incompatible command line syntax improvements in its replacement called avconv
    (see Changelog for details). Please use avconv instead.

    Seems stream 0 codec frame rate differs from container frame rate: 30000.00 (30000/1) -> 29.97 (30000/1001)
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/matmal14/gamelooter.com/test/cc-content/uploads/temp/9rOPPwxH64hJEK6bUooV.mp4':
    Metadata:
    major_brand : 3gp6
    minor_version : 256
    compatible_brands: isom3gp6
    creation_time : 2015-03-25 03:51:23
    Duration: 00:00:37.01, start: 0.000000, bitrate: 223 kb/s
    Stream #0.0(und): Video: mpeg4 (Simple Profile), yuv420p, 320x180 [PAR 1:1 DAR 16:9], 189 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 30k tbc
    Metadata:
    creation_time : 2015-03-25 03:51:23
    Stream #0.1(und): Audio: aac, 22050 Hz, mono, s16, 32 kb/s
    Metadata:
    creation_time : 2015-03-25 03:51:23
    Unknown encoder 'acc'
  • @Damian
    Uploads still dont work.
  • Oops, typo. Should be aac not acc. Sorry about that.
  • // Converter Called...
    Values passed to encoder:
    Array
    (
    [0] => /home/matmal14/gamelooter.com/test/cc-core/system/encode.php
    [1] => --video=13
    )

    Validating requested video...
    Establishing variables...
    Verifying raw video exists...
    Verifying raw video was valid size...

    Preparing for: H.264 Encoding...
    H.264 Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/Kddhs9BTRolwJOU3OO1O.mp4 -vcodec libx264 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -vb 800k -acodec aac -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/Kddhs9BTRolwJOU3OO1O_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/Kddhs9BTRolwJOU3OO1O.log 2>&1
    Verifying H.264 video was created...
    The temp H.264 file was not created. The id of the video is: 13





    ==================================================================
    H.264 ENCODING
    ==================================================================

    H.264 Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/Kddhs9BTRolwJOU3OO1O.mp4 -vcodec libx264 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -vb 800k -acodec aac -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/Kddhs9BTRolwJOU3OO1O_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/Kddhs9BTRolwJOU3OO1O.log 2>&1

    H.264 Encoding Output:


    ffmpeg version 0.8.16-4:0.8.16-0ubuntu0.12.04.1, Copyright (c) 2000-2014 the Libav developers
    built on Sep 16 2014 18:33:49 with gcc 4.6.3
    The ffmpeg program is only provided for script compatibility and will be removed
    in a future release. It has been deprecated in the Libav project to allow for
    incompatible command line syntax improvements in its replacement called avconv
    (see Changelog for details). Please use avconv instead.

    Seems stream 0 codec frame rate differs from container frame rate: 30000.00 (30000/1) -> 29.97 (30000/1001)
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/matmal14/gamelooter.com/test/cc-content/uploads/temp/Kddhs9BTRolwJOU3OO1O.mp4':
    Metadata:
    major_brand : 3gp6
    minor_version : 256
    compatible_brands: isom3gp6
    creation_time : 2015-03-13 02:42:29
    Duration: 00:02:36.13, start: 0.000000, bitrate: 226 kb/s
    Stream #0.0(und): Video: mpeg4 (Simple Profile), yuv420p, 320x144 [PAR 1:1 DAR 20:9], 192 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 30k tbc
    Metadata:
    creation_time : 2015-03-13 02:42:29
    Stream #0.1(und): Audio: aac, 22050 Hz, mono, s16, 31 kb/s
    Metadata:
    creation_time : 2015-03-13 02:42:29
    [buffer @ 0xa04e80] w:320 h:144 pixfmt:yuv420p
    [scale @ 0xa05120] w:320 h:144 fmt:yuv420p -> w:320 h:144 fmt:yuv420p flags:0x4
    [libx264 @ 0xa4e400] using SAR=1/1
    [libx264 @ 0xa4e400] using cpu capabilities: MMX2 SSE2Fast FastShuffle SSEMisalign LZCNT
    [libx264 @ 0xa4e400] profile Main, level 2.0
    [libx264 @ 0xa4e400] 264 - core 120 r2151 a3f4407 - H.264/MPEG-4 AVC codec - Copyleft 2003-2011 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_range=16 chroma_me=1 trellis=1 8x8dct=0 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=0 b_adapt=1 b_bias=0 direct=1 weightb=0 open_gop=1 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtree=1 bitrate=800 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.25 aq=1:1.00
    encoder 'aac' is experimental and might produce bad results.
    Add '-strict experimental' if you want to use it.
    Or use the non experimental encoder 'libvo_aacenc'.
  • Still not working @Damian
  • The log says it all. It's telling you that aac is experimental. Add '-strict experimental' after the aac, or replace the aac with libvo_aacenc.
  • // Converter Called...
    Values passed to encoder:
    Array
    (
    [0] => /home/matmal14/gamelooter.com/test/cc-core/system/encode.php
    [1] => --video=16
    )

    Validating requested video...
    Establishing variables...
    Verifying raw video exists...
    Verifying raw video was valid size...

    Preparing for: H.264 Encoding...
    H.264 Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/0TupKnAo1wVXhdATBETD.3gp -vcodec libx264 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -vb 800k -acodec aac -strict experimental -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/0TupKnAo1wVXhdATBETD_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/0TupKnAo1wVXhdATBETD.log 2>&1
    Verifying H.264 video was created...

    Checking qt-faststart permissions...

    Shifting moov atom on H.264 video...
    H.264 Shift Moov Atom Command: /home/matmal14/gamelooter.com/test/cc-core/system/bin/qtfaststart /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/0TupKnAo1wVXhdATBETD_temp.mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/h264/0TupKnAo1wVXhdATBETD.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/0TupKnAo1wVXhdATBETD.log 2>&1
    Verifying final H.264 file was created...

    Preparing for: Mobile Encoding...
    Mobile Encoding Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/0TupKnAo1wVXhdATBETD.3gp -vcodec libx264 -vf "scale=min(480\,iw):trunc(ow/a/2)*2" -vb 600k -ac 2 -ab 96k -ar 44100 -f mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/mobile/0TupKnAo1wVXhdATBETD_temp.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/0TupKnAo1wVXhdATBETD.log 2>&1
    Verifying Mobile video was created...

    Shifting moov atom on Mobile video...
    Faststart Command: /home/matmal14/gamelooter.com/test/cc-core/system/bin/qtfaststart /home/matmal14/gamelooter.com/test/cc-content/uploads/mobile/0TupKnAo1wVXhdATBETD_temp.mp4 /home/matmal14/gamelooter.com/test/cc-content/uploads/mobile/0TupKnAo1wVXhdATBETD.mp4 >> /home/matmal14/gamelooter.com/test/cc-core/logs/0TupKnAo1wVXhdATBETD.log 2>&1
    Verifying final Mobile file was created...

    Retrieving video duration...
    Duration command results:
    Array
    (
    [0] => Duration: 00:01:59.48, start: 0.000000, bitrate: 225 kb/s
    )

    Duration in Seconds: 119
    Thumb Position: 60

    Preparing to create video thumbnail...
    Thumbnail Creation Command: /usr/bin/ffmpeg -i /home/matmal14/gamelooter.com/test/cc-content/uploads/temp/0TupKnAo1wVXhdATBETD.3gp -ss 60 -vf "scale=min(640\,iw):trunc(ow/a/2)*2" -t 1 -r 1 -f mjpeg /home/matmal14/gamelooter.com/test/cc-content/uploads/thumbs/0TupKnAo1wVXhdATBETD.jpg >> /home/matmal14/gamelooter.com/test/cc-core/logs/0TupKnAo1wVXhdATBETD.log 2>&1
    Verifying valid thumbnail was created...

    Updating video information...
    Deleting raw video...
    Video ID: 16, has completed processing!



  • edited April 2015
    It seems to have processed and worked but the video is still not up on my site?
    @Damian
  • edited April 2015
    Ok it looks like the video finished encoding without errors, that's good.

    Did you turn "approval required"? If so can you check Admin panel - videos - pending. The video would be set to pending when processing is complete and will wait until an administrator approves it before it is visible on the site.
  • edited April 2015
    Thanks for all the help! I finally got it working!
This discussion has been closed.