1

I am using php-ffmpeg for converting uploaded videos. With all videos it was working great before. But from last few days through now only small videos are getting convert and giving me proper response on success. But large videos which size are more than 25MB they are uploading well on server converting also well but on success response it giving me error. image is bellow.

enter image description here so here when I refresh my page manually or check on server then I can see that video uploaded on server and converted also well already just issue facing in sending me success response when video get converted.

And code is same for small and large video convert so small is working well and with large facing issues from last few days through.

Any possible suggestion guys ?

Gaurang Sondagar
  • 814
  • 1
  • 9
  • 23

3 Answers3

4

Set this rule in your upload file or in main configuration file,By adding this line it removes memory limit for any file in wordpress. So that you can upload any size of file without limitations.

ini_set('memory_limit', '-1');

May this thing help you to solve out your problem.

Ajay Katariya
  • 439
  • 9
  • 22
0

Maybe it's a problem of time limit or memory limit, so you can add these lines:

set_time_limit(3600); // For exemple or 0 for no time limit
ini_set('memory_limit', '2048M'); // For exemple or -1 fo no memory limit

Or you can directly change php.ini file to set configuration globally

T. AKROUT
  • 1,719
  • 8
  • 18
  • Thank you T. AKROUT for your response. We have already tried that but it's not working for us we have increased limit from php.ini on our VPS and also I have created custom php.ini on server's directory for this and check phpinfo() so changes affecting to configurations but still same issue I am facing when converting video. Also I have increased RAM from 1 GB to 2 GB on my server then also same issues coming up. – Gaurang Sondagar Nov 09 '17 at 08:50
0

-> here is just for idea....

ini_set('upload_max_filesize',  '2000M');
ini_set('post_max_size',        '2000M');
ini_set('memory_limit', '4048M');
ini_set('display_errors', 'On');
ini_set('max_execution_time', 0);
ini_set('max_input_time', 0);

set_time_limit(0);
error_reporting(E_ALL);    
libxml_use_internal_errors(true);

-- and:

file_uploads
upload_max_filesize
max_input_time 
memory_limit 
max_execution_time 
post_max_size