1.抓php source code來編譯pcntl.so
mkdir tmp/phpsource
cd /tmp/phpsource
apt-get source php5
cd /tmp/phpsource/php5-*/ext/pcntl
phpize
./configure
make
2.將編好的pcntl.so複製到php lib裡
cd modules
cp pcntl.so /usr/lib/php5/
3.新增pcntl.ini
vi /etc/php5/mods-available/pcntl.ini
加入下列此行
extension=pcntl.so
4.link to mods-available/
cd /etc/php5/apache2/conf.d
ln -s /etc/php5/mods-available/pcntl.ini 20-pcntl.ini
5.編輯php.ini.
memory_limit = 256M
找到下列這行,並再前方加上;(註解掉此行)
disable_functions = pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
沒有留言:
張貼留言