欢迎各位兄弟 发布技术文章

这里的技术是共享的

You are here

安装DRUSH 遇到的问题以及解决办法

shiping1 的头像

安装DRUSH 遇到的问题以及解决办法

今天在本机安装drush-6.x-3.3,遇到了一些问题,还好搜出了解决方法。

本机 Ubuntu 10.04

下载安装drush-6.x-3.3

$ cd ~
$ wget http://ftp.drupal.org/files/projects/drush-6.x-3.3.tar.gz
$ tar zxvf drush-6.x-3.3.tar.gz
$ chmod u+x ~/drush/drush
$ sudo ln -s ~/drush/drush /usr/local/bin/drush

测试drush
$ drush help

却收到提示:exec: 53: php: not found

搜了一下,找到这篇讨论 http://drupal.org/node/738038#comment-2721536

安装php5-cli

$ sudo apt-get install php5-cli

重启apache
sudo /etc/init.d/apache2 restart

测试drush
$ drush help

显示了drush 命令帮助,但收到提示:

PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0

搜了一下,找到了解决方法

$ sudo cp /etc/php5/cli/conf.d/mcrypt.ini /etc/php5/cli/conf.d/mcrypt.ini_old
$ sudo vi /etc/php5/cli/conf.d/mcrypt.ini

将第一行的"#"换成";"
保存退出VI:
:wq

测试drush
$ drush help

问题全部解决了。

来自 http://playts.com/node/133

普通分类: