Re: RMI reaper thread prevents JVM from exiting
Le 25/01/2010 20:53, Christopher Schultz a écrit : You've reached way beyond my understanding of RMI at this point. Is it possible that, like JNDI, you might have trees of objects instead of just a flat list? In that case, you'd have to recursively unexport/unbind objects to make sure you got everything. Thanks for the advice. I've checked, and I think all objects are already unexported, because on each unexportObject() call the NoSuchObjectException is raised. Regards. Thomas Ce message est protégé par les règles relatives au secret des correspondances. Il est donc établi à destination exclusive de son destinataire. Celui-ci peut donc contenir des informations confidentielles. La divulgation de ces informations est à ce titre rigoureusement interdite. Si vous avez reçu ce message par erreur, merci de le renvoyer à l'expéditeur dont l'adresse e-mail figure ci-dessus et de détruire le message ainsi que toute pièce jointe. This message is protected by the secrecy of correspondence rules. Therefore, this message is intended solely for the attention of the addressee. This message may contain privileged or confidential information, as such the disclosure of these informations is strictly forbidden. If, by mistake, you have received this message, please return this message to the addressser whose e-mail address is written above and destroy this message and all files attached.
Re: tomcat memory usage
As far as I know, heap memory is used by objects. On the other hand, our application has static variables and references to the objects residing in heap area. Does it mean, static variables and references of our application are stored outside of reserved 512MB area? Or, the memory outside of 512MB reserved heap area used only by Java itself? From: Peter Crowther To: Tomcat Users List Sent: Tue, January 26, 2010 5:43:22 PM Subject: Re: tomcat memory usage 2010/1/26 Hüsnü Þentürk > Hi, > In our company, we are using apache tomcat as a windows service. We defined > jvm parameters "--JvmMs 512 --JvmMx 512" in service.bat. But application is > using 600,980 KB memory. I expect the application not to use more then 512 > MB. > > Can you explain me, the reason of this stuation. > > You are setting the memory that Java uses to store heap objects. That is not the only memory Java uses. Other uses include: - The JVM code itself; - Native code stacks per-thread; - Native objects such as sockets and threads; - Any loaded DLLs. You have no direct way of controlling the size of any of these. If you want to reduce Java's memory usage, you can reduce its heap space after monitoring what the process' overheads are. - Peter
Tomcat on Ubuntu 8.04 VPS and presumably multiple socket problems
Hi, I switched from a Windows XP based VPS to a Ubuntu 8.04 linux machine. Both run Tomcat 6.0.18 and 2.2.8 on tcp4. I now face several problems that might be related to some low level socket issue but do not necessarily need to. I am already glad to receive some hints to further boil down the issues. 1st issue: I cannot connect to a socket server embedded in a webapp and listening on port 1 any more in all cases. If I do it from a mobile device, it works, if i do it from my laptop over a dsl connection (router in between), a channel is opened and instantly closed. 2nd issue: mod_jk does not work. I think I replayed multiple instructions to set it up multiple times but in all cases it finally says "Could not find a worker for worker name=myWorker" 3rd issue: GWT-RPC calls do not get delivered any more to the browser on my laptop. IPtables is turned off. netstat -npl gives Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp0 0 0.0.0.0:84430.0.0.0:* LISTEN 17648/sw-cp-serverd tcp0 0 0.0.0.0:443 0.0.0.0:* LISTEN 17447/apache2 tcp0 0 0.0.0.0:993 0.0.0.0:* LISTEN 13847/couriertcpd tcp0 0 0.0.0.0:995 0.0.0.0:* LISTEN 13882/couriertcpd tcp0 0 127.0.0.1:8009 0.0.0.0:* LISTEN 29931/jsvc tcp0 0 0.0.0.0:106 0.0.0.0:* LISTEN 14178/xinetd tcp0 0 0.0.0.0:33060.0.0.0:* LISTEN 13704/mysqld tcp0 0 0.0.0.0:587 0.0.0.0:* LISTEN 14178/xinetd tcp0 0 0.0.0.0:110 0.0.0.0:* LISTEN 13868/couriertcpd tcp0 0 0.0.0.0:143 0.0.0.0:* LISTEN 13816/couriertcpd tcp0 0 0.0.0.0:1 0.0.0.0:* LISTEN 29931/jsvc tcp0 0 0.0.0.0:80800.0.0.0:* LISTEN 29931/jsvc tcp0 0 0.0.0.0:88800.0.0.0:* LISTEN 17648/sw-cp-serverd tcp0 0 0.0.0.0:80 0.0.0.0:* LISTEN 17447/apache2 tcp0 0 127.0.0.1:10001 0.0.0.0:* LISTEN 17648/sw-cp-serverd tcp0 0 0.0.0.0:465 0.0.0.0:* LISTEN 14178/xinetd tcp0 0 0.0.0.0:21 0.0.0.0:* LISTEN 14178/xinetd tcp0 0 83.169.23.236:530.0.0.0:* LISTEN 12281/named tcp0 0 127.0.0.1:530.0.0.0:* LISTEN 12281/named tcp0 0 127.0.0.1:631 0.0.0.0:* LISTEN 13913/cupsd tcp0 0 0.0.0.0:25 0.0.0.0:* LISTEN 14178/xinetd tcp0 0 127.0.0.1:953 0.0.0.0:* LISTEN 12281/named tcp0 0 127.0.0.1:6010 0.0.0.0:* LISTEN 20331/sshd: n...@nott tcp6 0 0 :::22 :::*LISTEN 13464/sshd tcp6 0 0 ::1:6010:::*LISTEN 20331/sshd: n...@nott udp0 0 0.0.0.0:53530.0.0.0:* 13545/avahi-daemon: udp0 0 0.0.0.0:47737 0.0.0.0:* 13545/avahi-daemon: udp0 0 83.169.23.236:530.0.0.0:* 12281/named udp0 0 127.0.0.1:530.0.0.0:* 12281/named udp0 0 0.0.0.0:43854 0.0.0.0:* 32643/adept_manager udp0 0 0.0.0.0:37455 0.0.0.0:* 12281/named udp6 0 0 :::37787:::* 12281/named Any thoughts on this? Your help is really appreciated. Thanks fatzopilot -- View this message in context: http://old.nabble.com/Tomcat-on-Ubuntu-8.04-VPS-and-presumably-multiple-socket-problems-tp27332135p27332135.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 5.5.28 Class loading issue
On 26/01/2010 18:12, ssmith wrote: Sorry, new to Nabble. I am defining a servlet filter. I tried to use the existing wars built for Tomcat 5.0.28, but they would not deploy at all. So, yes, I rebuilt them for Tomcat 5.5.28. You should rebuild, especially if you are compiling JSPs. Yes, I have a servlet-api.jar in the WEB-INF/lib/ and tomcat/common/lib directories. That'll be a problem. Don't put it in WEB-INF/lib. Eclipse (really MyEclipse) automatically builds the war with the jar, based on the project build path. I removed the servlet-api.jar from the WEB-INF/lib and started the server again---got the following error: SEVERE: Exception starting filter sitemesh java.lang.NoClassDefFoundError: javax/servlet/Filter at java.lang.ClassLoader.defineClass1(Native Method) Tomcat supplies all of the servlet & JSPs jars, you don't need to add them. With the servlet-api.jar in WEB-INF/lib/ I get the following error--which is my original error that I posted: SEVERE: Exception starting filter sitemesh java.lang.ClassCastException: com.opensymphony.module.sitemesh.filter.PageFilter As above, this is incorrect and will cause problems. I listed jasper.jar as being an issue. Why? If it's also duplicated in WEB-INF, then it should not be. It was naming-*.jars packaged with Tomcat 5.5.28 that was an issue. Again, why. No duplication allowed as above. Also, I had a references to older jars (such as jstl.jar) in my project--Tomcat 5.5.28 uses newer jars for several things. Tomcat 5.5 doesn't know JSTL exists, you must supply it if you are using it. Classes should only exist in one place in the classloader tree. You may not duplicate any class in WEB-INF that is supplied with Tomcat, in tomcat/lib. Yes, the class definitions in the web.xml are correctas they are when it runs on Tomcat 5.0.28. I orginally stated that the WikiUrlSessionIdFilter was a direct plug in class. That was not correct--it is referenced and used within our agriStatsUtilities.jar. The sitemesh class is a direct plug in class. Following is the web.xml: You might consider (backing up, then) removing all of the comments from your active server.xml. Much easier to read. p http://java.sun.com/xml/ns/j2ee"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; version="2.4" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd";> wikiUrlSessionIdFilter com.agristats.agriStatsUtilities.util.WikiUrlSessionIdFilter wikiUrlSessionIdFilter /* wikiUrlSessionIdFilter *.do wikiUrlSessionIdFilter /employeeUI/* wikiUrlSessionIdFilter /partyRoleUI/* wikiUrlSessionIdFilter /agriStatsMainUI/* wikiUrlSessionIdFilter /agriStatsStandardLayoutUI/* sitemesh com.opensymphony.module.sitemesh.filter.PageFilter sitemesh /* action org.apache.struts.action.ActionServlet config /WEB-INF/struts-config.xml debug 3 detail 3 0 action_tmp org.apache.struts.action.ActionServlet config /WEB-INF/struts-config.xml debug 3 detail 3 0 action *.do JUnitEETestServlet org.junitee.servlet.JUnitEEServlet JUnitEETestServlet /TestServlet/* 60 And below is the content of the server.xml---pretty much standard as provided by Tomcat, except for the definition for the email resource. I also modified the standard context.xml to include a DefaultContext for our email server (I did not provide contents of context.xml--but can if you need it). These modifications existed in the xml files for Tomcat 5.0.28. Thanks for quick reply, Smith - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: FW: JNDIRealm and roleNested
Hi Mark, Tomcat 6.0.24 has been released and the roleNested="true" still doesn't work with roleSearch="(member={1})" Shall I open a bug in https://issues.apache.org/bugzilla bugzilla ? regards, Gabriel. -- View this message in context: http://old.nabble.com/JNDIRealm-and-roleNested-tp24756476p27331784.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: JasperException in 6.0.24 with JSF tag
On 26/01/2010 13:26, Michael Heinen wrote: > Hi, > > I recently updated from Tomcat 6.0.20 to 6.0.24. > Now some jsps with jsf tags are not compiling anymore. > > Following tag results in a JasperException in 6.0.24 but compiles fine with > older versions: > > > > Question: > Should I file a bug for this or is this expected behavior? That looks like a regression to me. (And it is probably my fault. Sorry.) Please file a bug report. Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat/JDBC Thin Client and Oracle SQL Parsing
2010/1/26 Dan Denton : > > Can anyone point out any instances they've had where Tomcat or Tomcat with > the Oracle JDBC driver has exhibited similar behavior? Is your JDBC driver up-to-date, or as old as the Tomcat version that you are using? I once solved a thing by updating the driver. Best regards, Konstantin Kolinko - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Global JNDI resource loaded from a webapp
On 26/01/2010 07:59, Woonsan Ko wrote: > Does *global JNDI resource* mean that all implementation jars must be in > shared lib path together with the sharable interfaces? Yes. > If sharable interfaces are in the shared lib path like javax.sql.DataSource > or javax.jcr.Repository, but the real implementation of those are loaded from > a web application, then isn't it possible to call it a "global JNDI resource" > of javax.sql.DataSource or javax.jcr.Repository? This is unlikely to work and if by some fluke it did work you will have a memory leak. Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
User Authentication via Unix passwd File
Has anybody implemented user authentication, using Tomcat (6.0) realms, via standard old-school Unix passwd files? I've already implemented JDNIRealm (LDAP) authentication, but some of our sites aren't using LDAP yet. Doug Fulford Software Engineering Specialist (626)812-2248
RE: Tomcat access is very slow
> From: Yu Chao [mailto:yves0...@gmail.com] > Subject: Re: Tomcat access is very slow > > it takes 5 minutes to open a homepage, but in my colleague's > computer, only 10-20 seconds. Might be network timeouts, waiting for something like DNS resolution (as someone else already suggested, I believe). Compare the C:\WINDOWS\system32\drivers\etc\hosts files on the two computers, and perhaps run Wireshark on yours to see if there are network requests being made that are not being responded to. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat access is very slow
using my colleague's computer, means using his tomcat to run the project, not related with brower. 2010/1/27 Yu Chao > thank you. > > 1. XP > 2. 1.5.0 > 3. I have a tomcat project, which is running fast on my colleague's > computer, but very slow on mine. > 4. examples is very fast. > 5. no database, but webservice. > 6. IE, chrome, firefox, i tried all of them, same result. > > I even copied my colleague's tomcat to my computer, but doesn't work, it's > very slow when I accessing http://localhost:8080/projectname, it takes 5 > minutes to open a homepage, but in my colleague's computer, only 10-20 > seconds. > > 2010/1/27 Konstantin Kolinko > > 2010/1/26 Yu Chao : >> > sorry for my later response because I reinstalled my computer... the >> > situation is still slow, I got mad... >> >> 1. Your operating system = ? >> 2. Your Java runtime vendor and its version = ? >> 3. What are you trying to do, step by step. At what step do you >> observe the delays? >> 4. Is it only your application, that opens slowly? How about Tomcat >> examples? What about other, external, web sites? >> 5. Does your application have connections to a Database? >> 6. What web browser are you using? >> >> >> Best regards, >> Konstantin Kolinko >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> >> >
Re: Tomcat access is very slow
thank you. 1. XP 2. 1.5.0 3. I have a tomcat project, which is running fast on my colleague's computer, but very slow on mine. 4. examples is very fast. 5. no database, but webservice. 6. IE, chrome, firefox, i tried all of them, same result. I even copied my colleague's tomcat to my computer, but doesn't work, it's very slow when I accessing http://localhost:8080/projectname, it takes 5 minutes to open a homepage, but in my colleague's computer, only 10-20 seconds. 2010/1/27 Konstantin Kolinko > 2010/1/26 Yu Chao : > > sorry for my later response because I reinstalled my computer... the > > situation is still slow, I got mad... > > 1. Your operating system = ? > 2. Your Java runtime vendor and its version = ? > 3. What are you trying to do, step by step. At what step do you > observe the delays? > 4. Is it only your application, that opens slowly? How about Tomcat > examples? What about other, external, web sites? > 5. Does your application have connections to a Database? > 6. What web browser are you using? > > > Best regards, > Konstantin Kolinko > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > >
Re: Tomcat 6.0.24 empty logs with windows (not flushed?)
I've found that it's a known bug : https://issues.apache.org/bugzilla/show_bug.cgi?id=48614 https://issues.apache.org/bugzilla/show_bug.cgi?id=48614 I should have looked in bugzilla before :-). adding the following lines in the logging.properties (under the conf directory) solve the problem : 1catalina.org.apache.juli.FileHandler.bufferSize=-1 2localhost.org.apache.juli.FileHandler.bufferSize=-1 3manager.org.apache.juli.FileHandler.bufferSize=-1 4host-manager.org.apache.juli.FileHandler.bufferSize=-1 Gabriel. -- View this message in context: http://old.nabble.com/Tomcat-6.0.24-empty-logs-with-windows-%28not-flushed-%29-tp27327976p27328155.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Tomcat 6.0.24 empty logs with windows (not flushed?)
I've just migrated my tomcat 6.0.18 to 6.0.24 under windows. When I start tomcat, the log files are created under the $catalina_home\logs directory. But they are empty (catalina.log, localhost.log, ...). My tomcat server start correctly and the logs are displayed in the console. After a while some logs are at last flushed into the files, but not everything. When I stop the tomcat server, the logs are all flushed into the files but not the last lines (the ones about the shutdown). Has something been change about the log system under windows (maybe a new paramter to tell tomcat to flush the logs in real time)? Under linux everything works fine. Regards, Gabriel. -- View this message in context: http://old.nabble.com/Tomcat-6.0.24-empty-logs-with-windows-%28not-flushed-%29-tp27327976p27327976.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Grails WAR file not working
> From: AwTIn [mailto:tanner.kl...@gmail.com] > Subject: RE: Grails WAR file not working > > Tomcat version: 5.5.7 That's over 4.5 years old, so it might be time to upgrade... > JVM: 1.5.0-b64 That's nearly 6 years old... > OS: Ubuntu Are you running a real Tomcat (one downloaded from tomcat.apache.org), or a 3rd-party repackaged version from Ubuntu? If the latter, it scatters files all over the place and then tries to symlink them back together, so it's hard to tell where new webapps are actually supposed to go. Try updating to the current Tomcat version (5.5.28 or 6.0.24) and a current JVM and see if the problem persists. Also, as I said before, look in the Tomcat logs for any errors that might be reported there for the deployment of the webapp. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Grails WAR file not working
n828cl wrote: > >> From: AwTIn [mailto:tanner.kl...@gmail.com] >> Subject: Grails WAR file not working > >> What might cause this problem? > > Not telling us your exact Tomcat version, the JVM you're using, the OS > you're running on... for starters. > > You might want to look in the Tomcat logs. > > - Chuck > > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY > MATERIAL and is thus for use only by the intended recipient. If you > received this in error, please contact the sender and delete the e-mail > and its attachments from all computers. > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > > Tomcat version: 5.5.7 JVM: 1.5.0-b64 OS: Ubuntu -- View this message in context: http://old.nabble.com/Grails-WAR-file-not-working-tp27326818p27327331.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Grails WAR file not working
> From: AwTIn [mailto:tanner.kl...@gmail.com] > Subject: Grails WAR file not working > What might cause this problem? Not telling us your exact Tomcat version, the JVM you're using, the OS you're running on... for starters. You might want to look in the Tomcat logs. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 5.5.28 Class loading issue
Sorry, new to Nabble. I am defining a servlet filter. I tried to use the existing wars built for Tomcat 5.0.28, but they would not deploy at all. So, yes, I rebuilt them for Tomcat 5.5.28. Yes, I have a servlet-api.jar in the WEB-INF/lib/ and tomcat/common/lib directories. Eclipse (really MyEclipse) automatically builds the war with the jar, based on the project build path. I removed the servlet-api.jar from the WEB-INF/lib and started the server again---got the following error: SEVERE: Exception starting filter sitemesh java.lang.NoClassDefFoundError: javax/servlet/Filter at java.lang.ClassLoader.defineClass1(Native Method) With the servlet-api.jar in WEB-INF/lib/ I get the following error--which is my original error that I posted: SEVERE: Exception starting filter sitemesh java.lang.ClassCastException: com.opensymphony.module.sitemesh.filter.PageFilter I listed jasper.jar as being an issue. It was naming-*.jars packaged with Tomcat 5.5.28 that was an issue. Also, I had a references to older jars (such as jstl.jar) in my project--Tomcat 5.5.28 uses newer jars for several things. Yes, the class definitions in the web.xml are correctas they are when it runs on Tomcat 5.0.28. I orginally stated that the WikiUrlSessionIdFilter was a direct plug in class. That was not correct--it is referenced and used within our agriStatsUtilities.jar. The sitemesh class is a direct plug in class. Following is the web.xml: http://java.sun.com/xml/ns/j2ee"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; version="2.4" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd";> wikiUrlSessionIdFilter com.agristats.agriStatsUtilities.util.WikiUrlSessionIdFilter wikiUrlSessionIdFilter /* wikiUrlSessionIdFilter *.do wikiUrlSessionIdFilter /employeeUI/* wikiUrlSessionIdFilter /partyRoleUI/* wikiUrlSessionIdFilter /agriStatsMainUI/* wikiUrlSessionIdFilter /agriStatsStandardLayoutUI/* sitemesh com.opensymphony.module.sitemesh.filter.PageFilter sitemesh /* action org.apache.struts.action.ActionServlet config /WEB-INF/struts-config.xml debug 3 detail 3 0 action_tmp org.apache.struts.action.ActionServlet config /WEB-INF/struts-config.xml debug 3 detail 3 0 action *.do JUnitEETestServlet org.junitee.servlet.JUnitEEServlet JUnitEETestServlet /TestServlet/* 60 And below is the content of the server.xml---pretty much standard as provided by Tomcat, except for the definition for the email resource. I also modified the standard context.xml to include a DefaultContext for our email server (I did not provide contents of context.xml--but can if you need it). These modifications existed in the xml files for Tomcat 5.0.28. Thanks for quick reply, Smith -- View this message in context: http://old.nabble.com/Tomcat-5.5.28-Class-loading-issue-tp27323388p27327182.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat/JDBC Thin Client and Oracle SQL Parsing
Dan - I'd look into why Oracle took an "improper" index (whatever that means). There is nothing in Tomcat/JDK that would mess with your queries that I'm aware of. I'd also investigate all the standard reasons why Oracle recomputes explain plans for queries - most of which are related to the query. Are all your varying values passed via bind variables? What are your DBs optimization settings? Stuff like that. Otherwise, the question is probably better presented on an Oracle forum. Jeff -Original Message- From: Dan Denton [mailto:dden...@remitpro.com] Sent: Tuesday, January 26, 2010 11:41 AM To: users@tomcat.apache.org Subject: Tomcat/JDBC Thin Client and Oracle SQL Parsing Hello all. Several days ago we saw some strange behavior with an Oracle database after the restart of a tomcat webapp. Immediately after restart, Oracle was processing the query for a certain page using an improper index that caused the page/query to hang. We've taken a look at the configuration for our CBO and come to the conclusion that Oracle should not have reparsed the query unless the query were somehow different, but we can't find anything to indicate the query changed. While it's possible there's something we missed, I would like to know if anyone out there knows why a webapp restart would cause the database to reparse and choose a new execution plan. We're running Tomcat 5.5.12 with JDK 1.5.0_12. This is on an RHEL4 server running a 2.6.9 kernel. The tomcat instance is using a JDBC thin client to connect to the database. I know of no queries that are made to the database immediately upon startup, and it's certainly not this one since the query is page specific. Can anyone point out any instances they've had where Tomcat or Tomcat with the Oracle JDBC driver has exhibited similar behavior? Many thanks in advance, Dan *** NOTICE * This message is intended for the use of the individual or entity to which it is addressed and may contain information that is privileged, confidential, and exempt from disclosure under applicable law. If the reader of this message is not the intended recipient or the employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by reply or by telephone (call us collect at 512-343-9100) and immediately delete this message and all its attachments. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 100% CPU usage after moving from Java 5 to 6
2010/1/26 Leon Rosenberg > Another customer of mine was playing with gc settings for nearly a > year, because his tomcats collection times went higher and higher, and > after a short look at the heap dump with jmap and jhat, we found out > that he had 100.000.000 uncollectable garbage objects in the heap (2/3 > of his heap actually). Instead of investigating his heap pollution he > spent 11 month playing with gc options to setup a faster gc. In the > end the problem was solved in two days. > > Definitely. I've had the same in Smalltalk, the same in C# under the CLR. Fewer live objects in the heap = faster GC. Creating fewer short-lived objects = less time spent in GC and in tenuring objects. Almost always, the root of a GC performance problem isn't the GC at all :-). - Peter
Re: Tomcat access is very slow
2010/1/26 Yu Chao : > sorry for my later response because I reinstalled my computer... the > situation is still slow, I got mad... 1. Your operating system = ? 2. Your Java runtime vendor and its version = ? 3. What are you trying to do, step by step. At what step do you observe the delays? 4. Is it only your application, that opens slowly? How about Tomcat examples? What about other, external, web sites? 5. Does your application have connections to a Database? 6. What web browser are you using? Best regards, Konstantin Kolinko - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Grails WAR file not working
I have a WAR file created by Grails Web Framework that should (and has) worked over the Internet simply by placing the file in the Tomcat 'webapps' directory. When I place the WAR file and restart the server, the file is expanded correctly into a directory, but when I browse to its URL, I get an HTTP Status 404 error. What might cause this problem? -- View this message in context: http://old.nabble.com/Grails-WAR-file-not-working-tp27326818p27326818.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 100% CPU usage after moving from Java 5 to 6
On Tue, Jan 26, 2010 at 4:50 PM, Jesse Klaasse wrote: > > Hi Chuck, thanks for your extensive comments about the JVM options.. > On a site note... I have made the observation that the JVM is performing best without any explicit gc settings. Most time explicit GC settings just cause havoc (fixes sized generation spaces lead to 100% cpu usage and continuous full gcs, some performance options are extremely vm version specific and so on). Among the sites of my customers, one site is serving more than 500 requests per second in a single tomcat with only following options: -Xmx16G -Xms16G -XX:MaxPermSize=512M -XX:+PrintGCDetails -XX:+PrintGCTimeStamps Another customer of mine was playing with gc settings for nearly a year, because his tomcats collection times went higher and higher, and after a short look at the heap dump with jmap and jhat, we found out that he had 100.000.000 uncollectable garbage objects in the heap (2/3 of his heap actually). Instead of investigating his heap pollution he spent 11 month playing with gc options to setup a faster gc. In the end the problem was solved in two days. Most time I've seen people playing with gc settings, nothing good came out of it, save for real experts like Chuck. Thats just a side note ;-) regards Leon - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Tomcat/JDBC Thin Client and Oracle SQL Parsing
Hello all. Several days ago we saw some strange behavior with an Oracle database after the restart of a tomcat webapp. Immediately after restart, Oracle was processing the query for a certain page using an improper index that caused the page/query to hang. We've taken a look at the configuration for our CBO and come to the conclusion that Oracle should not have reparsed the query unless the query were somehow different, but we can't find anything to indicate the query changed. While it's possible there's something we missed, I would like to know if anyone out there knows why a webapp restart would cause the database to reparse and choose a new execution plan. We're running Tomcat 5.5.12 with JDK 1.5.0_12. This is on an RHEL4 server running a 2.6.9 kernel. The tomcat instance is using a JDBC thin client to connect to the database. I know of no queries that are made to the database immediately upon startup, and it's certainly not this one since the query is page specific. Can anyone point out any instances they've had where Tomcat or Tomcat with the Oracle JDBC driver has exhibited similar behavior? Many thanks in advance, Dan
JasperException in 6.0.24 with JSF tag
Hi, I recently updated from Tomcat 6.0.20 to 6.0.24. Now some jsps with jsf tags are not compiling anymore. Following tag results in a JasperException in 6.0.24 but compiles fine with older versions: Stack: Caused by: org.apache.jasper.JasperException: /pages/preferences.jsp(147,100) According to TLD or attribute directive in tag file, attribute value does not accept any expressions at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:40) at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407) at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:148) at org.apache.jasper.compiler.Validator$ValidateVisitor.checkXmlAttributes(Validator.java:1165) at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:852) at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1530) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2411) at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:871) at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1530) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2411) at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:871) at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1530) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2411) at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:871) at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1530) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2411) at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:871) at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1530) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2411) at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:871) at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1530) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2411) at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:871) at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1530) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2411) at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2417) at org.apache.jasper.compiler.Node$Root.accept(Node.java:495) at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2361) at org.apache.jasper.compiler.Validator.validateExDirectives(Validator.java:1775) at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:183) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:332) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:312) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:299) at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:589) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:646) at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:551) at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:488) at org.apache.jasper.runtime.JspRuntimeLibrary.i
RE: Tomcat 100% CPU usage after moving from Java 5 to 6
Hi Chuck, thanks for your extensive comments about the JVM options.. n828cl wrote: > >>-Xms10240m -Xmx10240m > > That's a very large heap; shouldn't hurt as long as you have enough RAM to > support it all without paging. (But see below for use with compressed > OOPs.) > This shouldn't be a problem, the system has 16 GB RAM, almost all of it dedicated to Tomcat. n828cl wrote: > >> Tomcat's CPU usage seems significantly lower than before >> (it's average seems about 10% now - which was 30-40% before) > > There are some improvements in the JDK/JRE 6 JIT and synchronization > handling, but probably not enough to account for that large a difference. > Well, I don't know where exactly it's coming from, but after a full day very closely monitoring the system, it turns out to be the truth. Which is not a bad thing, of course :) n828cl wrote: > >> I also added the -XX:+UseCompressedOops JVM option > > Be careful with that; it can impact CPU usage, since the compressed OOPs > have to be expanded into actual pointers every time they're used, and > pointers compressed when stored in a field. Works best with heap sizes > less than 4 GB, which avoids the decoding/encoding. For a real > explanation of compressed OOPs, look here: > http://wikis.sun.com/display/HotSpotInternals/CompressedOops > I already found that article myself. Since CPU usage is as low as it is now, I have decided to give it a try. Anyway, thanks again! -- View this message in context: http://old.nabble.com/Tomcat-100--CPU-usage-after-moving-from-Java-5-to-6-tp27305110p27324793.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: tomcat memory usage
2010/1/26 Hüsnü Þentürk > Hi, > In our company, we are using apache tomcat as a windows service. We defined > jvm parameters "--JvmMs 512 --JvmMx 512" in service.bat. But application is > using 600,980 KB memory. I expect the application not to use more then 512 > MB. > > Can you explain me, the reason of this stuation. > > You are setting the memory that Java uses to store heap objects. That is not the only memory Java uses. Other uses include: - The JVM code itself; - Native code stacks per-thread; - Native objects such as sockets and threads; - Any loaded DLLs. You have no direct way of controlling the size of any of these. If you want to reduce Java's memory usage, you can reduce its heap space after monitoring what the process' overheads are. - Peter
RE: Tomcat 100% CPU usage after moving from Java 5 to 6
> From: Jesse Klaasse [mailto:jesse.klaa...@indicia.nl] > Subject: Re: Tomcat 100% CPU usage after moving from Java 5 to 6 > > I found the following article particularly useful: > http://confluence.atlassian.com/display/DOC/Garbage+Collector+Performance+Issues Unfortunately, that article is so full of mistaken assumptions and outright errors that it must be taken with a large chunk of salt. There are some good things in it, but also a lot of rubbish. Among other things, the author is obviously unaware of how paging systems work, confusing contiguous virtual memory (required for the heap) with contiguous real memory (not required at all). > -XX:+UseConcMarkSweepGC This will reduce overall throughput, but also reduce the GC pause time. (GC pause time is pretty small even without that parameter these days.) It does make the GC threads do a lot more work, but you appear to have CPU time to burn. >-XX:+UseTLAB This has been the default for quite a few years now, so it's unnecessary to specify it. >-XX:+CMSClassUnloadingEnabled The above slows down CMS collections. You can leave it off if you never update JSPs on the fly, or redeploy webapps without a Tomcat restart. >-XX:+CMSPermGenSweepingEnabled The above is the old name for CMSClassUnloadingEnabled and should not be used. >-XX:+DisableExplicitGC Always a good idea to set the above. >-XX:NewSize=4096m I would be wary of setting the above parameter, preferring to let the JVM determine the value as needed. JDK/JRE 6 is much better at reacting to dynamic changes in workload than 1.4 was. >-Xms10240m -Xmx10240m That's a very large heap; shouldn't hurt as long as you have enough RAM to support it all without paging. (But see below for use with compressed OOPs.) > Tomcat's CPU usage seems significantly lower than before > (it's average seems about 10% now - which was 30-40% before) There are some improvements in the JDK/JRE 6 JIT and synchronization handling, but probably not enough to account for that large a difference. > I also added the -XX:+UseCompressedOops JVM option Be careful with that; it can impact CPU usage, since the compressed OOPs have to be expanded into actual pointers every time they're used, and pointers compressed when stored in a field. Works best with heap sizes less than 4 GB, which avoids the decoding/encoding. For a real explanation of compressed OOPs, look here: http://wikis.sun.com/display/HotSpotInternals/CompressedOops - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 5.5 org.apache.naming.ResourceRef cannot be cast to javax.sql.DataSource
> From: Steve Ryder [mailto:sry...@jsrsys.com] > Subject: Re: Tomcat 5.5 org.apache.naming.ResourceRef cannot be cast to > javax.sql.DataSource > > Oops: > sry...@srv:~$ java -version > java version "1.5.0" > gij (GNU libgcj) version 4.2.3 (Ubuntu 4.2.3-2ubuntu6) A very big oops. > I need to replace the java install with the Sun version. Correct; replace the toy JVM with a real one. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: tomcat memory usage
On 26/01/2010 15:12, Hüsnü Þentürk wrote: Hi, In our company, we are using apache tomcat as a windows service. We defined jvm parameters "--JvmMs 512 --JvmMx 512" in service.bat. But application is using 600,980 KB memory. I expect the application not to use more then 512 MB. Can you explain me, the reason of this stuation. Assuming they're actually working, those settings only govern the size of the heap. The JVM uses memory for things that are not part of the heap. p Informations: -- Server version: Apache Tomcat/6.0.20 Server built: May 14 2009 01:13:50 Server number: 6.0.20.0 OS Name:Windows 2003 OS Version: 5.2 Architecture: x86 JVM Version:1.5.0_04-b05 JVM Vendor: Sun Microsystems Inc. Thanks. Husnu Senturk - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 5.5.28 Class loading issue
On 26/01/2010 14:25, ssmith wrote: Spacing improves legibility. I have two filters within my web.xml--one uses a sitemesh plugin and the other uses a wikiUrlSessionIdFilter plugin---from sitemesh.jar and jboss-seam.jar respectively. If I place the two jars in tomcat/common/lib directory and start the server, I get ClassNotFoundExceptions when Tomcat tries to create servlets for the filters. Which are you defining in web.xml Servlet, or Servlet Filter? If I move the jars to the application's WEB-INF/lib directory, I get ClassCastException when Tomcat tries to create servlets for the filters. And yes this war works just fine under Tomcat 5.0.28---where both jars only reside in tomcat/common/lib. Is the WAR completely unchanged or are you deploying a new version for 5.5? I have checked for multiple instances of these jars throughout the application and there are none. The jars do not exist in any other tomcat directory. The jars are not on the CLASSPATH either and from what I understand, Tomcat 5.5 does not use the CLASSPATH anymore by default. Exactly which version of 5.5? Have you accidentally duplicated servlet-api.jar files? I have checked that the jars are the latest version--good to use with Tomcat 5.5---and they are. I have double and triple checked that these jars are not being indirectly packaged in the war somehow. I use Eclipse to do a basic build of the war---same as I did for Tomcat 5.0---except now I deploy to a Tomcat 5.5 server. Have you checked that the class definitions are correct in the web.xml. Post the relevant xml sections here. So far, I have worked through several issues of migrating from Tomcat 5.0 to 5.5 (logging changes, class loading changes, dependent jar changes, inconsisent jar issues, jasper jar issues, etc, etc, etc) and I am now completely at a loss on this one. I know it is some sort of class loading issue, but I have no idea if I can solve it and how. I cannot seem to figure out what Tomcat wants. "Jasper jar issues" sounds alarming. Tomcat 5.5 acts as if he has to have the jars in the application lib, but is confused when it uses those--like it alreay loaded the classes before, from somewhere else. In case it matters---I am starting Tomcat natively on Windows using startup.bat Anyone got any ideas on this---I could sure use some help? How have you defined the Host and Context, post the relevant section of your server.xml. p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
tomcat memory usage
Hi, In our company, we are using apache tomcat as a windows service. We defined jvm parameters "--JvmMs 512 --JvmMx 512" in service.bat. But application is using 600,980 KB memory. I expect the application not to use more then 512 MB. Can you explain me, the reason of this stuation. Informations: -- Server version: Apache Tomcat/6.0.20 Server built: May 14 2009 01:13:50 Server number: 6.0.20.0 OS Name: Windows 2003 OS Version: 5.2 Architecture: x86 JVM Version: 1.5.0_04-b05 JVM Vendor: Sun Microsystems Inc. Thanks. Husnu Senturk
RE: Disabled use of AcceptEx() WinSock2 API" error on Windows 7
> From: Richard Cooke [mailto:richa...@saratoga.co.za] > Subject: Re: Disabled use of AcceptEx() WinSock2 API" error on Windows > 7 > > The zip version starts without any problems using startup.bat. I did get Tomcat 6.0.20 running as a service on Win7, with a few caveats: 1) The OS is Win7 Ultimate *RC1* running on VMware. 2) The service was installed with service.bat running as administrator. 3) The JVM is JDK 1.7.0-ea-b76. So it's likely to be a tad different environment than yours... - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Tomcat 5.5.28 Class loading issue
I have two filters within my web.xml--one uses a sitemesh plugin and the other uses a wikiUrlSessionIdFilter plugin---from sitemesh.jar and jboss-seam.jar respectively. If I place the two jars in tomcat/common/lib directory and start the server, I get ClassNotFoundExceptions when Tomcat tries to create servlets for the filters. If I move the jars to the application's WEB-INF/lib directory, I get ClassCastException when Tomcat tries to create servlets for the filters. And yes this war works just fine under Tomcat 5.0.28---where both jars only reside in tomcat/common/lib. I have checked for multiple instances of these jars throughout the application and there are none. The jars do not exist in any other tomcat directory. The jars are not on the CLASSPATH either and from what I understand, Tomcat 5.5 does not use the CLASSPATH anymore by default. I have checked that the jars are the latest version--good to use with Tomcat 5.5---and they are. I have double and triple checked that these jars are not being indirectly packaged in the war somehow. I use Eclipse to do a basic build of the war---same as I did for Tomcat 5.0---except now I deploy to a Tomcat 5.5 server. So far, I have worked through several issues of migrating from Tomcat 5.0 to 5.5 (logging changes, class loading changes, dependent jar changes, inconsisent jar issues, jasper jar issues, etc, etc, etc) and I am now completely at a loss on this one. I know it is some sort of class loading issue, but I have no idea if I can solve it and how. I cannot seem to figure out what Tomcat wants. Tomcat 5.5 acts as if he has to have the jars in the application lib, but is confused when it uses those--like it alreay loaded the classes before, from somewhere else. In case it matters---I am starting Tomcat natively on Windows using startup.bat Anyone got any ideas on this---I could sure use some help? -- View this message in context: http://old.nabble.com/Tomcat-5.5.28-Class-loading-issue-tp27323388p27323388.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 100% CPU usage after moving from Java 5 to 6
I also added the -XX:+UseCompressedOops JVM option (as suggested in the Confluence article I mentioned earlier). BTW, for those who want to know: this option is available since update 14 of JDK 6 (see also http://java.sun.com/javase/6/webnotes/6u14.html), you don't need the "Performance branch" as mentioned in the article. This option is said to give a performance gain of 25% as well as a reduction of used heap space (see also http://blog.juma.me.uk/2008/10/14/32-bit-or-64-bit-jvm-how-about-a-hybrid/). Furthermore, I discovered the -XX:+UseTLAB option is a default option in JDK 6: http://java.sun.com/javase/technologies/hotspot/vmoptions.jsp I thought, I'd just let you all know! -- View this message in context: http://old.nabble.com/Tomcat-100--CPU-usage-after-moving-from-Java-5-to-6-tp27305110p27322864.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 5.5 org.apache.naming.ResourceRef cannot be cast to javax.sql.DataSource
Oops: sry...@srv:~$ java -version java version "1.5.0" gij (GNU libgcj) version 4.2.3 (Ubuntu 4.2.3-2ubuntu6) Copyright (C) 2007 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. sry...@srv:~$ which java /usr/bin/java sry...@srv:~$ OK, I think I see the problem. I contracted out the construction of this server. I need to replace the java install with the Sun version. Do you agree? - Original Message - From: "Bob Hall" To: "Tomcat Users List" Sent: Tuesday, January 26, 2010 1:47 AM Subject: Re: Tomcat 5.5 org.apache.naming.ResourceRef cannot be cast to javax.sql.DataSource Steve, --- On Mon, 1/25/10 at 10:50 PM, Steve Ryder wrote: I understand what you mean by don't use, but "I" am not using it. What do I need to change so that it is not used? How might I track down the offending library? What do you get when you type the following commands: $ java -version $ which java - Bob - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Global JNDI resource loaded from a webapp
- Original Message > From: Pid > To: users@tomcat.apache.org > Sent: Tue, January 26, 2010 12:21:20 PM > Subject: Re: Global JNDI resource loaded from a webapp > > On 26/01/2010 10:02, Woonsan Ko wrote: > > Hi All, > > > > Is it possible to configure a global JNDI resource which is loaded from a > webapp? > > If it is defined in a webapp, it's not a global JNDI resource. > So, no. Does *global JNDI resource* mean that all implementation jars must be in shared lib path together with the sharable interfaces? If sharable interfaces are in the shared lib path like javax.sql.DataSource or javax.jcr.Repository, but the real implementation of those are loaded from a web application, then isn't it possible to call it a "global JNDI resource" of javax.sql.DataSource or javax.jcr.Repository? Kind regards, Woonsan > > > p > > > I want to keep all related libraries for the resource in a web application, > not in shared library path, but I want the resource to be shared by other web > applications. > > The primary reason is because there are two many related jar files for the > resource object and those can conflict other web applications if they are > deployed onto shared library path. > > Also, I could make use of reloading feature by deploying onto a web app. > > > > Here's an example scenario: > >- In shared lib folder, minimized api jars files only are deployed. The > > api > jars contains shareable interfaces or factory classes. > >- /repository webapp contains all related jar files, initializes a > repository instance and register it into global JNDI resource by some way. > >- /cms webapp accesses the repository by JNDI to author and manage > contents. > >- /site webapp accesses the repository by JNDI to provide preview > > websites. > >- ... > > > > Could you please recommend me a possible solution/alternative on Tomcat? > > > > Thanks in advance, > > > > Woonsan > > > > > > > > > > > > - > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > > For additional commands, e-mail: users-h...@tomcat.apache.org > > > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat access is very slow
sorry for my later response because I reinstalled my computer... the situation is still slow, I got mad... 2010/1/26 Yu Chao > what ever I use localhost:8080, or direct 192.168.0.127:8080 > > 2010/1/16 Ziggy > > Is it slow when you try to access it directly using the IP address? >> >> On Fri, Jan 15, 2010 at 7:54 PM, Christopher Schultz < >> ch...@christopherschultz.net> wrote: >> >> > -BEGIN PGP SIGNED MESSAGE- >> > Hash: SHA1 >> > >> > Yu, >> > >> > On 1/15/2010 11:28 AM, Yu Chao wrote: >> > > I’m not a very new to Tomcat \with a few projects experience. >> > > >> > > I got a new note book, everything is very fast except tomcat access. >> > >> > Where is Tomcat running? On your notebook, or on another server? >> > >> > > I run a new project in my new tomcat(5.5.28 with no other project in >> > > webapp), I need about 2-5 minutes to open a page. >> > >> > Perhaps a DNS lookup is stalling? >> > >> > Details about your setup would be very helpful. >> > >> > - -chris >> > -BEGIN PGP SIGNATURE- >> > Version: GnuPG v1.4.10 (MingW32) >> > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ >> > >> > iEYEARECAAYFAktQx+EACgkQ9CaO5/Lv0PCh9wCgpahPcEWTdmJrFGQME+iwLfb3 >> > YysAniZoma4EdKR/TkIc3+4EGNj9+LCd >> > =2Ntb >> > -END PGP SIGNATURE- >> > >> > - >> > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> > For additional commands, e-mail: users-h...@tomcat.apache.org >> > >> > >> > >
Re: Tomcat access is very slow
what ever I use localhost:8080, or direct 192.168.0.127:8080 2010/1/16 Ziggy > Is it slow when you try to access it directly using the IP address? > > On Fri, Jan 15, 2010 at 7:54 PM, Christopher Schultz < > ch...@christopherschultz.net> wrote: > > > -BEGIN PGP SIGNED MESSAGE- > > Hash: SHA1 > > > > Yu, > > > > On 1/15/2010 11:28 AM, Yu Chao wrote: > > > I’m not a very new to Tomcat \with a few projects experience. > > > > > > I got a new note book, everything is very fast except tomcat access. > > > > Where is Tomcat running? On your notebook, or on another server? > > > > > I run a new project in my new tomcat(5.5.28 with no other project in > > > webapp), I need about 2-5 minutes to open a page. > > > > Perhaps a DNS lookup is stalling? > > > > Details about your setup would be very helpful. > > > > - -chris > > -BEGIN PGP SIGNATURE- > > Version: GnuPG v1.4.10 (MingW32) > > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ > > > > iEYEARECAAYFAktQx+EACgkQ9CaO5/Lv0PCh9wCgpahPcEWTdmJrFGQME+iwLfb3 > > YysAniZoma4EdKR/TkIc3+4EGNj9+LCd > > =2Ntb > > -END PGP SIGNATURE- > > > > - > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > > For additional commands, e-mail: users-h...@tomcat.apache.org > > > > >
Re: Global JNDI resource loaded from a webapp
On 26/01/2010 10:02, Woonsan Ko wrote: Hi All, Is it possible to configure a global JNDI resource which is loaded from a webapp? If it is defined in a webapp, it's not a global JNDI resource. So, no. p I want to keep all related libraries for the resource in a web application, not in shared library path, but I want the resource to be shared by other web applications. The primary reason is because there are two many related jar files for the resource object and those can conflict other web applications if they are deployed onto shared library path. Also, I could make use of reloading feature by deploying onto a web app. Here's an example scenario: - In shared lib folder, minimized api jars files only are deployed. The api jars contains shareable interfaces or factory classes. - /repository webapp contains all related jar files, initializes a repository instance and register it into global JNDI resource by some way. - /cms webapp accesses the repository by JNDI to author and manage contents. - /site webapp accesses the repository by JNDI to provide preview websites. - ... Could you please recommend me a possible solution/alternative on Tomcat? Thanks in advance, Woonsan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Global JNDI resource loaded from a webapp
Hi All, Is it possible to configure a global JNDI resource which is loaded from a webapp? I want to keep all related libraries for the resource in a web application, not in shared library path, but I want the resource to be shared by other web applications. The primary reason is because there are two many related jar files for the resource object and those can conflict other web applications if they are deployed onto shared library path. Also, I could make use of reloading feature by deploying onto a web app. Here's an example scenario: - In shared lib folder, minimized api jars files only are deployed. The api jars contains shareable interfaces or factory classes. - /repository webapp contains all related jar files, initializes a repository instance and register it into global JNDI resource by some way. - /cms webapp accesses the repository by JNDI to author and manage contents. - /site webapp accesses the repository by JNDI to provide preview websites. - ... Could you please recommend me a possible solution/alternative on Tomcat? Thanks in advance, Woonsan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
MultiViews analogon for web-apps?
Hi, For Apache httpd the "MultiViews" option can be set in the configuration-file. This allows resources to be called without providing the the file-extension in the URL, e.g. the URL "http://localhost/images/myImage"; returns the file "myImage.png" in the "images" folder (same as calling "http://localhost/images/myImage.png";). It further serves clients depending on their behaviour: When both the files "myImage.png" and "myImage.gif" are in the "images" folder, upon calling the URL "http://localhost/images/myImage"; httpd serves the png-image to the Firefox-browser (as it states its preference for png-images in the "Acept" header) while it serves the gif-image to Internet Explorer. So my question is: How do I enable this content-negotiation functionality for a java web-app when I use a stand-alone appserver such as Tomcat, i.e. without apache httpd in front? Do I have to write a filter for this or is there an easier way? Thanks, Adrian - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 100% CPU usage after moving from Java 5 to 6
Jesse Klaasse wrote: I have now fixed the infinite loop, and again did the update from Java 5 to Java 6. This time all seems to be working like a charm! Along with fixing the infinite loop, I have dug a little deeper into the JVM arguments. I found the following article particularly useful: http://confluence.atlassian.com/display/DOC/Garbage+Collector+Performance+Issues Using that article plus common sense, my arguments are now: -Djavax.sql.DataSource.Factory=org.apache.commons.dbcp.BasicDataSourceFactory -Dcom.sun.management.jmxremote -XX:MaxPermSize=512m -Xloggc:D:\logs\gc\tomcat-gc.log -X:+PrintGCDetails -XX:+UseConcMarkSweepGC -XX:+UseTLAB -XX:+CMSClassUnloadingEnabled -XX:+CMSPermGenSweepingEnabled -XX:+DisableExplicitGC -XX:NewSize=4096m -Xms10240m -Xmx10240m The NewSize parameter was new to me, and it's explanation on the aforementioned link made much sense. A few things I'm still not completely sure about: - I don't want any serial garbage collection to occur. I'm not sure whether my arguments take care of this now.. - Do I still need the -XX:+UseTLAB argument? - Do I still need the -XX:+CMSClassUnloadingEnabled flag? - Do I still need the -XX:+CMSPermGenSweepingEnabled flag? So, still some research to be done. In the meantime I am very pleased with the results. Tomcat's CPU usage seems significantly lower than before (it's average seems about 10% now - which was 30-40% before) - scary! Jesse, thanks for the feedback. 1) for the people here trying to help, it just "feels nice" to know that they have actually done so. 2) the searchable archives of this list are a real resource in case of problems (at least for the people who bother to search them before asking questions). Having the solution to the problem contained in the archive is certainly a plus. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 100% CPU usage after moving from Java 5 to 6
I have now fixed the infinite loop, and again did the update from Java 5 to Java 6. This time all seems to be working like a charm! Along with fixing the infinite loop, I have dug a little deeper into the JVM arguments. I found the following article particularly useful: http://confluence.atlassian.com/display/DOC/Garbage+Collector+Performance+Issues Using that article plus common sense, my arguments are now: -Djavax.sql.DataSource.Factory=org.apache.commons.dbcp.BasicDataSourceFactory -Dcom.sun.management.jmxremote -XX:MaxPermSize=512m -Xloggc:D:\logs\gc\tomcat-gc.log -X:+PrintGCDetails -XX:+UseConcMarkSweepGC -XX:+UseTLAB -XX:+CMSClassUnloadingEnabled -XX:+CMSPermGenSweepingEnabled -XX:+DisableExplicitGC -XX:NewSize=4096m -Xms10240m -Xmx10240m The NewSize parameter was new to me, and it's explanation on the aforementioned link made much sense. A few things I'm still not completely sure about: - I don't want any serial garbage collection to occur. I'm not sure whether my arguments take care of this now.. - Do I still need the -XX:+UseTLAB argument? - Do I still need the -XX:+CMSClassUnloadingEnabled flag? - Do I still need the -XX:+CMSPermGenSweepingEnabled flag? So, still some research to be done. In the meantime I am very pleased with the results. Tomcat's CPU usage seems significantly lower than before (it's average seems about 10% now - which was 30-40% before) - scary! -- View this message in context: http://old.nabble.com/Tomcat-100--CPU-usage-after-moving-from-Java-5-to-6-tp27305110p27319482.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org