Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Tomcat displays blank pages (help please)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
halzen
n00b
n00b


Joined: 21 Jun 2006
Posts: 49

PostPosted: Fri Oct 31, 2008 4:30 am    Post subject: Tomcat displays blank pages (help please) Reply with quote

hi guys,

I recently emerged tomcat, and it displays only blank pages :/

I have been fiddling around now for hours and have no idea why this may be. Im using this:

monoserv ~ # java-config-2 -L
The following VMs are available for generation-2:
1) Sun JDK 1.5.0.16 [sun-jdk-1.5]
*) Sun JDK 1.6.0.07 [sun-jdk-1.6]
monoserv ~ #

Tomcat loads up with no errors in catalina.out, and when a page is requested, no errors are printed, but it only ever displays a blank page.

This is a pretty urgent problem, and no-where can i find any conclusive reasoning.

Cheers,
h.
Back to top
View user's profile Send private message
fschaller
n00b
n00b


Joined: 09 Apr 2004
Posts: 74

PostPosted: Thu Jul 30, 2009 7:31 pm    Post subject: Reply with quote

Same problem here, is there a solution?

I just emerged tomcat in a hardened environment. Start-up was good, no problem, logs show no errors... has anyone an idea?
Back to top
View user's profile Send private message
Azangod
Tux's lil' helper
Tux's lil' helper


Joined: 18 May 2005
Posts: 107
Location: Italy

PostPosted: Fri Jul 31, 2009 10:43 am    Post subject: Reply with quote

Well, I'm no guru, I've a working environment with tomcat and it wasn't easy.
I remember I've spilled blood, at least for the whole pack: tomcat vhost+apache+mod_jk.
I had to read a lot of manuals and remember little. Tomcat configuration is so flexible that is complexity is sincerelly too high. You can follow dozen of how-tos completely different and still have serious troubles.
That's my unlucky story.. but in the end it works :)

Tomcat stand-alone (on port 8080 ) works?
Displays simple html pages? Write a full url 8080/index.html 'cause tomcat looks for index.jsp by default and, if I'm remembering well it doesn't autoload an index.html.

Have you already saw gentoo tomcat guide? http://www.gentoo.org/proj/en/java/tomcat-guide.xml
Back to top
View user's profile Send private message
chilili
n00b
n00b


Joined: 22 Jul 2009
Posts: 12

PostPosted: Fri Aug 21, 2009 10:18 am    Post subject: Reply with quote

me too, blank page!

The ebuild of Tomcat 6 is too suck to use, just install Tomcat 5 for instead.
Back to top
View user's profile Send private message
creepytennis
n00b
n00b


Joined: 03 Apr 2007
Posts: 37

PostPosted: Mon Aug 24, 2009 1:06 pm    Post subject: Reply with quote

Hi chaps,

I just stumbled across this, and found a solution.

The ROOT webapp is present (you can see the files in /var/lib/tomcat-6/webapps), but not running. If you create a folder in /var/lib/tomcat-6/webapps and put an html file in it, the server will serve that. e.g. http://localhost:8080/foo/bar.html

The documentation is misleading. There is a bug about this:

https://bugs.gentoo.org/277688

I personally think that a note should be added to the Gentoo Tomcat Guide and the ebuild as soon as possible. This has the potential to seriously waste a lot of people's time.
Back to top
View user's profile Send private message
chilili
n00b
n00b


Joined: 22 Jul 2009
Posts: 12

PostPosted: Wed Aug 26, 2009 3:26 am    Post subject: Reply with quote

I do not think Tomcat 6 really works.

I emerge tomcat-6 with examples, and /var/lib/tomcat-6/webapps/examples was installed.

When I access http://192.168.1.100:8080/examples/index.html got the following error from firefox.

Quote:
type Status report

message

description The requested resource () is not available.
Apache Tomcat/6.0.20


my tomcat version is (~) 6.0.20-r1, I have ever intalled 6.0.20 , same result.

BTW, tomcat-5 works well, and works well with mod_jk.
Back to top
View user's profile Send private message
creepytennis
n00b
n00b


Joined: 03 Apr 2007
Posts: 37

PostPosted: Wed Aug 26, 2009 10:31 am    Post subject: Reply with quote

It's possible that the examples webapp is not running, even though it is installed and you can see the files. This is what caught me out with the ROOT webapp. Something should definitely be added to the documentation to clarify the situation.

If you create a new folder in /var/lib/tomcat-6/webapps and put an html file in it, does the server serve that? e.g. http://localhost:8080/foo/bar.html

The tomcat-6 ebuilds clearly need better documentation, but they do work. I'm now running it without a problem.
Back to top
View user's profile Send private message
chilili
n00b
n00b


Joined: 22 Jul 2009
Posts: 12

PostPosted: Fri Aug 28, 2009 5:31 pm    Post subject: Reply with quote

creepytennis wrote:
It's possible that the examples webapp is not running, even though it is installed and you can see the files. This is what caught me out with the ROOT webapp. Something should definitely be added to the documentation to clarify the situation.

If you create a new folder in /var/lib/tomcat-6/webapps and put an html file in it, does the server serve that? e.g. http://localhost:8080/foo/bar.html

The tomcat-6 ebuilds clearly need better documentation, but they do work. I'm now running it without a problem.


Yes, you are RIGHT! thanks. I have two question still.
(1) how can I set the about foo as the ROOT, then I can access by http://localhost:8080/bar.html but not http://localhost:8080/foo/bar.html?
(2) how can I have multple instance Tomcat running in Gentoo? , multiple instance here I mean multi $CATALINA_BASE, so I can retstart any of the instance with effected others.

Thanks in advance.
Back to top
View user's profile Send private message
chilili
n00b
n00b


Joined: 22 Jul 2009
Posts: 12

PostPosted: Sat Aug 29, 2009 8:11 am    Post subject: Reply with quote

chilili wrote:
creepytennis wrote:
It's possible that the examples webapp is not running, even though it is installed and you can see the files. This is what caught me out with the ROOT webapp. Something should definitely be added to the documentation to clarify the situation.

If you create a new folder in /var/lib/tomcat-6/webapps and put an html file in it, does the server serve that? e.g. http://localhost:8080/foo/bar.html

The tomcat-6 ebuilds clearly need better documentation, but they do work. I'm now running it without a problem.


Yes, you are RIGHT! thanks. I have two question still.
(1) how can I set the about foo as the ROOT, then I can access by http://localhost:8080/bar.html but not http://localhost:8080/foo/bar.html?
(2) how can I have multple instance Tomcat running in Gentoo? , multiple instance here I mean multi $CATALINA_BASE, so I can retstart any of the instance with effected others.

Thanks in advance.


I solved both above questions.

(1) ROOT set, in etc/tomcat-6/server.xml
<host>
....
<Context path="" docBase="my_dir _under_webapps"
debug="5" reloadable="true" crossContext="true"/>
....
</host>

(2) Three independent instance
According the output of "equery f tomcat" , DIY.

Advice, I do advice that in the ebuild of tomcat, add special flag to do this.
Back to top
View user's profile Send private message
direwolf
Tux's lil' helper
Tux's lil' helper


Joined: 11 Jun 2003
Posts: 125
Location: Richmond, VA

PostPosted: Sat Aug 29, 2009 8:49 am    Post subject: Reply with quote

This is a really bad build of tomcat. I get they want to move directories like configurations around, etc. But it's resulted in all the urls being broken. The manager is in /manager/html ?? why? That can't be standard. No ROOT? Or not "started" Root? What's with that? /docs doesn't work either, and examples doesn't even show up. But of course they're in different places:

Code:

/var/lib/tomcat-6/webapps

/usr/share/tomcat-6/webapps


Some stuff in one place, some in another, and none of the links work. I can't make examples work at all, I just get a 404 no matter where I put it or what I guess as a url (if it's documented somewhere how I'm supposed to figure out how the url mangling works, I can't find it).

Also, you can't deploy tomcat-dbcp.jar in your war app, it has to be in the tomcat library (/usr/share/tomcat-6/lib).
_________________
========================================================
"Somebody has to do something, and it's just incredibly pathetic that it has to be us."
- Jerry Garcia
Back to top
View user's profile Send private message
chilili
n00b
n00b


Joined: 22 Jul 2009
Posts: 12

PostPosted: Sat Aug 29, 2009 11:41 am    Post subject: Reply with quote

direwolf wrote:
This is a really bad build of tomcat. I get they want to move directories like configurations around, etc. But it's resulted in all the urls being broken. The manager is in /manager/html ?? why? That can't be standard. No ROOT? Or not "started" Root? What's with that? /docs doesn't work either, and examples doesn't even show up. But of course they're in different places:

Code:

/var/lib/tomcat-6/webapps

/usr/share/tomcat-6/webapps


Some stuff in one place, some in another, and none of the links work. I can't make examples work at all, I just get a 404 no matter where I put it or what I guess as a url (if it's documented somewhere how I'm supposed to figure out how the url mangling works, I can't find it).

Also, you can't deploy tomcat-dbcp.jar in your war app, it has to be in the tomcat library (/usr/share/tomcat-6/lib).


You can search tomcat from bugs.gentoo.com, someone said examples was not compile infact. 8)
Back to top
View user's profile Send private message
Bombe
n00b
n00b


Joined: 07 Jul 2004
Posts: 21
Location: Hamburg, Germany

PostPosted: Fri Jul 23, 2010 3:46 pm    Post subject: Reply with quote

chilili wrote:
(1) ROOT set, in etc/tomcat-6/server.xml

As this still is an issue with tomcat-6.0.28, thank you very much for the solution. :)
Back to top
View user's profile Send private message
dylanthomasfan
n00b
n00b


Joined: 02 Mar 2005
Posts: 27

PostPosted: Thu Aug 12, 2010 1:35 am    Post subject: Tomcat 6.0.026: still not working Reply with quote

What kind of a build is this? This totally sucks! I have spent days on this, and I am hardly a Gentoo newbie!
Back to top
View user's profile Send private message
dylanthomasfan
n00b
n00b


Joined: 02 Mar 2005
Posts: 27

PostPosted: Thu Aug 12, 2010 11:16 pm    Post subject: Solved! Reply with quote

After an unnecessary amount of pain, I discovered that /usr/share/tomcat-6/webapps/ did not have a ROOT folder. I added the folder, and moved the /usr/share/tomcat-6/index.jsp/html and a few other files (mostly png and gif) from the same location into the /usr/share/tomcat-6/webapps/ROOT/ folder. And lo and behold, the test page is no longer blank. But--wait--I have other problems with the test page. Most of the localhost links don't work!

The index.jsp file--it points to incorrect places for the left hand navigation on localhost. For example, the link for "Release notes" and "changelog." But more importantly, the examples and docs and host-manager don't work. Now, I am trying to figure out if something else is broken in this build before I use this build for doing something actually useful.

Annoying.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum