Re: Weblogic VS. Tomcat
--- HARBOR: http://coolharbor.100free.com/index.htm Now Tomcat is also a cool application server --- - Original Message - From: Johnny Kewl [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Tuesday, October 16, 2007 7:10 AM Subject: Re: Weblogic VS. Tomcat --- HARBOR: http://coolharbor.100free.com/index.htm Now Tomcat is also a cool application server --- - Original Message - From: minky arora [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Monday, October 15, 2007 5:25 PM Subject: Weblogic VS. Tomcat Hi List, I need some advice regarding Tomcat Vs. Weblogic. I am building a website that has an Oracle DB as a back end.I am running scripts on the DB and displaying the results on the website.Users can log in and query the DB as well to get the desired results which could be info about anything in the DB. My question is: Do I require a server side Datasource for this? FIrst of all, I am not sure what this means.For my organization,only Weblogic has external access as Ive been told.SO if I do not need server side Datasource and connection pooling, I can go with Tomcat. I am very new to J2EE.could you please tell me a bit more about server side datasource:what it is and examples of how it is used.Do you think my application needs one?? If you google for Servlet versus Application Server, you will see many other people ask the question and you'll get the views of both camps. If you making a web site, you really dont need more than a Servlet container. Tomcat will let you set up a Datasource with connection pooling, in fact every container allows for that. I think its more about where you want to store the biz logic. People that havnt learnt the MVC model and that work mainly from JSP pages will tend to go for something like struts, or an application server for the biz logic. They use another framework for the biz logic. People that understand the MVC model will use servlets and JSP and make their own biz logic beans in the servlet container... that to me seems to be the tendency. I believe that for a web site a well designed web-app which houses the biz logic is faster and easier to understand, and easier to maintain, than redirecting requests to EJB's in another container, but it does depend very much on the context of the project. If for example there are also desktop apps that use that same biz logic, then the tendency will be to go for application server... ie the web server is a client and the desktops apps are a client to the EJB's. EJB (Application servers) like GlassFish, Geronimo, Weblogic, Spring, JBoss are complex technologies with a large learning curve and will require a great deal of effort on your part, they are also all different. Servlet based web solutions are easier to learn, and much more portable. If its a web solution... I would tend to say to you, keep it as simple as possible... but then again EJB on your CV may look nice as well ;) If its a critical job... I would tend to say, keep it a pure web based solution, because as a newbie the complexity of EJB may bite you. Tomcat is inside most of these other containers, so if it ever has to go EJB... conversion wont be too bad, but moving from say a Spring type solution to a Glassfish type solution would require a major effort. Keep it simple if you can. the more I play with these technologies the more I think that the ability to make simple solutions is the most desirable characteristic on any cv. Only people that really understand the technologies can keep it simple... simple is a skill. I would suggest you google for Tomcat and the MVC model... and then read as much about EJB as you can. You will start to see the overlap. In TC its very much more a traditional application, in EJB its very much a bean that needs to be controlled through IOC, (xml) configuration. That means in TC things like persisting beans to a dB is still very much an option, in EJB its almost a necessity because of the different architecture. EJB is a massive learning curve... good luck. AFTER THOUGHT... Actually when I reread your question... I think what you have been told is more policy than technology. I think what your IT guys are saying to you is that THEY want to control the biz logic, and ONLY they can access the dB. So if you try setup a dB pool on TC, they probably not going to give you the passwords to the dB ;) So I guess it means you have to ask them to make the biz logic EJB modules, and then you will call those from Tomcat... which only the WebLogic server can deduce from the dB. Perhaps good policy, or perhaps one way of protecting their jobs ;)
RE: CAS Clustering Not Working
I set the tcpListenAddress to the server IP address, and it is working now. Yay! -Original Message- From: Clifford Bryant [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 16, 2007 12:00 AM To: Tomcat Users List Subject: RE: CAS Clustering Not Working The CAS Clustering document says to use the JBossCacheTicketRegistry class in the Ticket Cache Replication section. How important is for the time to be in sync on the clustered servers? The Tomcat Clustering/Session Replication document says, Make sure that all nodes have the same time and sync with NTP service! I was unable to set up the JMX console (MX4J). I thought that might give me an idea of what was going wrong with the clustering. -Original Message- From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED] Sent: Monday, October 15, 2007 6:28 PM To: Tomcat Users List Subject: Re: CAS Clustering Not Working looks like you are mixing jboss clustering and tomcat clustering at the same time, choose one or the other :) Filip Clifford Bryant wrote: Hi, I followed the instructions in the CAS clustering link. (http://www.ja-sig.org/wiki/display/CASUM/Clustering+CAS) The multicast ping is working. But, the CAS clustering is not working. If I shut down the first server, and browse to the second server, then I am prompted to login again to the second server. This is the log from Catalina.out. Oct 15, 2007 12:44:24 PM org.apache.catalina.cluster.tcp.SimpleTcpCluster start INFO: Cluster is about to start Oct 15, 2007 12:44:24 PM org.apache.catalina.cluster.tcp.ReplicationTransmitter start INFO: Start ClusterSender at cluster Catalina:type=Cluster,host=localhost with name Catalina:type=ClusterSender,host=localhost Oct 15, 2007 12:44:24 PM org.apache.catalina.cluster.mcast.McastServiceImpl setupSocket INFO: Setting cluster mcast TTL to 1 Oct 15, 2007 12:44:24 PM org.apache.catalina.cluster.mcast.McastService start INFO: Sleeping for 2000 milliseconds to establish cluster membership Oct 15, 2007 12:44:26 PM org.apache.catalina.cluster.mcast.McastService registerMBean INFO: membership mbean registered (Catalina:type=ClusterMembership,host=localhost) Oct 15, 2007 12:44:29 PM org.apache.catalina.cluster.session.DeltaManager start INFO: Register manager /cas to cluster element Host with name localhost Oct 15, 2007 12:44:29 PM org.apache.catalina.cluster.session.DeltaManager start INFO: Starting clustering manager at /cas Oct 15, 2007 12:44:29 PM org.apache.catalina.cluster.session.DeltaManager getAllClusterSessions INFO: Manager [/cas]: skipping state transfer. No members active in cluster group. 2007-10-15 12:44:32,075 INFO [org.jasig.cas.util.JBossCacheFactoryBean] - Starting TreeCache service. --- GMS: address is 127.0.0.1:32789 Cliff Bryant This e-mail and any files transmitted with it are confidential and are intended solely for the use of the individual or entity to whom they are addressed. This communication may contain information that is protected from disclosure by applicable law. If you are not the intended recipient, or the employee or agent responsible for delivering this communication to the intended recipient, be advised that you have received this e-mail in error and any use, dissemination, forwarding, printing or copying of this e-mail is strictly prohibited. If you believe that you have received this e-mail in error, please immediately notify Edgewater Technology by telephone at (781) 246-3343 and delete the communication from all e-mail files. No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.5.488 / Virus Database: 269.14.10/1070 - Release Date: 10/14/2007 9:22 AM - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail and any files transmitted with it are confidential and are intended solely for the use of the individual or entity to whom they are addressed. This communication may contain information that is protected from disclosure by applicable law. If you are not the intended recipient, or the employee or agent responsible for delivering this communication to the intended recipient, be advised that you have received this e-mail in error and any use, dissemination, forwarding, printing or copying of this e-mail is strictly prohibited. If you believe that you have received this e-mail in error, please immediately notify Edgewater Technology by telephone at (781) 246-3343 and delete the communication from all e-mail files. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL
Re: StreamCorruptedException - where to look to fix
David kerber wrote: Running TC 5.5.15 on Windows server 2003, JRE 1.5.0_12. Where do I start looking to try to fix the exception below? I get this on most startups of Tomcat. I know it's related to reloading sessions that were saved on the previous shutdown, and I've fixed a few serialization errors in my classes, but can't figure this one out. The shutdown appears to be normal in the log: Do you actually need to reload the saved sessions? p Oct 15, 2007 4:17:14 PM org.apache.coyote.http11.Http11AprProtocol pause INFO: Pausing Coyote HTTP/1.1 on http-8081 Oct 15, 2007 4:17:14 PM org.apache.coyote.ajp.AjpAprProtocol pause INFO: Pausing Coyote AJP/1.3 on ajp-8009 Oct 15, 2007 4:17:15 PM org.apache.catalina.core.StandardService stop INFO: Stopping service Catalina 2007-10-15 16:17:15: debugValue = 1: Context destroyed: [EMAIL PROTECTED] Oct 15, 2007 4:17:15 PM org.apache.coyote.http11.Http11AprProtocol destroy INFO: Stopping Coyote HTTP/1.1 on http-8081 Oct 15, 2007 4:17:15 PM org.apache.coyote.ajp.AjpAprProtocol destroy INFO: Stopping Coyote AJP/1.3 on ajp-8009 Oct 15, 2007 4:17:29 PM org.apache.coyote.http11.Http11AprProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8081 Oct 15, 2007 4:17:29 PM org.apache.coyote.ajp.AjpAprProtocol init INFO: Initializing Coyote AJP/1.3 on ajp-8009 Oct 15, 2007 4:17:29 PM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 500 ms Oct 15, 2007 4:17:29 PM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Oct 15, 2007 4:17:29 PM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.5.15 Oct 15, 2007 4:17:29 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled Oct 15, 2007 4:17:29 PM org.apache.catalina.startup.ContextConfig applicationWebConfig INFO: Missing application web.xml, using defaults only StandardEngine[Catalina].StandardHost[localhost].StandardContext[] Oct 15, 2007 4:17:29 PM org.apache.catalina.session.StandardManager doLoad SEVERE: IOException while loading persisted sessions: java.io.StreamCorruptedException java.io.StreamCorruptedException at java.io.ObjectInputStream$BlockDataInputStream.readBlockHeader(Unknown Source) at java.io.ObjectInputStream$BlockDataInputStream.refill(Unknown Source) at java.io.ObjectInputStream$BlockDataInputStream.skipBlockData(Unknown Source) at java.io.ObjectInputStream.skipCustomData(Unknown Source) at java.io.ObjectInputStream.readSerialData(Unknown Source) at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) at java.io.ObjectInputStream.readObject0(Unknown Source) at java.io.ObjectInputStream.readObject(Unknown Source) at java.util.ArrayList.readObject(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at java.io.ObjectStreamClass.invokeReadObject(Unknown Source) at java.io.ObjectInputStream.readSerialData(Unknown Source) at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) at java.io.ObjectInputStream.readObject0(Unknown Source) at java.io.ObjectInputStream.readObject(Unknown Source) at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1384) at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:919) at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:393) at org.apache.catalina.session.StandardManager.load(StandardManager.java:320) at org.apache.catalina.session.StandardManager.start(StandardManager.java:636) at org.apache.catalina.core.ContainerBase.setManager(ContainerBase.java:431) at org.apache.catalina.startup.ContextConfig.managerConfig(ContextConfig.java:403) at org.apache.catalina.startup.ContextConfig.start(ContextConfig.java:1066) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:261) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) at org.apache.catalina.core.StandardContext.start(StandardContext.java:4111) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524) at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:603) at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:535) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:470) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1118) at
request.getRemoteuser returns null
I'll try to make this as short and clear as I can. I have an instalation of Apache 2.2.6 and tomcat 6.0.14. On the apache side we have instaled the kerberos mod for authentication. that one is installed ok, we have a php file that prints out the headers and remoteuser has the correct value. I am trying to do the same thing for a jsp file in tomcat(I want the request.getParameter to return the login name of the user logged in). Now as I remember, for tomcat in server.xml in conf, by setting the tomcatAuthentication=false for the AJP1.3 connector the getRemoteUser should return the user authenticated through Apache, right? still, my request.getRemoteuser returns null. So what am I doing wrong or what else needs configuring? 10x in advance Fussy? Opinionated? Impossible to please? Perfect. Join Yahoo!'s user panel and lay it on us. http://surveylink..yahoo.com/gmrs/yahoo_panel_invite.asp?a=7 - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
No servlet class has been specified for servlet null
Hi, I’m trying to bend tomcat in my own application. Therefore I’m using the Embedded Tomcat version 5.5.23. I have started only a server, engine, host and context, so I have a server without the sockets etc. this because it has to become a test-application for the web-app of the company. The server starts gracefully, but when I call context.invoke(request,response) I get this error: SEVERE: Allocate exception for servlet null With this stacktrace: javax.servlet.ServletException: No servlet class has been specified for servlet null at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:10 16) at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:791) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja va:127) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja va:174) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:870) at nl.realworks.embedTomcat.EmbedTomcat.invoke(EmbedTomcat.java:74) at nl.realworks.embedTomcat.StartEmbedTomcat.main(StartEmbedTomcat.java:29) Exception in thread main java.lang.NullPointerException at org.apache.catalina.connector.Request.setAttribute(Request.java:1383) at org.apache.catalina.core.StandardWrapperValve.exception(StandardWrapperValve .java:331) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja va:145) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja va:174) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:870) at nl.realworks.embedTomcat.EmbedTomcat.invoke(EmbedTomcat.java:74) at nl.realworks.embedTomcat.StartEmbedTomcat.main(StartEmbedTomcat.java:29) does anyone has a idea what the cause of this problem is? The request I send is “GET /index.jsp” using a MockHttpServletRequest of the spring framework. I convert the mockhttpservletrequest to a org.apache.cataline.connecor.Request. and that works. The code in tomcat where the error is caused by: // Complain if no servlet class has been specified if (actualClass == null) { unavailable(null); throw new ServletException (sm.getString(standardWrapper.notClass, getName())); } Thanks in advance. Auke Noppe No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.488 / Virus Database: 269.14.12/1072 - Release Date: 15-10-2007 17:55
RE: More number of connections got created than maxActive
I found that issue is around minIdle settings. When I had following settings: maxActive = 50 maxIdle = 30 minIdle=30 factory=org.apache.commons.dbcp.BasicDataSourceFactory maxWait=1 timeBetweenEvictionRunsMillis=90 numTestsPerEvictionRun=50 minEvictableIdleTimeMillis=180 testWhileIdle=true testOnBorrow = true validationQuery='select 1 from dual' Number of connections in the pool went upto 121. When I changed minIdle to 15 and did my load test connecitons in the pool went upto 66 Looks like maxActive is getting bypassed with minIdle. When I changed minIdle to 10 and did my load test connections in the pool went upto 24 Can someone please throw light on what is going on here? I am using DBCP 1.2.1 Bhaskar -Original Message- From: Bhaskar [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 16, 2007 10:20 AM To: 'Tomcat Users List' Subject: RE: More number of connections got created than maxActive Yes. I tested it. After stopping tomcat, all connections to oracle went down and only my app was running in tomcat . -Original Message- From: David Smith [mailto:[EMAIL PROTECTED] Sent: Monday, October 15, 2007 6:59 PM To: Tomcat Users List Subject: Re: More number of connections got created than maxActive Can you determine with certainty that this one pool was responsible for all 121 connections? You don't have any other webapps with their own pool hitting the same db? --David Bhaskar wrote: Hi, I am currently using dbcp 1.2.1 with common pool 1.3. Currently i have following settings in server.xml: maxActive = 50 maxIdle = 30 minIdle=30 factory=org.apache.commons.dbcp.BasicDataSourceFactory maxWait=1 timeBetweenEvictionRunsMillis=90 numTestsPerEvictionRun=50 minEvictableIdleTimeMillis=180 testWhileIdle=true testOnBorrow = true validationQuery='select 1 from dual' Issue is when i restarted tomcat, i seen there were only 6 connections. After 15 minutes, i see there were 121 connections in netstat against oracle port. Can someone please help me understand the DBCP behaviour here? how can it go beyond maxActive? Thanks, Bhaskar System info: --- S Y S T E M --- OS:Red Hat Enterprise Linux AS release 4 (Nahant Update 2) uname:Linux 2.6.9-22.ELsmp #1 SMP Mon Sep 19 18:32:14 EDT 2005 i686 vm_info: Java HotSpot(TM) Server VM (1.4.2_13-b06) for linux-x86, built on Oct 18 2006 09:55:11 by unknown with unknown compiler - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
Hans van Zijst wrote: Hi, Since I updated my system last week, mod_jk doesn't work anymore. Tomcat starts up just fine, no errors or warnings. I checked that the AJP1.3 connector runs, it listens on port 8009. Apache runs fine as well, but as soon as I connect to the URL I mapped to Tomcat, I get: [error] jk_handler::mod_jk.c (2223): Could not init service for worker=confluence I did a few traces and found out that no connection is attempted to port 8009, so I assume the problem is somewhere in my Apache config. I'm lost for answers as I couldn't find anything on the web or in my documentation. Can anyone please point me in the right direction? This is my configuration: Linux (Debian Lenny, i386) Tomcat 5.5 Apache 2.2.6 mod_jk 1.2.25 Fine. What's your platform (OS)? Here's my workers.properties: BEGIN workers.properties worker.list=confluence worker.confluence.host=localhost worker.confluence.port=8009 worker.confluence.type=ajp13 Very basic, but OK. END workers.properties I configured mod_jk to log as much as possible. This is what it logs (from startup to Internal server error): What do you mean by Internal server error: this string is not shown here. Is there anything in the Apache error log? BEGIN mod_jk log [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] open_jklog::mod_jk.c (2652): log time stamp format is '[%a %b %d %H:%M:%S.%Q %Y] ' [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] uri_worker_map_open::jk_uri_worker_map.c (423): rule map size is 2 [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (372): exact rule '/confluence=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (364): wildchar rule '/confluence/*=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [info] init_jk::mod_jk.c (2775): mod_jk/1.2.25 initialized [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] open_jklog::mod_jk.c (2652): log time stamp format is '[%a %b %d %H:%M:%S.%Q %Y] ' [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] uri_worker_map_open::jk_uri_worker_map.c (423): rule map size is 2 [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (372): exact rule '/confluence=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (364): wildchar rule '/confluence/*=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.891 2007] [15502:3078624944] [info] init_jk::mod_jk.c (2775): mod_jk/1.2.25 initialized [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] map_uri_to_worker::jk_uri_worker_map.c (597): Attempting to map URI '/confluence/' from 2 maps [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] map_uri_to_worker::jk_uri_worker_map.c (609): Attempting to map context URI '/confluence/*=confluence' source 'JkMount' [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] map_uri_to_worker::jk_uri_worker_map.c (624): Found a wildchar match '/confluence/*=confluence' [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] jk_handler::mod_jk.c (2131): Into handler jakarta-servlet worker=confluence r-proxyreq=0 [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] wc_get_worker_for_name::jk_worker.c (115): found a worker confluence [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] wc_maintain::jk_worker.c (323): Maintaining worker confluence [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] wc_get_name_for_type::jk_worker.c (292): Found worker type 'ajp13' [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [error] jk_handler::mod_jk.c (2223): Could not init service for worker=confluence this dump doesn't show any lines, which assure, that workers.properties got found and read. Usually it should dump the contents of the workers.properties in debug log level. You should find lines close to the following: [Tue Oct 16 12:08:49.730 2007] [7002:1] [debug] do_shm_open::jk_shm.c (402): Truncated shared memory to 28800 [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] do_shm_open::jk_shm.c (447): Initialized shared memory size=28800 free=28672 addr=0xfee5 [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] do_shm_open_lock::jk_shm.c (321): Opened shared memory lock /some/path/logs/jk-runtime-status.7002.lock [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] init_jk::mod_jk.c (2673): Initialized shm:/some/path/logs/jk-runtime-status.7002 (28672 bytes) [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] init_jk::mod_jk.c (2690): Setting default connection pool max size to 1 [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] jk_map_read_property::jk_map.c (492): Adding property 'worker.list' with value 'confluence' to map. [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug]
Tomcat Commons logging and log4j
Hi All, I have been working with tomcat and log4j for a while and it worked perfectly. Now I have updated all my web apps to use commons logging. I have discovered that the Tomcat developers have absolutly no idea how to do something right when it comes to commons logging and I am curious to why. I tried tomcat 5.028 and commons logging. I discovered that tomcat used it's own commons-logging-api.jar file and it was impossible to override this commons logging file. I am running tomcat 6 now and I have discovered that tomcat 6 uses commons logging without log4j enabled. I have log4j.jar and commons-logging-1.1.jar in my webapp\WEB-INF\lib directory and I put my log4j.properties file in the webapp\WEB-INF\classes ditrectory so this should be correct. If I create a FileAppender like this: log4j.appender.fileout=org.apache.log4j.RollingFileAppender log4j.appender.fileout.File=/tmp/myLog.log log4j.appender.fileout.MaxFileSize=1024KB log4j.appender.fileout.MaxBackupIndex=1 log4j.appender.fileout.layout=org.apache.log4j.PatternLayout log4j.appender.fileout.layout.conversionPattern=[%-6p] %-13d{ABSOLUTE} %-26C{1} %-4L %m%n I have discovered that the /tmp/myLog.log is created but nothing is outputed to this file. I am curious, why have the tomcat developers disabled something that is so commonly used? Thanks in advance, Martyn - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: redirecting old context uris when moving context [SOLVED]
Thanks for the comments, I ended up writing a little servlet filter. I forgot to mention that I had a filter mapping /* on the root context, so that /someuri was being caught by the root context first, so I needed a filter to bypass this. We're also not proxying through apache. Cheers Daniel M Garland wrote: Hi I was formerly hosting a web application at http://somehost/somecontext which I am now hosting at http://somehost so that the context is now ROOT, instead of somecontext. Is there a way of mapping / redirecting 'old' URI from somecontext to the ROOT, so that http://somehost/somecontext/someuri becomes http://somehost/someuri This would be advantageous to me because bookmarked / search-engine listings for /someuri are now giving a 404, which I'd prefer to be a redirect. There is also the matter of links on other websites. Thanks in advance Dan Garland __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
Hi Rainer, Thanks for the reply. [EMAIL PROTECTED] 16-10-2007 12:11:54 This is my configuration: Linux (Debian Lenny, i386) Tomcat 5.5 Apache 2.2.6 mod_jk 1.2.25 Fine. What's your platform (OS)? I run Linux, kernel 2.6.22 on an i386, with Sun's SDK 1.5, update 12 and Tomcat 5.5.25. I configured mod_jk to log as much as possible. This is what it logs (from startup to Internal server error): What do you mean by Internal server error: this string is not shown here. Is there anything in the Apache error log? Ah, sorry. The Internal server error is the message my browser displays when I connect. It first asks for the SSL certificate and then forwards me to the mapped URL, but I never get there. The Apache log doesn't show much: [Tue Oct 16 11:58:04 2007] [warn] No JkLogFile defined in httpd.conf. Using default /var/log/apache2/mod_jk.log [Tue Oct 16 11:58:04 2007] [warn] No JkShmFile defined in httpd.conf. Using default /var/log/apache2/jk-runtime-status [Tue Oct 16 11:58:04 2007] [info] Loading certificate private key of SSL-aware server [Tue Oct 16 11:58:04 2007] [info] Configuring server for SSL protocol [Tue Oct 16 11:58:04 2007] [warn] No JkLogFile defined in httpd.conf. Using default /var/log/apache2/mod_jk.log [Tue Oct 16 11:58:04 2007] [warn] No JkShmFile defined in httpd.conf. Using default /var/log/apache2/jk-runtime-status [Tue Oct 16 11:58:04 2007] [info] Loading certificate private key of SSL-aware server [Tue Oct 16 11:58:04 2007] [info] Configuring server for SSL protocol [Tue Oct 16 11:58:04 2007] [notice] Apache/2.2.6 (Debian) mod_jk/1.2.25 mod_ssl/2.2.6 OpenSSL/0.9.8e configured -- resuming normal operations [Tue Oct 16 11:58:18 2007] [info] [client 10.15.7.31] Connection to child 64 established (server xxx.xxx.xxx:443) [Tue Oct 16 11:58:18 2007] [info] Seeding PRNG with 648 bytes of entropy [Tue Oct 16 11:58:27 2007] [info] Initial (No.1) HTTPS request received for child 64 (server xxx.xxx.xxx:443) [Tue Oct 16 11:58:27 2007] [info] [client 10.15.7.31] Connection closed to child 64 with standard shutdown (server xxx.xxx.xxx:443) That is, this is Apache's errorlog, the access log only states that Apache was started. BEGIN mod_jk log [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] open_jklog::mod_jk.c (2652): log time stamp format is '[%a %b %d %H:%M:%[CUT -- CUT -- CUT] [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [error] jk_handler::mod_jk.c (2223): Could not init service for worker=confluence this dump doesn't show any lines, which assure, that workers.properties got found and read. Usually it should dump the contents of the workers.properties in debug log level. You should find lines close to the following: [Tue Oct 16 12:08:49.730 2007] [7002:1] [debug] do_shm_open::jk_shm.c (402): Truncated shared memory to 28800 [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] do_shm_open::jk_shm.c (447): Initialized shared memory size=28800 free=28672 addr=0xfee5 [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] do_shm_open_lock::jk_shm.c (321): Opened shared memory lock /some/path/logs/jk-runtime-status.7002.lock [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] init_jk::mod_jk.c (2673): Initialized shm:/some/path/logs/jk-runtime-status.7002 (28672 bytes) [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] init_jk::mod_jk.c (2690): Setting default connection pool max size to 1 [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] jk_map_read_property::jk_map.c (492): Adding property 'worker.list' with value 'confluence' to map. [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] jk_map_resolve_references::jk_map.c (752): Checking for references with prefix worker. with wildcard (recursion 1) [Tue Oct 16 12:08:49.731 2007] [7002:1] [debug] jk_map_dump::jk_map.c (590): Dump of map: 'ServerRoot' - '/opt/build/test/apache22-prefork-2.2.6sp1_0.9.8e-1' [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] jk_map_dump::jk_map.c (590): Dump of map: 'worker.list' - 'confluence' [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] build_worker_map::jk_worker.c (241): creating worker confluence [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] wc_create_worker::jk_worker.c (145): about to create instance confluence of ajp13 [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] wc_create_worker::jk_worker.c (158): about to validate and init confluence [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] ajp_validate::jk_ajp_common.c (2216): worker confluence contact is ' localhost:8009' [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] ajp_init::jk_ajp_common.c (2346): setting endpoint options: [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] ajp_init::jk_ajp_common.c (2349): keepalive:0 [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] ajp_init::jk_ajp_common.c (2353): timeout: 0 [Tue Oct 16 12:08:49.732 2007] [7002:1] [debug] ajp_init::jk_ajp_common.c (2357): buffer size: 0 [Tue
Re: Tomcat Commons logging and log4j
Martyn Hiemstra wrote: Hi All, I have been working with tomcat and log4j for a while and it worked perfectly. Now I have updated all my web apps to use commons logging. I have discovered that the Tomcat developers have absolutly no idea how to do something right when it comes to commons logging and I am curious to why. Non-specific insults are likely to generate attention, but unlikely to encourage help. Never-the-less, I will attempt to assist. I tried tomcat 5.028 and commons logging. I discovered that tomcat used it's own commons-logging-api.jar file and it was impossible to override this commons logging file. commons-logging-api is not the same as commons-logging I am running tomcat 6 now and I have discovered that tomcat 6 uses commons logging without log4j enabled. log4j is 'enabled' when you configure it and supply the jar file. I have log4j.jar and commons-logging-1.1.jar in my webapp\WEB-INF\lib directory and I put my log4j.properties file in the webapp\WEB-INF\classes ditrectory so this should be correct. Sounds just like the configuration I am using, successfully I might add. If I create a FileAppender like this: log4j.appender.fileout=org.apache.log4j.RollingFileAppender log4j.appender.fileout.File=/tmp/myLog.log log4j.appender.fileout.MaxFileSize=1024KB log4j.appender.fileout.MaxBackupIndex=1 log4j.appender.fileout.layout=org.apache.log4j.PatternLayout log4j.appender.fileout.layout.conversionPattern=[%-6p] %-13d{ABSOLUTE} %-26C{1} %-4L %m%n I have discovered that the /tmp/myLog.log is created but nothing is outputed to this file. From the obvious questions department: * have you set a logging level that will permit log messages to be written to the file? * what attributes are set in your application context configuration? I am curious, why have the tomcat developers disabled something that is so commonly used? It's not disabled, you are probably doing something wrong. Log4J works perfectly well if it's configured correctly. p Thanks in advance, Martyn - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSR 199 (Jsr199JavaCompiler) compile errors
Mark, Thank you for your reply. I am aware that Glassfish is not Tomcat. However, it seems to me that since the class in question is managed by Apache that there must have been some level of collaboration between the two teams and a reasonable assumption on my part that Apache may have been working to enable Jasper to address JSR 199. It appears that you are implying something to the contrary; along the lines that Sun may have taken a snapshot of Jasper and modified it specifically for Glassfish perhaps. This is certainly possible but, I don't see this as feasible since they have made the statement that they (Sun) have adopted Jasper as their compiler. With all that said, it still leaves me in a place where I'm wondering how Jasper might be used to actually compile a JSP outside of using the ANT or JSPC approach. Now, that Java SE 6 has a nice Compile class it seems like we are much closer to being able to take a standardized approach to real-time compilation. This, in essence is what I am attempting to explore. The class I mentioned appeared, at least on the surface, to be such an effort on the part of Sun and Apache. I am willing to concede that perhaps it is not and would like that clarification from Apache or Sun should that be the case. Thanks, Fran Mark Thomas-15 wrote: Fran Varin wrote: Thank you for your reply. I d/l'd from the following location: http://repo1.maven.org/maven-java.net/jasper-jsr199/java-sources/ The information was based on this article: http://blogs.sun.com/kchung/entry/speed_up_jsp_compilations_with Glassfish != Tomcat There is no guarantee that the internal interfaces are the same. Mark - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/JSR-199-%28Jsr199JavaCompiler%29-compile-errors-tf4629050.html#a13231996 Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
Good Morning http://localhost/ I mirrored your configuration: RewriteEngine On RewriteLogLevel 3 RewriteRule ^/confluence/ - [R,L] RewriteRule ^(.*)$ /confluence/$1 [R,L,NE] DocumentRoot /var/www/confluence/confluence Directory / Options FollowSymLinks AllowOverride None /Directory Directory /var/www/confluence/confluence/ Options Indexes FollowSymLinks MultiViews AllowOverride None Order allow,deny allow from all ##SSLRequireSSL /Directory Alias /confluence /var/www/confluence/confluence Location /confluence/WEB-INF/* deny from all /Location Location /confluence/META-INF/* deny from all /Location and see this entry in $APACHE2_HOME/logs/access.log 127.0.0.1 - - [17/Oct/2000:08:13:00 -0400] GET /confluence// HTTP/1.1 200 148 in \var\www\confluence\confluence I have one index.html which reads as follows html head titleThis is in var\www\confluence\confluence/title /head body This is in var\www\confluence\confluence /body /html and this is what I see when I reference localhost:80 This is in var\www\confluence\confluence So the configuration does work in Apache2 using this version of mod_rewrite mod_rewrite.so 7/27/2006 57,426 Martin-- - Original Message - Wrom: CMHVIBGDADRZFSQHYUCDDJBLVLMHAALPTCXLYRW To: Tomcat Users List users@tomcat.apache.org Sent: Tuesday, October 16, 2007 6:11 AM Subject: Re: mod_jk: Could not init service for worker Hans van Zijst wrote: Hi, Since I updated my system last week, mod_jk doesn't work anymore. Tomcat starts up just fine, no errors or warnings. I checked that the AJP1.3 connector runs, it listens on port 8009. Apache runs fine as well, but as soon as I connect to the URL I mapped to Tomcat, I get: [error] jk_handler::mod_jk.c (2223): Could not init service for worker=confluence I did a few traces and found out that no connection is attempted to port 8009, so I assume the problem is somewhere in my Apache config. I'm lost for answers as I couldn't find anything on the web or in my documentation. Can anyone please point me in the right direction? This is my configuration: Linux (Debian Lenny, i386) Tomcat 5.5 Apache 2.2.6 mod_jk 1.2.25 Fine. What's your platform (OS)? Here's my workers.properties: BEGIN workers.properties worker.list=confluence worker.confluence.host=localhost worker.confluence.port=8009 worker.confluence.type=ajp13 Very basic, but OK. END workers.properties I configured mod_jk to log as much as possible. This is what it logs (from startup to Internal server error): What do you mean by Internal server error: this string is not shown here. Is there anything in the Apache error log? BEGIN mod_jk log [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] open_jklog::mod_jk.c (2652): log time stamp format is '[%a %b %d %H:%M:%S.%Q %Y] ' [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] uri_worker_map_open::jk_uri_worker_map.c (423): rule map size is 2 [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (372): exact rule '/confluence=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (364): wildchar rule '/confluence/*=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.742 2007] [15501:3078624944] [info] init_jk::mod_jk.c (2775): mod_jk/1.2.25 initialized [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] open_jklog::mod_jk.c (2652): log time stamp format is '[%a %b %d %H:%M:%S.%Q %Y] ' [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] uri_worker_map_open::jk_uri_worker_map.c (423): rule map size is 2 [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (372): exact rule '/confluence=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.890 2007] [15502:3078624944] [debug] uri_worker_map_add::jk_uri_worker_map.c (364): wildchar rule '/confluence/*=confluence' source 'JkMount' was added [Thu Oct 11 11:10:04.891 2007] [15502:3078624944] [info] init_jk::mod_jk.c (2775): mod_jk/1.2.25 initialized [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] map_uri_to_worker::jk_uri_worker_map.c (597): Attempting to map URI '/confluence/' from 2 maps [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] map_uri_to_worker::jk_uri_worker_map.c (609): Attempting to map context URI '/confluence/*=confluence' source 'JkMount' [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] map_uri_to_worker::jk_uri_worker_map.c (624): Found a wildchar match '/confluence/*=confluence' [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] jk_handler::mod_jk.c (2131): Into handler jakarta-servlet worker=confluence r-proxyreq=0 [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug] wc_get_worker_for_name::jk_worker.c (115): found a worker confluence [Thu Oct 11 11:10:14.351 2007] [15508:3060181904] [debug]
Re: Tomcat Commons logging and log4j
Hi Pid, Thanks for your response. Please forgive my initial response. After reading so much about how JCL isnt working correctly under Tomcat I was getting frustrated. Having to spend 2 days getting it to work without success is for every programmer frustrating. I found this website: http://tomcat.apache.org/tomcat-6.0-doc/logging.html It states that you need to activate it by building something first. This means it isnt enabled be default. I even found a website where a person stated that anybody using JCL with tomcat are just plain stupid. Here is the link: http://www.bileblog.org/?p=259 These blogs/forums also indicate problems with tomcat and JCL: http://www.oreillynet.com/onjava/blog/2006/08/tomcat_5x_commons_logging_and.html http://java2.5341.com/msg/96959.html http://commons.apache.org/logging/commons-logging-1.1/troubleshooting.html#Apache_Tomcat If so many people are having problems then this must be an error on Tomcat's behalf. Also If I use the exact same lib files in the exact same place and the same configuration file but I replace protected final Log log = LogFactory.getLog( class )(JCL) with protected final Logger logger = Logger.getLogger( class )(Log4j) it should produce the same logging but it doesnt. When I use JCL no logging occures except to the system output but this is because tomcat uses java.util.Logging and that defaults output to the System.out I hope someone can help out in getting JCL with tomcat and log4j to work. Thanks in advance, Martyn Pid schreef: Martyn Hiemstra wrote: Hi All, I have been working with tomcat and log4j for a while and it worked perfectly. Now I have updated all my web apps to use commons logging. I have discovered that the Tomcat developers have absolutly no idea how to do something right when it comes to commons logging and I am curious to why. Non-specific insults are likely to generate attention, but unlikely to encourage help. Never-the-less, I will attempt to assist. I tried tomcat 5.028 and commons logging. I discovered that tomcat used it's own commons-logging-api.jar file and it was impossible to override this commons logging file. commons-logging-api is not the same as commons-logging I am running tomcat 6 now and I have discovered that tomcat 6 uses commons logging without log4j enabled. log4j is 'enabled' when you configure it and supply the jar file. I have log4j.jar and commons-logging-1.1.jar in my webapp\WEB-INF\lib directory and I put my log4j.properties file in the webapp\WEB-INF\classes ditrectory so this should be correct. Sounds just like the configuration I am using, successfully I might add. If I create a FileAppender like this: log4j.appender.fileout=org.apache.log4j.RollingFileAppender log4j.appender.fileout.File=/tmp/myLog.log log4j.appender.fileout.MaxFileSize=1024KB log4j.appender.fileout.MaxBackupIndex=1 log4j.appender.fileout.layout=org.apache.log4j.PatternLayout log4j.appender.fileout.layout.conversionPattern=[%-6p] %-13d{ABSOLUTE} %-26C{1} %-4L %m%n I have discovered that the /tmp/myLog.log is created but nothing is outputed to this file. From the obvious questions department: * have you set a logging level that will permit log messages to be written to the file? * what attributes are set in your application context configuration? I am curious, why have the tomcat developers disabled something that is so commonly used? It's not disabled, you are probably doing something wrong. Log4J works perfectly well if it's configured correctly. p Thanks in advance, Martyn - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
Hi Martin, The problem is not in mod_rewrite, but in mod_jk. The mod_rewrite has worked like a charm from the beginning, mod_jk has stopped working little more than a week ago. Kind regards, Hans [EMAIL PROTECTED] 17-10-2000 14:22:31 Good Morning http://localhost/ I mirrored your configuration: [ CUT -- CUT -- CUT ] So the configuration does work in Apache2 using this version of mod_rewrite mod_rewrite.so 7/27/2006 57,426 Martin-- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat Commons logging and log4j
Martyn Hiemstra wrote: Hi Pid, Thanks for your response. Please forgive my initial response. After reading so much about how JCL isnt working correctly under Tomcat I was getting frustrated. Having to spend 2 days getting it to work without success is for every programmer frustrating. I found this website: http://tomcat.apache.org/tomcat-6.0-doc/logging.html It states that you need to activate it by building something first. This means it isnt enabled be default. By default, only java.util.logging is available for the core Tomcat The key word there is core. I'm assuming that you want to use log4j for your *application* logging, not to log internal Tomcat server activity. If so, you can safely ignore the references above as they do not apply to your situation. I even found a website where a person stated that anybody using JCL with tomcat are just plain stupid. Here is the link: http://www.bileblog.org/?p=259 It's a rant, ignore it. These blogs/forums also indicate problems with tomcat and JCL: http://www.oreillynet.com/onjava/blog/2006/08/tomcat_5x_commons_logging_and.html Again, n/a if you're using Tomcat 6. http://java2.5341.com/msg/96959.html This seems to refer to a classloader issue, and not an internal problem with Tomcat. http://commons.apache.org/logging/commons-logging-1.1/troubleshooting.html#Apache_Tomcat Again, not applicable. commons-logging-api is NOT commons-logging, and the apache docs even go on to explain that putting a later version of commons-logging into a webapp classpath is entirely possible and will in fact work as advertised because commons-logging-api *does not contain any log adapters*. If so many people are having problems then this must be an error on Tomcat's behalf. You are yet to demonstrate that there is a problem with Tomcat, or in fact the Tomcat is unable to use Log4J. As I stated before, I am successfully using JCL and Log4J on a number of servers - as I'm sure other lists members are too. Also If I use the exact same lib files in the exact same place and the same configuration file but I replace protected final Log log = LogFactory.getLog( class )(JCL) with protected final Logger logger = Logger.getLogger( class )(Log4j) it should produce the same logging but it doesnt. When I use JCL no logging occures except to the system output but this is because tomcat uses java.util.Logging and that defaults output to the System.out (see below) I hope someone can help out in getting JCL with tomcat and log4j to work. I am trying to, but you're determined to stick to your faulty assumption that there's a fault with Tomcat (which there doesn't appear to be to me). I shall repeat my questions: * have you set a logging level that will permit log messages to be written to the file? * what attributes are set in your application context configuration? E.g. is the swallowOutput=true attribute set? http://tomcat.apache.org/tomcat-6.0-doc/config/context.html Answer these, and we'll continue. p Thanks in advance, Martyn Pid schreef: Martyn Hiemstra wrote: Hi All, I have been working with tomcat and log4j for a while and it worked perfectly. Now I have updated all my web apps to use commons logging. I have discovered that the Tomcat developers have absolutly no idea how to do something right when it comes to commons logging and I am curious to why. Non-specific insults are likely to generate attention, but unlikely to encourage help. Never-the-less, I will attempt to assist. I tried tomcat 5.028 and commons logging. I discovered that tomcat used it's own commons-logging-api.jar file and it was impossible to override this commons logging file. commons-logging-api is not the same as commons-logging I am running tomcat 6 now and I have discovered that tomcat 6 uses commons logging without log4j enabled. log4j is 'enabled' when you configure it and supply the jar file. I have log4j.jar and commons-logging-1.1.jar in my webapp\WEB-INF\lib directory and I put my log4j.properties file in the webapp\WEB-INF\classes ditrectory so this should be correct. Sounds just like the configuration I am using, successfully I might add. If I create a FileAppender like this: log4j.appender.fileout=org.apache.log4j.RollingFileAppender log4j.appender.fileout.File=/tmp/myLog.log log4j.appender.fileout.MaxFileSize=1024KB log4j.appender.fileout.MaxBackupIndex=1 log4j.appender.fileout.layout=org.apache.log4j.PatternLayout log4j.appender.fileout.layout.conversionPattern=[%-6p] %-13d{ABSOLUTE} %-26C{1} %-4L %m%n I have discovered that the /tmp/myLog.log is created but nothing is outputed to this file. From the obvious questions department: * have you set a logging level that will permit log messages to be written to the file? * what attributes are set in your application context configuration? I am curious, why have the tomcat developers
Re: mod_jk: Could not init service for worker
Hans van Zijst wrote: How does that file look like? Are the paths OK? Does that file really get read in? The mod_jk.log is posted above. If I need to see the messages you posted, I assume that somehow the workers.properties is not being read during startup. This is how mod_jk is loaded in Apache: LoadModule jk_module /usr/lib/apache2/modules/mod_jk.so JkWorkersFile /etc/apache2/workers.properties This is the config that's included in Apache. The paths are ok. I found quite a few Tomcat messages in my syslog. Tomcat errors should be irrelevant at this stage, your mod_jk doesn't initialize correctly, even before trying to context tomcat. You could double check, if the Apache user can really read /etc/apache2/workers.properties. As a temporary workaround, since your workers.properties is very small, you could try JkWorkerProperty directives. Each line a.b.c=d of workers.properties can also be given directly in an httpd.conf include as JkWorkerProperty a.b.c=d If that works, we definitely know, that the probloem lies in finding the correct workers.properties. Your situation is definitely strange. No problems related to your symptoms are known. By the way: the JkWorkersFile directive should be included in the global part of the httpd configuration, not inside a virtual server. Last thing: if you post the jk log again with JkLogLevel trace, I can check against the normal startup lines and detect the first step during startup that's missing. Log level trace will log most function calls at function entry and return. Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSR 199 (Jsr199JavaCompiler) compile errors
Mark, I did some further digging and d/l'd the source for Glassfish. I have found that Glassfish indeed does include a version of Jasper that appears to have been modified. This confirms some of my thinking in my previous response. However, it does leave me with an uncomfortable feeling. I'm not comfortable with a statement that indicates Glassfish uses Jasper as the compiler when it is not an off the shelf version. It means to me, as a developer, that the advancements that are made appear to have not been contributed back, or at least made there way back, into the mainstream code base; in this case Jasper. So, to take advantage of this, I would need to fork the Sun version even further to try and remove any specifics that Sun may have added solely for their purpose. So, I guess the question is, does Apache intend on rolling the JSR 199 functionality into Jasper? Or is there an alternative that Apache has to offer or is possibly working on? Thanks, Fran Fran Varin wrote: Mark, Thank you for your reply. I am aware that Glassfish is not Tomcat. However, it seems to me that since the class in question is managed by Apache that there must have been some level of collaboration between the two teams and a reasonable assumption on my part that Apache may have been working to enable Jasper to address JSR 199. It appears that you are implying something to the contrary; along the lines that Sun may have taken a snapshot of Jasper and modified it specifically for Glassfish perhaps. This is certainly possible but, I don't see this as feasible since they have made the statement that they (Sun) have adopted Jasper as their compiler. With all that said, it still leaves me in a place where I'm wondering how Jasper might be used to actually compile a JSP outside of using the ANT or JSPC approach. Now, that Java SE 6 has a nice Compile class it seems like we are much closer to being able to take a standardized approach to real-time compilation. This, in essence is what I am attempting to explore. The class I mentioned appeared, at least on the surface, to be such an effort on the part of Sun and Apache. I am willing to concede that perhaps it is not and would like that clarification from Apache or Sun should that be the case. Thanks, Fran Mark Thomas-15 wrote: Fran Varin wrote: Thank you for your reply. I d/l'd from the following location: http://repo1.maven.org/maven-java.net/jasper-jsr199/java-sources/ The information was based on this article: http://blogs.sun.com/kchung/entry/speed_up_jsp_compilations_with Glassfish != Tomcat There is no guarantee that the internal interfaces are the same. Mark - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/JSR-199-%28Jsr199JavaCompiler%29-compile-errors-tf4629050.html#a13233145 Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
Hi, [EMAIL PROTECTED] 16-10-2007 14:52:45 Tomcat errors should be irrelevant at this stage, your mod_jk doesn't initialize correctly, even before trying to context tomcat. You could double check, if the Apache user can really read /etc/apache2/workers.properties. Yup, Apache can find and read the file, it's world-readable. As a temporary workaround, since your workers.properties is very small, you could try JkWorkerProperty directives. Each line a.b.c=d of workers.properties can also be given directly in an httpd.conf include as JkWorkerProperty a.b.c=d If that works, we definitely know, that the probloem lies in finding the correct workers.properties. Your situation is definitely strange. No problems related to your symptoms are known. Nice test. I tried it, but it yields exactly the same. I removed the reference to the workers.properties file and included the JkWorkerProperty statements in httpd.conf. Unfortunately the messages that appear in the log are exactly the same... Looks like the workers.properties file is being read correctly. By the way: the JkWorkersFile directive should be included in the global part of the httpd configuration, not inside a virtual server. I noticed :) Apache complained when I did a config check the first time (I added it to the VirtualHost at first). Last thing: if you post the jk log again with JkLogLevel trace, I can check against the normal startup lines and detect the first step during startup that's missing. Log level trace will log most function calls at function entry and return. Regards, Rainer See below. I switched logging to trace, restarted Apache and did the request. This is the log. Kind regards, Hans - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSR 199 (Jsr199JavaCompiler) compile errors
Fran Varin wrote: Mark, Thank you for your reply. I am aware that Glassfish is not Tomcat. However, it seems to me that since the class in question is managed by Apache that there must have been some level of collaboration between the two teams Tomcat was originated with a code donation from Sun. Some time ago (I forget exactly when), Sun started Glassfish and forked the Tomcat code as a starting point. and a reasonable assumption on my part that Apache may have been working to enable Jasper to address JSR 199. I am not aware of any efforts in this direction. It appears that you are implying something to the contrary; along the lines that Sun may have taken a snapshot of Jasper and modified it specifically for Glassfish perhaps. Exactly. This is certainly possible but, I don't see this as feasible since they have made the statement that they (Sun) have adopted Jasper as their compiler. I haven't seen that statement so can't comment. With all that said, it still leaves me in a place where I'm wondering how Jasper might be used to actually compile a JSP outside of using the ANT or JSPC approach. Now, that Java SE 6 has a nice Compile class it seems like we are much closer to being able to take a standardized approach to real-time compilation. This, in essence is what I am attempting to explore. Patches are always welcome. The class I mentioned appeared, at least on the surface, to be such an effort on the part of Sun and Apache. I am willing to concede that perhaps it is not and would like that clarification from Apache or Sun should that be the case. The above should clarify this. HTH, Mark - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat Commons logging and log4j
Hi Pid, Thanks for all your answers. Since I have been working on this problem for some while I will give it a break for a few days and then continue again with a fresh view. I'll look over everything, this time assuming the error is on my behalf. When I round up the points you have stated: * have you set a logging level that will permit log messages to be written to the file? * what attributes are set in your application context configuration? E.g. is the swallowOutput=true attribute set? http://tomcat.apache.org/tomcat-6.0-doc/config/context.html and the error still exists I shall email this list again. Thanks for time and patience. Martyn Martyn Hiemstra wrote: Hi Pid, Thanks for your response. Please forgive my initial response. After reading so much about how JCL isnt working correctly under Tomcat I was getting frustrated. Having to spend 2 days getting it to work without success is for every programmer frustrating. I found this website: http://tomcat.apache.org/tomcat-6.0-doc/logging.html It states that you need to activate it by building something first. This means it isnt enabled be default. By default, only java.util.logging is available for the core Tomcat The key word there is core. I'm assuming that you want to use log4j for your *application* logging, not to log internal Tomcat server activity. If so, you can safely ignore the references above as they do not apply to your situation. I even found a website where a person stated that anybody using JCL with tomcat are just plain stupid. Here is the link: http://www.bileblog.org/?p=259 It's a rant, ignore it. These blogs/forums also indicate problems with tomcat and JCL: http://www.oreillynet.com/onjava/blog/2006/08/tomcat_5x_commons_logging_and.html Again, n/a if you're using Tomcat 6. http://java2.5341.com/msg/96959.html This seems to refer to a classloader issue, and not an internal problem with Tomcat. http://commons.apache.org/logging/commons-logging-1.1/troubleshooting.html#Apache_Tomcat Again, not applicable. commons-logging-api is NOT commons-logging, and the apache docs even go on to explain that putting a later version of commons-logging into a webapp classpath is entirely possible and will in fact work as advertised because commons-logging-api *does not contain any log adapters*. If so many people are having problems then this must be an error on Tomcat's behalf. You are yet to demonstrate that there is a problem with Tomcat, or in fact the Tomcat is unable to use Log4J. As I stated before, I am successfully using JCL and Log4J on a number of servers - as I'm sure other lists members are too. Also If I use the exact same lib files in the exact same place and the same configuration file but I replace protected final Log log = LogFactory.getLog( class )(JCL) with protected final Logger logger = Logger.getLogger( class )(Log4j) it should produce the same logging but it doesnt. When I use JCL no logging occures except to the system output but this is because tomcat uses java.util.Logging and that defaults output to the System.out (see below) I hope someone can help out in getting JCL with tomcat and log4j to work. I am trying to, but you're determined to stick to your faulty assumption that there's a fault with Tomcat (which there doesn't appear to be to me). I shall repeat my questions: * have you set a logging level that will permit log messages to be written to the file? * what attributes are set in your application context configuration? E.g. is the swallowOutput=true attribute set? http://tomcat.apache.org/tomcat-6.0-doc/config/context.html Answer these, and we'll continue. p Thanks in advance, Martyn Pid schreef: Martyn Hiemstra wrote: Hi All, I have been working with tomcat and log4j for a while and it worked perfectly. Now I have updated all my web apps to use commons logging. I have discovered that the Tomcat developers have absolutly no idea how to do something right when it comes to commons logging and I am curious to why. Non-specific insults are likely to generate attention, but unlikely to encourage help. Never-the-less, I will attempt to assist. I tried tomcat 5.028 and commons logging. I discovered that tomcat used it's own commons-logging-api.jar file and it was impossible to override this commons logging file. commons-logging-api is not the same as commons-logging I am running tomcat 6 now and I have discovered that tomcat 6 uses commons logging without log4j enabled. log4j is 'enabled' when you configure it and supply the jar file. I have log4j.jar and commons-logging-1.1.jar in my webapp\WEB-INF\lib directory and I put my log4j.properties file in the webapp\WEB-INF\classes ditrectory so this should be correct. Sounds just like the configuration I am using,
Re: mod_jk: Could not init service for worker
Hmm, seems like attachments are filtered out :) See below. I switched logging to trace, restarted Apache and did the request. This is the log. [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [debug] open_jklog::mod_jk.c (2652): log time stamp format is '[%a %b %d %H:%M:%S.%Q %Y] ' [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [trace] uri_worker_map_alloc::jk_uri_worker_map.c (182): enter [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [trace] uri_worker_map_open::jk_uri_worker_map.c (407): enter [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [debug] uri_worker_map_open::jk_uri_worker_map.c (423): rule map size is 1 [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [trace] uri_worker_map_add::jk_uri_worker_map.c (315): enter [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [debug] uri_worker_map_add::jk_uri_worker_map.c (364): wildchar rule '/confluence/*=confluence' source 'JkMount' was added [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [trace] uri_worker_map_add::jk_uri_worker_map.c (398): exit [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [trace] uri_worker_map_open::jk_uri_worker_map.c (479): exit [Tue Oct 16 15:11:44.732 2007] [8966:3078547120] [trace] uri_worker_map_alloc::jk_uri_worker_map.c (198): exit [Tue Oct 16 15:11:44.733 2007] [8966:3078547120] [info] init_jk::mod_jk.c (2775): mod_jk/1.2.25 initialized [Tue Oct 16 15:11:44.973 2007] [8967:3078547120] [debug] open_jklog::mod_jk.c (2652): log time stamp format is '[%a %b %d %H:%M:%S.%Q %Y] ' [Tue Oct 16 15:11:44.973 2007] [8967:3078547120] [trace] uri_worker_map_alloc::jk_uri_worker_map.c (182): enter [Tue Oct 16 15:11:44.973 2007] [8967:3078547120] [trace] uri_worker_map_open::jk_uri_worker_map.c (407): enter [Tue Oct 16 15:11:44.974 2007] [8967:3078547120] [debug] uri_worker_map_open::jk_uri_worker_map.c (423): rule map size is 1 [Tue Oct 16 15:11:44.974 2007] [8967:3078547120] [trace] uri_worker_map_add::jk_uri_worker_map.c (315): enter [Tue Oct 16 15:11:44.974 2007] [8967:3078547120] [debug] uri_worker_map_add::jk_uri_worker_map.c (364): wildchar rule '/confluence/*=confluence' source 'JkMount' was added [Tue Oct 16 15:11:44.974 2007] [8967:3078547120] [trace] uri_worker_map_add::jk_uri_worker_map.c (398): exit [Tue Oct 16 15:11:44.974 2007] [8967:3078547120] [trace] uri_worker_map_open::jk_uri_worker_map.c (479): exit [Tue Oct 16 15:11:44.974 2007] [8967:3078547120] [trace] uri_worker_map_alloc::jk_uri_worker_map.c (198): exit [Tue Oct 16 15:11:44.974 2007] [8967:3078547120] [info] init_jk::mod_jk.c (2775): mod_jk/1.2.25 initialized [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [trace] map_uri_to_worker::jk_uri_worker_map.c (542): enter [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [debug] map_uri_to_worker::jk_uri_worker_map.c (597): Attempting to map URI '/confluence/' from 1 maps [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [debug] map_uri_to_worker::jk_uri_worker_map.c (609): Attempting to map context URI '/confluence/*=confluence' source 'JkMount' [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [debug] map_uri_to_worker::jk_uri_worker_map.c (624): Found a wildchar match '/confluence/*=confluence' [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [trace] map_uri_to_worker::jk_uri_worker_map.c (627): exit [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [trace] jk_handler::mod_jk.c (2065): enter [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [debug] jk_handler::mod_jk.c (2131): Into handler jakarta-servlet worker=confluence r-proxyreq=0 [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [trace] wc_get_worker_for_name::jk_worker.c (105): enter [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [debug] wc_get_worker_for_name::jk_worker.c (115): found a worker confluence [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [trace] wc_get_worker_for_name::jk_worker.c (117): exit [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [trace] wc_maintain::jk_worker.c (309): enter [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [debug] wc_maintain::jk_worker.c (323): Maintaining worker confluence [Tue Oct 16 15:11:59.255 2007] [8973:3068496784] [trace] ajp_maintain::jk_ajp_common.c (2532): enter [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [trace] ajp_maintain::jk_ajp_common.c (2540): exit [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [trace] wc_maintain::jk_worker.c (334): exit [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [debug] wc_get_name_for_type::jk_worker.c (292): Found worker type 'ajp13' [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [error] jk_handler::mod_jk.c (2223): Could not init service for worker=confluence [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [trace] jk_handler::mod_jk.c (2227): exit - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSR 199 (Jsr199JavaCompiler) compile errors
Mark, Thank you for your note, it does clear up the confusion over this quite a bit. Regarding your comment that patches are always welcome. I am interested in pursuing this with the Jasper code base. What channels do I need to go through to open up a clear line of communication/assistance with this? I'm willing to put some of my time in on it but, would like the reassurance that I can gain access to the Jasper developers to work with them. Fran Mark Thomas-15 wrote: Fran Varin wrote: Mark, Thank you for your reply. I am aware that Glassfish is not Tomcat. However, it seems to me that since the class in question is managed by Apache that there must have been some level of collaboration between the two teams Tomcat was originated with a code donation from Sun. Some time ago (I forget exactly when), Sun started Glassfish and forked the Tomcat code as a starting point. and a reasonable assumption on my part that Apache may have been working to enable Jasper to address JSR 199. I am not aware of any efforts in this direction. It appears that you are implying something to the contrary; along the lines that Sun may have taken a snapshot of Jasper and modified it specifically for Glassfish perhaps. Exactly. This is certainly possible but, I don't see this as feasible since they have made the statement that they (Sun) have adopted Jasper as their compiler. I haven't seen that statement so can't comment. With all that said, it still leaves me in a place where I'm wondering how Jasper might be used to actually compile a JSP outside of using the ANT or JSPC approach. Now, that Java SE 6 has a nice Compile class it seems like we are much closer to being able to take a standardized approach to real-time compilation. This, in essence is what I am attempting to explore. Patches are always welcome. The class I mentioned appeared, at least on the surface, to be such an effort on the part of Sun and Apache. I am willing to concede that perhaps it is not and would like that clarification from Apache or Sun should that be the case. The above should clarify this. HTH, Mark - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/JSR-199-%28Jsr199JavaCompiler%29-compile-errors-tf4629050.html#a13233927 Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
I'm really puzzled. Somehow a lot of standard startup messages are missing. As long as they are not there, it might not be helpful to look for additional reasons, why the worker is not working. Did you define a JkLogFile (and JkLogLevel) inside the global server? Are you using one of the two standard httpd MPMs, i.e. worker or prefork? Anything special about your way of starting up apache, like using httpd -X or so? How many httpd processes do you have after startup? Could you try a binary download from the connectors site. We generally prefer compilation by the user, but for debugging it might be interesting to check with our contributed build. From the code it's clear, that we either don't run an important part of the startup code, or we run it, but don't do the logging. The code usually gets called automatically by httpd during initialization off a new httpd process. You could also simplify things for the moment by producing a logs sub directory if your ServerRoot and making it writable for the httpd processes (and checking if something interesting appears there (like a file mod_jk.log). Regards, Rainer Hans van Zijst wrote: Hmm, seems like attachments are filtered out :) See below. I switched logging to trace, restarted Apache and did the request. This is the log. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Simple question
How do I configure Tomcat to provide a page redirect from the context of a servlet to the default start page i.e.: /myapp/ to go to - /myapp/home Thanks Peter - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
On Tue, 2007-10-16 at 15:37 +0200, Hans van Zijst wrote: Hmm, seems like attachments are filtered out :) See below. I switched logging to trace, restarted Apache and did the request. This is the log. [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [debug] wc_get_name_for_type::jk_worker.c (292): Found worker type 'ajp13' [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [error] jk_handler::mod_jk.c (2223): Could not init service for worker=confluence Hi Hans, Are you are sure that tomcat is listening on localhost:8009 (ie. telnet localhost 8009 connects)? Are you by any chance running SELinux? It can limit the Apache process connecting to given sockets. Cheers, Ben [Tue Oct 16 15:11:59.287 2007] [8973:3068496784] [trace] jk_handler::mod_jk.c (2227): exit - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Simple question
add a myapp/index.jsp that does the redirect En l'instant précis du 16/10/07 16:13, Peter Stavrinides s'exprimait en ces termes: How do I configure Tomcat to provide a page redirect from the context of a servlet to the default start page i.e.: /myapp/ to go to - /myapp/home Thanks Peter - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- http://www.devlog.be (a belgian developer's logs) - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Simple question
Peter Stavrinides wrote: How do I configure Tomcat to provide a page redirect from the context of a servlet to the default start page i.e.: /myapp/ to go to - /myapp/home add home to the list of 'welcome' files in your web.xml welcome-file-list welcome-fileindex.jsp/welcome-file ... welcome-filehome/welcome-file /welcome-file-list p Thanks Peter - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Simple question
Thanks! Pid wrote: Peter Stavrinides wrote: How do I configure Tomcat to provide a page redirect from the context of a servlet to the default start page i.e.: /myapp/ to go to - /myapp/home add home to the list of 'welcome' files in your web.xml welcome-file-list welcome-fileindex.jsp/welcome-file ... welcome-filehome/welcome-file /welcome-file-list p Thanks Peter - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk: Could not init service for worker
Hi Ben, Yes, Tomcat is listening on port 8009 on both interfaces (external IP and localhost). I can telnet to it. Apache however doesn't try to connect, I verified that with a network sniffer. I don't use SELinux, as I don't know enough about it yet. Kind regards, Hans [EMAIL PROTECTED] 16-10-2007 16:05:35 Hi Hans, Are you are sure that tomcat is listening on localhost:8009 (ie. telnet localhost 8009 connects)? Are you by any chance running SELinux? It can limit the Apache process connecting to given sockets. Cheers, Ben - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: More number of connections got created than maxActive
Isn't it http://issues.apache.org/jira/browse/DBCP-28 ? Connection leak ... It was fixed in DBCP 1.2.2. You may want to read through the Release History of DBCP for other bugs that have been already found and fixed, http://commons.apache.org/dbcp/changes-report.html - 2007/10/16, Bhaskar [EMAIL PROTECTED]: I found that issue is around minIdle settings. When I had following settings: maxActive = 50 maxIdle = 30 minIdle=30 factory=org.apache.commons.dbcp.BasicDataSourceFactory maxWait=1 timeBetweenEvictionRunsMillis=90 numTestsPerEvictionRun=50 minEvictableIdleTimeMillis=180 testWhileIdle=true testOnBorrow = true validationQuery='select 1 from dual' Number of connections in the pool went upto 121. When I changed minIdle to 15 and did my load test connecitons in the pool went upto 66 Looks like maxActive is getting bypassed with minIdle. When I changed minIdle to 10 and did my load test connections in the pool went upto 24 Can someone please throw light on what is going on here? I am using DBCP 1.2.1 Bhaskar - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSR 199 (Jsr199JavaCompiler) compile errors
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Fran, Fran Varin wrote: What channels do I need to go through to open up a clear line of communication/assistance with this? Report a bug/enhancement. Post a patch. You'll get a response: believe me. I'm willing to put some of my time in on it but, would like the reassurance that I can gain access to the Jasper developers to work with them. Most if not all of the Tomcat devs lurk on this list (including Mark, Bill, Tim, Filip, Rainer, Remy, and Mladen -- I assume others are here but less vocal). Your contributions will not go ignored. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHFOLS9CaO5/Lv0PARAjR6AJ9jUHW6h3I19Gs6PiZ6jMNHr5KLXwCdFqIt qZNcPqMmkWhvNDjDpBeTifY= =C2yc -END PGP SIGNATURE- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
jndi.properties in Tomcat 5.5.23 ??
I have an existing application that accesses JBoss with the jndi info defined in the jndi.properties file. I want to make a web enabled version of that application. I have copied the access code from my application into my servlet. When I run the servlet I get : javax.naming.NameNotFoundException: Name UtilitiesFacadeEJB is not bound in this Context I know this is a jndi problem, where do I need to put my jndi.properties file in Tomcat 5.5.23 for my InitialContext to find it? Here is my jndi.properties file: - java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces java.naming.provider.url=172.16.145.140 -- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Fw: Tomcat 5.5.25, SSL and invalid keystore format
Hello, is anyone able to help me with this? I can't get SSL to work on Tomcat 5.5.25, I am still getting the Invalid keystore format or class not found error. Anyone response is greatly appreciated. Thank you. Cheers, Werner. - Original Message - From: Werner Schalk [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org; Martin Gainty [EMAIL PROTECTED] Sent: Monday, October 15, 2007 11:05 AM Subject: Re: Tomcat 5.5.25, SSL and invalid keystore format Dear Martin, dear list, it is not really working, to be honest. Here is what I did: 1. step: Deletion of the old keystore, generation of a new one: debian:~# rm /tmp/tomcat.keystore debian:~# keytool -genkey -alias tomcat -keyalg RSA -keystore /tmp/tomcat.keystore Enter key store password: secret Enter key password for tomcat: secret You are about to enter information that will be incorporated into your certificate request. This information is what is called a Distinguished Name or DN. There are quite a few fields but you can use supplied default values, displayed between brackets, by just hitting Enter, or blank the field by entering the . character before hitting Enter. Common Name (hostname, IP, or your name): localhost Organization Name (company) [The Sample Company]: My Company Organizational Unit Name (department, division): My division Locality Name (city, district) [Sydney]: Munich State or Province Name (full name) [NSW]: Baveria Country Name (2 letter code) [AU]: DE 2. step: Configuration of server.xml, addition of a new connector Connector port=8443 protocol=org.apache.coyote.http11.Http11NioProtocol minSpareThreads=5 maxSpareThreads=75 enableLookups=true disableUploadTimeout=true acceptCount=100 maxThreads=200 scheme=https secure=true keyAlias=tomcat SSLEnabled=true keystoreFile=/tmp/tomcat.keystore keystorePass=secret clientAuth=false sslProtocol=TLS/ Now when starting Tomcat 5.5.25, I get the following error message in catalina.out: 01-Oct-2007 05:48:54 org.apache.catalina.connector.Connector init SEVERE: Protocol handler instantiation failed: java.lang.ClassNotFoundException: org.apache.coyote.http11.Http11NioProtocol 01-Oct-2007 05:48:54 org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/lib/jdk1.6.0_02/jre/lib/i386/client:/usr/lib/jdk1.6.0_02/jre/lib/i386:/usr/lib/jdk1.6.0_02/jre/../lib/i386:/usr/java/packages/lib/i386:/lib:/usr/lib 01-Oct-2007 05:48:54 org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8180 01-Oct-2007 05:48:54 org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8170 01-Oct-2007 05:48:54 org.apache.catalina.connector.Connector initialize SEVERE: Error registering connector java.lang.NullPointerException at org.apache.tomcat.util.IntrospectionUtils.getProperty(IntrospectionUtils.java:377) at org.apache.catalina.connector.Connector.getProperty(Connector.java:302) at org.apache.catalina.connector.Connector.createObjectName(Connector.java:970) at org.apache.catalina.connector.Connector.initialize(Connector.java:998) at org.apache.catalina.core.StandardService.initialize(StandardService.java:578) at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:782) at org.apache.catalina.startup.Catalina.load(Catalina.java:504) at org.apache.catalina.startup.Catalina.load(Catalina.java:524) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:267) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432) java.lang.NullPointerException at org.apache.catalina.connector.Connector.initialize(Connector.java:1011) at org.apache.catalina.core.StandardService.initialize(StandardService.java:578) at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:782) at org.apache.catalina.startup.Catalina.load(Catalina.java:504) at org.apache.catalina.startup.Catalina.load(Catalina.java:524) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:267) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
Re: Fw: Tomcat 5.5.25, SSL and invalid keystore format
not sure how you can use the NIO connector in Tomcat 5.5.25, it wasn't added until Tomcat 6.0 Filip Werner Schalk wrote: Hello, is anyone able to help me with this? I can't get SSL to work on Tomcat 5.5.25, I am still getting the Invalid keystore format or class not found error. Anyone response is greatly appreciated. Thank you. Cheers, Werner. - Original Message - From: Werner Schalk [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org; Martin Gainty [EMAIL PROTECTED] Sent: Monday, October 15, 2007 11:05 AM Subject: Re: Tomcat 5.5.25, SSL and invalid keystore format Dear Martin, dear list, it is not really working, to be honest. Here is what I did: 1. step: Deletion of the old keystore, generation of a new one: debian:~# rm /tmp/tomcat.keystore debian:~# keytool -genkey -alias tomcat -keyalg RSA -keystore /tmp/tomcat.keystore Enter key store password: secret Enter key password for tomcat: secret You are about to enter information that will be incorporated into your certificate request. This information is what is called a Distinguished Name or DN. There are quite a few fields but you can use supplied default values, displayed between brackets, by just hitting Enter, or blank the field by entering the . character before hitting Enter. Common Name (hostname, IP, or your name): localhost Organization Name (company) [The Sample Company]: My Company Organizational Unit Name (department, division): My division Locality Name (city, district) [Sydney]: Munich State or Province Name (full name) [NSW]: Baveria Country Name (2 letter code) [AU]: DE 2. step: Configuration of server.xml, addition of a new connector Connector port=8443 protocol=org.apache.coyote.http11.Http11NioProtocol minSpareThreads=5 maxSpareThreads=75 enableLookups=true disableUploadTimeout=true acceptCount=100 maxThreads=200 scheme=https secure=true keyAlias=tomcat SSLEnabled=true keystoreFile=/tmp/tomcat.keystore keystorePass=secret clientAuth=false sslProtocol=TLS/ Now when starting Tomcat 5.5.25, I get the following error message in catalina.out: 01-Oct-2007 05:48:54 org.apache.catalina.connector.Connector init SEVERE: Protocol handler instantiation failed: java.lang.ClassNotFoundException: org.apache.coyote.http11.Http11NioProtocol 01-Oct-2007 05:48:54 org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/lib/jdk1.6.0_02/jre/lib/i386/client:/usr/lib/jdk1.6.0_02/jre/lib/i386:/usr/lib/jdk1.6.0_02/jre/../lib/i386:/usr/java/packages/lib/i386:/lib:/usr/lib 01-Oct-2007 05:48:54 org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8180 01-Oct-2007 05:48:54 org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8170 01-Oct-2007 05:48:54 org.apache.catalina.connector.Connector initialize SEVERE: Error registering connector java.lang.NullPointerException at org.apache.tomcat.util.IntrospectionUtils.getProperty(IntrospectionUtils.java:377) at org.apache.catalina.connector.Connector.getProperty(Connector.java:302) at org.apache.catalina.connector.Connector.createObjectName(Connector.java:970) at org.apache.catalina.connector.Connector.initialize(Connector.java:998) at org.apache.catalina.core.StandardService.initialize(StandardService.java:578) at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:782) at org.apache.catalina.startup.Catalina.load(Catalina.java:504) at org.apache.catalina.startup.Catalina.load(Catalina.java:524) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:267) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432) java.lang.NullPointerException at org.apache.catalina.connector.Connector.initialize(Connector.java:1011) at org.apache.catalina.core.StandardService.initialize(StandardService.java:578) at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:782) at org.apache.catalina.startup.Catalina.load(Catalina.java:504) at org.apache.catalina.startup.Catalina.load(Catalina.java:524) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at
Error unregistering mbean
Last night we upgraded our JVM from 1.4 to 1.5. After the upgrade, the server still works, however we're getting an exception thrown repeatedly: - Error unregistering mbean javax.management.RuntimeOperationsException: Object name cannot be null at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.isRegistered( DefaultMBeanServerInterceptor.java:545) at com.sun.jmx.mbeanserver.JmxMBeanServer.isRegistered( JmxMBeanServer.java:619) at org.apache.commons.modeler.Registry.unregisterComponent( Registry.java:642) at org.apache.jk.common.ChannelSocket.processConnection( ChannelSocket.java:706) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java :866) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run( ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) Caused by: java.lang.IllegalArgumentException: Object name cannot be null ... 7 more We're running Tomcat 5.0, Apache 2.0 with jk_mod against a sybase db. The only change was the JVM and our webapp compiled in 1.5. Any ideas where to start looking??? Todd -- -- The only dumb question is the one you were too afraid to ask. Check out RouteRuler - Free software for runners, cyclists, walkers, etc. http://routeruler.sourceforge.net
How to? debug large session size? drill down and tools / over 400K is too be for replication
users@tomcat.apache.org We have an application that has a pretty large session size ( 400K). This is causing issues for scalability and makes session replication for fail over quite impractical. What can be used to drill down live and generate a runtime report (perhaps a graph too) showing what http session attributes are the memory hog? We are looking to see not just the attribute that is the issue but perhaps the aggregate (or aggregate of aggregate) of the session attributes and their size in memory. Thanks! - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to? debug large session size? drill down and tools / over 400K is too be for replication
I use www.yourkit.com Filip hanasaki jiji wrote: users@tomcat.apache.org We have an application that has a pretty large session size ( 400K). This is causing issues for scalability and makes session replication for fail over quite impractical. What can be used to drill down live and generate a runtime report (perhaps a graph too) showing what http session attributes are the memory hog? We are looking to see not just the attribute that is the issue but perhaps the aggregate (or aggregate of aggregate) of the session attributes and their size in memory. Thanks! - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RES: How to? debug large session size? drill down and tools / over 400K is too be for replication
We use Lambda Probe http://www.lambdaprobe.org here -Mensagem original- De: hanasaki jiji [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 16 de outubro de 2007 15:53 Para: users@tomcat.apache.org Assunto: How to? debug large session size? drill down and tools / over 400K is too be for replication users@tomcat.apache.org We have an application that has a pretty large session size ( 400K). This is causing issues for scalability and makes session replication for fail over quite impractical. What can be used to drill down live and generate a runtime report (perhaps a graph too) showing what http session attributes are the memory hog? We are looking to see not just the attribute that is the issue but perhaps the aggregate (or aggregate of aggregate) of the session attributes and their size in memory. Thanks! - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to? debug large session size? drill down and tools / over 400K is too be for replication
I should have mentioned we are using websphere ... looks like there is no support http://forums.yourkit.com/viewtopic.php?t=216highlight=ibm Other thoughts? On 10/16/07, Milanez, Marcus [EMAIL PROTECTED] wrote: We use Lambda Probe http://www.lambdaprobe.org here -Mensagem original- De: hanasaki jiji [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 16 de outubro de 2007 15:53 Para: users@tomcat.apache.org Assunto: How to? debug large session size? drill down and tools / over 400K is too be for replication users@tomcat.apache.org We have an application that has a pretty large session size ( 400K). This is causing issues for scalability and makes session replication for fail over quite impractical. What can be used to drill down live and generate a runtime report (perhaps a graph too) showing what http session attributes are the memory hog? We are looking to see not just the attribute that is the issue but perhaps the aggregate (or aggregate of aggregate) of the session attributes and their size in memory. Thanks! - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to? debug large session size? drill down and tools / over 400K is too be for replication
We run across tomcat, websphere, BEA and currently are only working in websphere. Others to follow. On 10/16/07, hanasaki jiji [EMAIL PROTECTED] wrote: I should have mentioned we are using websphere ... looks like there is no support http://forums.yourkit.com/viewtopic.php?t=216highlight=ibm Other thoughts? On 10/16/07, Milanez, Marcus [EMAIL PROTECTED] wrote: We use Lambda Probe http://www.lambdaprobe.org here -Mensagem original- De: hanasaki jiji [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 16 de outubro de 2007 15:53 Para: users@tomcat.apache.org Assunto: How to? debug large session size? drill down and tools / over 400K is too be for replication users@tomcat.apache.org We have an application that has a pretty large session size ( 400K). This is causing issues for scalability and makes session replication for fail over quite impractical. What can be used to drill down live and generate a runtime report (perhaps a graph too) showing what http session attributes are the memory hog? We are looking to see not just the attribute that is the issue but perhaps the aggregate (or aggregate of aggregate) of the session attributes and their size in memory. Thanks! - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
yeah, changing the error message wont help anyone, especially yourself :) make sure that your -D parameter actually took in effect, and that you didn't put it in the wrong place. easiest way to check, have a JSP print out the system property for you Filip David Marshall wrote: Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
and that your library is valid, and that you are calling System.loadLibrary with the correct name Filip David Marshall wrote: Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Error unregistering mbean
You may consider upgrading from Tomcat 5.0 to Tomcat 5.5. + It implements the same version of the specification (Servlets 2.4/JSP 2.0), thus there must be no impact for your webapp. + It is designed to run on JVM 1.5 in its default configuration. (Running with JVM 1.4 requires additional components). See Dependency Changes in http://tomcat.apache.org/tomcat-5.5-doc/RELEASE-NOTES.txt + It is actively supported. 2007/10/16, todd runstein [EMAIL PROTECTED]: Last night we upgraded our JVM from 1.4 to 1.5. After the upgrade, the server still works, however we're getting an exception thrown repeatedly: - Error unregistering mbean javax.management.RuntimeOperationsException: Object name cannot be null at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.isRegistered( DefaultMBeanServerInterceptor.java:545) at com.sun.jmx.mbeanserver.JmxMBeanServer.isRegistered( JmxMBeanServer.java:619) at org.apache.commons.modeler.Registry.unregisterComponent( Registry.java:642) at org.apache.jk.common.ChannelSocket.processConnection( ChannelSocket.java:706) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java :866) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run( ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) Caused by: java.lang.IllegalArgumentException: Object name cannot be null ... 7 more We're running Tomcat 5.0, Apache 2.0 with jk_mod against a sybase db. The only change was the JVM and our webapp compiled in 1.5. Any ideas where to start looking??? Todd -- -- The only dumb question is the one you were too afraid to ask. Check out RouteRuler - Free software for runners, cyclists, walkers, etc. http://routeruler.sourceforge.net - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Chunking in Tomcat 5.5.23 w/ Axis2 1.3
I have read the posts on chunking not being able to be disabled in tomcat 5.5.x. This is unfortunate. However, I am not setting or writing the reponse code, axis2 1.3 is. I have disabled chunking in axis2 as recommended by commenting out the transfer endoding like below. However, the responses are still coming back chunked. I am not sure if tomcat 5.5.23 is overriding the headers that axis2 is setting or if something else is going on. Anyone have any ideas or suggestions? My apologies if this is not a tomcat 5.5.x issue. The documentation I followed for axis2 at http://wso2.org/library/209 transportSender name=http class=org.apache.axis2.transport.http.CommonsHTTPTransportSender parameter name=PROTOCOLHTTP/1.1/parameter !--parameter name=Transfer-Encodingchunked/parameter-- /transportSender Thank you, Joe -- View this message in context: http://www.nabble.com/Chunking-in-Tomcat-5.5.23-w--Axis2-1.3-tf4636460.html#a13241335 Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
I'm not doing a System.loadLibrary. The library is needed by a third-party jar that I am using. SInce it works from within Eclipse I know that their jar and the shared object (.so file) work correctly together and that the shared object is indeed in the correct location on library path. Its only when I deploy to the production version of Tomcat (on the same machine) that this stuff fails. At that point I don't have Eclipse's VM parameter setting abilities available to me and the only place to put it is in JAVA_OPTS. From the tomcat log file I can see that the java.library.path is set as intended. I'll try your JSP idea just to be 100% the path is set correctly. Filip Hanik - Dev Lists wrote: and that your library is valid, and that you are calling System.loadLibrary with the correct name Filip David Marshall wrote: Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
UTF-8 Properties File
Hi folks, Besides using native2ascii, would someone please recommend me how to make tocmat to work with UTF-8 properties files, thanks! Billy Ng
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
Is your third-party jar placed into the shared libraries folder as it should be? See http://wiki.apache.org/tomcat/HowTo#head-a4b7185ee95d0cf14a48f92c08d1eb66b561139d http://forum.java.sun.com/thread.jspa?threadID=780109 See also http://java.sun.com/docs/books/jni/html/design.html chapters 11.2.3 and 11.2.4. Is the script file /etc/init.d/tomcat editable for you? E.g., to define the JAVA_OPTS there? Or you are defining them in a profile file of the user that is su-ed to run the tomcat? Looking forward to your results with JSP. 2007/10/17, David Marshall [EMAIL PROTECTED]: I'm not doing a System.loadLibrary. The library is needed by a third-party jar that I am using. SInce it works from within Eclipse I know that their jar and the shared object (.so file) work correctly together and that the shared object is indeed in the correct location on library path. Its only when I deploy to the production version of Tomcat (on the same machine) that this stuff fails. At that point I don't have Eclipse's VM parameter setting abilities available to me and the only place to put it is in JAVA_OPTS. From the tomcat log file I can see that the java.library.path is set as intended. I'll try your JSP idea just to be 100% the path is set correctly. Filip Hanik - Dev Lists wrote: and that your library is valid, and that you are calling System.loadLibrary with the correct name Filip David Marshall wrote: Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
Yes. its in TOMCAT_HOME/shared/lib Konstantin Kolinko wrote: Is your third-party jar placed into the shared libraries folder as it should be? See http://wiki.apache.org/tomcat/HowTo#head-a4b7185ee95d0cf14a48f92c08d1eb66b561139d http://forum.java.sun.com/thread.jspa?threadID=780109 See also http://java.sun.com/docs/books/jni/html/design.html chapters 11.2.3 and 11.2.4. Is the script file /etc/init.d/tomcat editable for you? E.g., to define the JAVA_OPTS there? Or you are defining them in a profile file of the user that is su-ed to run the tomcat? Looking forward to your results with JSP. 2007/10/17, David Marshall [EMAIL PROTECTED]: I'm not doing a System.loadLibrary. The library is needed by a third-party jar that I am using. SInce it works from within Eclipse I know that their jar and the shared object (.so file) work correctly together and that the shared object is indeed in the correct location on library path. Its only when I deploy to the production version of Tomcat (on the same machine) that this stuff fails. At that point I don't have Eclipse's VM parameter setting abilities available to me and the only place to put it is in JAVA_OPTS. From the tomcat log file I can see that the java.library.path is set as intended. I'll try your JSP idea just to be 100% the path is set correctly. Filip Hanik - Dev Lists wrote: and that your library is valid, and that you are calling System.loadLibrary with the correct name Filip David Marshall wrote: Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
I have tried editing the tomcat scripts (catalina.sh) to set JAVA_OPTS in there and it didn't solve the problem. Currently I set the JAVA_OPTS in my user .bashrc and .bash_profile. So when I run the startup script the user is me ( I have to run the script with sudo). I'm verifying that JAVA_OPTS is set with a printenv before running tomcat start Is the script file /etc/init.d/tomcat editable for you? E.g., to define the JAVA_OPTS there? Or you are defining them in a profile file of the user that is su-ed to run the tomcat? Looking forward to your results with JSP. Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
The results of printing System.getProperty(java.library.path) in the jsp does show the correct path to my shared object Looking forward to your results with JSP. 2007/10/17, David Marshall [EMAIL PROTECTED]: I'm not doing a System.loadLibrary. The library is needed by a third-party jar that I am using. SInce it works from within Eclipse I know that their jar and the shared object (.so file) work correctly together and that the shared object is indeed in the correct location on library path. Its only when I deploy to the production version of Tomcat (on the same machine) that this stuff fails. At that point I don't have Eclipse's VM parameter setting abilities available to me and the only place to put it is in JAVA_OPTS. From the tomcat log file I can see that the java.library.path is set as intended. I'll try your JSP idea just to be 100% the path is set correctly. Filip Hanik - Dev Lists wrote: and that your library is valid, and that you are calling System.loadLibrary with the correct name Filip David Marshall wrote: Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
byte trafic accounting
Our application serves request for mobile device (cellular phone). We need to find a way to keep track of how many byte were read from the request and sent in the response. We need to whole size of the request/response not just the Content-Length (GET /TestValve/apps HTTP/1.1 ... headers, everything). I was planning to go for a Valve but it doesn't work: public void invoke(Request request, Response response) throws IOException, ServletException { getNext().invoke(request, response); String localAddr = request.getLocalAddr(); int bytesRead = request.getCoyoteRequest().getBytesRead(); long bytesSent = response.getCoyoteResponse().getBytesWritten(); System.out.println(request from: + localAddr + , recv= + bytesRead + , sent= + bytesSent); } bytesRead and bytesSent are always 0. What's wrong? How can I do it? We're are currently using Tomcat 5.5.25. Pascal - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How to Suppress Server Header in the HTTP Response
Hi, I am looking for a way to suppress the server header in the HTTP Response. I am using Tomcat version 559. Any help is appreciated. Thanks, J
Re: Mini HOW-TO: Tomcat as a service on Windows Server 2003 64-bit edition
Hi there, Thanks a lot for this meaningful info. I too have a similar requirement: running the Tomcat on 64 bit OS Windows server 2003 / 64 bit Xeon 1.6GHz, 8G RAM I followed the commands below given in your thread. I installed the 64 bit JRE from Sun, Installed 32 bit tomcat. Edited all the necessary values in the registry for the node Wow6432Node I copied the 64bit compiled exe from bugzilla link given by you. However i'm now getting a strange error when i try to run the exe from the command line or try to run the tomcat from the services.msc. Snapshot C:\Tomcat55\bintomcat5.exe [2007-10-16 17:39:16] [402 prunsrv.c] [error] The system cannot find the file specified. [2007-10-16 17:39:16] [1246 prunsrv.c] [error] Load configuration failed C:\Tomcat55\binprunsrv.exe [2007-10-16 17:41:40] [402 prunsrv.c] [error] The system cannot find the file specified. [2007-10-16 17:41:40] [1246 prunsrv.c] [error] Load configuration failed C:\Tomcat55\bintomcat5.exe.64bit [2007-10-16 17:41:51] [402 prunsrv.c] [error] The system cannot find the file specified. [2007-10-16 17:41:51] [1246 prunsrv.c] [error] Load configuration failed However the tomcat5w.exe original runs fine and the service window opens up. I tried running the server from there, but no luck there/ I confirmed all the entries once again in the registry. Have you encountered similar problem? Please suggest input. I'm stuck now. Thanks in advance. Swapnil Richard Mundell wrote: Dear all, While Tomcat will run happily on a 64-bit edition of Windows by running it directly through a 64-bit build of Java, the native Windows Service support which is bundled with Tomcat 5.5.x is presently 32-bit only. The reason to run Tomcat in a 64-bit environment is to run with large memory allocations (we have the requirement to run with around 4GB of heap space). At best you can squeeze about 1.5GB of heap allocation in a Windows 32-bit environment. To run larger than that you'll need a 64-bit CPU and OS. There's a couple of outstanding 'bugzilla' tickets (35869 39327) requesting this support but the Tomcat developers obviously haven't had a chance to build it into the core package yet. So, in the meantime, for anyone attempting to run Tomcat in 64-bit mode in Windows so save you the pain and extensive Googling to find a solution, here's a (very) brief HOW-TO. (Note that I've got this working on Windows 2003 Server Standard 64-bit edition on an Intel chipset - I'd imagine the same instructions would work fine on AMD environments and XP 64-bit). 1) Download and install the 64 bit edition of Java for Windows 2) Download and install the 32 bit version of Tomcat 5.5.x for Windows 3) Recompile 'procrun' (which is the binary $CATALINA_ROOT/bin/Tomcat5.exe in the Windows distribution) using the patch listed in Bugzilla ticket 39327 (http://issues.apache.org/bugzilla/show_bug.cgi?id=39327) and replace Tomcat5.exe with the newly compiled prunsrv.exe. 4) Add the registry keys to Windows which are listed at the end of this email (don't forget to adjust them to use your server's paths for the JVM and Tomcat). 5) Using regedit, edit the HKLM\SOFTWARE\Apache Software Foundation\Procrun 2.0\Tomcat5\Parameters\Java\Options and adjust for memory settings appropriate to your environment. 6) Start (or restart) the Apache Tomcat service. Note that although you can stop/start the Tomcat service via the bundled Tomcat service helper, if you need to change its configuration you will need to manually edit the registry key mentioned in step 5. Of course, the hardest part of this (for non-developers) is recompiling procrun. I'd be very happy to mail you a copy of the compiled binary (for Intel 64-bit Xeon and AMD 64-bit chipsets) that the contributor of the patch in ticket 39237 very kindly provided for me. This is intended as a stop-gap while the Tomcat developers implement this into the core Windows distribution. Good luck! Richard ___ Richard Mundell The Roberts Group Market Data Expertise that FITS. www.trgrp.com -- [HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Procrun 2.0\Tomcat5\Parameters\Java] Jvm=C:\\jdk\\jre\\bin\\server\\jvm.dll Classpath=C:\\tomcat\\bin\\bootstrap.jar Options=hex(7):2d,00,44,00,63,00,61,00,74,00,61,00,6c,00,69,00,6e,00,61,00 ,\ 2e,00,68,00,6f,00,6d,00,65,00,3d,00,43,00,3a,00,5c,00,74,00,72,00,67,00,5c,\ 00,66,00,69,00,74,00,73,00,77,00,65,00,62,00,5c,00,74,00,6f,00,6d,00,63,00,\ 61,00,74,00,00,00,2d,00,44,00,6a,00,61,00,76,00,61,00,2e,00,65,00,6e,00,64,\ 00,6f,00,72,00,73,00,65,00,64,00,2e,00,64,00,69,00,72,00,73,00,3d,00,43,00,\ 3a,00,5c,00,74,00,72,00,67,00,5c,00,66,00,69,00,74,00,73,00,77,00,65,00,62,\ 00,5c,00,74,00,6f,00,6d,00,63,00,61,00,74,00,5c,00,63,00,6f,00,6d,00,6d,00,\
Connector Compression
Hi there, Is there any reason why you would not want to use compression on a Connector? Thanks in advance. Mike Fax.com The New Way To Fax! http://www.fax.com/ www.fax.com Confidential: This electronic message and all contents contain information from Fax.com, Inc. which may be privileged, confidential or otherwise protected from disclosure. The information is intended to be for the addressee(s) only. If you are not an addressee, any disclosure, copy, distribution or use of the contents of this message is prohibited. If you have received this electronic message in error, please notify the sender by reply e-mail and destroy the original message and all copies. Thank you.
Re: StreamCorruptedException - where to look to fix
Pid wrote: David kerber wrote: Running TC 5.5.15 on Windows server 2003, JRE 1.5.0_12. Where do I start looking to try to fix the exception below? I get this on most startups of Tomcat. I know it's related to reloading sessions that were saved on the previous shutdown, and I've fixed a few serialization errors in my classes, but can't figure this one out. The shutdown appears to be normal in the log: Do you actually need to reload the saved sessions? p Well, I'm sure my users would like it if they didn't have to re-enter their data if I happen to restart the system while they're using it. But other than that, I just left TC at its default settings, which are to reload sessions. From the deafening silence in response to my post, I guess there's no standard places to start looking to correct this? D - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Connector Compression
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Mike, Mike Cronin wrote: Is there any reason why you would not want to use compression on a Connector? The mod_jk connector does not support any compression, so you obviously don't mean that one. The HTTP(s) connectors both support gzip compression. You may not want to use compression if you have constrained CPU resources (either high transaction rates or a weak CPU). Compression is pretty heavy on the CPU so you have to decide is bandwidth is more precious than CPU time. You may also have a client that does not support compression, but I believe that the connector automatically detects this and will not compress unless the client advertises an accept-encoding of gzip. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHFVs19CaO5/Lv0PARAibUAJ4zRx2W9ex9Iyh+SrrGuIN/drtH9QCgm5ct 1fjKXJCUDLbBx20voJ/2168= =ZvSU -END PGP SIGNATURE- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: StreamCorruptedException - where to look to fix
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 David, David Kerber wrote: From the deafening silence in response to my post, I guess there's no standard places to start looking to correct this? This is a very strange error. If you change class definitions for the objects being serialized, you may cause a version mismatch and the stored objects will not be able to be de-serialized. My experience has been that you get a more descriptive error message in this case, though. If you simply stop and restart Tomcat, are your sessions persisted and re-read from the disk properly? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHFVvZ9CaO5/Lv0PARAq8AAKCVPrZXfp7/YDyjLp75irC4PKsXUgCguZcv BJzb5YNUMNH0J7nq8QliLFY= =vhfk -END PGP SIGNATURE- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Error unregistering mbean
Yup, upgrading is probably the best answer. Depending on which version of 5.0 you have, you might also be able to work around it by setting request.registerRequests=false on the Connector / element in server.xml. In any case, the error is harmless, besides taking up space in the log file. Konstantin Kolinko [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] You may consider upgrading from Tomcat 5.0 to Tomcat 5.5. + It implements the same version of the specification (Servlets 2.4/JSP 2.0), thus there must be no impact for your webapp. + It is designed to run on JVM 1.5 in its default configuration. (Running with JVM 1.4 requires additional components). See Dependency Changes in http://tomcat.apache.org/tomcat-5.5-doc/RELEASE-NOTES.txt + It is actively supported. 2007/10/16, todd runstein [EMAIL PROTECTED]: Last night we upgraded our JVM from 1.4 to 1.5. After the upgrade, the server still works, however we're getting an exception thrown repeatedly: - Error unregistering mbean javax.management.RuntimeOperationsException: Object name cannot be null at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.isRegistered( DefaultMBeanServerInterceptor.java:545) at com.sun.jmx.mbeanserver.JmxMBeanServer.isRegistered( JmxMBeanServer.java:619) at org.apache.commons.modeler.Registry.unregisterComponent( Registry.java:642) at org.apache.jk.common.ChannelSocket.processConnection( ChannelSocket.java:706) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java :866) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run( ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) Caused by: java.lang.IllegalArgumentException: Object name cannot be null ... 7 more We're running Tomcat 5.0, Apache 2.0 with jk_mod against a sybase db. The only change was the JVM and our webapp compiled in 1.5. Any ideas where to start looking??? Todd -- -- The only dumb question is the one you were too afraid to ask. Check out RouteRuler - Free software for runners, cyclists, walkers, etc. http://routeruler.sourceforge.net - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.library.path / Unsatisfied Link Error problem with Linux Tomcat 5.5
Does the native library consist of a single .so file, or there are several ones? See the second NOTE MEG here: http://wrapper.tanukisoftware.org/doc/english/prop-java-library-path-n.html It is about requirements for LD_LIBRARY_PATH if there are several libraries. Does your printenv mention the value of LD_LIBRARY_PATH? Is there any difference compared to when you are running Eclipse? 2007/10/17, David Marshall [EMAIL PROTECTED]: The results of printing System.getProperty(java.library.path) in the jsp does show the correct path to my shared object Looking forward to your results with JSP. 2007/10/17, David Marshall [EMAIL PROTECTED]: I'm not doing a System.loadLibrary. The library is needed by a third-party jar that I am using. SInce it works from within Eclipse I know that their jar and the shared object (.so file) work correctly together and that the shared object is indeed in the correct location on library path. Its only when I deploy to the production version of Tomcat (on the same machine) that this stuff fails. At that point I don't have Eclipse's VM parameter setting abilities available to me and the only place to put it is in JAVA_OPTS. From the tomcat log file I can see that the java.library.path is set as intended. I'll try your JSP idea just to be 100% the path is set correctly. Filip Hanik - Dev Lists wrote: and that your library is valid, and that you are calling System.loadLibrary with the correct name Filip David Marshall wrote: Filip : Thanks. I didn't literally mean X. The library it won't load is called Netica. I just changed it to X to be more general. I hope I'm not just creating confusion for everyone. thanks dm Filip Hanik - Dev Lists wrote: I believe there is a -Djava.awt.headless=true or something like that, so that it doesn't try to load your X windows environment Filip David Marshall wrote: Using Tomcat 5.5 on Linux. I've set my environment variable with export JAVA_OPTS='-Djava.library.path=/path/to/my/sharedobjectfolder' After restarting tomcat and hitting my servlet (which depends on the .so file in the folder above) I get an UnsatisfiedLinkError no X found in java.library.path I've looked in catalina.out and see a message that says that The Apache Tomcat Native library cannot be found on java.library.path: /path/to/my/sharedobjectfolder. So it appears that Tomcat is using the path at least when it starts up. I've seen other Linux Tomcat users raising this same problem and not getting any answers. Within Eclipse I can run Tomcat and configure a VM parameter for java.library.path and my library is successfully found when the servlet runs so this issue only pertains to running tomcat directly from the startup scripts (e.g. /etc/init.d/tomcat start) What could be wrong? - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Marshall Staff Software Engineer Center For Knowledge Communication Computer Science Dept. University of Massachusetts - Amherst www.cs.umass.edu/~marshall - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5.25, SSL and invalid keystore format
As Filip has already pointed out, the Nio Connector is only available with TC 6.0.x+. Otherwise, I can's suggest much except to set JAVA_OPTS=-Djavax.net.debug=ssl before launching Tomcat. You could also set the logging level to DEBUG (which is FINE for JUL logging) for the category org.apache.tomcat.util.net, but I doubt it will produce anything interesting. You could also check if keytool can actually list the contents of your keystore. Werner Schalk [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hello, is anyone able to help me with this? I can't get SSL to work on Tomcat 5.5.25, I am still getting the Invalid keystore format or class not found error. Anyone response is greatly appreciated. Thank you. Cheers, Werner. - Original Message - From: Werner Schalk [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org; Martin Gainty [EMAIL PROTECTED] Sent: Monday, October 15, 2007 11:05 AM Subject: Re: Tomcat 5.5.25, SSL and invalid keystore format Dear Martin, dear list, it is not really working, to be honest. Here is what I did: 1. step: Deletion of the old keystore, generation of a new one: debian:~# rm /tmp/tomcat.keystore debian:~# keytool -genkey -alias tomcat -keyalg RSA -keystore /tmp/tomcat.keystore Enter key store password: secret Enter key password for tomcat: secret You are about to enter information that will be incorporated into your certificate request. This information is what is called a Distinguished Name or DN. There are quite a few fields but you can use supplied default values, displayed between brackets, by just hitting Enter, or blank the field by entering the . character before hitting Enter. Common Name (hostname, IP, or your name): localhost Organization Name (company) [The Sample Company]: My Company Organizational Unit Name (department, division): My division Locality Name (city, district) [Sydney]: Munich State or Province Name (full name) [NSW]: Baveria Country Name (2 letter code) [AU]: DE 2. step: Configuration of server.xml, addition of a new connector Connector port=8443 protocol=org.apache.coyote.http11.Http11NioProtocol minSpareThreads=5 maxSpareThreads=75 enableLookups=true disableUploadTimeout=true acceptCount=100 maxThreads=200 scheme=https secure=true keyAlias=tomcat SSLEnabled=true keystoreFile=/tmp/tomcat.keystore keystorePass=secret clientAuth=false sslProtocol=TLS/ Now when starting Tomcat 5.5.25, I get the following error message in catalina.out: 01-Oct-2007 05:48:54 org.apache.catalina.connector.Connector init SEVERE: Protocol handler instantiation failed: java.lang.ClassNotFoundException: org.apache.coyote.http11.Http11NioProtocol 01-Oct-2007 05:48:54 org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/lib/jdk1.6.0_02/jre/lib/i386/client:/usr/lib/jdk1.6.0_02/jre/lib/i386:/usr/lib/jdk1.6.0_02/jre/../lib/i386:/usr/java/packages/lib/i386:/lib:/usr/lib 01-Oct-2007 05:48:54 org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8180 01-Oct-2007 05:48:54 org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote HTTP/1.1 on http-8170 01-Oct-2007 05:48:54 org.apache.catalina.connector.Connector initialize SEVERE: Error registering connector java.lang.NullPointerException at org.apache.tomcat.util.IntrospectionUtils.getProperty(IntrospectionUtils.java:377) at org.apache.catalina.connector.Connector.getProperty(Connector.java:302) at org.apache.catalina.connector.Connector.createObjectName(Connector.java:970) at org.apache.catalina.connector.Connector.initialize(Connector.java:998) at org.apache.catalina.core.StandardService.initialize(StandardService.java:578) at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:782) at org.apache.catalina.startup.Catalina.load(Catalina.java:504) at org.apache.catalina.startup.Catalina.load(Catalina.java:524) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:267) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432) java.lang.NullPointerException at org.apache.catalina.connector.Connector.initialize(Connector.java:1011) at org.apache.catalina.core.StandardService.initialize(StandardService.java:578) at