This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Servlets and the fly likes 500 internal server error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "500 internal server error " Watch "500 internal server error " New topic
Author

500 internal server error

madhur jain
Ranch Hand

Joined: Aug 27, 2002
Posts: 49
hi!
i have installed 4.0.5
but on typing http://localhost:8080
i am getting 500 Internal Server error in the browser.
what shoul i do
also where should i place my servlets to access them as
http://localhost:8080/servlet/myservlet
the book says in the server_root/webapps/ROOT/WEB-INF/classes
directory but there is no such classes dir. in WEB-INF
should i create it.
thanx
madhur.
Rick Hightower
Author
Ranch Hand

Joined: Feb 20, 2002
Posts: 350

hi!
i have installed 4.0.5

Tomcat?

but on typing http://localhost:8080
i am getting 500 Internal Server error in the browser.
what shoul i do

Hmmm....
Run Tomcat in verbose mode and see if you can see an exception stack trace.

also where should i place my servlets to access them as
http://localhost:8080/servlet/myservlet
the book says in the server_root/webapps/ROOT/WEB-INF/classes
directory but there is no such classes dir. in WEB-INF
should i create it.

Yes create it. Compile your servlets and put them there. You will also need to create a web application deployment descriptor, and then create a servlet mapping to map your servlet to the URL you listed.
What book are you using?


Rick Hightower is CTO of Mammatus which focuses on Cloud Computing, EC2, etc. Rick is invovled in Java CDI and Java EE as well. linkedin,twitter,blog
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: 500 internal server error