【发布时间】:2016-03-02 21:18:46
【问题描述】:
我有一个 Centos 6-Apache-Passenger-Ruby 的组合。按照说明here 进行安装。我也有 whm,这意味着必须通过单击来更改 httpd.conf。在尝试包含/etc/httpd/conf.d/*.conf 时,告诉我有一个错误,因为:Cannot load /usr/local/apache/modules/mod_passenger.so into server.
问题是/etc/httpd/conf.d/passenger.conf 的这一行:
LoadModule passenger_module modules/mod_passenger.so
句子的最后部分应该指向实际的mod_passenger.so,那不在/etc/httpd/modules里面...问题是它在哪里?
我是通过yum安装的,意思是:
sudo yum install -y epel-release pygpgme curl
sudo curl --fail -sSLo /etc/yum.repos.d/passenger.repo https://oss-binaries.phusionpassenger.com/yum/definitions/el-passenger.repo
sudo yum install -y mod_passenger
当我运行sudo /usr/bin/passenger-config validate-install 时,安装哪个 apache(已经全部运行)并不重要,如下所示:
You did not specify 'LoadModule passenger_module' in any of your
Apache configuration files. This means that Phusion Passenger
for Apache is not installed or not active. Please run the
Phusion Passenger Apache module installer:
/usr/bin/ruby /usr/bin/passenger-install-apache2-module --apxs2=/usr/bin/apxs
我运行安装程序,说一切正常,但始终无法运行...
我知道我必须像这样指定位置的位置:
LoadModule passenger_module /path/to/the/module
但我找不到它。定位 mod_passenger.so 不起作用。而且我不能去 .rvm 位置,因为不在那里。乘客不是作为 gem 安装,而是通过 yum...
有什么技巧可以找到乘客在哪里找到mod_passenger.so?谢谢。
【问题讨论】:
-
我找到了解决方案 find / -type f -name mod_passenger.so... 感谢serverfault.com/questions/139790/…
-
find很好也很彻底,但它比我在下面展示的rpm解决方案消耗更多的 I/O、CPU 和时钟时间。
标签: ruby-on-rails linux apache passenger