1

When I use drush to download modules, I get this weird error:

drush dl registry_rebuild exec(): Unable to fork [wget --version 2>&1] exec.inc:150 [warning] exec(): Unable to fork [curl --version 2>&1] exec.inc:150 [warning] exec(): Unable to fork [which curl 2>&1] exec.inc:150 [warning] wget nor curl executables found. [error]

which wget gives me /usr/bin/wget and which curl gives me /usr/bin/curl. /usr/bin/ is in my PATH. This seldom works if I do drush cc drush. How do I solve this permanently?

  • 1
  • 1
    That error in on windows. Besides, my error goes away temporarily if I do a drush cc drush – Kartagis Mar 4 '14 at 7:03
  • which OS you are using? – user12947 Mar 4 '14 at 7:43
  • I am using CentOS. – Kartagis Mar 4 '14 at 8:39
  • I tried to download and enable facetapi, and I got the errors again. I cc'd all, then there were no problems. – Kartagis Mar 4 '14 at 21:53
1

On Centos, to install wget:

sudo yum install wget

To install curl the following should suffice:

sudo yum install php-curl
sudo service httpd restart

++++++++++++++++++++ EDIT +++++++++++++++++++++++++

According to this post, "unable to fork" errors are likely to result from too many processes running. They recommend increasing the limit like so:

sysctl -w kern.maxprocs=1000000
  • The op states that the commands are installed, this is tested by using 'which'. – Letharion Mar 4 '14 at 15:11
  • well that's how you install them. :) if it says they're installed, you should be able to use them. If you can't, it's possibly because the path hasn't been exported. – Ollie Mar 4 '14 at 15:29
  • Right, I realize that's how they are installed, but that doesn't answer the question. It possibly is a path issue, but the op also states that the relevant directory is in the PATH already. – Letharion Mar 4 '14 at 17:10
  • oops, you're right. :s I've edited my answer to be more relevant. – Ollie Mar 4 '14 at 19:05
  • sysctl -w kern.maxprocs=1000000 error: "kern.maxprocs" is an unknown key – Kartagis Jun 13 '15 at 20:13
0

On nginx on aws, I've found the php-fpm can get out of hand. To tell if that's happened, ps -ef |grep php-fpm|wc -l. If the number is more than 10 or so, you can reset php-fpm with: sudo service php-fpm restart

0

I fix the "Unable to fork could" with Drush by restarting my server. I think @Ollie's anwser is right.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.