新手问题 [已解决] apache +passenger 发布 rails 应用,出现 404

wjlight · January 08, 2013 · Last by wjlight replied at January 09, 2013 · 2578 hits

启动 mongrel 跑 rails,在浏览器中输入http://ip:3000/controller/可以正常工作

但是,使用 apache 启动后,在 public 中的 index.html 应该是该目录下所有 html 都可以访问到,除了这些其他的任意路径都返回 404,如在浏览器中输入http://ip/controller/,404返回 url /controller not found in this server

感觉只能访问静态页面,rails 相关的东西都没法用,

请问这是怎么回事啊?

通常是配置或者权限问题,具体要去 apache 的 log 下面看一下,通常 apache 的 log 地址在这里:

/var/log/apache2/error.log

@lgn21st 非常感谢,问题解决了~~~

You need to Sign in before reply, if you don't have an account, please Sign up first.