My application is giving error "Application error (Apache)
Change this error message for exceptions thrown outside of an action
(like in Dispatcher setups or broken Ruby code) in public/500.html".
Although am not using Apache as a web server but it is installed on my
system. I am using WebRick Server. All other applications are running,
but when i am trying to run a particular application this error is
coming.
My application is giving error "Application error (Apache)
Although am not using Apache as a web server but it is installed on my
system. I am using WebRick Server. All other applications are running,
try shutting down the apache server. if it is giving u an Apache error
just shut the thing down. you don’t need an apache server in the
background to see u’r app. maybe it is overriding some of the defaults
webrick thinks it has and … crash .
ruby script/server. Server is starting properly, it is not giving any
error.
When i am typing "http://localhost:3000/login " on browser then its
giving error.
Can you check if the server is intialized properly by opening the
url : “http://localhost:3000” i.e. without your controller, if it
works fine, most probably you need there’s some problem with your
controller class.
You’d usually only get that if you are somehow running in production
mode or if something is seriously wrong with your development
environment and it can’t start up properly.
Few things you could try:
Ensure you are running in development mode:
ruby script/server -edevelopment
Just to make sure you are running in development mode.
Can you return a model from the console? (i.e.
ExistingModel.find(:all)
ruby script/console
This will confirm that you can connect to the database okay.
Check your log files for any errors & make sure they are writable
At a last resort I’d try to create a dummy controller or strip some
code from an existing one so all your doing is returning a static page
and gradually add it back in until it falls over.
I am not sure, what’s wrong with your webrick server, but I would
suggest you to try switching to mongrel and see if it works fine. I am
assuming your ruby installation is fine and without any issues.
you can run ‘gem install mongrel’ and then select the appropriate
version to install the same…