curl nor wget was found When I use drush to download modules, I get this weird error:

drush dl registry_rebuild
exec(): Unable to fork [wget --version 2&gt;&amp;1] exec.inc:150 [warning]
exec(): Unable to fork [curl --version 2&gt;&amp;1] exec.inc:150 [warning]
exec(): Unable to fork [which curl 2&gt;&amp;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?
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