gpt4 book ai didi

ruby-on-rails - 启动 Rails Passenger App 时出错

转载 作者:行者123 更新时间:2023-12-05 06:44:08 50 4
gpt4 key购买 nike

我使用 RVM 将 ruby​​ 版本更改为 2.1.5,使用 Apache 配置了 4 个 Rails App,但我无法使用 Passenger 启动它们。所以我每次都会遇到这个错误。

App 8612 stderr: Cannot execute "/root/.rvm/gems/ruby-2.1.5/gems/passenger-5.0.8/buildout/support-binaries/PassengerAgent": Permission denied (errno=13)
[ 2015-06-01 20:11:43.2847 8422/7f244835b700 App/Implementation.cpp:287 ]: Could not spawn process for application /var/www/example: An error occured while starting up the preloader.
Error ID: 2862c35c
Error details saved to: /tmp/passenger-error-pKDVAi.html
Message from application: Cannot execute "/root/.rvm/gems/ruby-2.1.5/gems/passenger-5.0.8/buildout/support-binaries/PassengerAgent": Permission denied (errno=13)


[ 2015-06-01 20:11:43.2889 8422/7f2449b9f700 age/Hel/Req/CheckoutSession.cpp:252 ]: [Client 2-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 2862c35c. Please see earlier logs for details about the error.

我应该如何纠正这种情况?我使用 chown -R 777/root/.rvm/gems/ruby-2.1.5/gems/passenger-5.0.8/buildout/support-binaries/ ,但问题最后

最佳答案

首先,您不应该使用 root 用户运行您的应用程序。

PassengerUserSwitching on 添加到您的虚拟主机。如果您的 Web 应用程序归 root 所有,它应该能够使用 rvm(因为它仅为 root 用户安装)。

关于ruby-on-rails - 启动 Rails Passenger App 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30585392/

50 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com