robintw
robintw

Reputation: 28571

500 Internal Server Error for rails app with no errors recorded in any log file

I have a rails application that is giving a 500 Internal Server Error page when I try and visit it (it's at http://www.helendan.rtwilson.com), however I can't find any details on the error in any of the log files.

I've tried looking inside ./log in the rails application directory and there is nothing in any of the log files there. I've also tried looking at the web server logs themselves, and the access.log file shows an access to / and a request for the favicon, but nothing else, and the error.log is completely blank.

I have run rails console and checked that I can do some basic things with my application. For example:

>> rails console
Loading development environment (Rails 3.0.3)
irb(main):001:0> @p = Present.find(1)
=> #<Present id: 1, title: "Nice Sheets", notes: "We'd like some nice sheets for our married bed. Pre...", est_price: "50", taken: true, created_at: "2011-01-29 23:56:17", updated_at: "2011-05-05 10:46:58">
irb(main):002:0> exit

and that all seems to work fine.

I'm at a loss as to where to look to find out what on earth the error is, and therefore how to debug it. As far as I'm aware the application worked fine last time I used it!

Any ideas on where I might be able to find some sort of error message? (This is on a shared server at Dreamhost by the way, so I am limited in certain things I can do).

Update: I have now been shown the error message by Dreamhost support, and it is as follows:

Could not find rake-0.9.2.2 in any of the sources

Try running `bundle install`.

*** Exception EOFError in spawn manager (Unexpected end-of-file
detected.) (process 22025):

    from /dh/passenger/lib/phusion_passenger/utils.rb:306:in
`unmarshal_and_raise_errors'

    from
/dh/passenger/lib/phusion_passenger/rack/application_spawner.rb:71:in
`spawn_application'

    from
/dh/passenger/lib/phusion_passenger/rack/application_spawner.rb:41:in
`spawn_application'

    from /dh/passenger/lib/phusion_passenger/spawn_manager.rb:159:in
`spawn_application'

    from /dh/passenger/lib/phusion_passenger/spawn_manager.rb:287:in
`handle_spawn_application'

    from
/dh/passenger/lib/phusion_passenger/abstract_server.rb:352:in `__send__'

    from
/dh/passenger/lib/phusion_passenger/abstract_server.rb:352:in `main_loop'

    from
/dh/passenger/lib/phusion_passenger/abstract_server.rb:196:in
`start_synchronously'

    from /dh/passenger/bin/passenger-spawn-server:61

[ pid=21527 file=ext/apache2/Hooks.cpp:727 time=2012-01-09 16:12:58.339
]:

 Unexpected error in mod_passenger: Cannot spawn application
'/home/robintw/rails/presents-hd': The spawn server has exited
unexpectedly.

 Backtrace:

    in 'virtual boost::shared_ptr
Passenger::ApplicationPoolServer::Client::get(const
Passenger::PoolOptions&)' (ApplicationPoolServer.h:471)

They're saying that it's a problem with my apps configuration, but I'm not so sure. Running rails server works fine from the command line - and I can access the application via lynx on localhost:3000 and it works fine. I've run bundle install and it doesn't find anything it needs to install, and says that rake-0.9.2.2 is installed already.

Any ideas on what I might be able to do about this?

Upvotes: 2

Views: 8482

Answers (1)

Zubin
Zubin

Reputation: 9732

If there was a problem with the logfile, you'd see an error starting rails console. My guess is it's a web server configuration error, in which case you'll need to take a look at the web server logs. I'm not sure, but hopefully they're accessible from somewhere in your home directory.

Upvotes: 1

Related Questions