aspose file tools*
The moose likes Tomcat and the fly likes Problems with apache and tomcat behind a router Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Problems with apache and tomcat behind a router" Watch "Problems with apache and tomcat behind a router" New topic
Author

Problems with apache and tomcat behind a router

Jerry Olsson
Greenhorn

Joined: Mar 24, 2004
Posts: 15
Hello, I made a search for my problem but couldn't find anything so I decided to post.
I'm running Apache and Tomcat on a win2k machine which are placed behind a DI-604 router.
I've connected the apache and the tomcat using a JK. The problem is that I'm not sure what my host should be? I have a dyndns that points at my ip from my isp. when I access plain html (that is placed in tomcats directories) it works fine but as soon as I access a .jsp it doesn't work and I get the following errormessage:
"No Host matches server name puma.kicks-ass.org
Your browser sent a request that this server could not understand.
Additionally, a 400 Bad Request error was encountered while trying to use an ErrorDocument to handle the request."
I have set the internal ip to the server as the host in server.xml and it works if I access the jsp with the local ip (http://192.168.0.158/examples/jsp/dates/date.jsp). if I access with (http://puma.kicks-ass.org/examples/jsp/dates/date.jsp)
Summary:
I can access plain html on the tomcat with my dyndns but not .jsp.
I can access both plain html and .jsp using the internal ip.
I hope someone can help me here. I'm going crazy over here

adding the essential parts of server.xml
Mike Curwen
Ranch Hand

Joined: Feb 20, 2001
Posts: 3695

did you try :
<host name="puma.kicks-ass.org" ...
Jerry Olsson
Greenhorn

Joined: Mar 24, 2004
Posts: 15
I used puma.kicks-ass.org first but then it didn't work. tried several other things that didn't work. Using the internal ip instead worked but not on everything. I realized today that I didn't replace puma.kicks-ass.org everywhere in server.xml and when I did that it worked fine
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problems with apache and tomcat behind a router
 
Similar Threads
beginner question:error 404 servlet not available in Tomcat
JSP files Deployment problem in sun java system web server
JSP files Deployment problem in sun java system web server
ServletContext's getContext method
How do you set up Tomcat as a web server?