Original link: http://www.bowen-tech.top/articles/detail/25
php-fpm linux environment using the exec function calls ffmpeg, error ffmpeg: command not found the solution
打印具体报错命令
0 => 'sh: ffmpeg: command not found',
Specific reasons for invoking the command through PHP, without introducing a corresponding environment variable, this command can not find the cause
Solution
PHP-fpm.conf the inside of the profile in front of the following lines; remove
my PHP php-fpm.conf profile in /usr/local/php/etc/php-fpm.conf ;
the env [the PATH] which was added ffmpeg path, such as in my / usr / local / ffmpeg / bin
env[PATH] = /usr/local/bin:/usr/bin:/bin:/usr/local/ffmpeg/bin