linux - php exec() works on some calls, not other similar ones -


i have php script cuts video. here 3 exec() commands - 2 execute while 1 not:

works:

sudo ffmpeg -i /home/vidserver/videos/$filename.mp4 -ss $ctime -t 00:00:06 -acodec copy -vcodec copy -y /var/vidcache/test$x.mp4

works:

sudo ffmpeg -i /var/vidcache/test$x.mp4 -qscale:v 1 /var/vidcache/i$x.mpg

does not work:

sudo ffmpeg -i concat:"i0.mpg|i1.mpg" -qscale:v 1 /var/vidcache/output.mpg

/var/vidcache has 777 privs , www-data in sudoers file nopasswd (yes, know - debug purposes before lock down security).

when run last command php script command line itself, work. (running www-data or root.) when try put in function called web page, not work.

any ideas?

this should fix third exec:

sudo ffmpeg -i "concat:i0.mpg|i1.mpg" -qscale:v 1 /var/vidcache/output.mpg 

here wiki page on how concat media files in ffmpeg.


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -