undeploy /admin

2007-08-21 Thread Marco Schwarz
Hi, I'm new in the list and I begin using apache-tomcat-5.5.23 with juddi. My question: When I change a parameter JNDI (jdbc/juddiDB) in the juddy project with the Administration Tool I see the following log and my session is invalidate. 21.08.2007 08:19:22 org.apache.catalina.startup.HostConfig

Re: SSL port number

2007-08-21 Thread Markus Schönhaber
Stephen Caine wrote: Stephen Caine wrote: A simple way to restart Tomcat from a non-root user would be nice. Interesting wish. A non-root user with the right to control my system services is approximately the last thing I would want to see. Well, if you can set a 'user' option for

Re: Very Slow Startup with APR

2007-08-21 Thread Markus Schönhaber
Adrian Sutton schrieb: I've been setting up Tomcat 5.5, with Java 5 on a Debian Etch server with a lot of success and just one problem - Tomcat seems to take a long time to load. I think the problem started when I installed APR/ tomcat native and enabled SSL through it but it's hard to

Re: Possible Tomcat + Javascript + Internet Explorer Problem

2007-08-21 Thread redminator
Thanks for the help. I figured the problem. It was a javascript problem after all. Thanks a lot again. -- View this message in context: http://www.nabble.com/Possible-Tomcat-%2B-Javascript-%2B-Internet-Explorer-Problem-tf4297179.html#a12250815 Sent from the Tomcat - User mailing list archive at

Tomcat manager

2007-08-21 Thread Andrew Hole
Hello! I've lot of tomcat instances running around the world and I want an easy way to manager each one, using some simple manager tool. DO you suggest something? Some plugin to eclipse? Thanks a lot

Memory problems

2007-08-21 Thread Morten
Hi We have implemented a picture server in Tomcat. The pictures are cached in a map. When the memory is nearly full, some entries are removed from map. However, eventually the entries in the map become fewer and fewer even though the memory consumption stays high. In other words more and more

Re: Tomcat manager

2007-08-21 Thread ben short
In what way do you want to manage them? Are you aware of the manager webapp [1] ? [1] http://tomcat.apache.org/tomcat-6.0-doc/manager-howto.html On 8/21/07, Andrew Hole [EMAIL PROTECTED] wrote: Hello! I've lot of tomcat instances running around the world and I want an easy way to manager

Re: Very Slow Startup with APR

2007-08-21 Thread Adrian Sutton
On 21/08/2007, at 5:39 PM, Markus Schönhaber wrote: WAG: your APR uses /dev/random as random source which blocks when it runs out of entropy. You could re-build APR after you ./configure'd it with --with-devrandom=/dev/urandom or you could try Mladen's advice here

RE: Memory problems

2007-08-21 Thread Peter Crowther
From: Morten According to a heap dump done by jmap, there are many org.apache.tomcat.util.buf.ByteChunk instances referencing large byte[], which we suspect to be previously used pictures. We have tried both Tomcat 5.5.9 and Tomcat 6 under JBoss 4.2.0. Both showed the same

Re: Very Slow Startup with APR

2007-08-21 Thread Markus Schönhaber
Adrian Sutton wrote: In the end, ~root/.rnd and ~tomcat55/.rnd were both ignored but setting the RANDFILE environment variable worked. Not sure what it was defaulting to. Anyway, everything now starts up lightning fast. Thanks for the help. I had just re-read Mladen's mail and

Re: Very Slow Startup with APR

2007-08-21 Thread Markus Schönhaber
Markus Schönhaber wrote: Does Tomcat start still fast if you do something like dd if=/dev/random of=/dev/null bs=1 let that run for a couple of seconds and start Tomcat immediately after interrupting it? I think that's phrased a bit confusingly. What I tried to say is the following: If you -

Re: Very Slow Startup with APR

2007-08-21 Thread Adrian Sutton
I had just re-read Mladen's mail and experimented with RANDFILE myself, thinking that setting it to /dev/urandom might be the easiest solution. I strace'd Tomcat but couldn't find any hint that the value of RANDFILE is honored. Since my APR is built to use /dev/urandom I can't be sure, but

