soTimeout not worked on channelNioSocket
I have configuared tomcat to use the NIO impl over AJP, here are the lines in server.xml Connector address=127.0.0.1 port=0 channelNioSocket.port=8009 channelNioSocket.soTimeout=60 channelNioSocket.bufferSize=16384 channelNioSocket.maxThreads=125 channelNioSocket.minSpareThreads=10 channelNioSocket.maxSpareThreads=50 redirectPort=8443 protocol=AJP/1.3 useBodyEncodingForURI=true / (TC version 5.5.17) I had setted the soTimeout with 10 minutes, cause I notice such stages in server status Stage Time B Sent B Recv Client VHost Request S 33280840 ms 359 KB 0 KB x.x.x.x 127.0.0.1 GET ... That shows several requests were blocking on reading request bodies for hours. But unfortunately it dosen't worked for me, I am expecting a request should only blocking mostly 10 minutes on read, after that a SocketTimeoutException should raised. After digest the source code of ChannelNioSocket.java, I found that ChannelNioSocket.SocketInputStream just wait infinitly if no data comes while socket could not be detected closing private void block(int len) throws IOException { ... ... if(!dataAvailable) { blocking = true; if(log.isDebugEnabled()) log.debug(Waiting for +len+ bytes to be available); try{ wait(socketTimeout); }catch(InterruptedException iex) { log.debug(Interrupted,iex); } blocking = false; } if(dataAvailable) { dataAvailable = false; if(fill(len) 0) { isClosed = true; } } } The socketTimeout parameter is not used to throw SocketTimeoutException, actually it has no meaning. I even read the source for TC 6.0.13, the same as above. Should it be more precisely that throwing SocketTimeoutException on later condiction test for (dataAvailable) is not true? In ChannelSocket implement, the problem is not exists, it uses blocking Socket.getInputStream, and it would throws SocketTimeoutException for socket timeout while Socket.setSoTimeout was called -- View this message in context: http://www.nabble.com/soTimeout-not-worked-on-channelNioSocket-tf4586318.html#a13091613 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: Problems with DBCP in tomcat6
El jue, 04-10-2007 a las 05:38 -0400, David Smith escribió: Add validationQuery=select 1 to your Resource .../ definition to cause the database pool to test connections and regenerate them as necessary before your code gets a connection. --David Perfect. It works. That was the solution. Thank you very much. Josué Alcalde González wrote: I am having a problem with DBCP. It is a problem with my applications written last year for apache-tomcat-5.5. They worked perfectly but I will soon need apache-tomcat-6 and I have upgraded my servers. I haven't had any problem with my old applications until I discovered every morning an exception occurs in my applications related to database connection. It is not a very big problem (connection fails, an error is reported to the user, the user tries it again and it works) but it is really annoying. Has something important changed in DBCP which can cause such a problem? Of course, I suppose you will need more tips to help me. As I have said, I use the default datasource and connection pool system included with tomcat. I use to declare my datasource in META-INF/context.xml. For example: ---META-INF/context.xml- ?xml version=1.0 encoding=UTF-8? Context debug=5 reloadable=true crossContext=true Resource name=jdbc/GesdocDB auth=Container type=javax.sql.DataSource maxActive=100 maxIdle=30 maxWait=1000 username=gesdocweb password=*** driverClassName=com.mysql.jdbc.Driver url=jdbc:mysql://127.0.0.1:3306/gesdoc/ /Context ---META-INF/context.xml- I use two different ways to access db in different apps. I have used JDBC+common-db-utils and Hibernate and I am having this problem with both. Since JDBC access is more transparent than Hibernate, I will try to give you enough info about how the connection is done. This would be a tipical conection to database to chek the password of a user (sorry, the code is in spanish): - es.csa.dipu.gesdoc.consultas.ConsultasUsuario - 80 public static User getUsuarioConLogin(String login) throws DataAccessException { 81 String sql = SELECT idUsuario, login, nombre, apellido1, 82 + apellido2, perfil, cambiarPassword, 83 + password, estado 84 + FROM Usuarios WHERE login = ?;; 85 try { 86 QueryRunner run = new QueryRunner(DbUtils.getDataSource()); 87 ResultSetHandler h = new BeanHandler(Usuario.class); 88 return (Usuario) run.query(sql, login, h); 89 } catch (Exception e) { 90 log.warn(msg.get(ERROR_CONSULTA_USUARIO), e); 91 throw new DataAccessException(msg.get(ERROR_CONSULTA_USUARIO),e); 92 } 93 } - es.csa.dipu.gesdoc.consultas.ConsultasUsuario - run.query() will close resultsets, statements and connection and it seems the problem is when it tries to close connection. This is a trace of the error: 04-oct-2007 8:52:12 es.csa.dipu.gesdoc.consultas.ConsultasUsuario getUsuarioConLogin ADVERTENCIA: Se ha producido un error al consultar en la tabla usuarios. java.sql.SQLException: Already closed. at org.apache.tomcat.dbcp.dbcp.PoolableConnection.close(PoolableConnection.java:84) at org.apache.tomcat.dbcp.dbcp.PoolingDataSource $PoolGuardConnectionWrapper.close(PoolingDataSource.java:181) at org.apache.commons.dbutils.DbUtils.close(DbUtils.java:38) at org.apache.commons.dbutils.QueryRunner.close(QueryRunner.java:524) at org.apache.commons.dbutils.QueryRunner.query(QueryRunner.java:311) at org.apache.commons.dbutils.QueryRunner.query(QueryRunner.java:285) at es.csa.dipu.gesdoc.consultas.ConsultasUsuario.getUsuarioConLogin(ConsultasUsuario.java:88) at es.csa.dipu.gesdoc.beans.LoginBean.doLogin(LoginBean.java:123) at sun.reflect.GeneratedMethodAccessor694.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:132) at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:61) at javax.faces.component.UICommand.broadcast(UICommand.java:109) at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:97) at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:171) at org.apache.myfaces.lifecycle.InvokeApplicationExecutor.execute(InvokeApplicationExecutor.java:32) at org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:95) at
Re: Why Net use ... does not work with WebDAV servlet
Hi Mark, I also monitored the request/response between WebDAV servlet in Tomcate and MS Mini Redirector and compared it with Apache (mod_dav) and MS Mini Redirector. I can say no difference. But I don't know what it works with Apache but not for Tomcat one . Do you have any idea? can it be consequence of Authentication or Authorization policy of Tomcat? I have spent all last week working on this problem but no success! any idea or comment will be appreciated. regards, /shahab Mark Thomas [EMAIL PROTECTED] wrote: Shahab1355 wrote: sorry for late answering and I hop it is not too late. I ma using Tomcat 5.5 and the WebDAV servlet developed by Apache. but the servlet does not respond to the net use command. I have taken a look at the request/response cycle with tcpmon (from Axis) and I can't see anything obviously wrong. The request/response are shown below. If anyone can see what the problem is with the response, let me know. Mark Request === PROPFIND /webdav HTTP/1.1 Depth: 0 translate: f User-Agent: Microsoft-WebDAV-MiniRedir/5.1.2600 Host: localhost Content-Length: 0 Connection: Keep-Alive Response HTTP/1.1 207 Multi-Status Server: Apache-Coyote/1.1 Content-Type: text/xml;charset=UTF-8 Content-Length: 548 Date: Tue, 02 Oct 2007 04:14:42 GMT - /webdav/ 2007-10-02T04:08:34Z HTTP/1.1 200 OK - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Boardwalk for $500? In 2007? Ha! Play Monopoly Here and Now (it's updated for today's economy) at Yahoo! Games.
Over 70 instances of Tomcat after startup
Afternoon, This is my first posting to this list and after breifly checking the archives I hope this question is not a duplicate: - I have an unusual problem with my previously stable container which now generates over 70 instance on startup. This container has been working correctly for over 12 months, and I am assured by our dev team that no discrete modifications have been made. On startup this output is generated: - start_apps MerchantAdmin Starting MerchantAdmin Using CATALINA_BASE: /rel/apps/MerchantAdmin Using CATALINA_HOME: /rel/tomcat Using CATALINA_TMPDIR: /rel/apps/MerchantAdmin/temp Using JAVA_HOME: /usr/lib/java /rel/tomcat/bin/start_apps.sh: line 36: 30725 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736: syntax error in expression (error token is 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736) After a min or so, the following number of instances are running: - ps aux | grep -c MerchantAdmin 71 I would be very grateful for any assistance with this problem.. Kind regards Ray Statham - 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: Over 70 instances of Tomcat after startup
Probably worth posting the /rel/tomcat/bin/start_apps.sh script as it sounds like it could be suspect. On 10/8/07, Ray Statham [EMAIL PROTECTED] wrote: Afternoon, This is my first posting to this list and after breifly checking the archives I hope this question is not a duplicate: - I have an unusual problem with my previously stable container which now generates over 70 instance on startup. This container has been working correctly for over 12 months, and I am assured by our dev team that no discrete modifications have been made. On startup this output is generated: - start_apps MerchantAdmin Starting MerchantAdmin Using CATALINA_BASE: /rel/apps/MerchantAdmin Using CATALINA_HOME: /rel/tomcat Using CATALINA_TMPDIR: /rel/apps/MerchantAdmin/temp Using JAVA_HOME: /usr/lib/java /rel/tomcat/bin/start_apps.sh: line 36: 30725 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736: syntax error in expression (error token is 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736) After a min or so, the following number of instances are running: - ps aux | grep -c MerchantAdmin 71 I would be very grateful for any assistance with this problem.. Kind regards Ray Statham - 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: Over 70 instances of Tomcat after startup
Hi Ben, thanks for your very speedy reply. Please find the full file listing below: - #!/bin/bash APPS_BASE=/rel/apps OLD_PWD=`pwd` case $1 in ) echo $0 [all | app1 [app2]..[appN] ]; exit 0; ;; all) echo Starting all. for i in ${APPS_BASE}/[-A-Za-z0-9_]* do cd $i; appname=`echo $i | sed -e 's|.*/\(.*\)|\1|'`; test -f bin/start_${appname}.sh sh bin/start_${appname}.sh start; done ;; *) x=0 y=$# while (( $# 0 )) do appname=${APPS_BASE}/$1 declare -i procid if [ -d ${appname} ]; then cd ${appname}; procid=`ps ax | grep -Dcatalina.base=${appname} | grep -v grep | awk '{print $1}'` if [ $procid != 0 ]; then echo Application $1 appears to be already running (pid $procid) elif [ -f bin/start_${1}.sh ]; then sh bin/start_${1}.sh start sleep 2; *** line 36 ***procid=`ps ax | grep -Dcatalina.base=${appname} | grep -v grep | awk '{print $1}'` if [ $procid != 0 ]; then echo $1 Start OK (pid $procid); let x=x+1; fi fi else echo Application $1 doesn't exist or is disabled; let procid=0; fi shift; done if [ $y -gt 1 ]; then echo Started $x of $y Applications fi ;; esac cd ${OLD_PWD} ben short wrote: Probably worth posting the /rel/tomcat/bin/start_apps.sh script as it sounds like it could be suspect. On 10/8/07, Ray Statham [EMAIL PROTECTED] wrote: Afternoon, This is my first posting to this list and after breifly checking the archives I hope this question is not a duplicate: - I have an unusual problem with my previously stable container which now generates over 70 instance on startup. This container has been working correctly for over 12 months, and I am assured by our dev team that no discrete modifications have been made. On startup this output is generated: - start_apps MerchantAdmin Starting MerchantAdmin Using CATALINA_BASE: /rel/apps/MerchantAdmin Using CATALINA_HOME: /rel/tomcat Using CATALINA_TMPDIR: /rel/apps/MerchantAdmin/temp Using JAVA_HOME: /usr/lib/java /rel/tomcat/bin/start_apps.sh: line 36: 30725 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736: syntax error in expression (error token is 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736) After a min or so, the following number of instances are running: - ps aux | grep -c MerchantAdmin 71 I would be very grateful for any assistance with this problem.. Kind regards Ray Statham - 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: Trouble running tomcat on Ubuntu Linux OS X Tiger
From: Unnsse Khan [mailto:[EMAIL PROTECTED] Subject: Re: Trouble running tomcat on Ubuntu Linux OS X Tiger It was the tar.gz package that is downloadable from: http://tomcat.apache.org/download-55.cgi#5.5.25 I am guessing that I only downloaded the Core distribution... Is this the problem? No, that's fine - should be all you need. Still looking like a permissions problem. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Disable HTTP TRACE and DELETE methods
if you use virtual hosts, you should add in each one : RewriteEngine on RewriteOptions inherit Because rewrite rules are not inherited by default. -- Bj On 10/5/07, David Delbecq [EMAIL PROTECTED] wrote: Hi, This is a mailing list about tomcat J2EE server, not about apache webserver. You will likekly not get any answer to your question here mohamed rafi a écrit : Hi, I want to disable the HTTP TRACE and DELETE methods to be invoked on my webserver. I checked on the Net, and found that mod_rewrite should be enabled for this. So, I did the following in httpd.conf, and recycled the Apache Server: LoadModule rewrite_module /usr/libexec/httpd/mod_rewrite.so AddModule mod_rewrite.c IfModule mod_rewrite.c RewriteEngine on RewriteCond %{REQUEST_METHOD} ^TRACE RewriteRule .* - [F] /IfModule It does not help, and still TRACE is enabled: vg0601f-dhcp86:~/Desktop rafi$ telnet test.serial.com 80 Trying xx.xx.xx.xx... Connected to test.serial.com. Escape character is '^]'. TRACE / HTTP/1.0 Host: test.serial.com HTTP/1.1 200 OK Date: Thu, 04 Oct 2007 17:32:02 GMT Server: Apache/1.3.33 (Darwin) mod_ssl/2.8.24 OpenSSL/0.9.7i mod_jk/1.2.6 Connection: close Content-Type: message/http TRACE / HTTP/1.0 Host: test.serial.com .. Connection closed by foreign host. What am missing here? Any pointers on this are most welcome. Regards Mohamed Rafi S Take the Internet to Go: Yahoo!Go puts the Internet in your pocket: mail, news, photos more. http://mobile.yahoo.com/go?refer=1GNXIC - 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: Over 70 instances of Tomcat after startup
It looks like ps ax | grep ... lists several processes for the same JVM, due to threads behavior is Linux, (see 1. http://tomcat.apache.org/faq/unix.html#ps 2. http://java.sun.com/developer/technicalArticles/Programming/linux/index.html (scroll down to About Linux Threads) 3. http://publib.boulder.ibm.com/infocenter/javasdk/v5r0/index.jsp?topic=/com.ibm.java.doc.diagnostics.50/diag/problem_determination/linux_ps.html ) and the next line, if [ $procid != 0 ]; produces syntax error when $procid expands into several lines. Probably the solution is to replace the ps ax | grep ... command so that it 1) requests a hierarchical listing of processes, 2) filters it, but chooses the top line only, 3) parse pid out of it. What version of java are you using? - 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 track can't track the exact line and display the bug line number
When compiling with Ant the debug information is off by default. Look for the debug option of javac task in Ant manual here: http://ant.apache.org/manual/CoreTasks/javac.html - 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: Over 70 instances of Tomcat after startup
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Ray, Ray Statham wrote: procid=`ps ax | grep -Dcatalina.base=${appname} | grep -v grep | awk '{print $1}'` Are you sure this is line 36? It seems like this wouldn't be the one failing, but one where you were trying to use the value of $procid. - From the behavior you are observing and the error message, I'm guessing that you are getting multiple pids back from your process search, which is tripping-up your script. You might want to plan for multiple pids coming back and take appropriate action. Note that you can use $! to get the pid of the last-executed background command., rather than trying to use your messy ps | grep | awk solution. Not sure if there's a better way to see if it's already running. Most scripts like this use a pidfile somewhere to store the pid of the previous execution, and shutdown scripts remove that file. It's crude, but it usually works. http://www.gnu.org/software/bash/manual/bashref.html#SEC25 - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHCj4B9CaO5/Lv0PARAvxcAJ966qImlJdwT6NJSu/E7J9HyEA31wCghRKC qv7xfoA+n388T+efgNWYpfc= =bzV7 -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]
How can I specify the Tomcat directory?
Hello. I've reinstalled the Tomcat server v6.0 on my computer, but when I try to run my application on the Eclipse, I get the error: 'The specified Tomcat installation directory does not exist'. How can I specify the Tomcat installation directory? What am I missing in the configurations of the Eclipse? Waiting for a reply, with the best regards, Jaime Almeida. IPLNet WebMail http://www.net.ipl.pt/mail - 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 can I specify the Tomcat directory?
I've reinstalled the Tomcat server isn't much detail to go on. See if the following link helps by explaining the Tomcat support in Eclipse: http://www.eclipse.org/webtools/faq/TomcatServerFAQ.php It covers WTP 1.5.x, but the majority of the info applies to WTP 2.0.x as well. Cheers, Larry -Original Message- From: Jaime Almeida [mailto:[EMAIL PROTECTED] Sent: Monday, October 08, 2007 11:14 AM To: users@tomcat.apache.org Subject: How can I specify the Tomcat directory? Hello. I've reinstalled the Tomcat server v6.0 on my computer, but when I try to run my application on the Eclipse, I get the error: 'The specified Tomcat installation directory does not exist'. How can I specify the Tomcat installation directory? What am I missing in the configurations of the Eclipse? Waiting for a reply, with the best regards, Jaime Almeida. IPLNet WebMail http://www.net.ipl.pt/mail - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 6 on ubuntu linux(Fiesty Fawn)
Hi , My webapp hangs on tomcat. I have struts,spring and hibernate on it. I was getting an OutOfMemory error initially, on clicking each of the links. I thought the problem could be jvm's . when I did ls -alt /usr/bin/java , it pointed to /usr/local../alternatives/java.. and java -version gave gij 1.4.2. What is that? I thought this could be the reason since my javac -version pointed to jdk1.6 . I changed the symlink to point to jdk1.6 java by issuing ln -s /usr/local/jdk../java /usr/bin/java But my webapp is now hanging? Is there any reason? -- Thanks Arun George
Re: Tomcat connections not closing.
connectionTimeout - gets set to your sockets SO_TIMEOUT, but disableUploadTimeout=true unsets the value in the line above, causing socketWrite0 to not have a timeout, hence if you set disableUploadTimeout=false, then you will make sure that socket read and writes from your servlets/jsps, will be subject to timeout as well, and not hang. in your apache httpd conf file, make sure your mod_proxy has a timeout configured as well after that, I would put in a network sniffer (like ethereal) between apache and tomcat, so that you can see where it gets stuck and why. Filip rgoers wrote: FWIW we have been experiencing this problem intermittently for 2 years and still haven't figured out what is causing it. We changed from IBM JDK 1.4.2 to Sun 1.5, tomcat to JBoss 4.0.3. The only difference is that in our case once the thread gets stuck it never seems to time out - at least as far as we can tell. In our case we might go for a week before we see this happen. In our case all of the requests go through an Apache Proxy. The requests might then go through a load balancer - we've tried it both ways - before hittlng the servlet container. I'd appreciate more details in why connectionTimeout and disableUploadTimeout might have some effect - their descriptions don't seem to apply to this scenario. Ralph Hello Tomcat users, We are having difficulty with connections to Tomcat remaining open after the client hits stop in their browser. This only seems to happen when we have a particular combination of load balancer hardware in front of the tomcats. We are also running apache and have not seen the same behavior there, even though the load balancer hardware and config is the same. We are using Tomcat 5.5.20 on linux 2.6.9-34.0.1.ELsmp. It is running standalone. We are using APR in some environments and not in others, but see the problem in either configuration. We have captured tcpdumps and see the pattern at the bottom of this email. It appears that the web application tries to retransmit until it gets a RST from the client after about 12 minutes. When we finally get the RST, we get a lot of exceptions (some of them are due to the fact that our session timeout is shorter than the length of these requests. I can add them later if they would be useful). When we do threaddumps of the java process, many threads appear to be stuck in java.net.SocketOutputStream.socketWrite0 Thread [0x0fd] exceeded timeout of [18] millis. Current execution stack at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.coyote.http11.InternalOutputBuffer.realWriteBytes(InternalOut putBuffer.java:746) at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:433) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:348) at org.apache.coyote.http11.InternalOutputBuffer$OutputStreamOutputBuffer.d oWrite(InternalOutputBuffer.java:769) at org.apache.coyote.http11.filters.ChunkedOutputFilter.doWrite(ChunkedOutp utFilter.java:125) at org.apache.coyote.http11.InternalOutputBuffer.doWrite(InternalOutputBuff er.java:579) at org.apache.coyote.Response.doWrite(Response.java:559) at org.apache.catalina.connector.OutputBuffer.realWriteBytes(OutputBuffer.j ava:361) at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:433) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:348) at org.apache.tomcat.util.buf.IntermediateOutputStream.write(C2BConverter.j ava:235) at sun.nio.cs.StreamEncoder$CharsetSE.writeBytes(StreamEncoder.java:336) at sun.nio.cs.StreamEncoder$CharsetSE.implWrite(StreamEncoder.java:395) at sun.nio.cs.StreamEncoder.write(StreamEncoder.java:136) at java.io.OutputStreamWriter.write(OutputStreamWriter.java:191) at org.apache.tomcat.util.buf.WriteConvertor.write(C2BConverter.java:189) at org.apache.tomcat.util.buf.C2BConverter.convert(C2BConverter.java:80) at org.apache.catalina.connector.OutputBuffer.realWriteChars(OutputBuffer.j ava:535) at org.apache.tomcat.util.buf.CharChunk.flushBuffer(CharChunk.java:439) at org.apache.tomcat.util.buf.CharChunk.append(CharChunk.java:294) at org.apache.catalina.connector.OutputBuffer.write(OutputBuffer.java:456) at org.apache.catalina.connector.CoyoteWriter.write(CoyoteWriter.java:142) at org.apache.jasper.runtime.JspWriterImpl.write(JspWriterImpl.java:276) - 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: My own web page as tomcat default web page
*Keep your .war file outside of Tomcat's directory structure and create a file in conf/Catalina/[host] named ROOT.xml; this file must contain a Context element with a docBase attribute that gives the location of your .war file* I tried doing this. But its not working, and the page is still going to to default administrator page. *Well, actually, it's not. Are you running a real version of Tomcat (one downloaded from tomcat.apache.org), or do have some 3rd-party repackaged junk? If the latter, I'd strongly recommend throwing it away and installing a real Tomcat.* I downloaded the application from tomcat.apache.org. and the installation type is 'full'. Its actually not going to 'manager/html' but the url is still 'http://localhost/'. what i want is if if give 'http://localhost/' it should go to ' http://localhost/MyApp/index.jsp' how can i do that. Is there any configuration i have to change? -- Pavan S. Kumar On 10/5/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Pavan Singaraju [mailto:[EMAIL PROTECTED] Subject: Re: My own web page as tomcat default web page On 10/5/07, Nathan Bahr [EMAIL PROTECTED] wrote: Try renaming MyApp(.jar) to ROOT(.jar) in the webapps directory. We'll assume you meant .war, not .jar, in the above. Is there any other way of doing the configuration? I should not rename my application. The default webapp must be deployed as ROOT - no ifs, ands, or buts. It's not likely that you want to deploy your application twice, once as ROOT and once as MyApp, but that is an option. If you insist on not renaming your .war file, you have a couple of options: 1) Write a simple filter, servlet, or .jsp that forwards (or redirects) requests for the default app to the desired one. 2) Keep your .war file outside of Tomcat's directory structure and create a file in conf/Catalina/[host] named ROOT.xml; this file must contain a Context element with a docBase attribute that gives the location of your .war file. I have my application and i am configuring my server. By default when you give the URL it will be going to TOMCAT manager page. for e.g., 'http://locahost' will take you to 'http://localhost/manager/html' which is tomcat's default page. Well, actually, it's not. Are you running a real version of Tomcat (one downloaded from tomcat.apache.org), or do have some 3rd-party repackaged junk? If the latter, I'd strongly recommend throwing it away and installing a real Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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 6 on ubuntu linux(Fiesty Fawn)
I have tomcat 6 running on fiesty with jdk 1.6 and have the following in my init script... JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.00 On 10/8/07, Arun [EMAIL PROTECTED] wrote: Hi , My webapp hangs on tomcat. I have struts,spring and hibernate on it. I was getting an OutOfMemory error initially, on clicking each of the links. I thought the problem could be jvm's . when I did ls -alt /usr/bin/java , it pointed to /usr/local../alternatives/java.. and java -version gave gij 1.4.2. What is that? I thought this could be the reason since my javac -version pointed to jdk1.6 . I changed the symlink to point to jdk1.6 java by issuing ln -s /usr/local/jdk../java /usr/bin/java But my webapp is now hanging? Is there any reason? -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Perl Permissions on Tomcat
Hi, I'm trying to run a Perl script on Tomcat 5.5.8 -- I've managed to successfully run read-only Perl script, but the script I'm trying to run connects to the database and needs to write to the local hard drive. Whenever I try to execute the script, it creates a Perl.exe thread on my Windows server and just never return the HTML code (so the browser keeps loading) -- it seems there is a permission problem. I've tried executing the script on plain old DOS and it works just fine (returns the right HTML code with database information). I've also searched the mailing archives, and tried changing the catalina.policy file by adding the following line: // Give all permission to servlets-cgi.jar grant codeBase file:${catalina.home}/server/lib/servlets-cgi.jar { permission java.security.AllPermission; }; but it doesn't work. Any idea how I can give Perl.exe read/write permission as executed through Tomcat 5.5.8? Thanks in advance! - 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: My own web page as tomcat default web page
From: Pavan Singaraju [mailto:[EMAIL PROTECTED] Subject: Re: My own web page as tomcat default web page Its actually not going to 'manager/html' but the url is still 'http://localhost/'. You seem to be contradicting your earlier posting. What are we to believe? what i want is if if give 'http://localhost/' it should go to 'http://localhost/MyApp/index.jsp' how can i do that. Is there any configuration i have to change? We already told you how. Did you forget to remove the existing ROOT directory under webapps? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Perl Permissions on Tomcat
Li Ye Chen wrote: // Give all permission to servlets-cgi.jar grant codeBase file:${catalina.home}/server/lib/servlets-cgi.jar { permission java.security.AllPermission; }; Are you running with a security manger? If so, try running without and get things working that way first. Then we can focus on the permissions. 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 6 on ubuntu linux(Fiesty Fawn)
Ben, I installed jdk from jdk-6u1-linux-i586.bin. Still my path has not updated, I have to manually point the symlink . Is this not suns's jdk? Am I not using the correct jdk? grep -r -i JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.00 -l /usr did not give me a valid entry either. ? [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo My jvm directory looks like this. On 10/8/07, ben short [EMAIL PROTECTED] wrote: I have tomcat 6 running on fiesty with jdk 1.6 and have the following in my init script... JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.00 On 10/8/07, Arun [EMAIL PROTECTED] wrote: Hi , My webapp hangs on tomcat. I have struts,spring and hibernate on it. I was getting an OutOfMemory error initially, on clicking each of the links. I thought the problem could be jvm's . when I did ls -alt /usr/bin/java , it pointed to /usr/local../alternatives/java.. and java -version gave gij 1.4.2. What is that? I thought this could be the reason since my javac -version pointed to jdk1.6 . I changed the symlink to point to jdk1.6 java by issuing ln -s /usr/local/jdk../java /usr/bin/java But my webapp is now hanging? Is there any reason? -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
RE: Tomcat 6 on ubuntu linux(Fiesty Fawn)
From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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 6 on ubuntu linux(Fiesty Fawn)
Right I installed the jdk from apt as follows.. sudo apt-get install sun-java6-jdk Much easier that messing about with a bin file.. Then set it up using the following command... sudo update-java-alternatives -s java-6-sun How are you starting tomcat? From a script in /etc/init.d ? How did you install tomcat on the box? via apt-get or did you download from http://tomcat.apache.org/download-60.cgi? Regards Ben On 10/8/07, Arun [EMAIL PROTECTED] wrote: Ben, I installed jdk from jdk-6u1-linux-i586.bin. Still my path has not updated, I have to manually point the symlink . Is this not suns's jdk? Am I not using the correct jdk? grep -r -i JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.00 -l /usr did not give me a valid entry either. ? [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo My jvm directory looks like this. On 10/8/07, ben short [EMAIL PROTECTED] wrote: I have tomcat 6 running on fiesty with jdk 1.6 and have the following in my init script... JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.00 On 10/8/07, Arun [EMAIL PROTECTED] wrote: Hi , My webapp hangs on tomcat. I have struts,spring and hibernate on it. I was getting an OutOfMemory error initially, on clicking each of the links. I thought the problem could be jvm's . when I did ls -alt /usr/bin/java , it pointed to /usr/local../alternatives/java.. and java -version gave gij 1.4.2. What is that? I thought this could be the reason since my javac -version pointed to jdk1.6 . I changed the symlink to point to jdk1.6 java by issuing ln -s /usr/local/jdk../java /usr/bin/java But my webapp is now hanging? Is there any reason? -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - 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: Perl Permissions on Tomcat
Will it pose a security risk if I disable the Security Manager? I am running an enterprise firewall on the server... -Original Message- Date: Mon Oct 08 12:03:37 EDT 2007 From: Mark Thomas [EMAIL PROTECTED] Subject: Re: Perl Permissions on Tomcat To: Tomcat Users List users@tomcat.apache.org Li Ye Chen wrote: // Give all permission to servlets-cgi.jar grant codeBase file:${catalina.home}/server/lib/servlets-cgi.jar { permission java.security.AllPermission; }; Are you running with a security manger? If so, try running without and get things working that way first. Then we can focus on the permissions. 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] - 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 6 on ubuntu linux(Fiesty Fawn)
How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
Re: Tomcat 6 on ubuntu linux(Fiesty Fawn)
Don't worry about removing it for now follow the steps i showed you to install jdk 1.6 and then set it as what gets executed when you type java at the prompt On 10/8/07, Arun [EMAIL PROTECTED] wrote: How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - 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 6 on ubuntu linux(Fiesty Fawn)
sorry, you did not include the steps to install jdk1.6 in this conversation. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Don't worry about removing it for now follow the steps i showed you to install jdk 1.6 and then set it as what gets executed when you type java at the prompt On 10/8/07, Arun [EMAIL PROTECTED] wrote: How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
Re: Tomcat 6 on ubuntu linux(Fiesty Fawn)
Hmm, Well here they are again... Right I installed the jdk from apt as follows.. sudo apt-get install sun-java6-jdk Much easier that messing about with a bin file.. Then set it up using the following command... sudo update-java-alternatives -s java-6-sun How are you starting tomcat? From a script in /etc/init.d ? How did you install tomcat on the box? via apt-get or did you download from http://tomcat.apache.org/download-60.cgi? Regards Ben On 10/8/07, Arun [EMAIL PROTECTED] wrote: sorry, you did not include the steps to install jdk1.6 in this conversation. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Don't worry about removing it for now follow the steps i showed you to install jdk 1.6 and then set it as what gets executed when you type java at the prompt On 10/8/07, Arun [EMAIL PROTECTED] wrote: How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - 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 6 on ubuntu linux(Fiesty Fawn)
Ben, Sorry, I replied a bit fast. I got it. I got the steps. That is correct. Using apt is better. Yes, I got tomcat from that website. I did a tar -xvvf and copied it to /usr/local/bin. Is that correct ? Hold on a second anyway. Why do you prefer sunjdk other than the normal one. Or are they same? On 10/8/07, ben short [EMAIL PROTECTED] wrote: Hmm, Well here they are again... Right I installed the jdk from apt as follows.. sudo apt-get install sun-java6-jdk Much easier that messing about with a bin file.. Then set it up using the following command... sudo update-java-alternatives -s java-6-sun How are you starting tomcat? From a script in /etc/init.d ? How did you install tomcat on the box? via apt-get or did you download from http://tomcat.apache.org/download-60.cgi? Regards Ben On 10/8/07, Arun [EMAIL PROTECTED] wrote: sorry, you did not include the steps to install jdk1.6 in this conversation. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Don't worry about removing it for now follow the steps i showed you to install jdk 1.6 and then set it as what gets executed when you type java at the prompt On 10/8/07, Arun [EMAIL PROTECTED] wrote: How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
Re: How can I specify the Tomcat directory?
I still have the problem with the Tomcat Server when I try to run my application. Now I don't have the 'run on server' selection on the 'Run As' menu in my video.jsp that I have to run for the sake of my Final Project... I have to open the 'Open Run Dialog' to run my application, but always get the error: 'The specified Tomcat installation directory does not exist'. How can I solve this problem? Best regards, Jaime Almeida. Larry Isaacs writes: I've reinstalled the Tomcat server isn't much detail to go on. See if the following link helps by explaining the Tomcat support in Eclipse: http://www.eclipse.org/webtools/faq/TomcatServerFAQ.php It covers WTP 1.5.x, but the majority of the info applies to WTP 2.0.x as well. Cheers, Larry -Original Message- From: Jaime Almeida [mailto:[EMAIL PROTECTED] Sent: Monday, October 08, 2007 11:14 AM To: users@tomcat.apache.org Subject: How can I specify the Tomcat directory? Hello. I've reinstalled the Tomcat server v6.0 on my computer, but when I try to run my application on the Eclipse, I get the error: 'The specified Tomcat installation directory does not exist'. How can I specify the Tomcat installation directory? What am I missing in the configurations of the Eclipse? Waiting for a reply, with the best regards, Jaime Almeida. IPLNet WebMail http://www.net.ipl.pt/mail - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] IPLNet WebMail http://www.net.ipl.pt/mail - 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 6 on ubuntu linux(Fiesty Fawn)
For running I linked catalina.sh by ln ln -s /usr/local/apache-tomcat-6.0.13/bin/catalina.sh catalina. And I start the server by catalina start and stop it by catalina stop. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Right I installed the jdk from apt as follows.. sudo apt-get install sun-java6-jdk Much easier that messing about with a bin file.. Then set it up using the following command... sudo update-java-alternatives -s java-6-sun How are you starting tomcat? From a script in /etc/init.d ? How did you install tomcat on the box? via apt-get or did you download from http://tomcat.apache.org/download-60.cgi? Regards Ben On 10/8/07, Arun [EMAIL PROTECTED] wrote: Ben, I installed jdk from jdk-6u1-linux-i586.bin. Still my path has not updated, I have to manually point the symlink . Is this not suns's jdk? Am I not using the correct jdk? grep -r -i JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.00 -l /usr did not give me a valid entry either. ? [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java- gcj.jinfo My jvm directory looks like this. On 10/8/07, ben short [EMAIL PROTECTED] wrote: I have tomcat 6 running on fiesty with jdk 1.6 and have the following in my init script... JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.00 On 10/8/07, Arun [EMAIL PROTECTED] wrote: Hi , My webapp hangs on tomcat. I have struts,spring and hibernate on it. I was getting an OutOfMemory error initially, on clicking each of the links. I thought the problem could be jvm's . when I did ls -alt /usr/bin/java , it pointed to /usr/local../alternatives/java.. and java -version gave gij 1.4.2. What is that? I thought this could be the reason since my javac -version pointed to jdk1.6 . I changed the symlink to point to jdk1.6 java by issuing ln -s /usr/local/jdk../java /usr/bin/java But my webapp is now hanging? Is there any reason? -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
Re: FindClass org/apache/catalina/startup/Bootstrap failed
Marlin Pierce schrieb: I downloaded the zip file, followed the instructions, and startup.bat gave the following in stdout Using CATALINA_BASE: C:\Program Files\Apache Software Foundation\apache-tomcat-6.0.14 Using CATALINA_HOME: C:\Program Files\Apache Software Foundation\apache-tomcat-6.0.14 Using CATALINA_TMPDIR: C:\Program Files\Apache Software Foundation\apache-tomcat-6.0.14\temp Using JRE_HOME:C:\Program Files\Java\jdk1.6.0_02 but the web server was not running. Another shell window did open, but it closed right away. As Chuck already pointed out, the logs should contain info about what happened. As a side note: when testing a Tomcat installation I find it convenient to use catalina.bat run instead of startup.bat because one can see the log messages on stdout of the same console not in another shell window which might quickly be gone again. But nevertheless: regardless of the means you use to start Tomcat, the relevant info should (also) be in the logs. Regards mks The logs directory is empty. catalina run outputs the following: Using CATALINA_BASE: C:\Program Files\Apache Software Foundation\apache-tomcat -6.0.14 Using CATALINA_HOME: C:\Program Files\Apache Software Foundation\apache-tomcat -6.0.14 Using CATALINA_TMPDIR: C:\Program Files\Apache Software Foundation\apache-tomcat -6.0.14\temp Using JRE_HOME:C:\Program Files\Java\jdk1.6.0_02 Exception in thread main java.lang.NoClassDefFoundError: java/la/g ClassLoader JRE_HOME=C:\Program Files\Java\jdk1.6.0_02 When I change JRE_HOME to C:\Program Files\Java\jre1.6.0_02 the output of catalina run is: Using CATALINA_BASE: C:\Program Files\Apache Software Foundation\apache-tomcat -6.0.14 Using CATALINA_HOME: C:\Program Files\Apache Software Foundation\apache-tomcat -6.0.14 Using CATALINA_TMPDIR: C:\Program Files\Apache Software Foundation\apache-tomcat -6.0.14\temp Using JRE_HOME:C:\Program Files\Java\jre1.6.0_02 Exception in thread main java.lang.NoClassDefFoundError: java/la/g?String at java.lang.Class.getDeclaredConstructors0(Native Method) at java.lang.Class.privateGetDeclaredConstructors(Unknown Source) at java.lang.Class.getConstructor0(Unknown Source) at java.lang.Class.newInstance0(Unknown Source) at java.lang.Class.newInstance(Unknown Source) at org.apache.juli.ClassLoaderLogManager.readConfiguration(ClassLoaderLogManager.java:398) at org.apache.juli.ClassLoaderLogManager.readConfiguration(ClassLoaderLogManager.java:342) at org.apache.juli.ClassLoaderLogManager.readConfiguration(ClassLoaderLogManager.java:238) at java.util.logging.LogManager$2.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.util.logging.LogManager.readPrimordialConfiguration(Unknown Source) at java.util.logging.LogManager.getLogManager(Unknown Source) at java.util.logging.Logger.init(Unknown Source) at java.util.logging.LogManager$RootLogger.init(Unknown Source) at java.util.logging.LogManager$RootLogger.init(Unknown Source) at java.util.logging.LogManager$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.util.logging.LogManager.clinit(Unknown Source) at java.util.logging.Logger.getLogger(Unknown Source) at org.apache.juli.logging.DirectJDKLog.init(DirectJDKLog.java:71) at org.apache.juli.logging.DirectJDKLog.getInstance(DirectJDKLog.java:178) at org.apache.juli.logging.LogFactory.getInstance(LogFactory.java:170) at org.apache.juli.logging.LogFactory.getInstance(LogFactory.java:241) at org.apache.juli.logging.LogFactory.getLog(LogFactory.java:296) at org.apache.catalina.startup.Bootstrap.clinit(Bootstrap.java:54) Exception in thread Thread-0 java.lang.NoClassDefFoundError: Could not initialize class java.util.logging.LogManager at java.util.logging.LogManager$Cleaner.run(Unknown Source) The OS is Windows Server 2003. - 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 6 on ubuntu linux(Fiesty Fawn)
Ben , Ding On 10/8/07, ben short [EMAIL PROTECTED] wrote: Hmm, Well here they are again... Right I installed the jdk from apt as follows.. sudo apt-get install sun-java6-jdk Much easier that messing about with a bin file.. Then set it up using the following command... sudo update-java-alternatives -s java-6-sun How are you starting tomcat? From a script in /etc/init.d ? How did you install tomcat on the box? via apt-get or did you download from http://tomcat.apache.org/download-60.cgi? Regards Ben On 10/8/07, Arun [EMAIL PROTECTED] wrote: sorry, you did not include the steps to install jdk1.6 in this conversation. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Don't worry about removing it for now follow the steps i showed you to install jdk 1.6 and then set it as what gets executed when you type java at the prompt On 10/8/07, Arun [EMAIL PROTECTED] wrote: How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
Re: Perl Permissions on Tomcat
Li Ye Chen wrote: Will it pose a security risk if I disable the Security Manager? I am running an enterprise firewall on the server... That depends on your environment. But you have a separate machine for development and/or testing - right? Right now we need to figure out if it is the security manager causing the problem or something else. 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]
Very Long Full GC after Inactivity
Hi, We are running an application on Tomcat 5.0.28 with Java 1.4.2. The usage of the application is very cyclical. It is used heavily during the day, and lightly at night. During peak daytime hours, a full garbage collection takes less than 2 seconds, which is fine. However, after a long period of inactivity in the evening, a full garbage collection will be triggered and take a very long time. Sometimes over a minute! Is there any way to avoid this long garbage collection? Why does it take so long? (Maybe because it is filling up with many small objects over time rather than a few larger objects?) Thanks for your help. -Bill p.s. Upgrading to a newer version of Tomcat or Java is unfortunately not an option at this point. -- View this message in context: http://www.nabble.com/Very-Long-Full-GC-after-Inactivity-tf4589459.html#a13100609 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: Very Long Full GC after Inactivity
Hi, check the jvm runs in server mode (check there is a '-server' parameter given to jvm startup). Server and client mode have different GC mecanisms. Bill Clarke-Fields a écrit : Hi, We are running an application on Tomcat 5.0.28 with Java 1.4.2. The usage of the application is very cyclical. It is used heavily during the day, and lightly at night. During peak daytime hours, a full garbage collection takes less than 2 seconds, which is fine. However, after a long period of inactivity in the evening, a full garbage collection will be triggered and take a very long time. Sometimes over a minute! Is there any way to avoid this long garbage collection? Why does it take so long? (Maybe because it is filling up with many small objects over time rather than a few larger objects?) Thanks for your help. -Bill p.s. Upgrading to a newer version of Tomcat or Java is unfortunately not an option at this point. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Exception in thread main????
Hello. I've already solved the problem with the Tomcat specified directory, but now I have a new problem: 'Excpetion in thread main'. What thread main? My application doesn't have any main - It's a jsp application and it doesn't need any main. What is causing this problem? Can you tell me? Best regards, Jaime Almeida. IPLNet WebMail http://www.net.ipl.pt/mail - 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 6 on ubuntu linux(Fiesty Fawn)
Thanks Ben , Now my weapp is running. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Hmm, Well here they are again... Right I installed the jdk from apt as follows.. sudo apt-get install sun-java6-jdk Much easier that messing about with a bin file.. Then set it up using the following command... sudo update-java-alternatives -s java-6-sun How are you starting tomcat? From a script in /etc/init.d ? How did you install tomcat on the box? via apt-get or did you download from http://tomcat.apache.org/download-60.cgi? Regards Ben On 10/8/07, Arun [EMAIL PROTECTED] wrote: sorry, you did not include the steps to install jdk1.6 in this conversation. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Don't worry about removing it for now follow the steps i showed you to install jdk 1.6 and then set it as what gets executed when you type java at the prompt On 10/8/07, Arun [EMAIL PROTECTED] wrote: How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
RE: Problem with session
Hi, thanks for the reply. I checked the log in the logs directory, there's nothing that says tomcat has been restarted. I run tomcat 5.0. It's an internal session id that is stored in the session. I run on windows xp pro. The JRE says version 6 in the readme. I'm going to have a look at the keepalive and let you know if it has an impact. Thank you very much for this info. Caldarale, Charles R wrote: From: Alex79 [mailto:[EMAIL PROTECTED] Subject: Problem with session I am running a web service on tomcat, which I am not very familiar with (tomcat). At least tell us the version of Tomcat you're using; also, although probably not relevant for this problem, include the JRE/JDK level and the platform you're running on. A client application that sends requests to this web service sends the session id with a certain type of request. Are you referring to a session cookie or the JSESSIONID parameter (as defined in the servlet spec), or is this a roll-your-own session identifier? After many requests (over 1000) occurring in the same session (in other words, by the same client), the session id no longer exists (the web service throws an error when the type of request that has the session id parameter gives an unknown session id). There is a maxKeepAliveRequests attribute for a Connector element, with a default setting of 100. It's possible that's coming into play, depending on the client you're using. Read about here: http://tomcat.apache.org/tomcat-5.5-doc/config/http.html Any idea if tomcat is somehow auto-refreshing my web application (or itself) causing my session to be cleared? Unlikely, but if the webapp is being restarted, it should show up in Tomcat's logs. Have you looked at them? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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/Problem-with-session-tf4585082.html#a13100920 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: Very Long Full GC after Inactivity
From: David Delbecq [mailto:[EMAIL PROTECTED] Subject: Re: Very Long Full GC after Inactivity check the jvm runs in server mode (check there is a '-server' parameter given to jvm startup). Server and client mode have different GC mecanisms. That's not correct; the set of GC algorithms available for server and client are identical, but the default heap sizes are different. For initial problem analysis, turn on -verbose:gc if you haven't already, and use JConsole to look at the heap usage. You may need a profiler to find out just what objects are hanging around and causing the long pause. You might want to try running with a later JVM - a 1.5 or 6 version should give you reduced pause times as well as better performance overall. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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 can I specify the Tomcat directory?
From: Jaime Almeida [mailto:[EMAIL PROTECTED] Subject: Re: How can I specify the Tomcat directory? Now I don't have the 'run on server' selection on the 'Run As' menu in my video.jsp that I have to run for the sake of my Final Project... I have to open the 'Open Run Dialog' to run my application, but always get the error: 'The specified Tomcat installation directory does not exist'. This really seems to be an Eclipse configuration issue, not a Tomcat one. Have you tried the Eclipse mailing lists? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Exception in thread main????
From: Jaime Almeida [mailto:[EMAIL PROTECTED] Subject: Exception in thread main I have a new problem: 'Excpetion in thread main'. What thread main? The main thread is just the initial one that creates the JVM and calls the initial class; all Java programs have one. What is causing this problem? Can you tell me? You've left out all interesting information, such as what the exception really was and the stack trace associated with it. You seem unfamiliar with Java, so you might want to brush up a bit on that first. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: FindClass org/apache/catalina/startup/Bootstrap failed
From: Marlin Pierce [mailto:[EMAIL PROTECTED] Subject: Re: FindClass org/apache/catalina/startup/Bootstrap failed Exception in thread main java.lang.NoClassDefFoundError: java/la/g ClassLoader Is the above an accurate representation of the message? If so, an n has been replaced by a slash, and you've got some serious data corruption happening. Exception in thread main java.lang.NoClassDefFoundError: java/la/g?String Looks like more of the same - a class name has been changed. Something is corrupted; could be your JDK/JRE or Tomcat installations, or flakey memory, or unreliable disk, or ??? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Perl Permissions on Tomcat
Yes, it's on a separate machine... -Original Message- Date: Mon Oct 08 12:52:23 EDT 2007 From: Mark Thomas [EMAIL PROTECTED] Subject: Re: Perl Permissions on Tomcat To: Tomcat Users List users@tomcat.apache.org Li Ye Chen wrote: Will it pose a security risk if I disable the Security Manager? I am running an enterprise firewall on the server... That depends on your environment. But you have a separate machine for development and/or testing - right? Right now we need to figure out if it is the security manager causing the problem or something else. 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] - 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: Very Long Full GC after Inactivity
David, Tomcat is running as a Windows service, and the jvm startup parameter is set to: C:\j2sdk1.4.2_11\jre\bin\server\jvm.dll. Do I also need to pass a -server parameter? Thanks, -Bill David Delbecq-2 wrote: Hi, check the jvm runs in server mode (check there is a '-server' parameter given to jvm startup). Server and client mode have different GC mecanisms. Bill Clarke-Fields a écrit : Hi, We are running an application on Tomcat 5.0.28 with Java 1.4.2. The usage of the application is very cyclical. It is used heavily during the day, and lightly at night. During peak daytime hours, a full garbage collection takes less than 2 seconds, which is fine. However, after a long period of inactivity in the evening, a full garbage collection will be triggered and take a very long time. Sometimes over a minute! Is there any way to avoid this long garbage collection? Why does it take so long? (Maybe because it is filling up with many small objects over time rather than a few larger objects?) Thanks for your help. -Bill p.s. Upgrading to a newer version of Tomcat or Java is unfortunately not an option at this point. - 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/Very-Long-Full-GC-after-Inactivity-tf4589459.html#a13101254 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: Problem with session
From: Alex79 [mailto:[EMAIL PROTECTED] Subject: RE: Problem with session I checked the log in the logs directory, there's nothing that says tomcat has been restarted. What about the webapp being restarted? (Not likely either.) I run tomcat 5.0. Tomcat 5.0.what? It's an internal session id that is stored in the session. So this is not a Tomcat issue - it's a problem with your webapp. The JRE says version 6 in the readme. You need to be more precise; run java -version to get the exact level. I'm going to have a look at the keepalive and let you know if it has an impact. Since this appears to be an application-specific session identifier, and not the one defined by the servlet spec, the keepalive setting shouldn't matter. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Very Long Full GC after Inactivity
Charles, I have tuned the heap size based on what is ideal during peak hours. The problem is that off-hours usage is very different, and leads to these very long full GCs. Does it sound like an application problem? I have not done any analysis to determine what kind of objects are hanging around. This is a third party application, so there is really not much we can do on that front anyway. Again, unfortunately upgrading is not an option for us at this point. Thanks, -Bill Caldarale, Charles R wrote: From: David Delbecq [mailto:[EMAIL PROTECTED] Subject: Re: Very Long Full GC after Inactivity check the jvm runs in server mode (check there is a '-server' parameter given to jvm startup). Server and client mode have different GC mecanisms. That's not correct; the set of GC algorithms available for server and client are identical, but the default heap sizes are different. For initial problem analysis, turn on -verbose:gc if you haven't already, and use JConsole to look at the heap usage. You may need a profiler to find out just what objects are hanging around and causing the long pause. You might want to try running with a later JVM - a 1.5 or 6 version should give you reduced pause times as well as better performance overall. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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/Very-Long-Full-GC-after-Inactivity-tf4589459.html#a13101470 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: Very Long Full GC after Inactivity
From: Bill Clarke-Fields [mailto:[EMAIL PROTECTED] Subject: Re: Very Long Full GC after Inactivity Tomcat is running as a Windows service, and the jvm startup parameter is set to: C:\j2sdk1.4.2_11\jre\bin\server\jvm.dll. Do I also need to pass a -server parameter? No, there are no such parameters when running as a service. Your selection of the correct .dll guarantees server mode, which seems appropriate for your environment. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Very Long Full GC after Inactivity
From: Bill Clarke-Fields [mailto:[EMAIL PROTECTED] Subject: RE: Very Long Full GC after Inactivity The problem is that off-hours usage is very different, and leads to these very long full GCs. GC pause time is largely dependent on the number of live objects existing at the time of the GC, so yes, it could be an application problem. A profiler will help determine what these objects are. It's definitely unfortunate you can't upgrade, since that precludes you from running JConsole. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Problem with session
Java version: Java(TM) SE Runtime Environment (build 1.6.0_01-b06) Java HotSpot(TM) Client VM (build 1.6.0_01-b06, mixed mode) I modified the log4j.properties file to receive all logs from INFO. When the problem occurs, I see a WARN level message that says that there is no header (custom info stored by the webapp) in session (managed by tomcat I guess) for session id and that this is a normal condition after a server reboot and that it will occur until the client refreshes (that is, until the client send another type of request that initializes the header in the session). This message comes from the webapp (I have the source code and saw the message in it). That's why it makes me think that it has something to do with tomcat (or the webapp) restarting alone for some reason. I'll try to look further in the source code and try to see if the sessionid comes from tomcat, maybe I got that wrong and that it does come from tomcat. Where can I find the exact tomcat version? Thank you, Caldarale, Charles R wrote: From: Alex79 [mailto:[EMAIL PROTECTED] Subject: RE: Problem with session I checked the log in the logs directory, there's nothing that says tomcat has been restarted. What about the webapp being restarted? (Not likely either.) I run tomcat 5.0. Tomcat 5.0.what? It's an internal session id that is stored in the session. So this is not a Tomcat issue - it's a problem with your webapp. The JRE says version 6 in the readme. You need to be more precise; run java -version to get the exact level. I'm going to have a look at the keepalive and let you know if it has an impact. Since this appears to be an application-specific session identifier, and not the one defined by the servlet spec, the keepalive setting shouldn't matter. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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/Problem-with-session-tf4585082.html#a13101555 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: Problem with session
From: Alex79 [mailto:[EMAIL PROTECTED] Subject: RE: Problem with session Java(TM) SE Runtime Environment (build 1.6.0_01-b06) That's a couple of updates old, but very unlikely to be an issue. When the problem occurs, I see a WARN level message that says that there is no header (custom info stored by the webapp) in session (managed by tomcat I guess) Yes, that does sound like a Tomcat-managed session. Is there any chance your webapp is calling the invalidate() method for the session? You could always define a session listener for your webapp and have it log the comings and goings of each session. Where can I find the exact tomcat version? It's usually part of the name of the installation directory. It can be found by running the version.bat script, or looking on Tomcat's status page (http://host:port/manager/status). - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Form based auth - Not working
Hi, I'm experiencing a problem with the FORM based authentication provided by Tomcat. I've done almost (I think that everything!) that the doc requires to configure a FORM based authentication and doesn't work. I have a DB with users and user-roles tables and data in those tables but every time I try to log in my application it will fail with no reason, nor log either! I started thinking that any kind of authentication wasn't going to work, so I tried using the BASIC based one, which surprisingly worked :) So, I don't know what is my mistake. I'm sending here the content of my context xml file in Resource name=jdbc/PosgradoDS auth=Container type= javax.sql.DataSource maxActive=10 maxIdle=5 maxWait=1 username=root password=mysqlroot driverClassName= com.mysql.jdbc.Driver url=jdbc:mysql://192.168.10.3:3306/Posgrado?autoReconnect=true validationQuery=select * from TEST/ Realm className=org.apache.catalina.realm.JDBCRealm debug=99 driverName=com.mysql.jdbc.Driver connectionURL=jdbc:mysql://192.168.10.3:3306/Posgrado?user=rootamp;password=mysqlroot userTable=USERS userNameCol=USER_NAME userCredCol=USER_PASS userRoleTable=USER_ROLES roleNameCol=ROLE_NAME/ The db schema has been also configured to let anyone to get a connection to it, so that's not a problem and I've also tried getting data from the DataSource configured from my app and IT works fine! (as u may see, the realm is not a DataSourceRealm because it doesn't work at all, at least in my case!!! Another problem for another thread I guess...) The web.xml of my app is correctly configured and that's not the problem! Does any of you what is my problem? Regards, Nicolas Gonzalez P.S.: OS: Ubuntu 7.0.4 / Tomcat: 5.5 / Java: 5 / DB: MySQL 5 just in case any of u needs that info...
Re: Form based auth - Not working
Nicolas Gonzalez wrote: I've done almost (I think that everything!) that the doc requires to configure a FORM based authentication and doesn't work. I have a DB with users and user-roles tables and data in those tables but every time I try to log in my application it will fail with no reason, nor log either! I started thinking that any kind of authentication wasn't going to work, so I tried using the BASIC based one, which surprisingly worked :) BASIC auth with the realm below or with the MemoryUserDatabaseRealm? So, I don't know what is my mistake. I'm sending here the content of my context xml file in Looks OK at first glance. (as u may see, the realm is not a DataSourceRealm because it doesn't work at all, at least in my case!!! Another problem for another thread I guess...) That is probably because you need to specify localDataSource=true to tell the Realm the data source is defined in context.xml rather than globally in server.xml The web.xml of my app is correctly configured and that's not the problem! Can we see it any way, just to confirm please. 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: Form based auth - Not working
Please provide web.xml login form file (most probaly something like login.jsp) url you typed in browser what you see on screen `Nicolas Gonzalez a écrit : Hi, I'm experiencing a problem with the FORM based authentication provided by Tomcat. I've done almost (I think that everything!) that the doc requires to configure a FORM based authentication and doesn't work. I have a DB with users and user-roles tables and data in those tables but every time I try to log in my application it will fail with no reason, nor log either! I started thinking that any kind of authentication wasn't going to work, so I tried using the BASIC based one, which surprisingly worked :) So, I don't know what is my mistake. I'm sending here the content of my context xml file in Resource name=jdbc/PosgradoDS auth=Container type= javax.sql.DataSource maxActive=10 maxIdle=5 maxWait=1 username=root password=mysqlroot driverClassName= com.mysql.jdbc.Driver url=jdbc:mysql://192.168.10.3:3306/Posgrado?autoReconnect=true validationQuery=select * from TEST/ Realm className=org.apache.catalina.realm.JDBCRealm debug=99 driverName=com.mysql.jdbc.Driver connectionURL=jdbc:mysql://192.168.10.3:3306/Posgrado?user=rootamp;password=mysqlroot userTable=USERS userNameCol=USER_NAME userCredCol=USER_PASS userRoleTable=USER_ROLES roleNameCol=ROLE_NAME/ The db schema has been also configured to let anyone to get a connection to it, so that's not a problem and I've also tried getting data from the DataSource configured from my app and IT works fine! (as u may see, the realm is not a DataSourceRealm because it doesn't work at all, at least in my case!!! Another problem for another thread I guess...) The web.xml of my app is correctly configured and that's not the problem! Does any of you what is my problem? Regards, Nicolas Gonzalez P.S.: OS: Ubuntu 7.0.4 / Tomcat: 5.5 / Java: 5 / DB: MySQL 5 just in case any of u needs that info... - 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: Form based auth - Not working
Hi Mark and David! See my response inline On 10/8/07, Mark Thomas [EMAIL PROTECTED] wrote: Nicolas Gonzalez wrote: I've done almost (I think that everything!) that the doc requires to configure a FORM based authentication and doesn't work. I have a DB with users and user-roles tables and data in those tables but every time I try to log in my application it will fail with no reason, nor log either! I started thinking that any kind of authentication wasn't going to work, so I tried using the BASIC based one, which surprisingly worked :) BASIC auth with the realm below or with the MemoryUserDatabaseRealm? With the MemoryUserDatabaseRealm So, I don't know what is my mistake. I'm sending here the content of my context xml file in Looks OK at first glance. Looks ok for me too! (as u may see, the realm is not a DataSourceRealm because it doesn't work at all, at least in my case!!! Another problem for another thread I guess...) That is probably because you need to specify localDataSource=true to tell the Realm the data source is defined in context.xml rather than globally in server.xml Thx for this information. I didn't know that. I'll try and tell u what happens after with that change! The web.xml of my app is correctly configured and that's not the problem! Can we see it any way, just to confirm please. Sure. Here it is the security part of the xml file: .. security-constraint web-resource-collection web-resource-namePosgrado/web-resource-name url-pattern/*/url-pattern http-methodDELETE/http-method http-methodGET/http-method http-methodPOST/http-method http-methodPUT/http-method /web-resource-collection auth-constraint role-nameadmin/role-name /auth-constraint /security-constraint security-role descriptionAdministrador de la aplicacion/description role-nameadmin/role-name /security-role login-config auth-methodFORM/auth-method realm-namePosgrado Realm/realm-name form-login-config form-login-page/login.jsp/form-login-page form-error-page/autherror.jsp/form-error-page /form-login-config /login-config As you may have realized, in the BD there's a user with the role admin and (this was requested by David's email) the login.jsp and autherror.jsp are jsps taken from the examples of the tomcat documentation. Every time I try to go to a configured action (Struts action), let's say: main.do or whatever, I'm taken to the login.jsp. After typying in the user and pass (correctly typed) I'm taken to the autherror.jsp instead of the desired action. The jsp is just like the examples of the doc. This is the reason whay I'm not attaching those files to the email, because it's just the same Thanks in advance, Nicolas Gonzalez Buenos Aires - Argentina 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: My own web page as tomcat default web page
I forgot to remove the ROOT directory from the TOMCAT. Its working now. Thanks guys. -- Pavan S. Kumar On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Pavan Singaraju [mailto:[EMAIL PROTECTED] Subject: Re: My own web page as tomcat default web page Its actually not going to 'manager/html' but the url is still 'http://localhost/'. You seem to be contradicting your earlier posting. What are we to believe? what i want is if if give 'http://localhost/' it should go to 'http://localhost/MyApp/index.jsp' how can i do that. Is there any configuration i have to change? We already told you how. Did you forget to remove the existing ROOT directory under webapps? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Multi-thread issue on redeploy of application
It may not related to tomcat directly but I would appreciate if you can help me to find the problem with my web app. The web app creates number of threads, and on each deployement, web app should close threads and create new threads but it instead of closing/reusing old threads, it creates new threads which makes web app crashes. I use struts and in destroy method of RequestProcessor, I have code that shutdowns the ThreadExecutor, but I am not sure why this is not happening. Your help would be appreciated. - BR Take the Internet to Go: Yahoo!Go puts the Internet in your pocket: mail, news, photos more. http://mobile.yahoo.com/go?refer=1GNXIC
RE: Very Long Full GC after Inactivity
I'm just throwing ideas out now, but would it help to set a lower value for the -Xms parameter? Would the JVM shrink the heap size down when usage is low? (I'm guessing not.) Or, is there a way to schedule (or force) full garbage collections? Thanks, -Bill Caldarale, Charles R wrote: From: Bill Clarke-Fields [mailto:[EMAIL PROTECTED] Subject: RE: Very Long Full GC after Inactivity The problem is that off-hours usage is very different, and leads to these very long full GCs. GC pause time is largely dependent on the number of live objects existing at the time of the GC, so yes, it could be an application problem. A profiler will help determine what these objects are. It's definitely unfortunate you can't upgrade, since that precludes you from running JConsole. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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/Very-Long-Full-GC-after-Inactivity-tf4589459.html#a13103292 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: Multi-thread issue on redeploy of application
On 10/8/07, Cool Coder [EMAIL PROTECTED] wrote: I use struts and ..and there *is* a Struts mailing list, eh? Which would probably offer a much better chance of getting app-specific help. I'm just sayin' -- Hassan Schroeder [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: Very Long Full GC after Inactivity
From: Bill Clarke-Fields [mailto:[EMAIL PROTECTED] Subject: RE: Very Long Full GC after Inactivity I'm just throwing ideas out now, but would it help to set a lower value for the -Xms parameter? Probably not. For best throughput, you generally want -Xms and -Xmx to be the same, and as large as your environment allows. Would the JVM shrink the heap size down when usage is low? (I'm guessing not.) It does, but somewhat erratically. You really need to get a profiler running. Or, is there a way to schedule (or force) full garbage collections? Not guaranteed. You can call System.gc(), but there's no requirement that the JVM will honor the call (it usually does, though). If you install Lambda Probe (www.lambdaprobe.org), the System Information tab has a Force Garbage Collection link you can try. On the same page, Lambda Probe also has a Memory utilization button, but I don't remember if it works with your somewhat old versions of Tomcat and JVM. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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 can I specify the Tomcat directory?
How can I specify the Tomcat installation directory? What am I missing in the configurations of the Eclipse? The answer is that you specify the Tomcat installation directory when you are configuring Server Runtime Environment. It is like Java Runtime Environment, but for Java EE. In the main Preferences dialog, expand the Server item in the tree, there is Installed Runtimes item below it. It lists your configured server runtimes. Click Edit... (or Add..), and correct the path. - - - - There are also several places to look after you have done that: 1. Look for the preferences of your project (e.g. through Project\Preferences menu). In the project preferences dialog, look at the Java Build Path item. There, select the Libraries page. Among the libraries will be Apache Tomcat. Click Edit..., and reselect the version. 2. In the main window, in the list of servers (Servers view), you should either open the properties page for your server and check Launch configuration item there, or, easier, just delete and recreate your server. These two steps are to make sure that the server runtime configuration change is reflected in those components. - 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: Multi-thread issue on redeploy of application
Thanks buddy. - Original Message From: Hassan Schroeder [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Monday, October 8, 2007 3:53:20 PM Subject: Re: Multi-thread issue on redeploy of application On 10/8/07, Cool Coder [EMAIL PROTECTED] wrote: I use struts and ..and there *is* a Struts mailing list, eh? Which would probably offer a much better chance of getting app-specific help. I'm just sayin' -- Hassan Schroeder [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] Pinpoint customers who are looking for what you sell. http://searchmarketing.yahoo.com/
Re: Tomcat 6 on ubuntu linux(Fiesty Fawn)
My Project Manager has added Quartz/Rome. The OutOfMemory error comes from that. Exception in thread DefaultQuartzScheduler_Worker-1 java.lang.OutOfMemoryError: PermGen space Do you guys know why the QuartzScheduler does this? On 10/8/07, ben short [EMAIL PROTECTED] wrote: Hmm, Well here they are again... Right I installed the jdk from apt as follows.. sudo apt-get install sun-java6-jdk Much easier that messing about with a bin file.. Then set it up using the following command... sudo update-java-alternatives -s java-6-sun How are you starting tomcat? From a script in /etc/init.d ? How did you install tomcat on the box? via apt-get or did you download from http://tomcat.apache.org/download-60.cgi? Regards Ben On 10/8/07, Arun [EMAIL PROTECTED] wrote: sorry, you did not include the steps to install jdk1.6 in this conversation. On 10/8/07, ben short [EMAIL PROTECTED] wrote: Don't worry about removing it for now follow the steps i showed you to install jdk 1.6 and then set it as what gets executed when you type java at the prompt On 10/8/07, Arun [EMAIL PROTECTED] wrote: How to remove ? apt-get remove? what is the name for this? I dont know the name.. Am I using the right jdk? On 10/8/07, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) [EMAIL PROTECTED]:~/downloads# cd /usr/lib/jvm/ java-1.4.2-gcj-4.1-1.4.2.0/ java-gcj/ .java-gcj.jinfo That's the semi-functional GNU JVM implementation. Strongly suggest you remove it, since it's known to cause problems with complex applications such as Tomcat. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Thanks Arun George
Re: Error track can't track the exact line and display the bug line number
Thanks, Konstantin. Yes you are right. Now it is fine. If using Ant, the default is off, otherwise using command javac directly, by default it is on. On Mon, 2007-10-08 at 18:14 +0400, Konstantin Kolinko wrote: When compiling with Ant the debug information is off by default. Look for the debug option of javac task in Ant manual here: http://ant.apache.org/manual/CoreTasks/javac.html - 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: Very Long Full GC after Inactivity
garbage collection is a reactive process, ie, it wont kick in until it really needs to. and the time it takes for the GC, depends on your java heap size, -Xmx, in JDK 1.5 you can specify GC goals like -XX:MaxGCMinorPauseMillis=value -XX:MaxGCPauseMillis=value to tell the JVM to try to align its GC to meet these goals, however, with JDK 1.4.2 you could try to make your heap smaller or to put in manual System.gc() at a periodic interval, neither of these options is what I like, I would just upgrade the JDK, even though you said its not an option, it would be your best bet for a list of all your jvm options at hand, please take a look at http://blogs.sun.com/watt/resource/jvm-options-list.html Filip Bill Clarke-Fields wrote: Hi, We are running an application on Tomcat 5.0.28 with Java 1.4.2. The usage of the application is very cyclical. It is used heavily during the day, and lightly at night. During peak daytime hours, a full garbage collection takes less than 2 seconds, which is fine. However, after a long period of inactivity in the evening, a full garbage collection will be triggered and take a very long time. Sometimes over a minute! Is there any way to avoid this long garbage collection? Why does it take so long? (Maybe because it is filling up with many small objects over time rather than a few larger objects?) Thanks for your help. -Bill p.s. Upgrading to a newer version of Tomcat or Java is unfortunately not an option at this point. - 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 6 on ubuntu linux(Fiesty Fawn)
From: Arun [mailto:[EMAIL PROTECTED] Subject: Re: Tomcat 6 on ubuntu linux(Fiesty Fawn) Exception in thread DefaultQuartzScheduler_Worker-1 java.lang.OutOfMemoryError: PermGen space http://tomcat.apache.org/faq/memory.html - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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 create/setup a referer log on Tomcat 5.5 server?
My company is using Tomcat 5.5 server to host several websites. Right now, we want to track the stats of web traffic, and a referer log on the server is required for some traffic analyzers. How do we setup such a log? -- View this message in context: http://www.nabble.com/How-to-create-setup-a-referer-log-on-Tomcat-5.5-server--tf4590694.html#a13104911 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]
Linking external website as a default page on Tomcat 5
Hi, I am running tomcat5 version on ubuntu. I want to link external website, say google as my default page served by my tomcat. say when i connect to my tomcat using http://localhost/ then google should open as default page. Any idea? Rgds, -SK _ Exclusive matches at Shaadi.com! Start your Search Now. http://ss1.richmedia.in/recurl.asp?pid=204 - 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 create/setup a referer log on Tomcat 5.5 server?
On 10/8/07, nguyen [EMAIL PROTECTED] wrote: and a referer log How do we setup such a log? Read the doc? :-) http://tomcat.apache.org/tomcat-5.5-doc/config/valve.html HTH, -- Hassan Schroeder [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: Linking external website as a default page on Tomcat 5
On 10/8/07, Sridhar Kulkarni [EMAIL PROTECTED] wrote: I am running tomcat5 version on ubuntu. I want to link external website, say google as my default page served by my tomcat. say when i connect to my tomcat using http://localhost/ then google should open as default page. Any idea? http://sourceforge.net/projects/j2ep/ or http://tuckey.org/urlrewrite/ HTH, -- Hassan Schroeder [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: Linking external website as a default page on Tomcat 5
From: Sridhar Kulkarni [mailto:[EMAIL PROTECTED] Subject: Linking external website as a default page on Tomcat 5 I want to link external website, say google as my default page served by my tomcat. I'm curious - other than spoofing, why would you want to do this? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Very Long Full GC after Inactivity
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Bill, Bill Clarke-Fields wrote: Or, is there a way to schedule (or force) full garbage collections? Not really. You can issue a call to Runtime.gc(), but it's not guaranteed to do anything at all. My experience has been that the JVM does respect your request for a GC, even if it does take a few seconds to kick-in. Do you know what causes these 1-minute-long GCs to kick-off in the first place? I'm asking because you might be able to his a URL that would kick-start the full GC at, say, 5 in the morning just before your real customers got there. It' not perfect, but it might help. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHCqO59CaO5/Lv0PARAitPAJ9TkSr3a5s/ow70OkBVgodXtFyIFgCgi62l TsGjhWTkqGT/JNWPuFqUQoU= =9tx7 -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: Problem with session
Thanks Chuck, I'll check out for a call to the invalidate method of the session. I'll also give a try to the maxKeepAliveRequests, sounds like a good call to me. I read about it in the doc, it says that if there are more than 100 (default value as you mentionned) unprocessed queries in the pipeline, the server closes the connection. Is this for one client or for the whole server? What impact does it have on one session? Here's all the version info: Tomcat Version | JVM Version | JVM Vendor | OS Name | OS Version | OS Architecture Apache Tomcat/5.0.25 | 1.6.0_01-b06 | Sun Microsystems Inc. | Windows XP | 5.1 | x86 I saw some info on max thread also, could it be the cause? One thing I said in my first post that I did not exagerate, the server does receive a LOT of requests per second. Than you again. Caldarale, Charles R wrote: From: Alex79 [mailto:[EMAIL PROTECTED] Subject: RE: Problem with session Java(TM) SE Runtime Environment (build 1.6.0_01-b06) That's a couple of updates old, but very unlikely to be an issue. When the problem occurs, I see a WARN level message that says that there is no header (custom info stored by the webapp) in session (managed by tomcat I guess) Yes, that does sound like a Tomcat-managed session. Is there any chance your webapp is calling the invalidate() method for the session? You could always define a session listener for your webapp and have it log the comings and goings of each session. Where can I find the exact tomcat version? It's usually part of the name of the installation directory. It can be found by running the version.bat script, or looking on Tomcat's status page (http://host:port/manager/status). - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To 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/Problem-with-session-tf4585082.html#a13105465 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: Form based auth - Not working
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Nicolas, Nicolas Gonzalez wrote: I have a DB with users and user-roles tables and data in those tables but every time I try to log in my application it will fail with no reason, nor log either! Care to give us the database schema you are using? Please only show those tables that are relevant (USERS and USER_ROLES). You might want to provide sample contents for the user you are using as a test. I started thinking that any kind of authentication wasn't going to work, so I tried using the BASIC based one, which surprisingly worked :) Well, that's telling. I'm guessing your form isn't done correctly. Would you like to show us the form you are using, or should we keep guessing? validationQuery=select * from TEST Ouch! I wouldn't do that if I were you. Realm className=org.apache.catalina.realm.JDBCRealm Since you've got a JNDI connection pool already configured, why not use that for your Realm (DataSourceRealm) instead of a JDBCRealm. That way, everything uses the same set of connections instead of one separate one for logins. (as u may see, the realm is not a DataSourceRealm because it doesn't work at all, at least in my case!!! Another problem for another thread I guess...) I'm guessing that your form is the problem, not the database. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHCqUw9CaO5/Lv0PARAjlHAJ9PuW+DT9/4KlXsj6px3EDhGVoiiACeIu7+ 7DkzhMXZechE6HdiRa0Ai88= =1A0q -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: Very Long Full GC after Inactivity
Just a hypothesis. During these off-peak hours some other applications are actively running (maintenance etc.), and as java is not intensively used, its memory is swapped to the hard disks. Thus, when it awakens and does the GC, it takes so much time to wake up the memory walking through it to collect the garbage. What is memory consumption at night time? Are there memory-intensive tasks being performed at that time? May be restarting the tomcat can be scheduled after all those are done? (Or a forced GC, or filling memory with a bunch of dummy objects, up to Runtime.freeMemory()?) - 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 - 6.0.14 upgrade problem
I added: org.apache.naming.level=FINE org.apache.tomcat.dbcp.level=FINE to the bottom of my TC_HOME/conf/logging.properties, but the logging output didn't change. Is there something else that needs to be changed to enable logging? Here's the complete log file below: Oct 8, 2007 2:58:03 PM org.apache.catalina.core.AprLifecycleListener init INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C :\Program Files\Java\jdk1.5.0_12\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Fil es\Apache Software Foundation\apache-ant-1.6.5\bin;C:\Program Files\Putty\;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\Java\jdk1.5 .0_12\bin;C:\Program Files\jEdit Oct 8, 2007 2:58:03 PM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-8080 Oct 8, 2007 2:58:03 PM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 494 ms Oct 8, 2007 2:58:03 PM org.apache.catalina.realm.JAASRealm setContainer INFO: Set JAAS app name Catalina Oct 8, 2007 2:58:03 PM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Oct 8, 2007 2:58:03 PM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/6.0.14 Oct 8, 2007 2:58:03 PM org.apache.catalina.startup.HostConfig deployWAR INFO: Deploying web application archive oms.war WARN Digester - [ConverterRule]{faces-config/converter} Merge(null,java.math.BigDecimal) WARN Digester - [ConverterRule]{faces-config/converter} Merge(null,java.math.BigInteger) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/signUp1to3.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/registerSite.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/registerClinician.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/registerPrimary.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/home.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/home.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/home.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/home.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/registerService.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/instruction.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/providerRegistration.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/training.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/providerRegistration.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/instruction.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/changeMemberIdAndPassword.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/changeMemberIdAndPassword.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/store/shoppingCart.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/store/shoppingCart.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/store/shoppingCart.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/store/orderManager.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/store/orderDetail.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/store/orderDetail.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(*) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule} Merge(/store/shipping.jsp) WARN Digester - [NavigationRuleRule]{faces-config/navigation-rule}
Context path
Hi folks, I am trying to deploy webapps with context xml file. I have a context xml in the tomcat/conf/locahost/www.xml. The content is: Context path=abc docBase=C:/webapps/www/ When I start the tomcat, I can't access the anything with http://localhost/abc, but I can access http://localhost/www. Why? Thanks! Billy Ng
Re: Multi-thread issue on redeploy of application
It's been a while, but last I checked Struts didn't generate it's own threads. I'm guessing by your description that your code is generating threads. In that case, you need to maintain a reference to each thread and end them when the app stops. You can take a look at the various listener classes in the servlet spec to see which works best in dealing with the app stopping. --David Cool Coder wrote: It may not related to tomcat directly but I would appreciate if you can help me to find the problem with my web app. The web app creates number of threads, and on each deployement, web app should close threads and create new threads but it instead of closing/reusing old threads, it creates new threads which makes web app crashes. I use struts and in destroy method of RequestProcessor, I have code that shutdowns the ThreadExecutor, but I am not sure why this is not happening. Your help would be appreciated. - BR Take the Internet to Go: Yahoo!Go puts the Internet in your pocket: mail, news, photos more. http://mobile.yahoo.com/go?refer=1GNXIC - 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: Context path
Kwok Ng wrote: I am trying to deploy webapps with context xml file. I have a context xml in the tomcat/conf/locahost/www.xml. The content is: Context path=abc docBase=C:/webapps/www/ When I start the tomcat, I can't access the anything with http://localhost/abc, but I can access http://localhost/www. Why? Because the path is defined by the name of the context xml file. Remove the path element from the context xml file and rename it to abc.xml 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: Context path
Because your webapp's context.xml is named www.xml. The path spec in your Context ... ... /Context element is ignored in favor of the name of the xml file. I'd go further in saying you should also change the name of your webapp (C:\webapps\www - C:\webapps\abc). --David Kwok Ng wrote: Hi folks, I am trying to deploy webapps with context xml file. I have a context xml in the tomcat/conf/locahost/www.xml. The content is: Context path=abc docBase=C:/webapps/www/ When I start the tomcat, I can't access the anything with http://localhost/abc, but I can access http://localhost/www. Why? Thanks! Billy Ng - 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: Form based auth - Not working
Hi all, Thx for all the answers. I deleted my context file, the login.jsp, the data from the db and configured everything again (using localDataSource=true to be able to use the local data source) . Now the auth is working!!! I'm pretty sure, as u said, that I had a problem or in my jsp login file or in the db. I really can't tell what really happened, but i'm sure it was my mistake... Thx again for everything!!! Nicolas Gonzalez Buenos Aires - Argentina On 10/8/07, Christopher Schultz [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Nicolas, Nicolas Gonzalez wrote: I have a DB with users and user-roles tables and data in those tables but every time I try to log in my application it will fail with no reason, nor log either! Care to give us the database schema you are using? Please only show those tables that are relevant (USERS and USER_ROLES). You might want to provide sample contents for the user you are using as a test. I started thinking that any kind of authentication wasn't going to work, so I tried using the BASIC based one, which surprisingly worked :) Well, that's telling. I'm guessing your form isn't done correctly. Would you like to show us the form you are using, or should we keep guessing? validationQuery=select * from TEST Ouch! I wouldn't do that if I were you. Realm className=org.apache.catalina.realm.JDBCRealm Since you've got a JNDI connection pool already configured, why not use that for your Realm (DataSourceRealm) instead of a JDBCRealm. That way, everything uses the same set of connections instead of one separate one for logins. (as u may see, the realm is not a DataSourceRealm because it doesn't work at all, at least in my case!!! Another problem for another thread I guess...) I'm guessing that your form is the problem, not the database. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHCqUw9CaO5/Lv0PARAjlHAJ9PuW+DT9/4KlXsj6px3EDhGVoiiACeIu7+ 7DkzhMXZechE6HdiRa0Ai88= =1A0q -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: soTimeout not worked on channelNioSocket
More generally, it looks like it isn't handling the case where Apache drops the connection in mid-request well :(. Oh, well, there is a reason that the NIO impl over AJP is experimental (and thus not documented). Yes, it should probably throw an exception when the wait() returns without any data available, but it also needs work to handle the case where Apache drops the connection. As Filip suggested on the dev list, open up a BZ issue for this, and if you want to try your hand at adding a patch, it will be much appreciated :). Otherwise, I'll look into producing a patch myself. And many thanks for testing this :). William Leung [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I have configuared tomcat to use the NIO impl over AJP, here are the lines in server.xml Connector address=127.0.0.1 port=0 channelNioSocket.port=8009 channelNioSocket.soTimeout=60 channelNioSocket.bufferSize=16384 channelNioSocket.maxThreads=125 channelNioSocket.minSpareThreads=10 channelNioSocket.maxSpareThreads=50 redirectPort=8443 protocol=AJP/1.3 useBodyEncodingForURI=true / (TC version 5.5.17) I had setted the soTimeout with 10 minutes, cause I notice such stages in server status Stage Time B Sent B Recv Client VHost Request S 33280840 ms 359 KB 0 KB x.x.x.x 127.0.0.1 GET ... That shows several requests were blocking on reading request bodies for hours. But unfortunately it dosen't worked for me, I am expecting a request should only blocking mostly 10 minutes on read, after that a SocketTimeoutException should raised. After digest the source code of ChannelNioSocket.java, I found that ChannelNioSocket.SocketInputStream just wait infinitly if no data comes while socket could not be detected closing private void block(int len) throws IOException { ... ... if(!dataAvailable) { blocking = true; if(log.isDebugEnabled()) log.debug(Waiting for +len+ bytes to be available); try{ wait(socketTimeout); }catch(InterruptedException iex) { log.debug(Interrupted,iex); } blocking = false; } if(dataAvailable) { dataAvailable = false; if(fill(len) 0) { isClosed = true; } } } The socketTimeout parameter is not used to throw SocketTimeoutException, actually it has no meaning. I even read the source for TC 6.0.13, the same as above. Should it be more precisely that throwing SocketTimeoutException on later condiction test for (dataAvailable) is not true? In ChannelSocket implement, the problem is not exists, it uses blocking Socket.getInputStream, and it would throws SocketTimeoutException for socket timeout while Socket.setSoTimeout was called -- View this message in context: http://www.nabble.com/soTimeout-not-worked-on-channelNioSocket-tf4586318.html#a13091613 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] - 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: Multi-thread issue on redeploy of application
Yes it has something to do with my application. Let me tell you that this occurs when I hot deploy my application without restarting tomcat. Let me do a minute check. Thanks for your help. - RB Be a better Heartthrob. Get better relationship answers from someone who knows. Yahoo! Answers - Check it out. http://answers.yahoo.com/dir/?link=listsid=396545433
Re: Trouble running tomcat on Ubuntu Linux OS X Tiger
Chuck, It can't be a permissions problem, because I conducted a chmod +x *.sh inside $CATALINA_HOME/bin Hence: /DevTools/Java/Tomcat/apache-tomcat-5.5.25/bin untz$ ls -al *.sh -rwxr-xr-x 1 untz untz 12044 Aug 24 17:34 catalina.sh -rwxr-xr-x 1 untz untz841 Aug 24 17:34 digest.sh -rwxr-xr-x 1 untz untz 3059 Oct 8 16:08 setclasspath.sh -rwxr-xr-x 1 untz untz780 Aug 24 17:34 shutdown.sh -rwxr-xr-x 1 untz untz 1173 Aug 24 17:34 startup.sh -rwxr-xr-x 1 untz untz 2545 Aug 24 17:34 tool-wrapper.sh -rwxr-xr-x 1 untz untz784 Aug 24 17:34 version.sh I am getting the BASEDIR problem in both OS X Tiger and Ubuntu 7.0.4... When I googled, this problem, it seems as if a bunch of people were experiencing this but there was no solutions?! See: http://www.google.com/search?q=The+BASEDIR+environment+variable+is+not +defined+correctlyie=utf-8oe=utf-8aq=trls=org.mozilla:en- US:officialclient=firefox-a Also, I even posted this on JavaRanch's Big Moose Saloon (if you want a more detailed explanation): http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi? ubb=get_topicf=56t=005952p=1 This seems like a very common problem... As of now, I am Tomcat-less until this problem becomes fixed... Has anyone experienced this same problem (from the link above, it seems like a lot of people have)... With thanks, Unnsse On Oct 8, 2007, at 6:24 AM, Caldarale, Charles R wrote: From: Unnsse Khan [mailto:[EMAIL PROTECTED] Subject: Re: Trouble running tomcat on Ubuntu Linux OS X Tiger It was the tar.gz package that is downloadable from: http://tomcat.apache.org/download-55.cgi#5.5.25 I am guessing that I only downloaded the Core distribution... Is this the problem? No, that's fine - should be all you need. Still looking like a permissions problem. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e- mail and its attachments from all computers. - To 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: Trouble running tomcat on Ubuntu Linux OS X Tiger
Hi Mark, I just tried that and it worked! Then, I tried it by issuing: sh $CATALINA_HOME/bin/startup.sh and it worked again! I don't know what was wrong with it (I did reboot my computer, but don't know how much that helps)... Well, it wasn't working before, so I don't know what fixed it, but I am happy that's fixed, nonetheless! Happy coding, Unnsse On Oct 8, 2007, at 8:41 PM, Mark Thomas wrote: Unnsse Khan wrote: Chuck, It can't be a permissions problem, because I conducted a chmod +x *.sh inside $CATALINA_HOME/bin In case you missed Chuck's previous suggestion. Try a cd /DevTools/Java/Tomcat/apache-tomcat-5.5.25/bin first. 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] - 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: soTimeout not worked on channelNioSocket
Thanks for reply. It seems that neither the NIO impl nor the standard impl of AJP Connector do not handle the case where Apache drops the connection in mid-request well. I had try the standard way first, and still notice some requests blocks for hours (socket timeout is not setted). As busy threads count was so high, but most of them were just keepalive, so I decided to try NIO. (I didnt try APR yet) Bill Barker-2 wrote: More generally, it looks like it isn't handling the case where Apache drops the connection in mid-request well :(. Oh, well, there is a reason that the NIO impl over AJP is experimental (and thus not documented). Yes, it should probably throw an exception when the wait() returns without any data available, but it also needs work to handle the case where Apache drops the connection. As Filip suggested on the dev list, open up a BZ issue for this, and if you want to try your hand at adding a patch, it will be much appreciated :). Otherwise, I'll look into producing a patch myself. And many thanks for testing this :). William Leung [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I have configuared tomcat to use the NIO impl over AJP, here are the lines in server.xml Connector address=127.0.0.1 port=0 channelNioSocket.port=8009 channelNioSocket.soTimeout=60 channelNioSocket.bufferSize=16384 channelNioSocket.maxThreads=125 channelNioSocket.minSpareThreads=10 channelNioSocket.maxSpareThreads=50 redirectPort=8443 protocol=AJP/1.3 useBodyEncodingForURI=true / (TC version 5.5.17) I had setted the soTimeout with 10 minutes, cause I notice such stages in server status Stage Time B Sent B Recv Client VHost Request S 33280840 ms 359 KB 0 KB x.x.x.x 127.0.0.1 GET ... That shows several requests were blocking on reading request bodies for hours. But unfortunately it dosen't worked for me, I am expecting a request should only blocking mostly 10 minutes on read, after that a SocketTimeoutException should raised. After digest the source code of ChannelNioSocket.java, I found that ChannelNioSocket.SocketInputStream just wait infinitly if no data comes while socket could not be detected closing private void block(int len) throws IOException { ... ... if(!dataAvailable) { blocking = true; if(log.isDebugEnabled()) log.debug(Waiting for +len+ bytes to be available); try{ wait(socketTimeout); }catch(InterruptedException iex) { log.debug(Interrupted,iex); } blocking = false; } if(dataAvailable) { dataAvailable = false; if(fill(len) 0) { isClosed = true; } } } The socketTimeout parameter is not used to throw SocketTimeoutException, actually it has no meaning. I even read the source for TC 6.0.13, the same as above. Should it be more precisely that throwing SocketTimeoutException on later condiction test for (dataAvailable) is not true? In ChannelSocket implement, the problem is not exists, it uses blocking Socket.getInputStream, and it would throws SocketTimeoutException for socket timeout while Socket.setSoTimeout was called -- View this message in context: http://www.nabble.com/soTimeout-not-worked-on-channelNioSocket-tf4586318.html#a13091613 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] - 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/soTimeout-not-worked-on-channelNioSocket-tf4586318.html#a13109778 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]