• Welcome to WooUSEFUL by PHPVIBE . Please log in.

[ Video Sharing CMS v4 ] ffmpeg and cron job

Started by aryan2029,

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

aryan2029Topic starter

Dear support,

i have some problem which i couldn't fine where the problem is, i'm asking if this has happened with someone or support might know it.

1. i installed ffmpeg successfully by the tutorial of phpvibe support forum.
http://www.phpvibe.com/forum/tutorials/how-to-compile-ffmpeg-on-linux-x86-64-with-centos-6-5-final-cpanel-installed/msg23071/
but still when i upload more then 25mb video nothing will happen, video will not added to site. i don't know why.. video will be uploaded to site's disk but will not show at the site
i uploaded a phpvibe script to one of my free domain, which is in the some vps, please check
http://modvideo.com
username: admin@modvideo.com
password: admintest
i kindly ask support to check this page for me. i install ffmpeg successfully again if u need to check i can provide root access in pm.

2. i added cron.php to cpanel and the script admin option it doesn't import videos from youtube until i don't run /cron.php on browser.

best regards,
  •  

Marius

Hi,

1. Did you test the ffmpeg using the tester? Doesn't seem to work for me, I've uploaded an 15,5 mb flv file and it's not converting.
One other question is what's the VPS's hardware? Ffmpeg is pretty heavy, if it bumps to a limit the server will kill the process for taking to many resources.
Is the path to php bin's correct in admin?

2. Does it actually trigger the cron? What's the trigger response received on the e-mail by the panel?
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

aryan2029Topic starter

thank you mario for responding.

1.i have 2GB Ram with 2 CPU dedicated vps, and it's managed with cpanel, i have some vps with another provider it will be expired 31,12,14 which is still with me and it works well even i tried 300MB video it convert. but i don't know about this, and yes when i run - which ffmpeg - it provide me the some path for ffmpeg, i didn't tried .flv or any other i uploaded .mp4 which it doesn't convert.

2. i didn't received any email by cpanel about cron.

note, i kindly ask you to help me fine the ffmpeg problem, if root access needed please let me know i will provide it in pm.

thank you
  •  

Marius

Hi,

I'm not a hosting/ffmpeg expert, just coder. I know only usage typology when it comes to ffmpeg (php interaction).

What version is your ffmpeg? Make sure it's 1.0+ (Not 0.6 or 0.7, the commonly installed ffmpeg versions, but old as hell).

2 Gb of ram are very poor for ffmpeg since ffmpeg is really heavy. If you plan to let users upload videos then 2-3 simultaneous uploads over 100mb would bring that server down (or best scenario the ffmpeg will be killed for using to many resources).

See this:

http://www.phpvibe.com/uploading-not-working-on-phpvibe-missing-video-ffmpeg-debug/

http://www.phpvibe.com/choosing-a-server-for-phpvibe/
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

aryan2029Topic starter

  •  

max18121980

#5
Sorry in advance for the opportunity to repeat the question. Please help, as I do not know how to write the way to cron.

1. File cron.php  is in the root of the site. In Control Panel, I added a rule to cron
2. videocron.php and cron.php - permissions (chmod : 0555)
3. In the control panel, site I do not know how to write, because the video is not encoded !!!

Please help. I did not do so because spent a lot of hours and does not work
  •  

max18121980

Quote from: max18121980 on
Sorry in advance for the opportunity to repeat the question. Please help, as I do not know how to write the way to cron.

1. File cron.php  is in the root of the site. In Control Panel, I added a rule to cron
2. videocron.php and cron.php - permissions (chmod : 0555)
3. In the control panel, site I do not know how to write, because the video is not encoded !!!

Please help. I did not do so because spent a lot of hours and does not work
  •  

max18121980

Аt the moment when you add video to avi format show only Tumbnail. The video itself does not work.
  •  

Marius

Quote from: max18121980 on
Аt the moment when you add video to avi format show only Tumbnail. The video itself does not work.

Hi, seems you use an old tester. Use this one http://www.phpvibe.com/requirements/
It also has ffmpeg with output, this way we can see what's going on, it could be many reasons.
Hope you ffmpeg is 1.0+
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

#9
Here are the results.
  •  

Marius

If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

I did as it is written in your recommendations on the links below. I do not understand what the problem is. (((((
  •  

Marius

Quote from: max18121980 on
I did as it is written in your recommendations on the links below. I do not understand what the problem is. (((((

Your ffmpeg version is fine, but can you please paste all that output, in the image it's scrollable the box, and I can't just guess what the issue is.
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

I will give this error [aac @ 0x73c060] The encoder 'aac' is experimental but experimental codecs are not enabled, add '-strict -2' if you want to use it.

And I add -strict -2 in the tester ff.php and all so good to convert.

How do I edit right now to convert on the site (cron.php or videocron.php), rather than on the tester
  •  

Marius

videocron.php exact same code line as in the tester.
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

Sorry, but you just only one can help me!

You mean completely copy all the rows or just this one?

$output ="{ffmpeg-cmd} -i {input} -vcodec libx264 -s {ffmpeg-vsize} -threads 4 -movflags faststart -strict -2 {output}.mp4";
  •  

Marius

videocron.php change line 12 from :

$output ="{ffmpeg-cmd} -i {input} -vcodec libx264 -s {ffmpeg-vsize} -threads 4 -movflags faststart {output}.mp4";



to


$output ="{ffmpeg-cmd} -i {input} -vcodec libx264 -s {ffmpeg-vsize} -threads 4 -movflags faststart -strict -2 {output}.mp4";



As per your test's finding.
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

Thank you very much, all works fine. Yay. ;D
  •  

Marius

Sorry for taking so long, but for your comfort is always best to paste all info you can gather.
We can help as long as we have with what to debug the issue.
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

Ok, now the only problem - it is not loaded Russian filenames))

тест.avi (for example)
  •  

Marius

Gimme 1-2 more and longer names for file please which more characters which could be problematic. (just in case, so I can make relevant tests)
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

Believe me, any name in Russian - is not loaded, a link to the site I wrote a private message
  •  

Marius

It doesn't trigger the upload for me either on our sites.
There are many topics about this, seems to be a common problem, will try to find a result on google.
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

max18121980

Nu am nici o îndoială. sunteți cel mai bun programist, Domnul Mario!!!
  •  

Marius

Yeah, this is the problem in the browser console:

Uncaught SyntaxError: Failed to execute 'setRequestHeader' on 'XMLHttpRequest': 'тест.avi.avi' is not a valid HTTP header field value.
If this helped, consider buying me a coffee.
20 years coding, tweaking, building in PHP. Still creating!
  •  

Similar topics (7)