I try to install drush using the following command:

pear install drush/drush

I get this error message:

No releases available for package "pear.drush.org/drush" install failed.

Then I try with sudo:

sudo install drush/drush

I get this error message:

downloading drush-5.4.0.tgz …
Starting to download drush-5.4.0.tgz (398,652 bytes) done: 398,652 bytes
Could not rename /usr/bin/.tmpdrush to /usr/bin/drush copy(/usr/bin/drush): failed to open stream: No such file or directory
ERROR: commit failed.

I installed pear, and added the pear.drush.org channel. What is wrong?

I realize that my question was not very clear. I was trying to install drush using pear on OSX Mountain Lion and I got those errors. Anyway I managed to accomplish my task another way, by installing "homebrew" package manager and following a few steps from this tutorial (step 8 and 9).

Update: an even simpler way to install drush using homebrew:

brew install drush

That's it.

1 Answer 1


Use the following commands:

sudo rm /usr/bin/drush
sudo pear install drush/drush
sudo drush --version
  • or if you previously installed drush in /usr/local/bin, then use: sudo rm /usr/local/bin/drush Dec 6, 2013 at 18:14
  • Just for the record, since this question suddenly was listed as active again: Drush hasn't supported installation through Pear for many years. Read drush.org/latest/install for current install instructions which requires the use of Composer.
    – hansfn
    Jun 28, 2021 at 6:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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