Automatic Log File Rotation
Our company has standardized on newsyslog for squid and apache log file rotation and management for our production servers. I am in charge of implementing newsyslog for Tomcat log files and have a few questions: How can I keep Tomcat from adding the date to the end of the log filename? How can I keep Tomcat from rotating the logs and instead use /usr/local/sbin/newsyslog? Will this adversely affect Tomcat? With squid, I had to put the directive logfile_rotate to 0 and have newsyslog run 'squid -k rotate' to get this to work. Here is the homepage for newsyslog if anyone wants to know: http://www.weird.com/~woods/projects/newsyslog.html Thanks, Jeff Schroeder Web Administrator Comair, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Apache and Tomcat on separate hosts?
I finally got Apache2 + mod_jk2 + tomcat 4.1 working with tomcat doing vhosting on my laptop for development. The management said that is great that I should now roll it over to the dev servers before putting it into production. I started setting up everything and was down to creating the vhost in httpd.conf when I realized one fatal problem, Apache and Tomcat are on 2 separate servers. The way that I understand it, Apache finds a jsp page in it's docroot and if the host is in workers2.properties, it gets handed over to tomcat. If the webapp is not on the same box, how do you let apache find it to hand over to tomcat? My first thought was NFS, but the change control board frowns on any sort of filesharing among the servers. It's kind of important to get this properly working, is there any other way? Thanks. Jeff Schroeder Web Administrator Comair, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Re: Apache and Tomcat on separate hosts?
As I know, mod_jk2 project is no longer maintained so it's better to switch to mod_jk. With our java apps, mod_jk has an issue that causes apache to crash every 3-4 days. mod_jk2 does not, so it's doubtful we will be changing. Jeff Schroeder Web Administrator Comair, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat and the HttpServletRequest Object
Would anyone in the Project Management Committee, Advisory board, or the committer group acknowledge that this bug is understood and will be considered in the next releases of Tomcat? Thank you, Jeff Grangier Founder Chief Architect YourWebPro Inc. (847) 454-8000 -Original Message- From: Wendy Smoak [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 7:48 PM To: Tomcat Users List Subject: Re: Tomcat and the HttpServletRequest Object From: Hassan Schroeder [EMAIL PROTECTED] :snips from: http://www.w3.org/TR/html401/interact/forms.html#h-17.13 So it seems the HTML specification *does* require the parts be sent in particular (source) order. Thanks! I was using the wrong search terms-- 'parameter' instead of 'control name' and so I never found that. At which point I assumed the specification was silent on the matter and I could do whatever I pleased. :) So I stand corrected on the browser behavior part. But it has nothing to say about what *processing agents* do with 'em. And if the servlet spec *doesn't* demand that the parts be stored and made available in that same order... Assuming enough people can be convinced that this is broken, there's where the fix needs to be applied. Until the Servlet specification says that the order of request parameters must be preserved, Tomcat is free to do whatever it wants with them. Greg Murray (the Servlet specification lead) has asked for input on what we'd all like to see in the next version, so here's a chance to comment: http://weblogs.java.net/blog/gmurray71/archive/2005/07/got_servlets.html You can also get involved with the JCP: http://www.jcp.org/en/home/index -- Wendy Smoak - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat and the HttpServletRequest Object
Hello, I have migrated my application from iPlanet to Tomcat 5.5 (latest build as of today) and getting weird results with the HttpServletRequest object: Each Element out the getParameterNames enumeration used to be ordered based on the html form layout posting the data (using iPLanet). But, after the migration the fields are coming in random order when I try to loop through the fields dynamically. . . Here is a snapshot of the code: Enumeration paramNames = req.getParameterNames(); while(paramNames.hasMoreElements()) { paramName = (String)paramNames.nextElement(); . . . Has anyone encountered this issue before? Is there a work around? Thank you in advance for your help, Jeff
RE: Tomcat and the HttpServletRequest Object
Hello George, I will consider it an ehancement if it is not in the specification. Adding a logical order to the list makes it much easier to manage dynamically. Otherwize, any programmer will have to create their own proprietary indexing and ordering logic for it. Let me know if I can help in this upgrade? Thanks, Jeff -Original Message- From: George Sexton [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 12:40 PM To: 'Tomcat Users List' Subject: RE: Tomcat and the HttpServletRequest Object I see nothing in the specification that specifies the order of the elements returned in the enumeration. Why do you think this is a bug? George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 -Original Message- From: Jeff Grangier [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 11:22 AM To: tomcat-user@jakarta.apache.org Subject: Tomcat and the HttpServletRequest Object Hello, I have migrated my application from iPlanet to Tomcat 5.5 (latest build as of today) and getting weird results with the HttpServletRequest object: Each Element out the getParameterNames enumeration used to be ordered based on the html form layout posting the data (using iPLanet). But, after the migration the fields are coming in random order when I try to loop through the fields dynamically. . . Here is a snapshot of the code: Enumeration paramNames = req.getParameterNames(); while(paramNames.hasMoreElements()) { paramName = (String)paramNames.nextElement(); . . . Has anyone encountered this issue before? Is there a work around? Thank you in advance for your help, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat and the HttpServletRequest Object
Hey Dude, I was certainly not trying to be arbitrary . . . If Iplanet is more robust in this area don't take it personally. As far as your sour memory in DB development, please leave me out of it. This was a simple question that makes a lot of sense when you are building any web applications. If there is a problem with the specification, then it should be changed to accommodate the user. Tomcat or any other software of that sort are loaded with functions/features that sacrifice performance with functionality, this is what you call an option. Jeff Grangier -Original Message- From: George Sexton [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 1:46 PM To: 'Tomcat Users List' Subject: RE: Tomcat and the HttpServletRequest Object Even if I were to write this as an enhancement, I can tell you from past experience it would be rejected out of hand by the committers. In your particular case, the tool you were using before used something like a Vector or ArrayList to hold the parameter name/value pairs. Tomcat is almost certainly using a HashMap of some sort. Any deterministic implementation is going to be slower than the current random access implementation. Committers will savage any submission that appears slower and the person submitting it. No thanks, I'm not going there. Even if Tomcat were to work in the manner desired, there's nothing that says that every browser is going to submit the form elements in their order of definition. You really need to abandon this idea and make your application more robust. You remind me of people who do SQL database development. They don't specify an ORDER BY clause on their statements, but it always came back in the order they wanted. Then one day, they upgraded versions of the database or the query optimizer decided to take a different path, and all of a sudden the results are coming out of order. Much wailing and attempted reporting of bugs ensues... The truth is in SQL, that if you don't specify an ORDER BY clause, the database can return the results in any order it likes. Taking advantage of an implementation specific behavior is natural, but it can lead (as you have found out) to non-portable code. The final arbiter is the specification, and if the specification doesn't describe the behavior, you can't say anything about it. George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 -Original Message- From: Jeff Grangier [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 12:19 PM To: 'Tomcat Users List' Subject: RE: Tomcat and the HttpServletRequest Object Hello George, I will consider it an ehancement if it is not in the specification. Adding a logical order to the list makes it much easier to manage dynamically. Otherwize, any programmer will have to create their own proprietary indexing and ordering logic for it. Let me know if I can help in this upgrade? Thanks, Jeff -Original Message- From: George Sexton [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 12:40 PM To: 'Tomcat Users List' Subject: RE: Tomcat and the HttpServletRequest Object I see nothing in the specification that specifies the order of the elements returned in the enumeration. Why do you think this is a bug? George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 -Original Message- From: Jeff Grangier [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 11:22 AM To: tomcat-user@jakarta.apache.org Subject: Tomcat and the HttpServletRequest Object Hello, I have migrated my application from iPlanet to Tomcat 5.5 (latest build as of today) and getting weird results with the HttpServletRequest object: Each Element out the getParameterNames enumeration used to be ordered based on the html form layout posting the data (using iPLanet). But, after the migration the fields are coming in random order when I try to loop through the fields dynamically. . . Here is a snapshot of the code: Enumeration paramNames = req.getParameterNames(); while(paramNames.hasMoreElements()) { paramName = (String)paramNames.nextElement(); . . . Has anyone encountered this issue before? Is there a work around? Thank you in advance for your help, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED
RE: Tomcat and the HttpServletRequest Object
Hello Wendy, Is there anything we can do? I have worked with the MS DNA, .NET, SunOne, IBM Websphere frameworks and they all behave the same way by ordering the request parameters (first in first out). I know for sure that I am not the first one and neither the last one to have trouble with this kind of behavior using Tomcat. Even if the specification does not contain any direction on how to properly handle the request, Tomcat expected/ordered behavior would save hours of work to developers worldwide. I sure hope this issue is not an Open Source wake up call! Thanks for all your help, Jeff -Original Message- From: Wendy Smoak [mailto:[EMAIL PROTECTED] Sent: Friday, August 12, 2005 4:07 PM To: Tomcat Users List Subject: Re: Tomcat and the HttpServletRequest Object From: Bhupinder Dhillon [EMAIL PROTECTED] I have the same bloody problem. The application is a generic form handler that e-mails the form values. Most (all) of the clients expect the values to be in the same order as the form itself. You are depending on arbitrary browser behavior. As far as I can tell, there's nothing preventing me from writing a browser that, say, alphabetizes the request parameters before sending them to the server. Yes, most browsers send them in the order they appear in the HTML source, but unless/until some statement about request parameter order makes it into the relevant specification, you depend on that behavior at your own risk. This isn't something that can be handled by the container-- even if Tomcat stops rearranging the request params, you have no control over the browser implementation. -- Wendy Smoak - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Which Oracle JDBC Drive for JDK 1.5?
Like Paul said, it shouldn't be problem unless you're using specific Oracle 10 features or if you have synonyms or views linked to older Oracle databases. I've had a few synonyms that were linked to Oracle 7 and 8 tables that required using an older driver. If you run into problems, Oracle may only support you on 'certified' databases. I'd try it. If it works great, if doesn't then I patch to 10.1.0.4. I've also only used the thin client JDBC drivers, so I can't say much about the other drivers. HTH, Jeff Paul Singleton wrote: I noticed there are JDBC drivers for 10.1.0.2 and . Which should I use? I've always found that Oracle JDBC drivers are backwards compatible (not that I've driven them very hard) so I'd use the .4 (or should I patch to 10.1.0.4) not if it ain't broke :-) Paul S. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Additional reasons for broken pipe or connection resets?
Hi. I have a web application that has been working fine for several months, but now it is having some problems. We recently upgraded the OS on the server and version of Java. I'm now getting a large number of connection resets and broken pipe exceptions. For example, today from 10am to 12:30 we had nearly a 100 errors. I've had the network support folks test server network connection. They haven't found any dropped connection problems. I've search the web, this maillist and several newsgroups. In every case, the answer has been that this is caused by the user closing the browser, or selecting reset or just losing the connection. Before our upgrade, we might have gotten 10 error message on a busy day. Now that I am getting so many more errors, I'm concerned that something else could be happening. Is there another reason that might cause a broken pipe or connection reset exception? Thanks, Jeff Duska - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Making ${expr} work like c:out value=${expr}/
The JSP/JSTL spec has a very sensible default regarding the escaping of XML characters in c:out. That is to say, they are escaped unless you explicitly disable escaping. In the days of JSTL 1.0, this had the effect of preventing most web designers from inadvertently introducing XSS vulnerabilities into their apps. When JSP 2.0 came out with the free placement of naked ${expr} in JSP bodies, I naturally assumed that this expression would do the sensible, expected thing and escape XML characters. I'm horrified to discover that this is not the case. Is there any configuration parameter that tells Tomcat to do the *smart* thing rather than follow the spec? I'd really rather not have to type c:out everywhere, including inside HTML attributes. Not to mention search-and-replacing through all my existing JSP pages. How did this behavior get into the spec?? Jeff Schnitzer Voodoodyne Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Simple DBCP Conf Question
I have some questions about the connection pool parameters. I wonder if someone could give me a quick sketch of the relationship between minEvictableIdleTimeMillis and removeAbandonedTimeout ? I'd like to setup my application so that all connections in a pool are closed during times of no activity at all. Is that the implication of setting maxIdle to zero? And how do the timeout parameters allow me to define completely idle periods, like off hours when everyone has gone home and the applications are not being used? Thanks! -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How do I force session cookies to be set to the root path?
I'm using Tomcat 5.5.7 and I'm trying to get the session cookies to be set to something other than the webapp path, preferably the server root. In the change log for 5.5.4 it says Add the ability to force session cookies to be set to the root path /, but I can't find anything that actually says how to do it. Is this still possible, and if so, how do I do it? -- Jeff Hoffmann [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Troubleshooting Virtual Hosts with Tomcat 5 standalone mode...
I'm trying to setup a couple of virtual hosts using Tomcat in stand alone mode. I'm having a hell of a time to get this working correctly. I've tried several configs, but they all fail. I started with the goal of having a user directory for each virtual host. For example, for the sample domain1.com the appbase would be /home/domain/webapps. I setup my server.xml file to have the following host settings Host name=domain1.com debug=0 appBase=/home/domain/webapps unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Context path= docBase=./ /host This is pretty much cut and past from Tomcat: The Definitive Guide from Safari Online. This did not work. I would get just get a blank webpage. I then tried to update the host file. I didn't see why I'd need to do that since my DNS setup at Mydomain.com was working for ssh. I add domain1.com to the line for my localhost. I restarted Tomcat. No change. I am able to run the system on port 80 using just the localhost default settings. I figured I just did something wrong. I switched to this directions http://www.ex-parrot.com/~pete/tomcat-vhost.html This didn't worked either. When I looked at the requests in in Safari, it showed this as a bad request. I can telnet domain1.com 80. When I try GET index.jsp or index,html or /. Nothing happens. No error. It just closed the connection as if everything was working fine. I tried lynx from the server prompt. It gives a http 400 error, I think. It flashes by so fast I'm not sure. The catalina.out has no errors. I have my DNS setup via mydomain.com dns management tool. I have my A record pointing to the address. I don't think I need to do anything else. I'm at a loss of what to do now to troubleshoot this problem. I searched the mail list and the website nothing has jumped out at me. So, I hoping some kind soul might give me some pointers. What kills me is I'm sure this is something obvious I missed or not seeing. Thanks, Jeff Duska [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: non-root on 80
I'm using the jsvc in the commons-daemon with a Tomcat user. Other than not having to deal with the jsvc, is there a reason to pick this over jsvc? Thanks, Jeff Duska John Lianogou wrote: I had to set up a solution using IP tables on my redhat box. First some background as to why I solved it this way: You can't run anything directly on port 80 without that process being executed as the root user... which -- for a variety of reasons I'm sure you needn't hear me go into -- is a Really Bad Idea. ;-) What you want to do in this case is to reroute port 80 traffic to a port that tomcat can bind to when executed as a normal user. Here's what I did to accomplish this (hopefully you've got iptables on your box, as well... tho the path of this script may be different on yr system... so check into both matters if this doesn't work for you): /sbin/iptables -t nat -I PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8080 You'll need root permissions to do this, tho. Hope that helps, jL On Apr 4, 2005, at 5:58 PM, NetSQL wrote: I read that it has a stop method... but how do I get it to run at port 80 ? .V David Smith wrote: Look at jsvc in the commons-daemon project on jakarta.apache.org/commons --David NetSQL wrote: apache drops to non root after bind to 80. How can this be done w/ tc 5.5? .V - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SSL Under Tomcat 5.0
Hi, I'm new to Tomcat, so forgive my (temporary) naivite. I need to get my ecommerce web site (JSP) up and running, but when I add the connector for SSL to the server.xml Tomcat goes into an infinite loop with the following error message when the server attempts an SSL handshake (repeats ad-infinitum): No available certificate corresponds to the SSL cipher suites which are enabled. Here's the connector section from my server.xml: Connector className=org.apache.coyote.tomcat5.CoyoteConnector port=443 minProcessors=5 maxProcessors=75 enableLookups=true disableUploadTimeout=true acceptCount=100 debug=0 scheme=https secure=true clientAuth=false sslProtocol=TLS keystoreFile=conf/NCM.keystore keystorePass=changeit/ My SSL vendor has so far failed to identify the problem, and I am stumped also. Can anyone help? Jeffrey D. Gimprich Director of IT National Collectors Mint, Inc. 8 Slater Street Port Chester, NY 10573 ph: 914-935-9800 ext 236 fax: 914-935-3321 [EMAIL PROTECTED] http://www.nationalcollectorsmint.com
Tomcat 5.5.4 Admin application deploy
I'm trying a new Tomcat installation (5.5.4) under Windows XP SP2. I googled for this, but didn't find an answer. Tomcat comes up fine and the management application comes up fine. I have copied all of the jakarta-tomcat-5.5.4\server\webapp\admin\*.* to my $CATALINA_HOME\webapp\admin and restarted Tomcat. When I tried to run the web app, I get the log as per below. I've solved this by downloading commons-modeler.jar and putting it into my $CATALINA_HOME\common\lib directory. Can this be included in future releases to save others the problems I had? Thanks, Jeff SEVERE: End event threw error java.lang.NoClassDefFoundError: org/apache/commons/modeler/Registry at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2365) at java.lang.Class.getMethod0(Class.java:2611) at java.lang.Class.getMethod(Class.java:1579) at org.apache.commons.beanutils.MethodUtils.getMatchingAccessibleMethod(MethodUtils.java:535) at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:209) at org.apache.commons.digester.CallMethodRule.end(CallMethodRule.java:505) at org.apache.commons.digester.Rule.end(Rule.java:276) at org.apache.commons.digester.Digester.endElement(Digester.java:1058) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser. java:633) at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanEndElement(XMLNSDocum entScannerImpl.java:719) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDisp atcher.dispatch(XMLDocumentFragmentScannerImpl.java:1685) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDoc umentFragmentScannerImpl.java:368) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.jav a:834) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.jav a:764) at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java: 1242) at org.apache.commons.digester.Digester.parse(Digester.java:1567) at org.apache.struts.action.ActionServlet.initServlet(ActionServlet.java:1112) at org.apache.struts.action.ActionServlet.init(ActionServlet.java:324) at org.apache.webapp.admin.ApplicationServlet.init(ApplicationServlet.java:105) at javax.servlet.GenericServlet.init(GenericServlet.java:211) at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1053) at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:711) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:643) at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:541) at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:501) at admin.login_jsp._jspService(login_jsp.java:69) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.ja va:237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:674) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:4 65) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:400) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:303) at org.apache.catalina.authenticator.FormAuthenticator.authenticate(FormAuthenticator.java:21 5) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:446) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Pr otocol.java:731) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.jav a:80
RE: Tomcat 5.5.4 Admin application deploy
From: Jeff Urlwin [mailto:[EMAIL PROTECTED] Subject: Tomcat 5.5.4 Admin application deploy I have copied all of the jakarta-tomcat-5.5.4\server\webapp\admin\*.* to my $CATALINA_HOME\webapp\admin and restarted Tomcat. Why? Why what? Restart Tomcat or copied the files? The admin application is not included in the newer tomcat distributions, so it has to be installed separately. Jeff - Chuck - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 5.5.4 Admin application deploy
From: Jeff Urlwin [mailto:[EMAIL PROTECTED] Subject: RE: Tomcat 5.5.4 Admin application deploy The admin application is not included in the newer tomcat distributions, so it has to be installed separately. And when you unzip the admin download, it's automatically put in the proper place for execution. So why did you try to move it somewhere else? Because the path in the zip is jakarta-tomcat-5.5.4 and my install path is c:\java\Tomcat 5.5, which is different. Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 5.5.4 Admin application deploy
And when you unzip the admin download, it's automatically put in the proper place for execution. So why did you try to move it somewhere else? It depends by where you are unzipping the downloaded admin tool. I have done this operation exactly today following this steps (I was using a linux server, but I think is not important): 1) Download the tomcat 5.5.4 2) Download the Admin tool 5.5.4 3) Unzip the tomcat file 4) Unzip the admin file 5) Copy the contents of the admin folder into the folder of tomcat 6) edit the tomcat-user.xml adding the needed user with admin role 7) start tomcat this work for me, bye Did you have commons-modeler somewhere in your class path? Other than that, that's exactly what I did. Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 5.5.4 Admin application deploy
From: Jeff Urlwin [mailto:[EMAIL PROTECTED] Subject: RE: Tomcat 5.5.4 Admin application deploy 1) Download the tomcat 5.5.4 2) Download the Admin tool 5.5.4 3) Unzip the tomcat file 4) Unzip the admin file 5) Copy the contents of the admin folder into the folder of tomcat 6) edit the tomcat-user.xml adding the needed user with admin role 7) start tomcat Actually, if you use the default unzip folder, step 5 is unnecessary. I just did a clean install of 5.5.7 on WinXP to verify. Did you have commons-modeler somewhere in your class path? Other than that, that's exactly what I did. Not quite: your original message said that you put admin under %CATALINA_HOME%\webapps but the admin app expects to be in %CATALINA_HOME%\server\webapps which is also where the manager app resides. The admin unzip also updates %CATALINA_HOME%\conf\Catalina\localhost with the admin.xml file. Ok -- that makes the Mbean messages go away, which was my next task (THANKS!). At first, I had trouble putting the app under server\webapps. I've cleaned it and done it again and it works. It must have been the missing commons-modeler.jar which caused it to not work and when I tried fixing it, I moved it around. So, the lack of commons-modeler.jar is still an issue. Also, I used the installer to install Tomcat in the first place, which alllows you to pick your directory tree and suggests something under Program Files, which is still a pet-peeve for me. Thanks and Regards, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 5.5.4 Admin application deploy
I think your mistake is copying jakarta-tomcat-5.5.4\server\webapp\admin\*.* to $CATALINA_HOME\webapp\admin You should copy it to the correct location: $CATALINA_HOME\server\webapp\admin The admin.xml file expects it to be under server/webapps, see: Context docBase=${catalina.home}/server/webapps/admin privileged=true antiResourceLocking=false antiJARLocking=false !-- Uncomment this Valve to limit access to the Admin app to localhost for obvious security reasons. Allow may be a comma-separated list of hosts (or even regular expressions). Valve className=org.apache.catalina.valves.RemoteAddrValve allow=127.0.0.1/ -- /Context Thanks -- you are right. That did work. Strange. It thought it was missing the Registry class, but now that I put it in the right place it's not even asking for the commons-modeler. I just moved it out of the common\lib directory and it still works. Regards, Jeff HTH - Richard -Original Message- From: Jeff Urlwin [mailto:[EMAIL PROTECTED] Sent: Thursday, January 20, 2005 10:20 AM To: tomcat-user@jakarta.apache.org Subject: Tomcat 5.5.4 Admin application deploy I'm trying a new Tomcat installation (5.5.4) under Windows XP SP2. I googled for this, but didn't find an answer. Tomcat comes up fine and the management application comes up fine. I have copied all of the jakarta-tomcat-5.5.4\server\webapp\admin\*.* to my $CATALINA_HOME\webapp\admin and restarted Tomcat. When I tried to run the web app, I get the log as per below. I've solved this by downloading commons-modeler.jar and putting it into my $CATALINA_HOME\common\lib directory. Can this be included in future releases to save others the problems I had? Thanks, Jeff SEVERE: End event threw error java.lang.NoClassDefFoundError: org/apache/commons/modeler/Registry at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2365) at java.lang.Class.getMethod0(Class.java:2611) at java.lang.Class.getMethod(Class.java:1579) at org.apache.commons.beanutils.MethodUtils.getMatchingAccessible Method(Met hodUtils.java:535) at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUt ils.java:2 09) at org.apache.commons.digester.CallMethodRule.end(CallMethodRule. java:505) at org.apache.commons.digester.Rule.end(Rule.java:276) at org.apache.commons.digester.Digester.endElement(Digester.java:1058) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.e ndElement( AbstractSAXParser. java:633) at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerIm pl.scanEnd Element(XMLNSDocum entScannerImpl.java:719) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentSca nnerImpl$F ragmentContentDisp atcher.dispatch(XMLDocumentFragmentScannerImpl.java:1685) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentSca nnerImpl.s canDocument(XMLDoc umentFragmentScannerImpl.java:368) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration. parse(XML1 1Configuration.jav a:834) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration. parse(XML1 1Configuration.jav a:764) at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XML Parser.jav a:148) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.p arse(Abstr actSAXParser.java: 1242) at org.apache.commons.digester.Digester.parse(Digester.java:1567) at org.apache.struts.action.ActionServlet.initServlet(ActionServl et.java:11 12) at org.apache.struts.action.ActionServlet.init(ActionServlet.java:324) at org.apache.webapp.admin.ApplicationServlet.init(ApplicationSer vlet.java: 105) at javax.servlet.GenericServlet.init(GenericServlet.java:211) at org.apache.catalina.core.StandardWrapper.loadServlet(StandardW rapper.jav a:1053) at org.apache.catalina.core.StandardWrapper.allocate(StandardWrap per.java:7 11) at org.apache.catalina.core.ApplicationDispatcher.invoke(Applicat ionDispatc her.java:643) at org.apache.catalina.core.ApplicationDispatcher.doInclude(Appli cationDisp atcher.java:541) at org.apache.catalina.core.ApplicationDispatcher.include(Applica tionDispat cher.java:501) at admin.login_jsp._jspService(login_jsp.java:69) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilt er(Applica tionFilterChain.ja va:237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(Appli cationFilt erChain.java:157) at org.apache.catalina.core.ApplicationDispatcher.invoke(Applicat ionDispatc her.java:674
RE: Tomcat 5.5.4 Admin application deploy
From: Jeff Urlwin [mailto:[EMAIL PROTECTED] Subject: RE: Tomcat 5.5.4 Admin application deploy It must have been the missing commons-modeler.jar which caused it to not work and when I tried fixing it, I moved it around. So, the lack of commons-modeler.jar is still an issue. The commons-modeler.jar is distributed in server/lib as part of the main Tomcat download. I didn't have to do anything with it, so I still don't see the problem there. I'm betting that the server/lib path is only for applications which are in server/webapps and doesn't apply to applications in webapps. My fault for not copying the install correctly. Also, I used the installer to install Tomcat in the first place, which alllows you to pick your directory tree and suggests something under Program Files, which is still a pet-peeve for me. Which is one reason I don't use it (the main one being it's platform-specific, so is of no use on most of the systems I play with). I'm a Tomcat newbie, actually (couldn't you tell :), but I've been using Oracle's 9iAS for the last 4 years. So, I used what should have been the simplest to get started... Oh well. Thanks for your help! Regards, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
more logging in tomcat 5.5
hello! forgive the rambling nature of this message. my basic question is how do i get more detailed logging out of tomcat. i'm trying to set up a JNDIRealm to authenticate to an ldap server. in my realm config i've got the debug=99 name/value pair. my realm is included inside my host container. i see no debug output anywhere. where should i see this output? i also have an accesslog valve inside the host container like this: Valve className=org.apache.catalina.valves.AccessLogValve prefix=localhost_access_log. suffix=.out pattern=combined/ the localhost_access_log... files are being created with very minimal information in them. is this where the debug output from the realm should go, or in the catalina.out directory? i've also followed the steps exactly to try and configure log4j as found here: http://jakarta.apache.org/tomcat/tomcat-5.5-doc/logging.html after stopping and restarting tomcat, my log4j settings seem to have made no difference. they don't seem to be working at all. my log file as specified in the log4j.properties file is not being created. is there something further i must do to get this working? is there anything i can do to get more detailed logging out of tomcat and especially my realm config? sorry for the mess of questions. i appreciate any help, direction, or guidance! -jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
basic security tutorial
hello! does anyone know if there's a tutorial or reference on how to set up basic security using tomcat (5.5)? i'd like to get a better understanding of how to secure particular pages in a webapp. thanks! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: class file has wrong version?
Chris Cherrett wrote: I am trying to deploy with a client and am getting an error that I have never seen before. Any ideas where to start? bad class file: /usr/local/tomcat/webapps/tsiware/WEB-INF/classes/ConnectionPool/ConnectionPool.class class file has wrong version 49.0, should be 48.0 Please remove or make sure it appears in the correct subdirectory of the classpath. ConnectionPool dbConnectionPool = ConnectionPool.getInstance(); The class was compiled with 1.5 you're trying to run it on a 1.4 JVM. Recompile the class on 1.4 or upgrade the JVM. -- Jeff Hoffmann [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How/Where do I get security advisories for tomcat ?
Is there an official channel/website where security advisories for tomcat are releases/posted ? I saw some advisories on www.cert.org. Is www.cert.org the official source for these security advisories ? ___ Regards, Jeff Ong IBM Toronto Lab, Toronto, CANADA - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How/Where do I get security advisories for tomcat ?
Thanks for the information Yoav. Regards, Jeff Ong IBM Toronto Lab, Toronto, CANADA - Message from Shapira, Yoav [EMAIL PROTECTED] on Wed, 1 Dec 2004 14:55:17 -0500 - To: Tomcat Users List [EMAIL PROTECTED] Subject: RE: How/Where do I get security advisories for tomcat ? Hi, CERT is about as official as you can get, yeah. Yoav Shapira http://www.yoavshapira.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
jdbc via ResourceLink in context.xml not working in 5.5.4
Hello, I am moving from tomcat 5.0.28 to 5.5.4 and I'm having trouble getting my jdbc driver working in the new tomcat. I have a Resource set up under GlobalNamingResources in server.xml, just as I did in 5.0.28. I also have a corresponding conext xml file (named the same as my test app - jeff.xml) inside conf/Catalina/localhost which has a ResourceLink to the Resource. I've copied the jdbc .jar files to common/lib. As far as I can tell, everything is setup the exact same way it was in 5.0.28 yet I get this error when I try to access my test page: javax.servlet.ServletException: Unable to get connection, DataSource invalid: org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null' org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:845) Can anyone think of what I'm missing or what I screwed up? It works just fine under 5.0.28. My next step is to rename my 5.0.28 install and set it up again from scratch to make sure I'm not missing something in my setup steps. Help!!! thanks, -jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Sun J2SE JVM + tomcat + Debian??
I tried 2.6.7 w/o -server and it was a no-go. Also, a new libc6 just hit unstable and I tried the various combinations with that but it seems I'm stuck with 2.4.27 for now. Jeff Bowden wrote: Yeah, I'm using -server. I tried kernel 2.4.27 on the debian box and that actually works. If I get a chance I'll try it w/o -server on 2.6.7 but for now I'm happy that I don't have to switch distros just to run Java. Eric Weidner wrote: My config single-cpu Debian Sid Kernel 2.6.7 Sun jdk 1.4.2_04 Tomcat 5.0.26 Apache 2.0.49 + mod_jk2 2.0.4 James Mail Server 2.2.0 (Java based) My servers run fine. Are you trying to run with the -server VM? I've always had trouble with that on Linux. Eric On Wednesday 13 October 2004 02:33 pm, Jeff Bowden wrote: Is anyone using tomcat on debian with a Sun JVM? We've just experimented with running it on bleeding edge Gentoo and Debian boxes as well as a trailing edge Redhat 7.3 box. Of the three, Debian is the only one where things don't go quite right. It sort of works but it never spawns any threads and consquently doesn't perform very well on our 4 cpu box. We've gone over the configurations in these pretty carefully and it doesn't seem to be a config issue. We've tried all four combinations of j2se 1.4.2, j2se 1.5, tomcat4 and tomcat5 always with the same result. I also tried switching between 2.6.7 and 2.6.8 kernel. I'm guessing it's a library issue, probably libc, but I don't know how to tell. I realize that this is the tomcat user list and not the Sun Java/Debian support list so if you just want to tell me where to go I would be happy with that :-) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Sun J2SE JVM + tomcat + Debian??
Total wild goose chase. I was using ps auxw to look for threads which work on 2.4 but on 2.6 you need an extra 'H' to see the threads. To summarize: There is no problem running tomcat5 on sun-j2se-1.4.2 on debian unstable using kernel 2.6.8. Works like a champ. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Sun J2SE JVM + tomcat + Debian??
Yeah, I'm using -server. I tried kernel 2.4.27 on the debian box and that actually works. If I get a chance I'll try it w/o -server on 2.6.7 but for now I'm happy that I don't have to switch distros just to run Java. Eric Weidner wrote: My config single-cpu Debian Sid Kernel 2.6.7 Sun jdk 1.4.2_04 Tomcat 5.0.26 Apache 2.0.49 + mod_jk2 2.0.4 James Mail Server 2.2.0 (Java based) My servers run fine. Are you trying to run with the -server VM? I've always had trouble with that on Linux. Eric On Wednesday 13 October 2004 02:33 pm, Jeff Bowden wrote: Is anyone using tomcat on debian with a Sun JVM? We've just experimented with running it on bleeding edge Gentoo and Debian boxes as well as a trailing edge Redhat 7.3 box. Of the three, Debian is the only one where things don't go quite right. It sort of works but it never spawns any threads and consquently doesn't perform very well on our 4 cpu box. We've gone over the configurations in these pretty carefully and it doesn't seem to be a config issue. We've tried all four combinations of j2se 1.4.2, j2se 1.5, tomcat4 and tomcat5 always with the same result. I also tried switching between 2.6.7 and 2.6.8 kernel. I'm guessing it's a library issue, probably libc, but I don't know how to tell. I realize that this is the tomcat user list and not the Sun Java/Debian support list so if you just want to tell me where to go I would be happy with that :-) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Sun J2SE JVM + tomcat + Debian??
Is anyone using tomcat on debian with a Sun JVM? We've just experimented with running it on bleeding edge Gentoo and Debian boxes as well as a trailing edge Redhat 7.3 box. Of the three, Debian is the only one where things don't go quite right. It sort of works but it never spawns any threads and consquently doesn't perform very well on our 4 cpu box. We've gone over the configurations in these pretty carefully and it doesn't seem to be a config issue. We've tried all four combinations of j2se 1.4.2, j2se 1.5, tomcat4 and tomcat5 always with the same result. I also tried switching between 2.6.7 and 2.6.8 kernel. I'm guessing it's a library issue, probably libc, but I don't know how to tell. I realize that this is the tomcat user list and not the Sun Java/Debian support list so if you just want to tell me where to go I would be happy with that :-) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Directories under webapps showing up
Thanks for the response QM. I've attached the server.xml file, but I can tell you that I haven't changed it at all. It is the default file from Tomcat 5.0.28. I deploy my app using a context configuration file located in: $CATALINA_HOME/conf/[enginename]/[hostname]/ I did notice that autoDeploy is set to true. So, maybe that is the issue? --- QM [EMAIL PROTECTED] wrote: On Mon, Oct 04, 2004 at 02:46:39PM -0700, Jeff Faath wrote: : However, what bugs me is the subdirectories under the : webapps directory can still be accessed even though : I can't find the configuration information for them. Perhaps they're being automatically deployed on startup? Please post your server.xml. : Can someone give me an explanation as to why these : URLs of subdirectories beneath webapps are : resolving? Related to the above, it's likely a deployOnStartup tag in server.xml. I believe it's on by default, as a convenience for people who want to drop a set of apps/WARs into the webapps dir and have the changes picked up on Tomcat restart. Another solution -- though admittedly similar to your idea of deleting the other dirs -- is to use the $CATALINA_HOME vs $CATALINA_BASE setups to have one set of Tomcat binaries and several independent Tomcat instances. That way, the only webapps that exist for that instance are the ones you put there; any defaults/samples that ship with Tomcat are out of the picture. -QM -- software -- http://www.brandxdev.net tech news -- http://www.RoarNetworX.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- Comment these entries out to disable JMX MBeans support -- !-- You may also configure custom components (e.g. Valves/Realms) by including your own mbean-descriptor file(s), and setting the descriptors attribute to point to a ';' seperated list of paths (in the ClassLoader sense) of files to add to the default list. e.g. descriptors=/com/myfirm/mypackage/mbean-descriptor.xml -- Listener className=org.apache.catalina.mbeans.ServerLifecycleListener debug=0/ Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener debug=0/ !-- Global JNDI resources -- GlobalNamingResources !-- Test entry for demonstration purposes -- Environment name=simpleValue type=java.lang.Integer value=30/ !-- Editable user database that can also be used by UserDatabaseRealm to authenticate users -- Resource name=UserDatabase auth=Container type=org.apache.catalina.UserDatabase description=User database that can be updated and saved /Resource ResourceParams name=UserDatabase parameter namefactory/name valueorg.apache.catalina.users.MemoryUserDatabaseFactory/value /parameter parameter namepathname/name valueconf/tomcat-users.xml/value /parameter /ResourceParams /GlobalNamingResources !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Catalina !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 5 documentation bundle for more detailed instructions): * If your JDK version 1.3 or prior, download and install JSSE 1.0.2 or later, and put the JAR
Directories under webapps showing up
Hello, I have finally figured out how to install my web application as the default app for Tomcat (thereby forgoing the standard page under the ROOT directory). So, to get to welcome page of my app, all you need to do is access this URL: http://localhost:8080/ However, what bugs me is the subdirectories under the webapps directory can still be accessed even though I can't find the configuration information for them. So, for example, I could use this URL: http://localhost:8080/tomcat-docs And that will access the index.htm page in the tomcat-docs directory under webapps. I know a simple solution is to just delete the directory, but it bothers me that these directories can be accessed via a URL when nothing points to them. My app's docBase is even in an entirely different directory then Tomcat's webapps directory. Can someone give me an explanation as to why these URLs of subdirectories beneath webapps are resolving? Thanks, JF ___ Do you Yahoo!? Declare Yourself - Register online to vote today! http://vote.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
documentation for ant tasks
hello! is there anyplace where the catalina ant functions/tasks are documented? i've searched but obviously i'm not looking in the proper place. thanks! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Sybase and Tomcat 5, Possible Problem
After a lot of effort, I feel there may be some reason that the Sybase JConnect JDBC driver doesn't work in Tomcat 5.0.24 (I use Tomcat 4 for my Sybase driven apps quite a bit). The exception is: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null', cause: null META-INF/context.xml is: Context path=/forteCommon docBase=forteCommon reloadable=true ResourceLink name=jdbc/odsdb03 global=jdbc/odsdb03 type=javax.sql.DataSource/ /Context From conf/server.xml contains: GlobalNamingResources Resource name=jdbc/odsdb03 auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/odsdb03 parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter nameusername/name valueexcalibur/value /parameter parameter namepassword/name valuemypassword/value /parameter parameter namedriverClassName/name valuecom.sybase.jdbc2.jdbc.SybDriver/value /parameter parameter namedriverName/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter parameter nameurl/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter parameter namemaxActive/name value5/value /parameter /ResourceParams /GlobalNamingResources web.xml contains: web-app servlet servlet-name ProvCICS /servlet-name servlet-class com.ods.forte.cics.servlet.ProvCICS /servlet-class load-on-startup1/load-on-startup /servlet servlet-mapping servlet-nameProvCICS/servlet-name url-pattern/ProvCICS/url-pattern /servlet-mapping resource-ref descriptionodsdb03 Connection Pool/description res-ref-namejdbc/odsdb03/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref /web-app I have also tried working with the context placed in server.xml and with the Resource defined in the context, all combinations yield the same behavior. *Tomcat does actually log into the database server when it starts* I can see it from the database side. Therefore I know the jdbc jar file is loaded and the connection specification correct and working. In addition, the stack trace in catalina.out includes a point in Sybase code: Cannot create JDBC driver of class '' for connect URL 'null' java.lang.NullPointerException at com.sybase.jdbc2.jdbc.SybDriver.acceptsURL(SybDriver.java:197) at java.sql.DriverManager.getDriver(DriverManager.java:249) at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:743) ... So can I conclude that the app is actually linked to the resource? If so then the problem seems to be that the information required somehow does not reach down the driver? Ideas? Should I rollback to TC 4x for awhile? -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5 Database Connections
This is part question and part observation regarding database connectivity under Tomcat (5.0.24). My application normally runs in production at my company on a Tomcat 4.0.4 server. The applications includes Cocoon and access to several databases (Sybase) via both Tomcat connections from servlets and from Cocoon XSP pages. I've been at this for awhile now and I'm a huge fan of Tomcat (and Cocoon). On a new test server I setup Tomcat 5.0.24 and installed my applications. For sometime I thought all was well because most of my stuff is Cocoon driven, and it's fine, including database connectivity. This week I realized that my servlets are getting: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null', cause: null I've spent several days now trying to fix this. I've read verious posts from this list's archive, and several other places. I've studied many examples, and done google after google on it. My conclusion is that for whatever reason *a lot* of people have this trouble with TC 5x. However there are very few solutions. Yes, my jdbc jar file is in common/lib (and WEB-INF/lib, both). Yes, I've tried declarations in GlobalNamingResources and in the apps context, either. Yes web.xml contains a resource-ref with the same res-ref-name. The only thing I have not done is to create a META-INF/context.xml (is defining these resources in server.xml simply broken?). I'm dead stopped on this - yet I have no trouble at all with Tomcat 4.0.4. It seems like some people do get this to work. It seems like many, many people do not. Is there a bug at play in all this? Here's my question - Why is it so hard? -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Sybase and Tomcat 5, Possible Problem
Shapira, Yoav wrote: Hi, Hmm... It's good you can verify the login on the DB side. You should try to debug this in tomcat 5 rather than rolling back, if possible. Where is the driver jar located in your server? I've been trying to stick with common/lib. That seems to work. Since I was able to get a version 4.1.30 to work, I started over, using those elements, on the 5.0.24 server. I was able to get the 5.0.24 server to work this time! Not sure why, however. I imagine that the original exception was a red herring and my problem was really some misplaced tags or typo. I guess. It all still seems much harder than it should be. But once it works, it's rock solid. -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5 Database Connections
This is part question and part observation regarding database connectivity under Tomcat (5.0.24). My application normally runs in production at my company on a Tomcat 4.0.4 server. The applications includes Cocoon and access to several databases (Sybase) via both Tomcat connections from servlets and from Cocoon XSP pages. I've been at this for awhile now and I'm a huge fan of Tomcat (and Cocoon). On a new test server I setup Tomcat 5.0.24 and installed my applications. For sometime I thought all was well because most of my stuff is Cocoon driven, and it's fine, including database connectivity. This week I realized that my servlets are getting: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null', cause: null I've spent several days now trying to fix this. I've read verious posts from this list's archive, and several other places. I've studied many examples, and done google after google on it. My conclusion is that for whatever reason *a lot* of people have this trouble with TC 5x. However there are very few solutions. Yes, my jdbc jar file is in common/lib (and WEB-INF/lib, both). Yes, I've tried declarations in GlobalNamingResources and in the apps context, either. Yes web.xml contains a resource-ref with the same res-ref-name. The only thing I have not done is to create a META-INF/context.xml (is defining these resources in server.xml simply broken?). I'm dead stopped on this - yet I have no trouble at all with Tomcat 4.0.4. It seems like some people do get this to work. It seems like many, many people do not. Is there a bug at play in all this? Here's my question - Why is it so hard? -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Sybase and Tomcat 5, Possible Problem
After a lot of effort, I feel there may be some reason that the Sybase JConnect JDBC driver doesn't work in Tomcat 5.0.24 (I use Tomcat 4 for my Sybase driven apps quite a bit). The exception is: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null', cause: null META-INF/context.xml is: Context path=/forteCommon docBase=forteCommon reloadable=true ResourceLink name=jdbc/odsdb03 global=jdbc/odsdb03 type=javax.sql.DataSource/ /Context From conf/server.xml contains: GlobalNamingResources Resource name=jdbc/odsdb03 auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/odsdb03 parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter nameusername/name valueexcalibur/value /parameter parameter namepassword/name valuemypassword/value /parameter parameter namedriverClassName/name valuecom.sybase.jdbc2.jdbc.SybDriver/value /parameter parameter namedriverName/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter parameter nameurl/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter parameter namemaxActive/name value5/value /parameter /ResourceParams /GlobalNamingResources web.xml contains: web-app servlet servlet-name ProvCICS /servlet-name servlet-class com.ods.forte.cics.servlet.ProvCICS /servlet-class load-on-startup1/load-on-startup /servlet servlet-mapping servlet-nameProvCICS/servlet-name url-pattern/ProvCICS/url-pattern /servlet-mapping resource-ref descriptionodsdb03 Connection Pool/description res-ref-namejdbc/odsdb03/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref /web-app I have also tried working with the context placed in server.xml and with the Resource defined in the context, all combinations yield the same behavior. *Tomcat does actually log into the database server when it starts* I can see it from the database side. Therefore I know the jdbc jar file is loaded and the connection specification correct and working. In addition, the stack trace in catalina.out includes a point in Sybase code: Cannot create JDBC driver of class '' for connect URL 'null' java.lang.NullPointerException at com.sybase.jdbc2.jdbc.SybDriver.acceptsURL(SybDriver.java:197) at java.sql.DriverManager.getDriver(DriverManager.java:249) at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:743) ... So can I conclude that the app is actually linked to the resource? If so then the problem seems to be that the information required somehow does not reach down the driver? Ideas? Should I rollback to TC 4x for awhile? -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5 Database Connections
Graham Leggett wrote: Jeff Sexton wrote: This week I realized that my servlets are getting: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null', cause: null As a test, try the binary package as provided by Jakarta for tomcat (unless of course you are already doing so). In my case, the binary Jakarta supplied package v5.0.19 works, whereas the jpackage RPM of tomcat v5.0.19 does not. Same config. Wierd. I'm working with the binary for 5.0.24. Maybe I should try 5.0.19. One thing I did not mention is that I am doing this on AIX, but that doesn't seem like a factor (?). Whatever's going wrong *seems* to all be in the Tomcat world. -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5 Database Connections
Graham Leggett wrote: I think it's definitely tomcat - my environment is Postgresql on Redhat Enterprise and am getting the same thing. Dang, that's not good... I really like other things about the recent releases. But I have to agree. I just changed my java to call for a bogus resource name. The exception changed to no such resource in the context exactly as expected. So that's that. The server is connecting the database, and the app is looking up and finding the resource. But somehow the information needed to create the connection doesn't get through. Could there even be a work around? I mean other than re-writing my java to connect to the database on its own... -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5 Database Connections
Is the order of elements in the ResourceParams block meaningful? Rightly or wrongly meaningful that is... I keep looking for some way to understand way this seems to work for some people. Jeff Sexton wrote: Graham Leggett wrote: I think it's definitely tomcat - my environment is Postgresql on Redhat Enterprise and am getting the same thing. Dang, that's not good... I really like other things about the recent releases. But I have to agree. I just changed my java to call for a bogus resource name. The exception changed to no such resource in the context exactly as expected. So that's that. The server is connecting the database, and the app is looking up and finding the resource. But somehow the information needed to create the connection doesn't get through. Could there even be a work around? I mean other than re-writing my java to connect to the database on its own... -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5 Database Connections - from wierd to crazy
I switched from TC 5 to Tomcat 4.1.30 and again copied my (working) app again from the Tomcat 4.0.4 install. This time, it knew the driver but not the url. So in server.xml I changed one parameter From: parameter namedriverName/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter !-- Works in 4.0.4 -- To: parameter nameurl/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter That cured the no url exception. However now I get this exception: org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory, cause: JZ004: User name property missing in DriverManager.getConnection(..., Properties). Here's the whole context entry from server.xml: Context path=/forteCommon docBase=forteCommon reloadable=true Resource name=jdbc/odsdb03 auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/odsdb03 parameter nameuser/namevalueexcalibur/value /parameter parameter namepassword/namevaluepassword/value /parameter parameter namedriverClassName/name valuecom.sybase.jdbc2.jdbc.SybDriver/value /parameter parameter nameurl/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter /ResourceParams /Context I think I'm losing my mind. -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5 Database Connections - from wierd to crazy
Jeff Sexton wrote: I switched from TC 5 to Tomcat 4.1.30 and again copied my (working) app again from the Tomcat 4.0.4 install. This time, it knew the driver but not the url. So in server.xml I changed one parameter From: parameter namedriverName/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter !-- Works in 4.0.4 -- To: parameter nameurl/name valuejdbc:sybase:Tds:pdxax12:4100/value /parameter That cured the no url exception. However now I get this exception: org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory, cause: JZ004: User name property missing in DriverManager.getConnection(..., Properties). Changing this 4.0.4 version entry parameter nameuser/namevalueexcalibur/value /parameter to this: parameter nameusername/name valueexcalibur/value /parameter Allows 4.1.30 to work perfectly! So to sum up for now, 4.0.4 works for my app and 4.1.3 works if I change two entries in the resource. Still no luck with 5.0.24 though. -- The ODS Companies Jeff Sexton Information Services (503) 228-6554 x1026 http://www.odscompanies.com This message is intended for the sole use of the individual and entity to whom it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended addressee, nor authorized to receive for the intended addressee, you are hereby notified that you may not use, copy, disclose or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete the message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Server Specs
Carl Olivier wrote: Windows 2000 Server Tomcat 5.0.25 Apache 2.0.49 Mod_jk2 J2SDK 1.4.2_01 The sites use JDBC to a MS SQL 2000 server I just noticed that commons-dbcp-1.1 has a memory leak in it (http://issues.apache.org/bugzilla/show_bug.cgi?id=27465). I believe that's the version that ships with tomcat-5.0.25. If you're using DBCP for your database connections, you might want to check that. It's something I've just stumbled on and I don't know if it has any relation to anything, but it sounds like it'd be worth looking into. -- Jeff Hoffmann [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Memory leak with Tomcat 5.0.19
Brian Beckham wrote: Sorry bout that...got a little flustered :) I don't have any answers but I'd just like to chime in to say that I've had nearly identical problems when I was using 5.0.19. I've moved on to 5.0.24 now, but I found some error logs in one of my backups so I'm attaching them in case they might help. I think with both of these errors I was using j2sdk1.4.1 although I was having the same problem using 1.4.2 too. -- Jeff Hoffmann PropertyKey.com Unexpected Signal : 11 occurred at PC=0x403647F4 Function=(null)+0x403647F4 Library=/usr/java/j2sdk1.4.1/jre/lib/i386/server/libjvm.so NOTE: We are unable to locate the function name symbol for the error just occurred. Please refer to release documentation for possible reason and solutions. Current Java thread: at java.net.PlainSocketImpl.socketAccept(Native Method) at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:353) - locked 0x49fcd1c0 (a java.net.PlainSocketImpl) at java.net.ServerSocket.implAccept(ServerSocket.java:439) at java.net.ServerSocket.accept(ServerSocket.java:410) at org.apache.jk.common.ChannelSocket.accept(ChannelSocket.java:312) at org.apache.jk.common.ChannelSocket.acceptConnections(ChannelSocket.java:613) at org.apache.jk.common.SocketAcceptor.runIt(ChannelSocket.java:810) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:688) at java.lang.Thread.run(Thread.java:536) Dynamic libraries: 08048000-0804e000 r-xp 03:04 817673 /usr/java/j2sdk1.4.1/bin/java 0804e000-0804f000 rw-p 5000 03:04 817673 /usr/java/j2sdk1.4.1/bin/java 4000-40013000 r-xp 03:04 1602502/lib/ld-2.2.5.so 40013000-40014000 rw-p 00013000 03:04 1602502/lib/ld-2.2.5.so 40014000-40017000 r--s 03:04 1144706 /usr/java/j2sdk1.4.1/jre/lib/ext/dnsns.jar 40017000-40018000 r--s 03:04 801367 /home/iris/tomcat-5.0.19/common/lib/naming-java.jar 40018000-40025000 r-xp 03:04 2371049/lib/i686/libpthread-0.9.so 40025000-4002c000 rw-p d000 03:04 2371049/lib/i686/libpthread-0.9.so 4002d000-4002f000 r-xp 03:04 1602515/lib/libdl-2.2.5.so 4002f000-4003 rw-p 1000 03:04 1602515/lib/libdl-2.2.5.so 4003-404c8000 r-xp 03:04 883027 /usr/java/j2sdk1.4.1/jre/lib/i386/server/libjvm.so 404c8000-406d4000 rw-p 00497000 03:04 883027 /usr/java/j2sdk1.4.1/jre/lib/i386/server/libjvm.so 406e6000-406f8000 r-xp 03:04 1602519/lib/libnsl-2.2.5.so 406f8000-406f9000 rw-p 00012000 03:04 1602519/lib/libnsl-2.2.5.so 406fb000-4071c000 r-xp 03:04 2371047/lib/i686/libm-2.2.5.so 4071c000-4071d000 rw-p 0002 03:04 2371047/lib/i686/libm-2.2.5.so 4071d000-40726000 r-xp 03:04 359767 /usr/java/j2sdk1.4.1/jre/lib/i386/native_threads/libhpi.so 40726000-40727000 rw-p 8000 03:04 359767 /usr/java/j2sdk1.4.1/jre/lib/i386/native_threads/libhpi.so 40728000-40738000 r-xp 03:04 245402 /usr/java/j2sdk1.4.1/jre/lib/i386/libverify.so 40738000-4073a000 rw-p f000 03:04 245402 /usr/java/j2sdk1.4.1/jre/lib/i386/libverify.so 4073a000-4075b000 r-xp 03:04 245403 /usr/java/j2sdk1.4.1/jre/lib/i386/libjava.so 4075b000-4075d000 rw-p 0002 03:04 245403 /usr/java/j2sdk1.4.1/jre/lib/i386/libjava.so 4075d000-40772000 r-xp 03:04 245405 /usr/java/j2sdk1.4.1/jre/lib/i386/libzip.so 40772000-40774000 rw-p 00014000 03:04 245405 /usr/java/j2sdk1.4.1/jre/lib/i386/libzip.so 40774000-4085f000 r--s 03:04 212729 /home/iris/tomcat-5.0.19/common/endorsed/xercesImpl.jar 4085f000-4087e000 r--s 03:04 212730 /home/iris/tomcat-5.0.19/common/endorsed/xmlParserAPIs.jar 4087e000-41f4c000 r--s 03:04 1373665/usr/java/j2sdk1.4.1/jre/lib/rt.jar 41f8f000-41fa6000 r--s 03:04 1373645 /usr/java/j2sdk1.4.1/jre/lib/sunrsasign.jar 41fa6000-41fb9000 r--s 03:04 1373646/usr/java/j2sdk1.4.1/jre/lib/jce.jar 41fe1000-41fe7000 r--s 03:04 2354875/usr/lib/gconv/gconv-modules.cache 41fe7000-41ff r-xp 03:04 1602535/lib/libnss_files-2.2.5.so 41ff-41ff1000 rw-p 9000 03:04 1602535/lib/libnss_files-2.2.5.so 41ff1000-41fff000 r--s 03:04 1144708 /usr/java/j2sdk1.4.1/jre/lib/ext/ldapsec.jar 41fff000-4200 r--s 03:04 1782607 /home/iris/tomcat-5.0.19/server/lib/jkshm.jar 4200-4212c000 r-xp 03:04 2371045/lib/i686/libc-2.2.5.so 4212c000-42131000 rw-p 0012c000 03:04 2371045/lib/i686/libc-2.2.5.so 42135000-421a6000 r--s 03:04 1373647/usr/java/j2sdk1.4.1/jre/lib/jsse.jar 421a6000-42462000 r--s 03:04 1373663 /usr/java/j2sdk1.4.1/jre/lib/charsets.jar 444e2000-444e8000 r--s 03:04 2076877 /home/iris/tomcat-5.0.19/bin/bootstrap.jar 444e8000-444eb000 r--s 03:04 2076880 /home/iris/tomcat-5.0.19/bin/commons
Re: Memory leak with Tomcat 5.0.19
Brian Beckham wrote: Jeff, Can you tell me more about your sitation? Did 5.0.24 help? So far I haven't had any problems with 5.0.24, although I've only been running it a couple of days. When I had the problem with 5.0.19, I jumped back to 5.0.16 until a couple of days ago when I went up to 5.0.24. What options were you setting? They were essentially the same. My initial memory was set to 128M and max memory was set to 512M but I never maxed out the memory before the crash. I was using server VM and set the headless property. Were you using / are you using jsvc? No. What OS? It's mostly Redhat Hat 7.3 with kernel 2.4.20-20.7smp. I've used both of the following java environments and saw the same problem with both: Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-b21) Java HotSpot(TM) Client VM (build 1.4.1-b21, mixed mode) Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) Java HotSpot(TM) Client VM (build 1.4.2_04-b05, mixed mode) I don't know what else you'd like to know. I'm not running that version any more so it'd be kind of hard for me to test things but I'd be glad to tell you what I can remember from when I was. Like I said, I never found an answer but I wanted to corroborate in case somebody was inclined to dismiss it as a one-off problem. -- Jeff Hoffmann PropertyKey.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT] JAVA_OPTS in catalina.sh
Could this possibly be a time to try setting LD_ASSUME_KERNEL to 2.4? [EMAIL PROTECTED] 4/14/04 7:08:41 AM Thank you... will try to figure out the diff between the config and post it in Java forum :-) [EMAIL PROTECTED] 04/14/2004 08:45 PM Please respond to Tomcat Users List To: Tomcat Users List [EMAIL PROTECTED] cc: Subject:Re: [OT] JAVA_OPTS in catalina.sh On Wed, Apr 14, 2004 at 06:46:35PM +0800, Thomas Chua wrote: : but i am not familiar with linux so i do not know whether this minor : difference : will cause the VM to crash. The RH kernels leave their .config file in /boot (I forget the exact name). Run a diff between the two files and you'll see the options for each one. That said, there could be other differences between the two machines -- libraries, physical memory problems, etc. Have you had any luck posting finding this problem in the Java forums on Sun's website? -QM -- software -- http://www.brandxdev.net tech news -- http://www.RoarNetworX.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat Hangs
This is a For what it is worth message, since I think that your JVM upgrade was more to the point of solving the problem. But, the permanent generation issue: First, reference Yoav's email response to somebody last month: http://marc.theaimsgroup.com/?l=tomcat-userm=107590242329345w=2 Every time a context is restarted, there is a possibility that there will be some classloader objects that the JVM doesn't think it can dispose of. These are stored in the permanent generation memory. The perm gen is a small pool of memory just for this purpose - objects that will never be garbage collected. But, if the permanent gen fills up from these constant reloads you can get an OutOfMemoryException even though the old and new generation memory pools are not full. I think there was something about the memory not being able to go away because it was loaded by a classloader that was loading items to be shared by all web applications, so in other words from jar files in shared\lib or common\lib Once again, that doesn't seem to be your problem, especially if you are not reloading the context repeatedly. [EMAIL PROTECTED] 3/25/04 6:07:28 PM I'd say the activity is moderate. Some 6-10 users would be using our web application during that time. The machine is better than a development machine but not as good as production one. Jeff, can you explain more about the -- JVM's permanent generation. Thanks. - SPS - Original Message - From: Jeff Tulley [EMAIL PROTECTED] Date: Thursday, March 25, 2004 7:59 pm Subject: Re: Tomcat Hangs What kind of activity is going on with this server during those two hours? Heavy, moderate, light load? Is it a development box or production? I ask the last question, since some have seen a problelm with repeated redeploys of a web application, where the JVM's permanent generation memory is running out even though the rest of the memory pools are nowhere near full. Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com [EMAIL PROTECTED] 3/25/04 5:50:42 PM We have Tomcat 4.1.27 running in conjunction with Apache 1.3.x. We're using AJP13 connector. The machine that we're using has got over 2GB of Memory and good processor speed. Tomcat has been allocated 1 GB of max memory. The issue is: For every two hours or so Tomcat hangs. That means, Tomcat don't crash but simply don't accept any more connections. While Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JNDI Realm Problem
Yeah it looks like the fix to make the encoding only on the DN instead of the whole string was applied after 4.1.30 was tagged. It will have to be in a future release. [EMAIL PROTECTED] 3/25/04 5:56:16 PM Pascal, What version of Tomcsat are you using? In response to a defect, I added a feature to JNDIRealm a while back, that applied a filter to certain JNDI realms to encode characters such as and ( Later we learned that I should have focused that filtering a little more on a specific string, and too much was being filtered, so I submitted a fix. It was very simple, really only a one or two-line fix. The reason I suspect this is that your output below has \28 and \29 in the filter expression, which are the encodings for the parenthesis that would be surrounding the expression. The bug was that only the DN should have been encoded, not the whole filter expression. It looks like from CVS logs that the fix should be in 5.0.19, and 5.0.20, but not 5.0.18 Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com [EMAIL PROTECTED] 3/25/04 6:14:06 AM Hello, all ! I've got a really strange problem that is probably caused by my eyesight. I followed the JNDI Real HowTo on the Jakarta site, and I setup the necessary LDIF file and put the necessary entries inside server.xml. After struggling with various typo errors and configuration mistakes (I was having a migraine at the time), I finally got Tomcat to authenticate with my OpenLDAP server. The trouble is, it cannot find the role, so I always get kicked out with an authorization error. This is the error I am getting when I try to login to the Tomcat Web Administration page : 2004-03-25 20:42:53 JNDIRealm[Catalina]: lookupUser(tcadmin) 2004-03-25 20:42:53 JNDIRealm[Catalina]: dn=uid=tcadmin,ou=people,o=cymulacrum 2004-03-25 20:42:53 JNDIRealm[Catalina]: validating credentials by binding as the user 2004-03-25 20:42:53 JNDIRealm[Catalina]: binding as uid=tcadmin,ou=people,o=cymulacrum 2004-03-25 20:42:53 JNDIRealm[Catalina]: Username tcadmin successfully authenticated 2004-03-25 20:42:53 JNDIRealm[Catalina]: getRoles(uid=tcadmin,ou=people,o=cymulacrum) 2004-03-25 20:42:53 JNDIRealm[Catalina]: Searching role base 'ou=groups,o=cymulacrum' for attribute 'cn' 2004-03-25 20:42:53 JNDIRealm[Catalina]: With filter expression '\28uniqueMember=uid=tcadmin,ou=people,o=cymulacrum\29' 2004-03-25 20:42:53 JNDIRealm[Catalina]: Returning 0 roles - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JNDI Realm Problem
Pascal, What version of Tomcsat are you using? In response to a defect, I added a feature to JNDIRealm a while back, that applied a filter to certain JNDI realms to encode characters such as and ( Later we learned that I should have focused that filtering a little more on a specific string, and too much was being filtered, so I submitted a fix. It was very simple, really only a one or two-line fix. The reason I suspect this is that your output below has \28 and \29 in the filter expression, which are the encodings for the parenthesis that would be surrounding the expression. The bug was that only the DN should have been encoded, not the whole filter expression. It looks like from CVS logs that the fix should be in 5.0.19, and 5.0.20, but not 5.0.18 Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com [EMAIL PROTECTED] 3/25/04 6:14:06 AM Hello, all ! I've got a really strange problem that is probably caused by my eyesight. I followed the JNDI Real HowTo on the Jakarta site, and I setup the necessary LDIF file and put the necessary entries inside server.xml. After struggling with various typo errors and configuration mistakes (I was having a migraine at the time), I finally got Tomcat to authenticate with my OpenLDAP server. The trouble is, it cannot find the role, so I always get kicked out with an authorization error. This is the error I am getting when I try to login to the Tomcat Web Administration page : 2004-03-25 20:42:53 JNDIRealm[Catalina]: lookupUser(tcadmin) 2004-03-25 20:42:53 JNDIRealm[Catalina]: dn=uid=tcadmin,ou=people,o=cymulacrum 2004-03-25 20:42:53 JNDIRealm[Catalina]: validating credentials by binding as the user 2004-03-25 20:42:53 JNDIRealm[Catalina]: binding as uid=tcadmin,ou=people,o=cymulacrum 2004-03-25 20:42:53 JNDIRealm[Catalina]: Username tcadmin successfully authenticated 2004-03-25 20:42:53 JNDIRealm[Catalina]: getRoles(uid=tcadmin,ou=people,o=cymulacrum) 2004-03-25 20:42:53 JNDIRealm[Catalina]: Searching role base 'ou=groups,o=cymulacrum' for attribute 'cn' 2004-03-25 20:42:53 JNDIRealm[Catalina]: With filter expression '\28uniqueMember=uid=tcadmin,ou=people,o=cymulacrum\29' 2004-03-25 20:42:53 JNDIRealm[Catalina]: Returning 0 roles - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat Hangs
What kind of activity is going on with this server during those two hours? Heavy, moderate, light load? Is it a development box or production? I ask the last question, since some have seen a problelm with repeated redeploys of a web application, where the JVM's permanent generation memory is running out even though the rest of the memory pools are nowhere near full. Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com [EMAIL PROTECTED] 3/25/04 5:50:42 PM We have Tomcat 4.1.27 running in conjunction with Apache 1.3.x. We're using AJP13 connector. The machine that we're using has got over 2GB of Memory and good processor speed. Tomcat has been allocated 1 GB of max memory. The issue is: For every two hours or so Tomcat hangs. That means, Tomcat don't crash but simply don't accept any more connections. While using Tomcat with Apache we're getting 500 Internal Server Error. We are constantly restarting server to make it work. There is no good information in the logs that could lead us to debug this issue. I have tried several things. Taken out Apache and Connectors from the equation by running Tomcat as standalone. This time Tomcat we get server not found error - Page cannot be displayed message. I have also increased the maxProcessors of the connector to 300 instead of the default 75. Interesting thing is -- when Tomcat hangs the memory usage never reaches even half of the max memory (1 GB) allocated to Tomcat, and the number of threads that we see is also always less than half of maxProcessors value (300) set. If anybody encountered this kind of issue or if you have any thoughts please respond. Thanks in advance! - SPS - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Making suggestions
What is the procedure for suggesting a new feature for tomcat? *Jeff Poling, Research and Development, CMHC Systems** ** For every difficult problem, there is * A warp core breach is imminent? ** ** a solution that is simple, obvious, * This calls for the handyman's** ** and wrong.* secret weapon, duct tape. -- Red** ** * Green, Chief Engineer, USS Voyager* ** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Connection warning
At 09:06 AM 3/18/2004, Shapira, Yoav wrote: A good place to start would be right here (in a separate thread). Solicit feedback from other users and developers. This list has a number of experienced users who will shoot down a dumb idea before you propose it to the tomcat developers ;) Fair enough. *Assuming this doesn't already exist and I haven't found it* We use tomcat as our middleware to provide a GUI-like interface for our UNIX character-based back-end. We are running into a problem with maxProcesses being maxed out and users not being able to use the system. A good rule of thumb is to multiply the expected number of sessions times two or three to get the necessary number of processes ... but it only really works if our customer's internal reporting processes are sufficient enough so that the system admininistrator always knows the number of people working for the company (and therefore using the system). What I'd like is some way to keep tabs on the number of processes for any given connector(s) in use, and if it exceeds a certain threshhold, give some sort of sign ... an email, logfile entry, burning bush, whatever. *Jeff Poling, Research and Development, CMHC Systems** ** For every difficult problem, there is * A warp core breach is imminent? ** ** a solution that is simple, obvious, * This calls for the handyman's** ** and wrong.* secret weapon, duct tape. -- Red** ** * Green, Chief Engineer, USS Voyager* ** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Connector processes
Is there a way, from within a servlet, to find out what the maximum number of processes has (maxProcessors attribute) and how many of them are in use? *Jeff Poling, Research and Development, CMHC Systems** ** For every difficult problem, there is * A warp core breach is imminent? ** ** a solution that is simple, obvious, * This calls for the handyman's** ** and wrong.* secret weapon, duct tape. -- Red** ** * Green, Chief Engineer, USS Voyager* ** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: formbased login question
If you truly want a box with a username and password login on every page (as some portals have), then you do NOT want to use the container-provided security and the form-login-config Instead, you will have to create your own security / login mechanism in your own servlet / taglib / whatever. As David pointed out, doing what you specified below will mean that you need a completely separate login page that will pop up the first time somebody tries to access a secured page. That may not be what you want. (I'd try it and see if it is acceptable though, since it is the easiest solution). [EMAIL PROTECTED] 3/4/04 1:56:05 AM Before starting on a quest for more knowledge I thought I ask you all, I'm building a web app. A user should be able to login on every page available. So every page has a form with a loginname and password field. The form is formatted correctly for form based login. I'm not using frames! My web.xml contains : login-config auth-methodFORM/auth-method form-login-config form-login-page/*/form-login-page form-error-page/error.html/form-error-page /form-login-config /login-config I'm wondering about the form-login-page tag. How to make it clear to tomcat that every page can be a login page. I haven't tried it yet but I think my solution (/*) will not work. The testingserver DB is broken and we are using JDBCRealm. Who has experience with this and is willing to help me? I would like to know what to fill in in the form-login-page tag or any other way to solve this. Kind regards, Werner van Mook - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat heap vs. java.exe
] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This transmission is intended to be strictly confidential. If you are not the intended recipient of this message, you may not disclose, print, copy or disseminate this information. If you have received this in error, please reply and notify the sender (only) and delete the message. Unauthorized interception of this e-mail is a violation of federal criminal law. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This transmission is intended to be strictly confidential. If you are not the intended recipient of this message, you may not disclose, print, copy or disseminate this information. If you have received this in error, please reply and notify the sender (only) and delete the message. Unauthorized interception of this e-mail is a violation of federal criminal law. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This transmission is intended to be strictly confidential. If you are not the intended recipient of this message, you may not disclose, print, copy or disseminate this information. If you have received this in error, please reply and notify the sender (only) and delete the message. Unauthorized interception of this e-mail is a violation of federal criminal law. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
jsession id format?
Is the jsessionid a simple random number, or is there information encoded into it. For example, on one other application server (non-J2EE), the client IP address is encoded into the generated sessionID for security reasons. *Jeff Poling, Research and Development, CMHC Systems** ** For every difficult problem, there is * A warp core breach is imminent? ** ** a solution that is simple, obvious, * This calls for the handyman's** ** and wrong.* secret weapon, duct tape. -- Red** ** * Green, Chief Engineer, USS Voyager* ** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: HTTPS with Apache 2.0.48 and Tomcat 5.0.16
You can also put a transport guarantee of CONFIDENTIAL in web.xml When you do make sure that your redirect ports on the Apache connector in server.xml are correct (default is 8443, needs to be 443 if you are using Apache for SSL). [EMAIL PROTECTED] 2/2/04 10:32:51 AM I describe this in my HOWTO. http://www.linuxjava.net/howto/webapp/ You either redirect traffic from http to https for that virtual host, or you only mount the webapp in the http virtual host and not for the https. Oscar Carrillo On Mon, 2 Feb 2004, Ralf Schneider wrote: Am Montag, 2. Februar 2004 13:55 schrieb Yiannis Mavroukakis: Best remove that line, stick it in your httpd.conf instead along with the hostname. This wasn't the problem. I did not notice that mod_ssl was not compiled into httpd :-( After a rebuild of Apache (now with SSL support :-) and works now. My last problem to solve (I hope :-) is how can I prevent user from accessing the webapp with the normal HTTP protocol instead of HTTPS? At the moment both works, but I only want it to work with HTTPS. Ralf. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: anyone running tomcat-4.1.29 with commons-daemons?
Was there ever a resolution here? I'm getting exactly the same error using 4.1.x and the below linked Tomcat.sh script (modified to my paths). Thanks, +jeff Bill Barker wrote: I've been using commons-daemon happily with Tomcat 4.1.x for quite some time now. I'd suggest starting from http://cvs.apache.org/viewcvs/jakarta-commons/daemon/src/native/unix/native/Tomcat.sh?rev=1.1.1.1content-type=text/vnd.viewcvs-markup and modifying as nessary. - Original Message - From: Marten Lehmann [EMAIL PROTECTED] Newsgroups: gmane.comp.jakarta.tomcat.user Sent: Thursday, December 04, 2003 9:46 AM Subject: anyone running tomcat-4.1.29 with commons-daemons? Hello, I'm trying to use the commons-daemons package as of 20031204.tar.gz with jakarta-tomcat-4.1.29, everything should be in the right place, but jsvc exits with java.lang.NoSuchMethodException: org.apache.catalina.startup.BootstrapService.init([Ljava.lang.String;) at java.lang.Class.getMethod1(Class.java:1888) at java.lang.Class.getMethod(Class.java:1056) at org.apache.commons.daemon.support.DaemonLoader.load(DaemonLoader.java:165) jsvc.exec error: Cannot load daemon jsvc.exec error: Service exit with a return value of 3 commons-daemon.jar and bootstrap.jar are available at the defined place. Does this release maybe only work with tomcat 5? Any help would be great! Regards Marten Regards Marten This message is intended only for the use of the person(s) listed above as the intended recipient(s), and may contain information that is PRIVILEGED and CONFIDENTIAL. If you are not an intended recipient, you may not read, copy, or distribute this message or any attachment. If you received this communication in error, please notify us immediately by e-mail and then delete all copies of this message and any attachments. In addition you should be aware that ordinary (unencrypted) e-mail sent through the Internet is not secure. Do not send confidential or sensitive information, such as social security numbers, account numbers, personal identification numbers and passwords, to us via ordinary (unencrypted) e-mail. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: anyone running tomcat-4.1.29 with commons-daemons?
Was there ever a resolution here? I'm getting exactly the same error using 4.1.x and the below linked Tomcat.sh script (modified to my paths). Thanks, +jeff Bill Barker wrote: I've been using commons-daemon happily with Tomcat 4.1.x for quite some time now. I'd suggest starting from http://cvs.apache.org/viewcvs/jakarta-commons/daemon/src/native/unix/native/Tomcat.sh?rev=1.1.1.1content-type=text/vnd.viewcvs-markup and modifying as nessary. - Original Message - From: Marten Lehmann [EMAIL PROTECTED] Newsgroups: gmane.comp.jakarta.tomcat.user Sent: Thursday, December 04, 2003 9:46 AM Subject: anyone running tomcat-4.1.29 with commons-daemons? Hello, I'm trying to use the commons-daemons package as of 20031204.tar.gz with jakarta-tomcat-4.1.29, everything should be in the right place, but jsvc exits with java.lang.NoSuchMethodException: org.apache.catalina.startup.BootstrapService.init([Ljava.lang.String;) at java.lang.Class.getMethod1(Class.java:1888) at java.lang.Class.getMethod(Class.java:1056) at org.apache.commons.daemon.support.DaemonLoader.load(DaemonLoader.java:165) jsvc.exec error: Cannot load daemon jsvc.exec error: Service exit with a return value of 3 commons-daemon.jar and bootstrap.jar are available at the defined place. Does this release maybe only work with tomcat 5? Any help would be great! Regards Marten Regards Marten This message is intended only for the use of the person(s) listed above as the intended recipient(s), and may contain information that is PRIVILEGED and CONFIDENTIAL. If you are not an intended recipient, you may not read, copy, or distribute this message or any attachment. If you received this communication in error, please notify us immediately by e-mail and then delete all copies of this message and any attachments. In addition you should be aware that ordinary (unencrypted) e-mail sent through the Internet is not secure. Do not send confidential or sensitive information, such as social security numbers, account numbers, personal identification numbers and passwords, to us via ordinary (unencrypted) e-mail. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError with Seemingly Plenty of Memory
A while back somebody mentioned that if you continuously redeploy a web application, the symptoms you are mentioning occur. This is because of all of the objects that are stored in the permanent generation memory. This permanent generation runs out of space, even though the new generation and old generation heaps still have room to grow. (The permanent generation's size is a fixed percentage of the total memory). I do not know if this is something that can or is fixed in the most recent builds and latest major version (5) of Tomcat. On NetWare, we have a view into the memory where we can see how big the perm gen is and what percentage of it is allocated. I do not know if such a thing exists on other platforms though. If it does, I certainly have not yet found it. Searching the archives (at http://marc.theaimsgroup.com ), it looks like it could have something to do with the classloader layout of your application: http://marc.theaimsgroup.com/?l=tomcat-userm=107046034505454w=2 Although the possibility of a memory leak (sorry--unintended object retention) has not been completely ruled out (yes, I'm running the applications through a profiler), I'm quite puzzled that this problem would occur when, by all indications, memory use is nowhere near the limit. Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError with Seemingly Plenty of Memory
Do you edit the web.xml of your web application? That will cause Tomcat to redeploy the application. We had an application that would do this during their installation (so, only one time really), but I can imagine an application that might be trying to dynamically deploy servlets and set their mappings in the web.xml. I'm guessing this is NOT your situation though, since you'd probably already be thinking along the lines of redeploys. [EMAIL PROTECTED] 1/27/04 10:52:34 AM Hmmm...we don't do hot deploys, but the different generations are definitely something to look at. Thanks! Dhruva --- Jeff Tulley [EMAIL PROTECTED] wrote: A while back somebody mentioned that if you continuously redeploy a web application, the symptoms you are mentioning occur. This is because of all of the objects that are stored in the permanent generation memory. This permanent generation runs out of space, even though the new generation and old generation heaps still have room to grow. (The permanent generation's size is a fixed percentage of the total memory). I do not know if this is something that can or is fixed in the most recent builds and latest major version (5) of Tomcat. On NetWare, we have a view into the memory where we can see how big the perm gen is and what percentage of it is allocated. I do not know if such a thing exists on other platforms though. If it does, I certainly have not yet found it. Searching the archives (at http://marc.theaimsgroup.com ), it looks like it could have something to do with the classloader layout of your application: http://marc.theaimsgroup.com/?l=tomcat-userm=107046034505454w=2 Although the possibility of a memory leak (sorry--unintended object retention) has not been completely ruled out (yes, I'm running the applications through a profiler), I'm quite puzzled that this problem would occur when, by all indications, memory use is nowhere near the limit. Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
jk_nt_service.exe
I am having a terrible time finding this file. I am currently using Tomcat version 4.1.29 and would like to set it up as an NT service. Any help locating this file would be greatly appreciated. Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk problem
Lukas, I haven't been following this thread too closelyso maybe I've missed some of your earlier explanation... If you are going through port 8080, there is no mod_jk or mod_jk2 involved, and the problem is probably elsewhere - for instance maybe your web application is not set up properly(wrong directory structure?), or there are file permission problems on your directories or your web.xml file. I have a coworker who had these type of file permission problems twice in the last few weeks, and it was not immediately obvious that this was the problem. Or maybe your web.xml is not valid. When you go back to using mod_jk, be aware that the command in apache for mod_jk is more like: JkMount /*.jsp ajp13 You do not embed this in a location tag necessarily. But get things working through port 8080 first before tackling Apache integration. Like you said you just want to get started with JSP without the battle. [EMAIL PROTECTED] 1/26/04 2:35:24 PM Ok, now I'm really getting confused, I put the test.jsp file in $CATALINE_HOME/webapps/test.jsp and when doing http://localhost:8080/test.jsp in links (can't open my 8080 port yet...) I get a file cannot be found message, but when I look at the example folder they show as they should. Anyone who knows what I'm doing wrong? Also when adding Location /*.jsp JkUriSet worker ajp13:localhost:8009 /Location to my http.conf file I got an error message that said that apache couldn't recongnixe JkUriSet. Is that because JkUriSet is only availabel in jk2 or??? ./Lukas - Original Message - From: Guy Rouillier [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, January 26, 2004 9:39 PM Subject: RE: mod_jk problem Lukas Larsson wrote: Thx for the reply. I folloes your second link and found this site (http://johnturner.com/howto/apache2-tomcat4127-jk-rh9-howto.h tml) on how to configure mod_jk but I still get the same problem. Apache says that it is working with mod_jk, but it does not translate *.jsp pages (see http://garazdawi.homeftp.net/test.jsp for an example of what I mean). Can someone please tell me what I'm doing wrong. I would really want to get started with jsp without having to battle with mod_jk. Make sure your Tomcat is set up properly by going directly to it for the JSP page, bypassing Apache, e.g., http://garazdawi.homeftp.net:8080/test.jsp (assuming you left Tomcat on the default HTTP port.) If that doesn't work, then the problem is in Tomcat configuration not in mod_jk. Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Apache/Tomcat Integration. Urgent!!
when the site is highly active. minIdleSwap: Sessions must be idle for at least this long (in seconds) before they will be swapped out due to activity. 0 means sessions will almost always be swapped out after use - this will be noticeably slow for your users. maxIdleSwap: Sessions will be swapped out if idle for this long (in seconds). If minIdleSwap is higher, then it will override this. This isn't exact: it is checked periodically. -1 means sessions won't be swapped out for this reason, although they may be swapped out for maxActiveSessions. If set to = 0, guarantees that all sessions found in the Store will be loaded on startup. maxIdleBackup: Sessions will be backed up (saved to the Store, but left in active memory) if idle for this long (in seconds), and all sessions found in the Store will be loaded on startup. If set to -1 sessions will not be backed up, 0 means they should be backed up shortly after being used. To clear sessions from the Store, set maxActiveSessions, maxIdleSwap, and minIdleBackup all to -1, saveOnRestart to false, then restart Catalina. -- !-- Manager className=org.apache.catalina.session.PersistentManager debug=0 saveOnRestart=true maxActiveSessions=-1 minIdleSwap=-1 maxIdleSwap=-1 maxIdleBackup=-1 Store className=org.apache.catalina.session.FileStore/ /Manager -- Environment name=maxExemptions type=java.lang.Integer value=15/ Parameter name=context.param.name value=context.param.value override=false/ Resource name=jdbc/EmployeeAppDb auth=SERVLET type=javax.sql.DataSource/ ResourceParams name=jdbc/EmployeeAppDb parameternameusername/namevaluesa/value/parameter parameternamepassword/namevalue/value/parameter parameternamedriverClassName/name valueorg.hsql.jdbcDriver/value/parameter parameternameurl/name valuejdbc:HypersonicSQL:database/value/parameter /ResourceParams Resource name=mail/Session auth=Container type=javax.mail.Session/ ResourceParams name=mail/Session parameter namemail.smtp.host/name valuelocalhost/value /parameter /ResourceParams ResourceLink name=linkToGlobalResource global=simpleValue type=java.lang.Integer/ /Context /Host /Engine /Service /Server __ Do you Yahoo!? Yahoo! SiteBuilder - Free web site building tool. Try it! http://webhosting.yahoo.com/ps/sb/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Apache/Tomcat Integration. Urgent!!
Your worker name does not match the name in the generated mod_jk.conf. That file wants the worker name to be ajp13, whereas yours is named testWorker. Change that and restart apache and see what happens. [EMAIL PROTECTED] 1/23/04 12:00:40 PM Hi, Thanks for the reply. The contents of the workers.properties are given below, which i copied of the net. worker.list=testWorker worker.testWorker.port=8009 worker.testWorker.host=localhost worker.testWorker.type=ajp13 - The contents of mod_jk.conf are given below. ## Auto generated on Fri Jan 23 12:20:23 EST 2004## IfModule !mod_jk.c LoadModule jk_module /opt/libexec/mod_jk.so /IfModule JkWorkersFile /home/tomcat4.1/conf/jk/workers.properties JkLogFile /home/tomcat4.1/logs/mod_jk.log JkLogLevel info VirtualHost localhost ServerName localhost JkMount /webdav ajp13 JkMount /webdav/* ajp13 JkMount /examples ajp13 JkMount /examples/* ajp13 JkMount /tomcat-docs ajp13 JkMount /tomcat-docs/* ajp13 JkMount /manager ajp13 JkMount /manager/* ajp13 /VirtualHost --- Jeff Tulley [EMAIL PROTECTED] wrote: What are the contents of your auto-generated mod_jk.conf, and how do they match the web application you are trying to access? Also, it would be helpful to post the (relevant) contents of your workers.properties file. [EMAIL PROTECTED] 1/23/04 11:05:42 AM Hi, I am trying to integrate Apache 1.3 and Tomcat 4.0 The apache logs shows that it has started with mod_jk and mod_ssl.However when i send a request for a webapplication it gives errors saying page not found. Apache log shows that it is trying to find the application under htdocs Following is the apache and tomcat configuration. Any help would be highly appreciated. Thanks in advance //excerpt from the tomcat LoadModule jk_module /opt/libexec/mod_jk.so AddModule mod_jk.c JkWorkersFile /home/tomcat4.1/conf/jk/workers.properties JkLogFile /home/tomcat4.1/logs/mod_jk.log JkLogLevel debug Include /home/tomcat4.1/conf/auto/mod_jk.conf //-Tomcat server.xml- Server port=8005 shutdown=SHUTDOWN debug=0 Listener className=org.apache.ajp.tomcat4.config.ApacheConfig modJk=opt/libexec/mod_jk.so jkDebug=info workersConfig=/home/tomcat4.1/conf/jk/workers.properties jkLog=/home/tomcat4.1/logs/mod_jk.log/ !-- Comment these entries out to disable JMX MBeans support -- !-- You may also configure custom components (e.g. Valves/Realms) by including your own mbean-descriptor file(s), and setting the descriptors attribute to point to a ';' seperated list of paths (in the ClassLoader sense) of files to add to the default list. e.g. descriptors=/com/myfirm/mypackage/mbean-descriptor.xml -- Listener className=org.apache.catalina.mbeans.ServerLifecycleListener debug=0/ Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener debug=0/ !-- Global JNDI resources -- GlobalNamingResources !-- Test entry for demonstration purposes -- Environment name=simpleValue type=java.lang.Integer value=30/ !-- Editable user database that can also be used by UserDatabaseRealm to authenticate users -- Resource name=UserDatabase auth=Container type=org.apache.catalina.UserDatabase description=User database that can be updated and saved /Resource ResourceParams name=UserDatabase parameter namefactory/name valueorg.apache.catalina.users.MemoryUserDatabaseFactory/value /parameter parameter namepathname/name valueconf/tomcat-users.xml/value /parameter /ResourceParams /GlobalNamingResources !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO
RE: ServletRequest's path elements not updated by calls to getRequestDispatcher()
I think the difference between those seeing the redirect and those who are not is what browser they are using. Some browsers add the trailing slash for you, some do not. I tried this on Windows NT 4, IE 6(does add the /), and on Galeon/Mozilla on SUSE Linux (no / added). Client side, not server side. That said, you CAN do server side redirects, by the methods mentioned already (mod_rewrite, etc) [EMAIL PROTECTED] 1/21/04 1:13:12 PM www.apple.com/ipodmini does a redirect to www.apple.com/ipodmini/, which is the same behavior you get from a webserver (I believe most of them, but definitely IIS) when requesting a directory without the trailing slash. (I seem to recall that Microsoft calls it a courtesy redirect.) If you can redirect these requests to the actual location of the page that's serving the request, your life will get easier when it comes to relative hrefs/srcs. Even if you want to hide the location of your JSP, which is not a bad idea, to live up to what apple does your page only has to work with one URL ... and the other one gets redirected to the one that works. -john. -Original Message- From: Alan Weissman [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 21, 2004 2:54 PM To: 'Tomcat Users List' Subject: RE: ServletRequest's path elements not updated by calls to getRequestDispatcher() Ok, so what was said about using img src=/foo.gif theoretically seems true, but in practice it does not work. And I don't have the ability to mandate a request.getContextPath() for every Link on the site. All I want to do is do what apple does if you go to www.apple.com/ipodmini or www.apple.com/ipodmini/ you get the same page. This shouldn't be that hard, but whats the best way to do it? Should I just start using Apache's mod_rewrite? Thanks again, Alan -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 21, 2004 2:42 PM To: Tomcat Users List Subject: RE: ServletRequest's path elements not updated by calls to getRequestDispatcher() Howdy, No, if you use img=/foo.gif then '/' ALWAYS indicates to the browser to request it from the domain root. Yeah, but you don't want to do that because what if the context path changes? A relative link would be better, and it's good that the original poster is already trying to do that, e.g. ../foo.gif. Consider using request.getContextPath() + /images/foo.gif. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat - Automatically writes a session?
Verify in your JSP's .java file that sessions are really being turned off. Look to see if there is a session=pageContext.getSession() Also, I think the call to pageContext = _jspxFactory.getPageContext(. Needs to have false as the 3rd to last argument. [EMAIL PROTECTED] 1/20/04 12:39:54 PM Neal wrote: I used the tag [EMAIL PROTECTED] session=false% which does appear correct, but I'm still seeing that header: Set-Cookie: JSESSIONID=97C8777F16379B8EC2CD17273CE35C3C; Path=/ There are two reasons why I want to get rid of this: 1. I assume I'm waiting server resources holding open a session for every user, unnecessarily. 2. I've been told this may prevent Google from properly spidering the site. Can you please shed any more light on how to fix this potential issue? Probably not, but I will try... Did you clear the cookies on your browser? If the browser is saying Hi! XXX is my session ID, then, (iif that session exists), tomcat is free of saying Hi! keep your session ID, which is XXX Other than that, no idea. I have never struggled to avoid cookies. Sorry. I was only echoing something I have read in the past. Antonio Fiol Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat - Automatically writes a session?
Yeah, I see the same thing. No jsessionId in the header. with %@ page session=false % [EMAIL PROTECTED] 1/20/04 3:31:31 PM Its on by default because the spec says so. Are you sure you don't have a filter or anything else creating a session? I created a page called cowbell with this content with tomcat 4.1: -- [EMAIL PROTECTED] session=false% foo -- Then simulated a web browser: -- [EMAIL PROTECTED]: telnet localhost 8080 Trying 127.0.0.1... Connected to fever.joedog.org. Escape character is '^]'. GET /cowbell.jsp HTTP/1.1 Host: fever.joedog.org:8080 Connection: close HTTP/1.1 200 OK Content-Type: text/html;charset=ISO-8859-1 Content-Length: 5 Date: Tue, 20 Jan 2004 22:28:20 GMT Server: Apache-Coyote/1.1 Connection: close foo Connection closed by foreign host. -- -Tim neal cabage wrote: Unfortunately this isn't working either. In addition to the [EMAIL PROTECTED] session=false% directive in my JSP, I have also set the cookies=false attribute in my server.xml file, for the host in question. It is *still* happening! Perhaps this is a Tomcat bug, as previously suggested? Correct me if I'm wrong, but doesn't this imply a *HUGE* waist of RAM resources to be writing a cookie like this by default? Why on earth would a web app do this by default? Are there any other ways to shut it off? It was mentioned in the previous thread to look at the servlet being compiled, which may be a good idea - but I don't know what the solution will be if it is in fact compiling the servlet incorrectly. Any other config opps to choke it off? Neal Torsten Fohrer [EMAIL PROTECTED] wrote: tomcat sents automatically a cookie named jsessionid for session maintain to a browser. with cookies=false as a context attrribute you disable this behaviour from tomcat documentation: -- cookies Set to true if you want cookies to be used for session identifier communication if supported by the client (this is the default). Set to false if you want to disable the use of cookies for session identifier communication, and rely only on URL rewriting by the application. or http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/context.html cu Torsten Fohrer On Tuesday 20 January 2004 20:58, you wrote: Verify in your JSP's .java file that sessions are really being turned off. Look to see if there is a session=pageContext.getSession() Also, I think the call to pageContext = _jspxFactory.getPageContext(. Needs to have false as the 3rd to last argument. [EMAIL PROTECTED] 1/20/04 12:39:54 PM Neal wrote: I used the tag which does appear correct, but I'm still seeing that header: Set-Cookie: JSESSIONID=97C8777F16379B8EC2CD17273CE35C3C; Path=/ There are two reasons why I want to get rid of this: 1. I assume I'm waiting server resources holding open a session for every user, unnecessarily. 2. I've been told this may prevent Google from properly spidering the site. Can you please shed any more light on how to fix this potential issue? Probably not, but I will try... Did you clear the cookies on your browser? If the browser is saying Hi! XXX is my session ID, then, (iif that session exists), tomcat is free of saying Hi! keep your session ID, which is XXX Other than that, no idea. I have never struggled to avoid cookies. Sorry. I was only echoing something I have read in the past. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problems with jk2 on IIS 5.0 and Tomcat 4.0
On Fri, 16 Jan 2004 15:54:00 EST Rasmus Munk [EMAIL PROTECTED] wrote: HttpFilterProc [/camping_lars/servlet/camping.XMLServer.Server] is a servlet url - should redirect to ajp13:localhost:8009 HttpFilterProc check if [/camping_lars/servlet/camping.XMLServer.Server] is pointing to the web-inf directory HttpFilterProc started In HttpFilterProc Virtual Host redirection of localhost : 80 HttpFilterProc [/jakarta/isapi_redirector2.dll] is not a servlet url HttpFilterProc check if [/jakarta/isapi_redirector2.dll] is pointing to the web-inf directory HttpExtensionProc started HttpExtensionProc could not get a worker for name HttpExtensionProc worker is NULL I just recently spent a few days struggling with this 1. Did you setup the /jakarta/ virtual dir properly (pointing it to the dir that has isapi_redirector2.dll? 2. Did you install isapi_redirector2.dll at the server or site level? I found on w2k sp4 that I had to install it at the SITE level... Oddly it worked fine at the server level on sp2. If I get some time I'll investigate more. Good luck! -- Jeff Trout [EMAIL PROTECTED] Global Engineering / Terra Lycos - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Adjust Memory Settings
Hello all, I need to be able to adjust the memory settings for Tomcat as it runs on Win2003 as a service. In previous versions, I was able to modify the wrapper.properties file to something like this: wrapper.cmd_line=$(wrapper.javabin) -Djava.security.policy==$(wrapper.tomcat_policy) -Dtomcat.home=$(wrapper.tomcat_home) -Xmx384m -classpath $(wrapper.class_path) $(wrapper.startup_class) -config $(wrapper.server_xml) start Which would then allow 384mb for applications. In Tomcat 5 -- since it installs as a service automatically -- I'm unable to find where I can change this. Can someone point me in the right direction? Thanks in advance, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Adjust Memory Settings
I think I found the answer (in case anyone else wants to know). In the registry, find: HKLM\Software\apache software foundation\tomcat service manager\tomcat5\parameters And edit JavaOptions. This is where the command line parameters are stored. Does anyone know of a different/better way? This seems fairly simple and straightforward to me, but I would like to know if others have a better way of doing it. Jeff -Original Message- From: Jeff Greenland Sent: Monday, January 19, 2004 5:13 PM To: [EMAIL PROTECTED] Subject: Adjust Memory Settings Hello all, I need to be able to adjust the memory settings for Tomcat as it runs on Win2003 as a service. In previous versions, I was able to modify the wrapper.properties file to something like this: wrapper.cmd_line=$(wrapper.javabin) -Djava.security.policy==$(wrapper.tomcat_policy) -Dtomcat.home=$(wrapper.tomcat_home) -Xmx384m -classpath $(wrapper.class_path) $(wrapper.startup_class) -config $(wrapper.server_xml) start Which would then allow 384mb for applications. In Tomcat 5 -- since it installs as a service automatically -- I'm unable to find where I can change this. Can someone point me in the right direction? Thanks in advance, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Mozilla showing JSP source code
I'm sure this doesn't help, but we had the same problem with the 3.x series. It went away when we upgraded to 4.x and 5.x. Good luck, Jeff -Original Message- From: Guy Rouillier [mailto:[EMAIL PROTECTED] Sent: Monday, January 19, 2004 5:36 PM To: Tomcat Users List Subject: Mozilla showing JSP source code I've tried to do due diligence on this issue, searching the archives as well as Google. I'm sure it is a common problem, but I found several questions and no definitive responses, so here goes. Our website works fine with IE, but we're having a significant problem with Mozilla (and derivatives like Galeon). I've tried various versions, including 1.5 as well as the brand new 1.6. I'm seeing this problem both from a Windows XP/2000 host and a Solaris host. I've tried Mozilla both on Windows XP clients and Mandrake Linux 9.2 i586 clients. All exhibit the same behavior. As the title says, when using Mozilla, I'll frequently see source code in the browser window. If I hit reload, in most cases, I'll see the page properly displayed (99% of the time - rarely, I'll see the source again.) We are still using Apache 1.3.27, Tomcat 3.2.3 and mod_jk 1.2.4. Here, for example, is one I can produce very regularly: === HTTP/1.1 200 Date: Tue, 20 Jan 2004 00:14:25 GMT Server: Apache/1.3.26 (Unix) mod_jk mod_ssl/2.8.9 OpenSSL/0.9.6c Keep-Alive: timeout=15, max=99 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/html;charset=ISO-8859-1 1172 html === I'm still working on getting Tomcat 5.0.19 configured with JK2, in the hopes this will magically go away, but I've having problems getting JK2 configured properly. Here are some things I've tried or noticed: (1) I first tried going directly to Tomcat, bypassing Apache (using :8080) and this works. All our pages are displayed in Mozilla without any problem. That leads me to conclude that the problem is either in Tomcat delivering the pages to Apache via mod_jk, or in Apache delivering the pages to the browser. The first seems more likely. (2) We specify no buffer clause on our page directive. On some pages, specifying buffer=64kb seems to work. Frustratingly, this solution seems to work on some pages but not others, and on some systems and not others for the same page. (3) I also tried changing the KeepAliveTimeout in Apache httpd.conf. The default value is 15. As a test, I upped it to 150. Again, this solved the problem on some pages on some clients, but not reliably or predictably. It also caused Mozilla to spin its wheels for about the whole 2 1/2 minutes. (4) The most reliable way to see this fail is via a redirect. This happens most frequently on the secure half of our website (https). On those pages, we have an authentication header at the top of each page: %@ include file=/includes/authenheader.jspf % Inside this file, we check some session variables, and if they don't have the right set of values (or those values don't exist) we response.sendRedirect() to a login page. During this redirect, I *always* see the source for the login page - the login page has not come up cleanly one time. This page is very small, and neither the buffer or timeout changes help. If anyone has any ideas on how to address this problem, I'm willing to try anything. I really am out of ideas and don't know where to go next. Thanks for any help. -- Guy Rouillier - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 4 IIS5 - HTTPExtensionProc not getting the filter's added headers
] [jk_isapi_plugin.c (765)]: In HttpFilterProc test Default redirection of /jakarta/isapi_redirect.dll [Fri Jan 16 08:16:22 2004] [jk_uri_worker_map.c (460)]: Into jk_uri_worker_map_t::map_uri_to_worker [Fri Jan 16 08:16:22 2004] [jk_uri_worker_map.c (477)]: Attempting to map URI'/jakarta/isapi_redirect.dll [Fri Jan 16 08:16:22 2004] [jk_uri_worker_map.c (599)]: jk_uri_worker_map_t::map_uri_to_worker, done without a match [Fri Jan 16 08:16:22 2004] [jk_isapi_plugin.c (829)]: HttpFilterProc [/jakarta/isapi_redirect.dll] is not a servlet url Interesting, why is not treating isapi_redirect as an executable.. I found the answer to that by trying out jk2 which reported [after HTTPFilterProc decided this was a servlet request]: [Thu Jan 15 09:33:46 2004] (debug ) [jk_isapi_plugin.c (473)] HttpExtensionProc started [Thu Jan 15 09:33:46 2004] (debug )[jk_isapi_plugin.c (482)] HttpExtensionProc could not get a worker for name [Thu Jan 15 09:33:46 2004] (error ) [jk_isapi_plugin.c (488)] HttpExtensionProc worker is NULL So then I changed extension_uri to my little HTTP header asp I mentioned earlier and those Tomcat headers were non existant, which is likely the cause of my problems... There are also no errors dumped out by the filter, like setheader failed.. Any ideas / suggestions? I just saw a post about the jk2 installer, so I tried that - same thing happens. I'm thinking there is some obscure IIS thing. -- Jeff Trout [EMAIL PROTECTED] Global Engineering / Terra Lycos - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 4 IIS5 - HTTPExtensionProc not getting the filter's added headers
On Fri, 16 Jan 2004 09:28:00 EST Jeff Trout [EMAIL PROTECTED] wrote: Note: After much more tinkering I discovered this problem goes away if you install the isapi_redirect.dll at the site level, not server. Still quite odd that on machine a it worked fine on the server level. Maybe something for the FAQ / HOWTO? -- Jeff Trout [EMAIL PROTECTED] Global Engineering / Terra Lycos - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT] Apache and Tomcat together
I always think of the security of Apache not in terms of features provided, but number of eyeballs scrutinizing. Apache is SO widely used that I would think it is safe to say that exploits would be found sooner. Not enough people using Tomcat use the built-in HTTP stack, and so I wouldn't rely on it being completely exploit free (though our confidence level is pretty high, of course). [EMAIL PROTECTED] 1/14/04 3:42:00 AM achana mentioned security. Well, Apache has more HTTP Authentication modules than Tomcat does (although JDBC realm can go against any DB). We dons't have Kerberos HTTP Auth (SPNEGO authentication method), which comes in handy with the deployment of Microsoft's Active Directory. Nix. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: white pages in tomcat 4.1.24
I know that there is the possibility of JSPs being returned as a blank page, if it was unable to create a session. I have only seen this in doing high-load (like typically unrealistically high) testing. Maybe you are hitting that. Of course, that wouldn't match the behavior you are seeing of being able to access non-existing pages. It is something to check though. [EMAIL PROTECTED] 01/14/04 01:54PM Well, unfortunately their is no additional information. The webapp just delivers white pages. No log entry. normally our servlets logs every hit, but not after the crash. You can access any page you like also noexistent ones and there is no error message, just a white page. We have this problem just on the machine with 24 webapps. And the problem appeared first after we have installed 4 or 5 new webapps. Other machines with similar load and size, but less webapps never had this problem. All our webapps run absolutely the same code. We don't have unshared classes or libs. When we used mod_webapp and an application crashed, the same webapp was still accessible via http connector. It is not like that anymore since we use mod_jk2. -Thomas -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Mittwoch, 14. Januar 2004 14:45 To: Tomcat Users List Subject: RE: white pages in tomcat 4.1.24 Howdy, A webapp crashes. Has anyone experienced the same? Sure. What was the solution? Depends on why it crashed. You will need to provide more information in order to get more help, starting with the content of the tomcat logs when your webapp crashes ;) Yoav Shapira Millennium ChemInformatics -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 14, 2004 7:36 AM To: [EMAIL PROTECTED] Subject: white pages in tomcat 4.1.24 Hello, we are using tomcat 4.1.24 apache 1.3.29 and the most recent mod_jk2 on solaris 8. There are 24 webapps running. From time to time a webapp crashes and delivers just no-content-pages from then on. All other webapps continue running correctly. Does anyone have experienced the same? What was the solution? We had the same problem before when we used mod_webapp. Since mod_webapp is deprecated, we moved to mod_jk2 instead of posting the problem in the mail list. But it was not the solution. Thanks, Thomas Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Making index.jsp work as welcome page after upgrade
What is your apache configuration, the JkMount statements and the like? It seems like there could be a problem there and the request is never getting to Tomcat for some reason [EMAIL PROTECTED] 1/7/04 2:55:41 PM I don't quite understand. I have the 8080 connector commented out since we don't want to use Tomcat as standalone. I was able to disable everything else and get Tomcat up and running standalone to verify that it worked, and it does. I just run into problems as I try to connect up to Apache. -Original Message- From: Andres Ledesma [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 07, 2004 5:00 PM To: Tomcat Users List Subject: Re: Making index.jsp work as welcome page after upgrade I was following this thread, And it occurs to me that instead of comment the port:8080 line, write port:80 give it a try !! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: what *really* happens when you reload or stop/start a webapp?
No, this is just an example. What I'd like to know is if stop/start or reload has the same effect on a webapp as actually shutting down tomcat and starting it back up. +jeff QM wrote: : would everything get dumped and reset -- would that static variable go : back to it's original state when the class file is first loaded? : : I should probably be asking a more specific question about classloaders : and sandboxes and whatnot, but I'm not sure how this stuff works in : tomcat and I'm not familiar w/ classloaders beyond their basic operation. I'm not familiar with how the manager app reloads apps, but you could perform an experiment to find out: If you already have such a static var in question, write a quick JSP that prints that value to screen. Fire up your app, hit this JSP (to catch the initial/default value). Call the servlet/whatever that changes that value. Next, reload Tomcat using the manager app. Hit the JSP again (make sure to force a reload in your browser). Compare the printed value to the original/default. Also, is there any reason you require this to be a static variable? -QM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Classes cannot be found
Having problems with Tomcat finding classes. This seems simple, maybe someone can see where I'm overlooking something. I have in my /webapps/WEB-INF/classes/ folder this file: --- SitePage.class --- In my /webapps/ folder, I have a file site.jsp that starts like this: --- %@ page import=java.util.* % % SitePage thisPage = new SitePage(request, response); ... % --- However, whenever I hit this page, I get this compilation error: --- org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 5 in the jsp file: /site.jsp Generated servlet error: [javac] Compiling 1 source file D:\Jakarta5\work\Catalina\166.70.225.99\_\org\apache\jsp\site_jsp.java:4 8: cannot resolve symbol symbol : class SitePage location: class org.apache.jsp.site_jsp SitePage thisPage = new SitePage(request, response); ^ --- My log file for this web application shows: --- SEVERE: Env: Compile: javaFileName=/D:/Jakarta5/work/Catalina/166.70.225.99/_//org/apache/jsp\ site_jsp.java classpath=/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPDe stinations/webapps/WEB-INF/lib/nfc.jar;D:\Jakarta5\work\Catalina\166.70. 225.99\_;/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPDes tinations/webapps/WEB-INF/lib/nfc.jar;D:/Jakarta5/shared/classes/; (etc., etc.,) cp=D:\Jakarta5\bin\bootstrap.jar cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\work\Catalina\166.70.225.99\_ cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\shared\classes (etc., etc.,) --- Why can't this find the SitePage class? The classpath is correct in the logs, the file is in the WEB-INF/classes folder, it's not in a package or anything. Anyone have any ideas? I've spent days on this and still no luck. Is it a bug? What can I try to troubleshoot? I feel like I've exhausted my troubleshooting options thus far. Thanks in advance for everyone's help, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Classes cannot be found
Thanks, I'll go through and see if anything in here gives me some hints. However, I'm not getting ClassNotFound exceptions -- my files are not even compiling because the compiler Cannot Resolve Symbol. My problem lies in that the compiler (jasper) cannot find my compiled classes, even though the logs seem to show that they are in the classpath. -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 30, 2003 11:00 AM To: Tomcat Users List Subject: RE: Classes cannot be found Howdy, http://jakarta.apache.org/tomcat/faq/classnotfound.html Yoav Shapira Millennium ChemInformatics -Original Message- From: Jeff Greenland [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 30, 2003 12:59 PM To: Tomcat Users List Subject: Classes cannot be found Having problems with Tomcat finding classes. This seems simple, maybe someone can see where I'm overlooking something. I have in my /webapps/WEB-INF/classes/ folder this file: --- SitePage.class --- In my /webapps/ folder, I have a file site.jsp that starts like this: --- %@ page import=java.util.* % % SitePage thisPage = new SitePage(request, response); ... % --- However, whenever I hit this page, I get this compilation error: --- org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 5 in the jsp file: /site.jsp Generated servlet error: [javac] Compiling 1 source file D:\Jakarta5\work\Catalina\166.70.225.99\_\org\apache\jsp\site_jsp.java: 4 8: cannot resolve symbol symbol : class SitePage location: class org.apache.jsp.site_jsp SitePage thisPage = new SitePage(request, response); ^ --- My log file for this web application shows: --- SEVERE: Env: Compile: javaFileName=/D:/Jakarta5/work/Catalina/166.70.225.99/_//org/apache/jsp \ site_jsp.java classpath=/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPD e stinations/webapps/WEB-INF/lib/nfc.jar;D:\Jakarta5\work\Catalina\166.70 . 225.99\_;/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPDe s tinations/webapps/WEB-INF/lib/nfc.jar;D:/Jakarta5/shared/classes/; (etc., etc.,) cp=D:\Jakarta5\bin\bootstrap.jar cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\work\Catalina\166.70.225.99\_ cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\shared\classes (etc., etc.,) --- Why can't this find the SitePage class? The classpath is correct in the logs, the file is in the WEB-INF/classes folder, it's not in a package or anything. Anyone have any ideas? I've spent days on this and still no luck. Is it a bug? What can I try to troubleshoot? I feel like I've exhausted my troubleshooting options thus far. Thanks in advance for everyone's help, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Classes cannot be found
Oh, and I might add that everything worked fine in Tomcat 3 and Tomcat 4. Could it be configuration related in server.xml (or web.xml) in that I'm not specifying the context correctly? The server is able to run JSP files fine it seems, I just can't use any external classes. Thanks again, Jeff -Original Message- From: Jeff Greenland Sent: Tuesday, December 30, 2003 11:05 AM To: Tomcat Users List Subject: RE: Classes cannot be found Thanks, I'll go through and see if anything in here gives me some hints. However, I'm not getting ClassNotFound exceptions -- my files are not even compiling because the compiler Cannot Resolve Symbol. My problem lies in that the compiler (jasper) cannot find my compiled classes, even though the logs seem to show that they are in the classpath. -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 30, 2003 11:00 AM To: Tomcat Users List Subject: RE: Classes cannot be found Howdy, http://jakarta.apache.org/tomcat/faq/classnotfound.html Yoav Shapira Millennium ChemInformatics -Original Message- From: Jeff Greenland [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 30, 2003 12:59 PM To: Tomcat Users List Subject: Classes cannot be found Having problems with Tomcat finding classes. This seems simple, maybe someone can see where I'm overlooking something. I have in my /webapps/WEB-INF/classes/ folder this file: --- SitePage.class --- In my /webapps/ folder, I have a file site.jsp that starts like this: --- %@ page import=java.util.* % % SitePage thisPage = new SitePage(request, response); ... % --- However, whenever I hit this page, I get this compilation error: --- org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 5 in the jsp file: /site.jsp Generated servlet error: [javac] Compiling 1 source file D:\Jakarta5\work\Catalina\166.70.225.99\_\org\apache\jsp\site_jsp.java: 4 8: cannot resolve symbol symbol : class SitePage location: class org.apache.jsp.site_jsp SitePage thisPage = new SitePage(request, response); ^ --- My log file for this web application shows: --- SEVERE: Env: Compile: javaFileName=/D:/Jakarta5/work/Catalina/166.70.225.99/_//org/apache/jsp \ site_jsp.java classpath=/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPD e stinations/webapps/WEB-INF/lib/nfc.jar;D:\Jakarta5\work\Catalina\166.70 . 225.99\_;/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPDe s tinations/webapps/WEB-INF/lib/nfc.jar;D:/Jakarta5/shared/classes/; (etc., etc.,) cp=D:\Jakarta5\bin\bootstrap.jar cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\work\Catalina\166.70.225.99\_ cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\shared\classes (etc., etc.,) --- Why can't this find the SitePage class? The classpath is correct in the logs, the file is in the WEB-INF/classes folder, it's not in a package or anything. Anyone have any ideas? I've spent days on this and still no luck. Is it a bug? What can I try to troubleshoot? I feel like I've exhausted my troubleshooting options thus far. Thanks in advance for everyone's help, Jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Classes cannot be found
I think I've found out the same thing from the stuff I've read. I might have to stick with Tomcat 4 in order to keep our server working (and live with the crashes). I know it sounds simple to move everything into a package, but when I do that, I lose all of my serialized objects. Our original classes never had packages (from several years ago), and they've just not been modified. The problem with packaging them is that I lose all of my customers' data that has been serialized over the past many years. Does anyone know a way around the serialization problem? If there's an easy solution, I would jump on moving all of our classes into a package immediately -- something we've been wanting to do for a few years. Thanks for the help everyone, hopefully someone has a deserialization solution as well! Jeff -Original Message- From: Ben Souther [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 30, 2003 11:13 AM To: Tomcat Users List Subject: Re: Classes cannot be found Someone else correct me if I'm wrong but I belive that classes are now requried to be packages. On Tuesday 30 December 2003 01:10 pm, Jeff Greenland wrote: Oh, and I might add that everything worked fine in Tomcat 3 and Tomcat 4. Could it be configuration related in server.xml (or web.xml) in that I'm not specifying the context correctly? The server is able to run JSP files fine it seems, I just can't use any external classes. Thanks again, Jeff -Original Message- From: Jeff Greenland Sent: Tuesday, December 30, 2003 11:05 AM To: Tomcat Users List Subject: RE: Classes cannot be found Thanks, I'll go through and see if anything in here gives me some hints. However, I'm not getting ClassNotFound exceptions -- my files are not even compiling because the compiler Cannot Resolve Symbol. My problem lies in that the compiler (jasper) cannot find my compiled classes, even though the logs seem to show that they are in the classpath. -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 30, 2003 11:00 AM To: Tomcat Users List Subject: RE: Classes cannot be found Howdy, http://jakarta.apache.org/tomcat/faq/classnotfound.html Yoav Shapira Millennium ChemInformatics -Original Message- From: Jeff Greenland [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 30, 2003 12:59 PM To: Tomcat Users List Subject: Classes cannot be found Having problems with Tomcat finding classes. This seems simple, maybe someone can see where I'm overlooking something. I have in my /webapps/WEB-INF/classes/ folder this file: --- SitePage.class --- In my /webapps/ folder, I have a file site.jsp that starts like this: --- %@ page import=java.util.* % % SitePage thisPage = new SitePage(request, response); ... % --- However, whenever I hit this page, I get this compilation error: --- org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 5 in the jsp file: /site.jsp Generated servlet error: [javac] Compiling 1 source file D:\Jakarta5\work\Catalina\166.70.225.99\_\org\apache\jsp\site_jsp.java: 4 8: cannot resolve symbol symbol : class SitePage location: class org.apache.jsp.site_jsp SitePage thisPage = new SitePage(request, response); ^ --- My log file for this web application shows: --- SEVERE: Env: Compile: javaFileName=/D:/Jakarta5/work/Catalina/166.70.225.99/_//org/apache/jsp \ site_jsp.java classpath=/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPD e stinations/webapps/WEB-INF/lib/nfc.jar;D:\Jakarta5\work\Catalina\166.70 . 225.99\_;/D:/Web/VIPDestinations/webapps/WEB-INF/classes/;/D:/Web/VIPDe s tinations/webapps/WEB-INF/lib/nfc.jar;D:/Jakarta5/shared/classes/; (etc., etc.,) cp=D:\Jakarta5\bin\bootstrap.jar cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\work\Catalina\166.70.225.99\_ cp=D:\Web\VIPDestinations\webapps\WEB-INF\classes cp=D:\Web\VIPDestinations\webapps\WEB-INF\lib\nfc.jar cp=D:\Jakarta5\shared\classes (etc., etc.,) --- Why can't this find the SitePage class? The classpath is correct in the logs, the file is in the WEB-INF/classes folder, it's not in a package or anything. Anyone have any ideas? I've spent days on this and still no luck. Is it a bug? What can
what *really* happens when you reload or stop/start a webapp?
I've got a web services application that I'm running w/ axis in Tomcat. According to the howtos for the manager stopping or reloading a webapp will make it unavailable and it will search for new files to load, specifically mentioning .class and .jar files. But does it go further? A more specific question: If I 1) had a jar in my webapp that had a class with a static field 2) set that static field to some value via interacting with my webapp 3) did a stop/start or reload would everything get dumped and reset -- would that static variable go back to it's original state when the class file is first loaded? I should probably be asking a more specific question about classloaders and sandboxes and whatnot, but I'm not sure how this stuff works in tomcat and I'm not familiar w/ classloaders beyond their basic operation. thanks, +jeff - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5 and class importing problems
Hello all, sorry this is long, but it takes time to explain, I'm having a frustrating issue with JSP files and trying to import our custom classes. Originally the classes were developed when Tomcat 3 was out and being used, so putting all of our compiled (*.class) files into webapps\WEB-INF\classes worked fine -- the JSPs all ran and could see import the classes just dandy. When we upgraded to Tomcat 4, the classes were no longer visible. After some research and testing, we found that placing a: %@ page import=MyClass % At the top of each JSP file solved the problem. Kinda cumbersome to add that for every class that we used, but it worked. Now we are attempting to upgrade to Tomcat 5 and are again having class loading issues. The import line is causing the following error: D:\Jakarta5\work\Catalina\166.70.225.99\_\org\apache\jsp\site_jsp.java:8 : '.' expected import MyClass; Obviously the compiler is expecting a package name in order to import external classes (which I realize is probably a function of javac, not of tomcat). The first thing I did was to convert our entire class library to packages (it originally wasn't when it was developed several years ago). I then copied these classes to the WEB-INF\classes folder and the application began running. However, the next problem arose when some of our code was doing dynamic class instantiation (using Class.forName()) since all of the class names had changed. So, of course, I fixed that throughout the code, which brought me to my present position: serialization. Many of our classes contain state information which we serialize to a database. However, now that all of the class names have changed, we cannot deserialize any of our existing objects because the class names don't match (ClassCastException is what's being thrown, if I remember right). Realizing that we cannot lose our serialized objects (since they contain all of our customers' data), I have been looking into other options. Some of the things I have tried are putting the class files (the original -- before repackaging them) into JAR files, changing the scratch directory for compilation in hopes that the compiler will find our classes, and moving classes into various folders to see if they can be found. So, now that I've spoke my novel, here's my question: Is there a way I can simply allow Tomcat to import *.class from webapps\WEB-INF\classes\ and have them all available to my JSP (like it used to work in Tomcat 3)? The problem is simple -- I need my non-packaged classes to be available to my .JSP files. Yes, I realize that we should have the files all in the same package from the beginning, but we don't. Our hope is that finding a solution that will make it work will cost us less time/money than rebuilding all of the serialized objects in our customers' databases (which I haven't thought of a good way to do that yet, either). Any help or suggestions that anyone has is GREATLY appreciated. I've been fairly impressed with the Jakarta community as I've used the products over the past several years. Thanks in advance, Jeff P.S. Theoretically it shouldn't make a difference, but this is being deployed on a Windows Server 2003 machine. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: IIS6 connection toTomcat on Win 2003 Server
It *looks* like the guide you followed did not include the changes to web service extensions to allow the ISAPI application to run. In the IIS manager, click on the Web Service Extensions folder. On the right side, click on the Add a new Web service extension link. Type in any Extension name you want (I used Jakarta-Tomcat), then click the Add button and add the isapi_redirect2.dll file. Then check the Set extension status to Allowed box at the bottom and click OK. You'll have to restart IIS (right click on your computer name in the IIS Manager, then click All Tasks -- Restart IIS) before it'll take effect. Give that a shot! Jeff -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, December 29, 2003 4:56 PM To: [EMAIL PROTECTED] Subject: IIS6 connection toTomcat on Win 2003 Server Greetings. Windows 2003 server running IIS 6.0. (IIS 5.0 isolation mode) j2sdk1.4.2_03 Jakarta Tomcat 5.0.16 isapi_redirector2.dll New to Java and I did fry finding answers before subscribing. When I found http://www.rit.edu/~ack5504/tomcat-iis6-howto/narantugs-sengee-guide.htm l I really thought I'd made it. IIS is serving pages normal with the WWW service in IIS 5.0 isolation mode. Virtual dir for the dll is configured. Web Service extensions status for the dll is set to allow the dll. Registry contains the required reg entrys per www.rit.edu Tomcat is working fine on the url/:8080. jsp and servlets all work on 8080. server.xml http://localhost/examples/index.html or serverdrive:\inetpub\wwwroot\examples\index.html displays ok. When one of the example links is selected I get The page cannot be displayed error message. Expected to receive a tomcat error msg. It was the regular MS error page.. Have been thru the server.xml and workers2.properties several times. What else can I do? Any ideas would really be appreciated. Thanks Happy New Year Stew - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: IIS6 connection toTomcat on Win 2003 Server
This is a good resource that I've found: http://virtualict.net/support/kb/iis6-Tomcat5-JK2.html Not sure if it'll help you out or not, but it's worth a shot. Jeff -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, December 29, 2003 7:17 PM To: Tomcat Users List Subject: RE: IIS6 connection toTomcat on Win 2003 Server isapi_redirect2.dll is/was added/in the Web Service Extensions. My gut feeling is its something in the server.xml, workers2.properties, jk2.properties or some other file(s) I may have left out.. Where does the web.xml fall in to all of this? Web, tomcat and java directories have read execute permissions for the IUSR user. Is there any reason to bump that up to write create? Log files seem to be getting updated ok and there isn't any scarie log entries that point to any thing. Really appreciate your help and getting back. Thanks. It *looks* like the guide you followed did not include the changes to web service extensions to allow the ISAPI application to run. In the IIS manager, click on the Web Service Extensions folder. On the right side, click on the Add a new Web service extension link. Type in any Extension name you want (I used Jakarta-Tomcat), then click the Add button and add the isapi_redirect2.dll file. Then check the Set extension status to Allowed box at the bottom and click OK. You'll have to restart IIS (right click on your computer name in the IIS Manager, then click All Tasks -- Restart IIS) before it'll take effect. Give that a shot! Jeff -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, December 29, 2003 4:56 PM To: [EMAIL PROTECTED] Subject: IIS6 connection toTomcat on Win 2003 Server Greetings. Windows 2003 server running IIS 6.0. (IIS 5.0 isolation mode) j2sdk1.4.2_03 Jakarta Tomcat 5.0.16 isapi_redirector2.dll New to Java and I did fry finding answers before subscribing. When I found http://www.rit.edu/~ack5504/tomcat-iis6-howto/narantugs-sengee-guide.h tm l I really thought I'd made it. IIS is serving pages normal with the WWW service in IIS 5.0 isolation mode. Virtual dir for the dll is configured. Web Service extensions status for the dll is set to allow the dll. Registry contains the required reg entrys per www.rit.edu Tomcat is working fine on the url/:8080. jsp and servlets all work on 8080. server.xml http://localhost/examples/index.html or serverdrive:\inetpub\wwwroot\examples\index.html displays ok. When one of the example links is selected I get The page cannot be displayed error message. Expected to receive a tomcat error msg. It was the regular MS error page.. Have been thru the server.xml and workers2.properties several times. What else can I do? Any ideas would really be appreciated. Thanks Happy New Year Stew - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Urgent! Tomcat4 closed giving Out of Memory Error
Look at the open files - it is 9182. That IS already pretty high, but you may be hitting that limit since in Unix, everything is a file. Sockets, etc. On Linux, is there a way in the JVM to tell the difference between memory given to the new generation, old generation, and permanent generation in the JVM? There were users on this list posting weird OutOfMemory errors last week that were doing class reloading, and the permanent generation was filling up even though there was plenty of space in the old and new gen. Of course, I think these comments only apply to a 1.4.x JVM. Does your code do funky stuff with the classloaders, or are you reloading your application in Tomcat's manager? (or changing web.xml, which would cause reloads??) Have you profiled your application to find any memory leaks? [EMAIL PROTECTED] 12/6/03 11:45:27 AM I am using Linux2.4.20-smp. I think the limits for the entire system are not problem: cat /proc/sys/kernel/threads-max 14336 cat /proc/sys/fs/file-max 209708 cat /proc/sys/fs/file-nr 22311366209708 ulimit -a core file size(blocks, -c) 0 data seg size (kbytes, -d) unlimited file size (blocks, -f) unlimited max locked memory (kbytes, -l) unlimited max memory size (kbytes, -m) unlimited open files(-n) 9182 pipe size (512 bytes, -p) 8 stack size(kbytes, -s) 8192 cpu time (seconds, -t) unlimited max user processes(-u) 7168 virtual memory(kbytes, -v) unlimited But I can't find where the limits for each process/user are. One message found from google said PTHREAD_THREADS_MAX could be the max thread count per process. In my /usr/include/bits/local_lim.h, I have /* The number of threads per process. */ #define _POSIX_THREAD_THREADS_MAX 64 /* This is the value this implementation supports. */ #define PTHREAD_THREADS_MAX 16384 16384 is large enough, I believe. Then what could be the reason of the error? By the way, the Out of Memory error didn't appear all the time. Sometimes there was just no response without any error message. Do you know where I can get more detailed bug files? Thank you very much. Qi On Sat, 6 Dec 2003, Tim Funk wrote: When you get java.lang.OutOfMemoryError: unable to create new native thread it means you are running into an operating system limit. You can give the JVM 1 Exabyte of memory and you'll still get this error. Look at the kernel parameters for your machine and the following limits: 1) Threads allowable on the system 2) Threads run by a user 3) Threads run by a process 4) File handles per process 5) File handles per user Use your OS manual or Google to tweak these parameters. http://jakarta.apache.org/tomcat/faq/memory.html#why -Tim qi zhang wrote: Hi, I have stunk on this problem for almost 2 weeks. :-( In these two weeks, I have tried many methods, but it still doesn't work. I built a system to run TPCW benchmark. One web and application server, with tomcat4.0 running, one database with mysql4.0 running on it and several client machines. The Jave version is j2sdk1.4.0_03. The system worked perfect under light load. But when the number of clients exceeded some number (like 600), the tomcat4 didn't work anymore. I checked catalina.out. Sometimes no error message appear, while in some time it appeared the error: SEVERE: Caught exception executing [EMAIL PROTECTED], terminating thread java.lang.OutOfMemoryError: unable to create new native thread at java.lang.Thread.start(Native Method) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.init(ThreadPool.java:497) at - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Qi Zhang, Ph.D Student Department of Computer Science, College of William and Mary P.O. Box 8795 Williamsburg, VA 23187-8795 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat, eclipse and jpda
For debugging servlets, you simply start Tomcat up on the server machine in jpda mode, make sure you have a project in eclipse with all of your servlet code (compile with debug information, which in my eclipse is the default), and put a breakpoint in the servlet code. Connect to the Tomcat debug process. Then, hit the servlet with a browser, and your debugger should stop at your breakpoint no problem. JSPs are trickier since the source code is generated at runtime. You CAN pull in the .java file from the tomcat work directory, put it in your project, and maybe have some luck at getting a breakpoint set. (I do not know if it would be compiled with debug information or not though. You could use a precompilation script to guarantee this). There might be some Eclipse plugins that do JSP source-level debugging now, though I haven't seen one. If you have to debug servlet init code, that is a bit trickier, though not much. Simply change catalina.sh, where it has the JPDA arguments, changing suspend=n to suspend=y. Then the Tomcat java process will start up and immediately suspend itself until you connect with the debugger and resume the process. For servlets, there is nothing too different than debugging any other plain java code. [EMAIL PROTECTED] 12/5/03 8:26:12 AM Hi, I read the message in tomcat-user list about eclipse, tomcat and jpda, but i don't understand very well. I have two machines, one is a tomcat server and the other machine is my workstation. I execute tomcat with ./catalina.sh jpda run and i can connect with eclipse when I try to debug. This is a client machine. But, I don't debug anything. The project to debug where would it stay??? In server or client machine??? Moreover, how can i execute the jsp or sevlet??? With URL http://server:8080/ Thanks SERGI - Yahoo! Sorteos ¡Ya puedes comprar Lotería de Navidad! Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: mod_jk worker help please!!
I'll go through the potentially obvious mistakes: 1) Are you sure you are editing the correct workers.properties? 2) Have you cleared out the mod_jk.log before trying again, maybe the messages are old I'm sure you probably have done all of this, but I know that these mistakes, while obvious, are quite easy to make. [EMAIL PROTECTED] 12/5/03 10:27:04 AM Yes, I have that. So, why would it ignore my worker.list for the workers I define? 2003-12-04 17:16:58 Ajp13Connector[8009] Starting background thread 2003-12-04 17:16:58 Ajp13Processor[8009][0] Starting background thread 2003-12-04 17:16:58 Ajp13Processor[8009][1] Starting background thread 2003-12-04 17:16:58 Ajp13Processor[8009][2] Starting background thread 2003-12-04 17:16:58 Ajp13Processor[8009][3] Starting background thread 2003-12-04 17:16:58 Ajp13Processor[8009][4] Starting background thread workers.properties: workers.tomcat_home=C:\tomcat workers.java_home=C:\MMIS_IAS\jdk workers.th=C:\tomcat ps=\ worker.list=test worker.test.port=8009 worker.test.host=localhost worker.test.type=ajp13 http.conf: LoadModule jk_module modules/mod_jk.dll AddModule mod_jk.c JkWorkersFile C:/Tomcat/conf/jk/workers.properties JkLogFile C:/tomcat/logs/mod_jk.log JkLogLevel debug JkLogStampFormat [%a %b %d %H:%M:%S %Y] my mod_jk.log says: [Tue Dec 02 17:52:45 2003] [jk_worker.c (88)]: Into wc_open [Tue Dec 02 17:52:45 2003] [jk_worker.c (222)]: Into build_worker_map, creating 1 workers [Tue Dec 02 17:52:45 2003] [jk_worker.c (228)]: build_worker_map, creating worker ajp12 [Tue Dec 02 17:52:45 2003] [jk_worker.c (148)]: Into wc_create_worker [Tue Dec 02 17:52:45 2003] [jk_worker.c (162)]: wc_create_worker, about to create instance ajp12 of ajp12 [Tue Dec 02 17:52:45 2003] [jk_ajp12_worker.c (283)]: Into ajp12_worker_factory [Tue Dec 02 17:52:45 2003] [jk_worker.c (171)]: wc_create_worker, about to validate and init ajp12 [Tue Dec 02 17:52:45 2003] [jk_ajp12_worker.c (200)]: Into jk_worker_t::validate [Tue Dec 02 17:52:45 2003] [jk_ajp12_worker.c (212)]: In jk_worker_t::validate for worker ajp12 contact is localhost:8007 [Tue Dec 02 17:52:45 2003] [jk_worker.c (187)]: wc_create_worker, done [Tue Dec 02 17:52:45 2003] [jk_worker.c (238)]: build_worker_map, removing old ajp12 worker [Tue Dec 02 17:52:45 2003] [jk_worker.c (250)]: build_worker_map, done [Tue Dec 02 17:52:45 2003] [jk_worker.c (111)]: wc_open, done 1 Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat, eclipse and jpda
The source code must be on the client machine, in an eclipse project. The binary build of it will be in your normal web application, in a jar file in WEB-INF\lib or as a .class file under WEB-INF\classes You call the servlet as you normally would, by its mapping that is specified in your web.xml. If you can access the servlet that is running on the Tomcat server via a browser, then that is what you do when debugging as well. I do not understand your question about where the debug information is. If compiled correctly, your servlet's .class file will contain debug information. Or, are you asking where the JPDA settings are? They are in catalina.sh, look for the text -Xdebug ... Do a google search or search sun's site for more specific information on that. Or, are you asking how to attach a debugging process using Eclipse? After you have the source of your servle loaded in and the breakpoints set, Go to Run | Debug... then double click on Remote Java Application. This should create a run configuration for your servlet code. Make sure you change the host field to point to your tomcat server, and the port to 8000(it looks like that is the default address for debugging in catalina.sh). Then hit apply and/or the debug button, and you should be running. You can tell if you successfully attached to the Tomcat process if you get switched to the debugging perspective and some threads start getting listed in the threads window. Then you use a browser to hit your servlet. [EMAIL PROTECTED] 12/5/03 10:39:07 AM Thanks Jeff But, I have one question... The servlet code must be in server machine or client machine?Or two machines? I call client machine the machine that has eclipse. And I must call servlet in with server url? Moreover, where is the debug information? Jeff Tulley [EMAIL PROTECTED] wrote: For debugging servlets, you simply start Tomcat up on the server machine in jpda mode, make sure you have a project in eclipse with all of your servlet code (compile with debug information, which in my eclipse is the default), and put a breakpoint in the servlet code. Connect to the Tomcat debug process. Then, hit the servlet with a browser, and your debugger should stop at your breakpoint no problem. JSPs are trickier since the source code is generated at runtime. You CAN pull in the .java file from the tomcat work directory, put it in your project, and maybe have some luck at getting a breakpoint set. (I do not know if it would be compiled with debug information or not though. You could use a precompilation script to guarantee this). There might be some Eclipse plugins that do JSP source-level debugging now, though I haven't seen one. If you have to debug servlet init code, that is a bit trickier, though not much. Simply change catalina.sh, where it has the JPDA arguments, changing suspend=n to suspend=y. Then the Tomcat java process will start up and immediately suspend itself until you connect with the debugger and resume the process. For servlets, there is nothing too different than debugging any other plain java code. [EMAIL PROTECTED] 12/5/03 8:26:12 AM Hi, I read the message in tomcat-user list about eclipse, tomcat and jpda, but i don't understand very well. I have two machines, one is a tomcat server and the other machine is my workstation. I execute tomcat with ./catalina.sh jpda run and i can connect with eclipse when I try to debug. This is a client machine. But, I don't debug anything. The project to debug where would it stay??? In server or client machine??? Moreover, how can i execute the jsp or sevlet??? With URL http://server:8080/ Thanks SERGI - Yahoo! Sorteos ¡Ya puedes comprar Lotería de Navidad! Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Sorteos ¡Ya puedes comprar Lotería de Navidad! Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: weird digester issues
I'm assuming that the separation of /listener-c and lass on the next line are due to line-wrap in your email client. If not, that is your problem. listener-classcom.foo.bms.listeners.ApplicationContextListener/listener-c lass /listener Beyond that, the document seems to obey the DTD (I scanned it visually against the DTD, and then opened the file in IE, which usually complains about obvious errors such as the one above) [EMAIL PROTECTED] 12/4/03 2:10:50 PM Looks like this. ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameBMS Web Application/display-name !-- Listeners -- listener listener-classcom.foo.bms.listeners.ApplicationContextListener/listener-c lass /listener Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: response.sendRedirect() finite loop?!
Also, are you using the latest mod_jk? We had some thread hangs (never saw what you are seeing), that cleared up by moving to 1.2.5 mod_jk. [EMAIL PROTECTED] 12/3/03 7:05:52 AM Howdy, I've never seen something like this with tomcat, and I don't know enough about mod_jk to comment intelligently. If you don't need Apache, don't use it ;) Yoav Shapira Millennium ChemInformatics -Original Message- From: Stuart Stephen [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 03, 2003 7:37 AM To: Tomcat Users List Subject: RE: response.sendRedirect() finite loop?! Hi, On further investigation it would appear that this is not a Tomcat issue. It seems to be something to do with mod_jk. When a response.sendRedirect occurs it does not apply it properly. Or at least something is not executing properly. The setup we have is Apache 2.0.48, Tomcat 4.1.29, and mod_jk between them working with mod_ssl. I tested the code without using apache between me and Tomcat and everything worked as expected. Any suggestions or comments?? Regards Stuart -Original Message- From: Stuart Stephen [mailto:[EMAIL PROTECTED] Sent: 03 December 2003 10:06 To: [EMAIL PROTECTED] Subject: response.sendRedirect() finite loop?! talk2UtimeHi all, I am getting strange entries in my test_service_log.2003-12-03.txt. In my JSP which gets executed before this I am running a response.sendRedirect(/test/RedirectToMe.jsp); with a return; afterwards. So this should only get executed once. However. According to my logs its being accessed 1333 times in just SIX seconds [line count / 2]. I am the ONLY person on the server and therefore this is strange occurance! I checked the corresponding apache logs and this servlet was not in the logs, the servlet before hand which does the redirect was the only servlet that has been accessed externally. This is true from what the user sees. Is this a bug in Tomcat 4.1.29 or has something changed? I've been using Tomcat for a few years now and I've never seen anything like this? Regards, Stuart Stephen 2003-12-03 09:32:08 StandardContext[/t2ut]: Mapping contextPath='/test' with requestURI='/test/RedirectToMe.jsp' and relativeURI='/RedirectToMe.jsp' 2003-12-03 09:32:08 StandardContext[/t2ut]: Mapped to servlet 'jsp' with servlet path '/RedirectToMe.jsp' and path info 'null' and update=true 2003-12-03 09:32:08 StandardContext[/t2ut]: Mapping contextPath='/test' with requestURI='/test/RedirectToMe.jsp' and relativeURI='/RedirectToMe.jsp' 2003-12-03 09:32:08 StandardContext[/t2ut]: Mapped to servlet 'jsp' with servlet path '/RedirectToMe.jsp' and path info 'null' and update=true ... ... ... 2003-12-03 09:32:14 StandardContext[/t2ut]: Mapping contextPath='/t2ut' with requestURI='/t2ut/RoomTimes.jsp' and relativeURI='/RoomTimes.jsp' 2003-12-03 09:32:14 StandardContext[/t2ut]: Mapped to servlet 'jsp' with servlet path '/RoomTimes.jsp' and path info 'null' and update=true 2003-12-03 09:32:14 StandardContext[/t2ut]: Mapping contextPath='/t2ut' with requestURI='/t2ut/RoomTimes.jsp' and relativeURI='/RoomTimes.jsp' 2003-12-03 09:32:14 StandardContext[/t2ut]: Mapped to servlet 'jsp' with servlet path '/RoomTimes.jsp' and path info 'null' and update=true - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Session not freed in tomcat4.0.6
If you notice even in 4.x the section is commented out. Also, the StandardManager is used by default unless you specify it. So, if you want different settings than the defaults, then you need to add in a Manager section with the StandardManager as the class specified. Look at the docs for specifics. http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/manager.html [EMAIL PROTECTED] 12/3/03 8:24:50 AM Can you point me how to do these settings? Change the saveOnRestart setting to false in your server.xml Manager className=org.apache.catalina.session.PersistentManager debug=0 saveOnRestart=false maxActiveSessions=-1 minIdleSwap=-1 maxIdleSwap=-1 maxIdleBackup=-1 Store className=org.apache.catalina.session.FileStore/ /Manager BTW: I didn't notice the Manager section in the server.xml file in Tomcat 5x. has it been replaced? ALSO: If I were a committer, I would vote against making the new minimal server.xml file the default for future disturbutions. It's a lot easier to instruct us newbies to uncomment something from the file than to explain how to write sections in or switch from one config file to another.. On Wednesday 03 December 2003 10:01 am, senthilnathan wrote: Hi, Can you point me how to do these settings? Thanks, senthilnathan - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Wednesday, December 03, 2003 8:24 PM Subject: RE: Session not freed in tomcat4.0.6 Howdy, That's not a problem. Sessions are freed (destroyed) when they are timed out. They are persisted on restart. You can control these settings via the Manager element in server.xml. Yoav Shapira Millennium ChemInformatics -Original Message- From: senthilnathan [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 03, 2003 9:48 AM To: [EMAIL PROTECTED] Subject: Session not freed in tomcat4.0.6 Hi, I am using Tomcat 4.0.6 in solaris2.8 After tomcat shutdown, i am seeing the sessions are not freed. I mean After shutdown and restart the tomcat, i am getting the same sessionid and the session attributes are still there. Any idea what is the problem here? Thanks, senthilnathan This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Ben Souther F.W. Davison Company, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JK2 in server.xml with 4.1.29
Really? With all due respect, I have to totally disagree. You can use the Coyote Connector with mod_jk, and really should do so. The Ajp13Connector has had an exception at startup time and problems shutting down since about 4.1.18. It is an easy fix - I submitted a patch for it, only a simple change to an XML document. But, I was told at the time that since the connector is deprecated and that the Coyote connector works quite well, that it would not be fixed. Our experience with the Coyote Connector and mod_jk has been fine so far. We are using Apache as the web server. [EMAIL PROTECTED] 11/26/03 9:48:14 AM If you are going to use the mod_jk connector, I would stick with the old AJP connector. If you are going to use the mod)jk2 connector, use the newer Coyote connector. On Wed, 2003-11-26 at 08:44, Antony Paul wrote: Hi, I am trying configure Tomcat 4.1.27 + IIS on win2k. In server.xml there are two entries namely !-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 -- and !-- Define an AJP 1.3 Connector on port 8009 -- which one is to uncommented. rgds Antony Paul. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 4.1.29 and Remedy 5.1.2 MidTier
Yeah, that is mostly correct. There are also places where the spec is vague or doesn't specify behavior, and different application servers implement things differently. There are not a whole lot of spec or operation changes from the 4.0.x series that would completely break you. Offhand I can think of one though: The invoker servlet. It allows you to fire up a servlet directly by class name without defining it in your web.xml. Relying on that is dangerous and does lead to non-portable applications. As of Tomcat 4.1.12, the invoker was disabled by default. But, since you are running a JSP, there is no guarantee that there is a servlet in the mix (unless the JSP is doing a forward to a servlet or something). I think our Remedy team is using the ServletExec, so I do not have any examples myself of how to get it working on Tomcat. And, the full exception does not seem to be of much help. Maybe set debug=99 in the context definition and in all places where debug=0 in server.xml. That might yield a better error message. (Maybe not though). [EMAIL PROTECTED] 11/26/03 2:48:29 AM Hi Jeff, Thanks for the response. I already have a call in with Remedy and postings on the ARSLIST (no value from either so far). The ARSList does not have one posting that states the Midtier can be made to work with Tomcat (even though the doc states it can). Remedy Midtier comes with ServletExec as the default container - but I am loathe to swap Tomcat out as we already use it for other servlets. The support for 5.1.2 on Tomcat is there. Plus we are already running Remedy ARWEB 4.1.1 using Tomcat. I am new to Java, Tomcat and Servlets but have been reading around, Murachs Servlets and Wrox - Professional Apache Tomcat book. If a webapp is built so it doesn't rely on container specific extensions then it should be portable across containers right? Also what might be an obstacle to a webapp running on Tomcat 4.0.x but not on 4.1.x. I have read that these versions support different servlet specifications but aren't they backwardly compatible? On attempting to use Coyote HTTP Connector straight to Tomcat via http://enmc-mic:4321/arsys/apps/shared/config/config.jsp I get:- type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:2 54) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application FilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh ain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja va:256) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja va:191) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2417) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180 ) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:643) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve. java:171) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:641) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172 ) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:641) at org.apache.catalina.valves.RequestDumperValve.invoke(RequestDumperValve.java :221) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:641) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java :174) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext
Re: Tomcat Dies
I had not thought of that, but that should work well. I'll try it out and see. Right now I'm evaluating whether my test is actually a reasonable real-world test. The reason our testers did not find this earlier, is that their tests are a little more realistic to typical web site use. My test was more of a top-performance benchmark of dynamic content only, with each connection creating a new session. I guess my test is like a JSP site being slashdotted. It would be good if the PersistentManager solves the problem. Thanks for the good idea. [EMAIL PROTECTED] 11/25/03 6:17:13 PM Jeff Tulley wrote: What I have seen is that if there is a reasonably heavy load for a short amount of time, you can have too many sessions in memory that have not yet hit their session timeout value, and so cannot be freed by the garbage collector. It is very easy to run out of memory well before sessions start being let go. As far as I can tell though, once the sessions were freed, the memory itself cleared up. (These comments apply to 4.1.28 BTW) Jeff, have you tried a different session manager than the default (which is org.apache.catalina.session.StandardManager)? For example, org.apache.catalina.session.PersistentManager claims to be able to start swapping out inactive sessions to disk to save memory. http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/manager.html A config like this inserted into your context should solve your memory issues with some performance hit if a session is swapped out to disk and is later swapped in. However, the docs do warn that the manager hasn't been heavily tested. Manager className=org.apache.catalina.session.PersistentManager minIdleSwap=-1 maxIdleSwap=120 maxIdleBackup=-1 Store className=org.apache.catalina.session.FileStore/ /Manager The above config should swap out any sessions which haven't been accessed in the last 2 minutes. You can also config a JDBC store. -Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]