20 Tips for Using Tomcat in Production

2007-08-21 Thread Shane Witbeck
I thought my latest blog post would be of interest to the people on this list: http://www.digitalsanctum.com/2007/08/18/20-tips-for-using-tomcat-in-production/ - To start a new topic, e-mail: users@tomcat.apache.org To

Re: Memory problems

2007-08-21 Thread Morten
Are there any way to stop Tomcat from cached these large byte[] internally? The ByteChunks are referenced from IntermediateOutputstream, C2BConverter and OutputBuffer. Hmm. Those are all Tomcat util classes, so they're almost certainly held by something else. Can you find out what's holding

RES: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Milanez, Marcus
Thank you very much! -Mensagem original- De: Shane Witbeck [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 21 de agosto de 2007 09:10 Para: users@tomcat.apache.org Assunto: 20 Tips for Using Tomcat in Production I thought my latest blog post would be of interest to the people on

Re: Does anyone have an approach to checking if Tomcat instance is UP?

2007-08-21 Thread Paul Singleton
Kim Do you have reason to believe that the OutOfMemory exception is due to: * some cumulative effect (e.g. memory leak), in which case you need to restart, preferably (just) before it happens * the qty of active sessions, so you need to load-balance when near some threshold (offload to

Help for basic SSL certificate authentication

2007-08-21 Thread Igor Andjelkovic
Hi, I'am writing my very first Java aplication which is dealing with SSL. I want to write Server side aplication which will ask for certificate, and Client aplication which only need to show content of certificate on user screen, for example, in console. Every help is welcome. Thanks, Igor

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread David Delbecq
Very nice. May i suggest 2 comments perhaps?: 6... If you're loading several applications with several of the same library dependencies, consider moving them from the applications' |WEB-INF/lib| directory to Tomcat's shared library |{catalina.home}/shared/lib|. This will reduce the memory used by

Re: Very Slow Startup with APR

2007-08-21 Thread Markus Schönhaber
Adrian Sutton wrote: RANDFILE is definitely honored and it does work well setting it as / dev/urandom. I've restarted Tomcat a number of times and it stayed fast, plus: cat /proc/sys/kernel/random/entropy_avail consistently returns low values. Generating activity. In fact, with

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Lyallex
Good stuff I'm doing 70% of what you suggest and Tomcat 5.5.20 hums along nicely on Debian Linux with Java 1.5.0_04 I bet this one runs and runs ... Rgds Duncan On 8/21/07, Shane Witbeck [EMAIL PROTECTED] wrote: I thought my latest blog post would be of interest to the people on this list:

Re: Does anyone have an approach to checking if Tomcat instance is UP?

2007-08-21 Thread Paul Singleton
Jeff Hoffmann wrote: Christopher Schultz wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Dan, Dan Armbrust wrote: A simple cron job that points to a URL using lynx, and greps the output for what it should see will do the trick... I would use wget instead of Lynx, but that's just me.

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread David Smith
Well... be careful on the use of the shared/common classloader. It works as long as all the apps can use the same version of a library. If there are changes to the API and you have the library in the shared or common classloaders you'll have to upgrade all the webapps at once. --David

Re: Does anyone have an approach to checking if Tomcat instance is UP?

2007-08-21 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Kim, Kim Albee wrote: The JSP does a call to a method in our app -- which if it runs, that means the app is up and available -- the method does a simple query against the DB and then returns a status of OK if the method runs through just fine.

Re: How to detect user logins

2007-08-21 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 David, David Delbecq wrote: Current strategy works (it's separated in 2 steps inside a common-chain of operation), but it makes wuite a few lines to try to detect user login, and if tomcat was already providing such event that could be handled by

RE: context.xml not being copied across on deployment

2007-08-21 Thread Emsley, I (Iain)
Hi Chuck, I've tried removing it but the redeploy is still copying over the WAR version. I've rechecked the paths for the tomcat.context.xml which is pointing apparently to the correct place. Is there any thing else that I can check? Iain -Original Message- From: Caldarale, Charles

Re: Very Slow Startup with APR

2007-08-21 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Markus, Markus Schönhaber wrote: I'll have to find out why for me the value RANDFILE is set to doesn't seem to have any effect - or, for that matter, whether it really doesn't have any effect. Perhaps by configuring with --randfile=/dev/urandom

RE: context.xml not being copied across on deployment

2007-08-21 Thread Caldarale, Charles R
From: Emsley, I (Iain) [mailto:[EMAIL PROTECTED] Subject: RE: context.xml not being copied across on deployment I've tried removing it but the redeploy is still copying over the WAR version. That's what it's supposed to do. Why is that a problem? Is the one in META-INF/context.xml

Re: Very Slow Startup with APR

2007-08-21 Thread Rainer Jung
Markus Schönhaber wrote: Adrian Sutton wrote: RANDFILE is definitely honored and it does work well setting it as / dev/urandom. I've restarted Tomcat a number of times and it stayed fast, plus: cat /proc/sys/kernel/random/entropy_avail consistently returns low values. Generating activity.

Re: Very Slow Startup with APR

2007-08-21 Thread Rainer Jung
Followup to self: There's an addition in tcnative 1.1.10: Author: mturk Date: Sun Apr 1 22:22:42 2007 New Revision: 524725 URL: http://svn.apache.org/viewvc?view=revrev=524725 Log: In case we don't specify the global randFile use like mod_ssl does with builtin. This fixes long init on some

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Shane Witbeck
Chris, Yes I agree that the extent at which #6 is implemented probably depends a lot on the size of the app (namely the number of libraries). There's already a link to the Tomcat original documentation for #3 although I noticed I forgot the link for #2. Thanks for the comments, Shane On

java.io.FileNotFoundException on tomcat 6 startup

2007-08-21 Thread Chris Wiley
Hello, I am hoping someone can help me with this. I have been trying to get a standalone instance of tomcat 6 (6.0.13) to startup on a windows XP laptop. I am using java 6 (build 1.6.0_01-b06). I am not sure if this is just a java version incompatibility problem or something else. It

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Shane Witbeck
David, Thanks for your comments. I've added them to the blog post for everyone's benefit. Shane On 8/21/07, David Delbecq [EMAIL PROTECTED] wrote: Very nice. May i suggest 2 comments perhaps?: 6... If you're loading several applications with several of the same library dependencies,

Re: Very Slow Startup with APR

2007-08-21 Thread Markus Schönhaber
Christopher Schultz wrote: Markus Schönhaber wrote: I'll have to find out why for me the value RANDFILE is set to doesn't seem to have any effect - or, for that matter, whether it really doesn't have any effect. Perhaps by configuring with --randfile=/dev/urandom (which it sounds like you

Re: Very Slow Startup with APR

2007-08-21 Thread Markus Schönhaber
Rainer Jung wrote: There's an addition in tcnative 1.1.10: Author: mturk Date: Sun Apr 1 22:22:42 2007 New Revision: 524725 URL: http://svn.apache.org/viewvc?view=revrev=524725 Log: In case we don't specify the global randFile use like mod_ssl does with builtin. This fixes long init

Re: Very Slow Startup with APR

2007-08-21 Thread Rainer Jung
Markus Schönhaber wrote: Rainer Jung wrote: @@ -259,7 +259,7 @@ file = ssl_global_rand_file; if (file == NULL) -file = RAND_file_name(buffer, sizeof(buffer)); +return -1; else if ((n = RAND_egd(file)) 0) { return n; } Didn't check, but

RES: Re: Memory problems

2007-08-21 Thread Milanez, Marcus
Have you considered using Lambda Probe for tracking tomcat memory use details? Give it a try, maybe you'll be able to find alive object references that could be garbage collected. http://www.lambdaprobe.org/ -Mensagem original- De: news [mailto:[EMAIL PROTECTED] Em nome de Morten

Re: Very Slow Startup with APR

2007-08-21 Thread Markus Schönhaber
Rainer Jung schrieb: Let's see: doesn't this *remove* the RAND_file_name() line? Man page of RAND_file_name() says, that it returns a file for andomness and respects variable RANDFILE. I neither know the code well, nor did I check now, if there are other references to RANDFILE. Mladen's

Re: Very Slow Startup with APR

2007-08-21 Thread Rainer Jung
Markus Schönhaber wrote: Just to confirm that I don't get it wrong again: it is to be expected that the value of RANDFILE is ignored in my case since im using tcnative 1.10? That's my expectation too. - To start a new topic,

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Ben Souther
Tip #8: You tell the users about the tomcat-users.xml file for adding the role info but never tell them where to enter the RemoteAddrValve in order to restrict IPs. On Tue, 2007-08-21 at 10:57, Shane Witbeck wrote: David, Thanks for your comments. I've added them to the blog post for

Re: Does anyone have an approach to checking if Tomcat instance is UP?

2007-08-21 Thread Kim Albee
Everyone -- thanks for all the ideas and feedback. We've attempted to take the approach with our health.jsp to check the major functions in our application -- so if we can do a database request, that checks a bunch of things - and returns without error lets us know that our application is

RES: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Milanez, Marcus
We should create a wiki to accomplish all theses tips Why not? -Mensagem original- De: Ben Souther [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 21 de agosto de 2007 14:46 Para: Tomcat Users List Assunto: Re: 20 Tips for Using Tomcat in Production Tip #8: You tell the users

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Shane Witbeck
Good point. I've updated the entry to be more specific. Thanks! On 8/21/07, Ben Souther [EMAIL PROTECTED] wrote: Tip #8: You tell the users about the tomcat-users.xml file for adding the role info but never tell them where to enter the RemoteAddrValve in order to restrict IPs. On Tue,

Re: Running MINA inside Tomcat causing problems.

2007-08-21 Thread Filip Hanik - Dev Lists
then modify HostConfig.java to spit out that info, I looked at the code, it doesn't tell you why its reloading even with debug enabled Filip satish viswanatham wrote: Hi This undeploy does not happen during startup. It happens after receiving few TCP and UDP messages. Now the app gets

JDBCRealm + Expired Passwords

2007-08-21 Thread Stephen More
Has anyone written or know of a JDBCRealm that supports an expired password ? -Thanks Steve More - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail:

Uncanny Error

2007-08-21 Thread Peter Stavrinides
Hi All, Can anyone who is knowledgeable of dynamic class reloading help me to understand some strange behaviour... I run my servlet on Tomcat, it works great for a while, but then some classes seem to disappear, or at least they cant be found any more... I don't know much about Javaassist, but

Graceful webapp reloading

2007-08-21 Thread Jérôme Etévé
Hi everyone ! I'm wondering how to gracefully reload a webapp ? For the moment, I'm forcing the reloading of my application by touching my myapp.xml file in conf/Catalina/localhost/ . It causes myapp to be stop and then start. The problem is while that process, the queries on the server have

RE: Does anyone have an approach to checking if Tomcat instance is UP?

2007-08-21 Thread Nelson, Tracy M.
| From: Kim Albee [mailto:[EMAIL PROTECTED] | Sent: Tuesday, 21 August, 2007 12:49 | | We use a monitoring tool that has the automated checks for the application | JVM and we can set different threshholds there -- but I've got to be able | to | have the check run by the load balancer know that

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Ben Souther
The connector entries are also case sensitive: connector port=8009 ... Should be Connector port=8009 ... On Tue, 2007-08-21 at 13:55, Shane Witbeck wrote: Good point. I've updated the entry to be more specific. Thanks! On 8/21/07, Ben Souther [EMAIL PROTECTED] wrote: Tip #8: You

Re: Does anyone have an approach to checking if Tomcat instance is UP?

2007-08-21 Thread Smith Norton
No - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Shane Witbeck
Thanks! I've corrected the entries. On 8/21/07, Ben Souther [EMAIL PROTECTED] wrote: The connector entries are also case sensitive: connector port=8009 ... Should be Connector port=8009 ... On Tue, 2007-08-21 at 13:55, Shane Witbeck wrote: Good point. I've updated the entry to be

Re: JDBCRealm + Expired Passwords

2007-08-21 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Stephen, Stephen More wrote: Has anyone written or know of a JDBCRealm that supports an expired password ? Can you phrase that in a different way? I wouldn't want my JDBCRealm to allow expired passwords to be used. Do you mean that you want

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Kim Albee
In putting #1 into the JAVA_OPTS (which it appears that is the CATALINA_OPTS for our implementation), it doesn't appear to work, as Tomcat doesn't restart. It could be our version -- which is currently 5.0.30. please let me know if there are other steps we need to take here as well. thanks, Kim

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Shane Witbeck
You can actually use JAVA_OPTS or CATALINA_OPTS to add the options and the options only apply to JDK 1.5 or above. I don't think the version of Tomcat matters here. Shane On 8/21/07, Kim Albee [EMAIL PROTECTED] wrote: In putting #1 into the JAVA_OPTS (which it appears that is the CATALINA_OPTS

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Shane, Shane Witbeck wrote: You can actually use JAVA_OPTS or CATALINA_OPTS to add the options and the options only apply to JDK 1.5 or above. I don't think the version of Tomcat matters here. There is a (minor) difference between the two:

Why are log4j jars treated differently?

2007-08-21 Thread Pulkit Singhal
Hello, I'd like to ask a question regarding the log4j jars and how tomcat treats/handles them. Tomcat version: 5.5.23 Log4j version: 1.2.5 (I don't think that versions matter here) If one deploys as follows: ${tomcat_home}/shared/lib/log4j.jar ${tomcat_home}/shared/classes/log4j.properties

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Ben Souther
From: Christopher Schultz I also agree with David and, uh, David, that #6 is a little dubious. Yes, moving shared libraries into the common/lib directory will save you some memory, but it creates a management headache when it comes to version numbers, WAR

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Diego Yasuhiko Kurisaki
I agree, i'm not willing to pay the management overhead of putting my shared libraries to the tomcat common lib, unless my gains are very big in terms of memory consumption. I don't really think you should change for another one though, but you can make regards about the cons of that approach.

Re: 20 Tips for Using Tomcat in Production

2007-08-21 Thread Tim Funk
#6 - Shared classloaders are evil, but not as evil as the invoker servlet. With a shared loader you can easily get Singleton assumptions being wrong, class cast exceptions, versioning woes, and other issues. Saving a little perm memory just doesn't justify it. #7 - You should have a

tomcat embedded 5.5 localhost alias

2007-08-21 Thread Alex Cheung
Hi I am using tomcat embedded 5.5 to demo a web application on cd. I can't figure out how to change the URL string fromhttp://localhost:8080/. to http://myHost:8080/.. addAlias and setHostName dont seem to work. following are my host creation code: // set Engine properties

Re: JDBCRealm + Expired Passwords

2007-08-21 Thread Stephen More
On 8/21/07, Christopher Schultz [EMAIL PROTECTED] wrote: Stephen More wrote: Has anyone written or know of a JDBCRealm that supports an expired password ? Do you mean that you want expired-password-users to be forced to change their password before doing anything else? Yes, this is

Re: OT tomcat embedded 5.5 localhost alias

2007-08-21 Thread PTS
It has nothing to with Tomcat in this case. http://localhost equals http://127.0.0.1 equals http://AAA.BBB.CCC.DDD (the IP address of the machine) When it comes to accessing the web page from the machine that is hosting the site. The above is not exactly correct when it comes to things

RE: OT tomcat embedded 5.5 localhost alias

2007-08-21 Thread Alex Cheung
That explains things quite clearly thanks for the quick reply :) cheers Alex From: [EMAIL PROTECTED] To: users@tomcat.apache.org Subject: Re: OT tomcat embedded 5.5 localhost alias Date: Tue, 21 Aug 2007 21:38:13 -0400 It has nothing to with Tomcat in this case. http://localhost

Re: Tomcat on FreeBSD

2007-08-21 Thread Arend P. van der Veen
Ronald Klop wrote: What java version are you running? Ronald. On Fri Aug 17 16:00:41 CEST 2007 Tomcat Users List users@tomcat.apache.org wrote: Hi, I have installed Tomcat 5.5.23_1 on FreeBSD 6.2. I have used Servlets a lot in the past but have not used ant. I am now trying to get this