2

I keep getting the following error

Fatal error: Uncaught System_Daemon_Exception: PHP is compiled without --enable-pcntl directive in

I have used the PEAR Daemon program to create a daemon but I keep getting the error above.

I'm guessing I need the posix and pcntl extensions, but how do I install/enable pcntl and posix for PHP without recompiling PHP?

also I used the yum command but no package was found.

I'm on a CENTOS Linux server.

2 Answers2

2

CentOS 5.7 does not ship with those packages.

pcntl does not seem to be available, so either compile it yourself or use an additional repository, e.g. EPEL. We used it to get current php versions.

Community
  • 1
  • 1
cweiske
  • 30,033
  • 14
  • 133
  • 194
0

I was trying to do the same thing, and the only way that worked was compiling the pcntl extension itself -- at least it wasn't recompiling the whole php source. The method I used I mentioned in my answer at the serverfault question cweiske linked to.

I managed to adapt the instructions there to also work for the posix module, by just performing the same steps with "pcntl" replaced with "posix".

Community
  • 1
  • 1
Doug Kavendek
  • 3,624
  • 4
  • 31
  • 43