Re: Tomcat shutdown.sh troubleshooting on AS/400
On Wed, 2012-06-20 at 19:19 -0400, David Kerber wrote: > On 6/19/2012 8:07 PM, André Warnier wrote: > > James Lampert wrote: > >> . . . and when I looked back at the box I was testing, Tomcat *had* > >> finally shut down. And when I ran both the start and stop scripts > >> this time, the stop script worked perfectly (and promptly). > >> > >> Weird. Why would the shutdown take so long as to give the impression > >> it had failed entirely, then eventually work, then later work promptly? > >> > > > > 1) Gremlins. You need to exorcise your datacenter. > > or > > 2) because the first time, Tomcat had been running for a while, so it > > had a lot of things to shut down nicely and cleanup; while the second > > time, it had only be running for a much shorter time, and had less to > > clean up ? > > It's not gremlins, it's magic. I see this all the time on windows: it > shuts down in the time I'm willing to wait for it ~50% of the time. The > other 50% I end up killing the task. > Any time I've seen this it's because some app or library has carelessly started non-daemon threads that are still spinning. Everything Tomcat can shutdown has shutdown. You could always try 'catalina.sh stop -force'. > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > signature.asc Description: This is a digitally signed message part
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
Puzzle solved !! Yes I did not have the binary ! It was right in front of me on the Tomcat.apache.org/download-70.cgi So sorry for all the challenges. Thanks for every ones help !! I've got it up and running now ! Thanks again, Samuel. On Jun 20, 2012, at 7:23 PM, Oguz Kologlu wrote: > Try this link. It's a tomcat mirror for the binary distribution: > > http://mirror.overthewire.com.au/pub/apache/tomcat/tomcat-7/v7.0.28/bin/apache-tomcat-7.0.28.tar.gz > > > On 21/06/2012, at 11:46 AM, Samuel V Green III wrote: > >> That's exactly what I've been downloading, but when unpacking the tar.gz it >> unpacks as YadaYada-src >> I just ran java -v at my terminal and get this message : >> >> Unable to locate an executable at >> "/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/bin/java" (-1) >> >> So some how my system is messed up and have no idea how. >> the Java -v command produced results yesterday ? >> >> Doing some googling now for a fix. >> >> Samuel. >> On Jun 20, 2012, at 6:35 PM, Hassan Schroeder wrote: >> >>> On Wed, Jun 20, 2012 at 6:29 PM, Samuel V Green III >>> wrote: >>> I can't download a binary distribution…, I'm running Mac OS Lion and as far as I could see there was no binary distribution ? >>> >>> 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz >>> >>> Did you see what I downloaded? Get that. >>> >>> H* >>> -- >>> Hassan Schroeder hassan.schroe...@gmail.com >>> http://about.me/hassanschroeder >>> twitter: @hassan >>> >>> - >>> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >>> For additional commands, e-mail: users-h...@tomcat.apache.org >>> >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> >> > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
Try this link. It's a tomcat mirror for the binary distribution: http://mirror.overthewire.com.au/pub/apache/tomcat/tomcat-7/v7.0.28/bin/apache-tomcat-7.0.28.tar.gz On 21/06/2012, at 11:46 AM, Samuel V Green III wrote: > That's exactly what I've been downloading, but when unpacking the tar.gz it > unpacks as YadaYada-src > I just ran java -v at my terminal and get this message : > > Unable to locate an executable at > "/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/bin/java" (-1) > > So some how my system is messed up and have no idea how. > the Java -v command produced results yesterday ? > > Doing some googling now for a fix. > > Samuel. > On Jun 20, 2012, at 6:35 PM, Hassan Schroeder wrote: > >> On Wed, Jun 20, 2012 at 6:29 PM, Samuel V Green III >> wrote: >> >>> I can't download a binary distribution…, I'm running Mac OS Lion and as far >>> as I could see there was no binary distribution ? >> >> 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz >> >> Did you see what I downloaded? Get that. >> >> H* >> -- >> Hassan Schroeder hassan.schroe...@gmail.com >> http://about.me/hassanschroeder >> twitter: @hassan >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
> From: Samuel V Green III [mailto:macun...@gmail.com] > Subject: Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion" > That's exactly what I've been downloading, but when unpacking the tar.gz > it unpacks as YadaYada-src Then clearly you're downloading the source archive, not the binary one. Download the binary, untar, run. You don't need the source, you don't need to build it. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
If you've done an update you may now have java 1.7 installed (and maybe 1.6 removed) Oz On 21/06/2012, at 11:46 AM, Samuel V Green III wrote: > That's exactly what I've been downloading, but when unpacking the tar.gz it > unpacks as YadaYada-src > I just ran java -v at my terminal and get this message : > > Unable to locate an executable at > "/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/bin/java" (-1) > > So some how my system is messed up and have no idea how. > the Java -v command produced results yesterday ? > > Doing some googling now for a fix. > > Samuel. > On Jun 20, 2012, at 6:35 PM, Hassan Schroeder wrote: > >> On Wed, Jun 20, 2012 at 6:29 PM, Samuel V Green III >> wrote: >> >>> I can't download a binary distribution…, I'm running Mac OS Lion and as far >>> as I could see there was no binary distribution ? >> >> 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz >> >> Did you see what I downloaded? Get that. >> >> H* >> -- >> Hassan Schroeder hassan.schroe...@gmail.com >> http://about.me/hassanschroeder >> twitter: @hassan >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
That's exactly what I've been downloading, but when unpacking the tar.gz it unpacks as YadaYada-src I just ran java -v at my terminal and get this message : Unable to locate an executable at "/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/bin/java" (-1) So some how my system is messed up and have no idea how. the Java -v command produced results yesterday ? Doing some googling now for a fix. Samuel. On Jun 20, 2012, at 6:35 PM, Hassan Schroeder wrote: > On Wed, Jun 20, 2012 at 6:29 PM, Samuel V Green III > wrote: > >> I can't download a binary distribution…, I'm running Mac OS Lion and as far >> as I could see there was no binary distribution ? > > 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz > > Did you see what I downloaded? Get that. > > H* > -- > Hassan Schroeder hassan.schroe...@gmail.com > http://about.me/hassanschroeder > twitter: @hassan > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
On Wed, Jun 20, 2012 at 6:29 PM, Samuel V Green III wrote: > I can't download a binary distribution…, I'm running Mac OS Lion and as far > as I could see there was no binary distribution ? 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz Did you see what I downloaded? Get that. H* -- Hassan Schroeder hassan.schroe...@gmail.com http://about.me/hassanschroeder twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
So I created a new user and same issues. I can't download a binary distribution…, I'm running Mac OS Lion and as far as I could see there was no binary distribution ? Ugg.. Must be a way to get Tomcat running ! Thanks, Samuel. On Jun 20, 2012, at 6:04 PM, Oguz Kologlu wrote: > Yes. > Save yourself some pain. > Download the binary distribution unless you need it for a specific reason. > Oz > > > On 21/06/2012, at 10:57 AM, Samuel V Green III wrote: > >> Feeling like an idiot, but since I'm downloading apache-tomcat-7.0.28-src… >> Do I have to do a build first ? >> >> Thanks, >> >> Samuel. >> >> >> On Jun 20, 2012, at 3:50 PM, Hassan Schroeder wrote: >> >>> On Wed, Jun 20, 2012 at 3:28 PM, Samuel Green wrote: This afternoon I did a reinstall at /usr/local and still am not able to get it started. >>> >>> 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz >>> 15:42 ~/Downloads $ sudo mv apache-tomcat-7.0.28/ /usr/local >>> Password: >>> 15:42 ~/Downloads $ cd /usr/local >>> 15:42 /usr/local (master)$ cd apache-tomcat-7.0.28/ >>> 15:42 /usr/local/apache-tomcat-7.0.28 (master)$ export CATALINA_HOME=`pwd` >>> 15:43 /usr/local/apache-tomcat-7.0.28 (master)$ >>> $CATALINA_HOME/bin/catalina.sh run >>> Using CATALINA_BASE: /usr/local/apache-tomcat-7.0.28 >>> Using CATALINA_HOME: /usr/local/apache-tomcat-7.0.28 >>> Using CATALINA_TMPDIR: /usr/local/apache-tomcat-7.0.28/temp >>> Using JRE_HOME: >>> /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home >>> Using CLASSPATH: >>> /usr/local/apache-tomcat-7.0.28/bin/bootstrap.jar:/usr/local/apache-tomcat-7.0.28/bin/tomcat-juli.jar >>> Jun 20, 2012 3:43:18 PM org.apache.catalina.core.AprLifecycleListener init >>> INFO: The APR based Apache Tomcat Native library which allows optimal >>> performance in production environments was not found on the >>> java.library.path: >>> .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java >>> Jun 20, 2012 3:43:19 PM org.apache.coyote.AbstractProtocol init >>> INFO: Initializing ProtocolHandler ["http-bio-8080"] >>> . etc. . >>> >>> So with the new install, what does your startup log look like? >>> >>> >>> -- >>> Hassan Schroeder hassan.schroe...@gmail.com >>> http://about.me/hassanschroeder >>> twitter: @hassan >>> >>> - >>> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >>> For additional commands, e-mail: users-h...@tomcat.apache.org >>> >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> >> > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
Yes. Save yourself some pain. Download the binary distribution unless you need it for a specific reason. Oz On 21/06/2012, at 10:57 AM, Samuel V Green III wrote: > Feeling like an idiot, but since I'm downloading apache-tomcat-7.0.28-src… > Do I have to do a build first ? > > Thanks, > > Samuel. > > > On Jun 20, 2012, at 3:50 PM, Hassan Schroeder wrote: > >> On Wed, Jun 20, 2012 at 3:28 PM, Samuel Green wrote: >>> This afternoon I did a reinstall at /usr/local >>> and still am not able to get it started. >> >> 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz >> 15:42 ~/Downloads $ sudo mv apache-tomcat-7.0.28/ /usr/local >> Password: >> 15:42 ~/Downloads $ cd /usr/local >> 15:42 /usr/local (master)$ cd apache-tomcat-7.0.28/ >> 15:42 /usr/local/apache-tomcat-7.0.28 (master)$ export CATALINA_HOME=`pwd` >> 15:43 /usr/local/apache-tomcat-7.0.28 (master)$ >> $CATALINA_HOME/bin/catalina.sh run >> Using CATALINA_BASE: /usr/local/apache-tomcat-7.0.28 >> Using CATALINA_HOME: /usr/local/apache-tomcat-7.0.28 >> Using CATALINA_TMPDIR: /usr/local/apache-tomcat-7.0.28/temp >> Using JRE_HOME: >> /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home >> Using CLASSPATH: >> /usr/local/apache-tomcat-7.0.28/bin/bootstrap.jar:/usr/local/apache-tomcat-7.0.28/bin/tomcat-juli.jar >> Jun 20, 2012 3:43:18 PM org.apache.catalina.core.AprLifecycleListener init >> INFO: The APR based Apache Tomcat Native library which allows optimal >> performance in production environments was not found on the >> java.library.path: >> .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java >> Jun 20, 2012 3:43:19 PM org.apache.coyote.AbstractProtocol init >> INFO: Initializing ProtocolHandler ["http-bio-8080"] >> . etc. . >> >> So with the new install, what does your startup log look like? >> >> >> -- >> Hassan Schroeder hassan.schroe...@gmail.com >> http://about.me/hassanschroeder >> twitter: @hassan >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
Something screwy in your current environment. For a quick test: Create a new user Unpack tomcat into you user directory (don't mess around with /usr/local) start it up (not as root) Post the result. Oz On 21/06/2012, at 10:45 AM, Samuel V Green III wrote: > So I have my new install on /usr/local/tomcat (renamed 7.0.28) > Following your instructions …. same old problem: > Startup output: > > Using CATALINA_BASE: /usr/local/tomcat > Using CATALINA_HOME: /usr/local/tomcat > Using CATALINA_TMPDIR: /usr/local/tomcat/temp > Using JRE_HOME: > /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home > Using CLASSPATH: > /usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/tomcat-juli.jar > Exception in thread "main" java.lang.NoClassDefFoundError: > org/apache/catalina/startup/Bootstrap > Caused by: java.lang.ClassNotFoundException: > org.apache.catalina.startup.Bootstrap > at java.net.URLClassLoader$1.run(URLClassLoader.java:202) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:190) > at java.lang.ClassLoader.loadClass(ClassLoader.java:306) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) > at java.lang.ClassLoader.loadClass(ClassLoader.java:247) > > I have /usr/local/tomcat/bin in my .bash_profile path > and when I issue: > sudo startup.sh > I get the following output: > > Using CATALINA_BASE: /usr/local/tomcat > Using CATALINA_HOME: /usr/local/tomcat > Using CATALINA_TMPDIR: /usr/local/tomcat/temp > Using JRE_HOME: > /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home > Using CLASSPATH: > /usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/tomcat-juli.jar > > My catalina.out reads: > > Exception in thread "main" java.lang.NoClassDefFoundError: > org/apache/catalina/startup/Bootstrap > Caused by: java.lang.ClassNotFoundException: > org.apache.catalina.startup.Bootstrap > at java.net.URLClassLoader$1.run(URLClassLoader.java:202) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:190) > at java.lang.ClassLoader.loadClass(ClassLoader.java:306) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) > at java.lang.ClassLoader.loadClass(ClassLoader.java:247) > > So still no start. > > > > On Jun 20, 2012, at 3:50 PM, Hassan Schroeder wrote: > >> On Wed, Jun 20, 2012 at 3:28 PM, Samuel Green wrote: >>> This afternoon I did a reinstall at /usr/local >>> and still am not able to get it started. >> >> 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz >> 15:42 ~/Downloads $ sudo mv apache-tomcat-7.0.28/ /usr/local >> Password: >> 15:42 ~/Downloads $ cd /usr/local >> 15:42 /usr/local (master)$ cd apache-tomcat-7.0.28/ >> 15:42 /usr/local/apache-tomcat-7.0.28 (master)$ export CATALINA_HOME=`pwd` >> 15:43 /usr/local/apache-tomcat-7.0.28 (master)$ >> $CATALINA_HOME/bin/catalina.sh run >> Using CATALINA_BASE: /usr/local/apache-tomcat-7.0.28 >> Using CATALINA_HOME: /usr/local/apache-tomcat-7.0.28 >> Using CATALINA_TMPDIR: /usr/local/apache-tomcat-7.0.28/temp >> Using JRE_HOME: >> /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home >> Using CLASSPATH: >> /usr/local/apache-tomcat-7.0.28/bin/bootstrap.jar:/usr/local/apache-tomcat-7.0.28/bin/tomcat-juli.jar >> Jun 20, 2012 3:43:18 PM org.apache.catalina.core.AprLifecycleListener init >> INFO: The APR based Apache Tomcat Native library which allows optimal >> performance in production environments was not found on the >> java.library.path: >> .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java >> Jun 20, 2012 3:43:19 PM org.apache.coyote.AbstractProtocol init >> INFO: Initializing ProtocolHandler ["http-bio-8080"] >> . etc. . >> >> So with the new install, what does your startup log look like? >> >> >> -- >> Hassan Schroeder hassan.schroe...@gmail.com >> http://about.me/hassanschroeder >> twitter: @hassan >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
Feeling like an idiot, but since I'm downloading apache-tomcat-7.0.28-src… Do I have to do a build first ? Thanks, Samuel. On Jun 20, 2012, at 3:50 PM, Hassan Schroeder wrote: > On Wed, Jun 20, 2012 at 3:28 PM, Samuel Green wrote: >> This afternoon I did a reinstall at /usr/local >> and still am not able to get it started. > > 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz > 15:42 ~/Downloads $ sudo mv apache-tomcat-7.0.28/ /usr/local > Password: > 15:42 ~/Downloads $ cd /usr/local > 15:42 /usr/local (master)$ cd apache-tomcat-7.0.28/ > 15:42 /usr/local/apache-tomcat-7.0.28 (master)$ export CATALINA_HOME=`pwd` > 15:43 /usr/local/apache-tomcat-7.0.28 (master)$ > $CATALINA_HOME/bin/catalina.sh run > Using CATALINA_BASE: /usr/local/apache-tomcat-7.0.28 > Using CATALINA_HOME: /usr/local/apache-tomcat-7.0.28 > Using CATALINA_TMPDIR: /usr/local/apache-tomcat-7.0.28/temp > Using JRE_HOME: > /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home > Using CLASSPATH: > /usr/local/apache-tomcat-7.0.28/bin/bootstrap.jar:/usr/local/apache-tomcat-7.0.28/bin/tomcat-juli.jar > Jun 20, 2012 3:43:18 PM org.apache.catalina.core.AprLifecycleListener init > INFO: The APR based Apache Tomcat Native library which allows optimal > performance in production environments was not found on the > java.library.path: > .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java > Jun 20, 2012 3:43:19 PM org.apache.coyote.AbstractProtocol init > INFO: Initializing ProtocolHandler ["http-bio-8080"] > . etc. . > > So with the new install, what does your startup log look like? > > > -- > Hassan Schroeder hassan.schroe...@gmail.com > http://about.me/hassanschroeder > twitter: @hassan > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
So I have my new install on /usr/local/tomcat (renamed 7.0.28) Following your instructions …. same old problem: Startup output: Using CATALINA_BASE: /usr/local/tomcat Using CATALINA_HOME: /usr/local/tomcat Using CATALINA_TMPDIR: /usr/local/tomcat/temp Using JRE_HOME: /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home Using CLASSPATH: /usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/tomcat-juli.jar Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/catalina/startup/Bootstrap Caused by: java.lang.ClassNotFoundException: org.apache.catalina.startup.Bootstrap at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) I have /usr/local/tomcat/bin in my .bash_profile path and when I issue: sudo startup.sh I get the following output: Using CATALINA_BASE: /usr/local/tomcat Using CATALINA_HOME: /usr/local/tomcat Using CATALINA_TMPDIR: /usr/local/tomcat/temp Using JRE_HOME: /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home Using CLASSPATH: /usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/tomcat-juli.jar My catalina.out reads: Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/catalina/startup/Bootstrap Caused by: java.lang.ClassNotFoundException: org.apache.catalina.startup.Bootstrap at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) So still no start. On Jun 20, 2012, at 3:50 PM, Hassan Schroeder wrote: > On Wed, Jun 20, 2012 at 3:28 PM, Samuel Green wrote: >> This afternoon I did a reinstall at /usr/local >> and still am not able to get it started. > > 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz > 15:42 ~/Downloads $ sudo mv apache-tomcat-7.0.28/ /usr/local > Password: > 15:42 ~/Downloads $ cd /usr/local > 15:42 /usr/local (master)$ cd apache-tomcat-7.0.28/ > 15:42 /usr/local/apache-tomcat-7.0.28 (master)$ export CATALINA_HOME=`pwd` > 15:43 /usr/local/apache-tomcat-7.0.28 (master)$ > $CATALINA_HOME/bin/catalina.sh run > Using CATALINA_BASE: /usr/local/apache-tomcat-7.0.28 > Using CATALINA_HOME: /usr/local/apache-tomcat-7.0.28 > Using CATALINA_TMPDIR: /usr/local/apache-tomcat-7.0.28/temp > Using JRE_HOME: > /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home > Using CLASSPATH: > /usr/local/apache-tomcat-7.0.28/bin/bootstrap.jar:/usr/local/apache-tomcat-7.0.28/bin/tomcat-juli.jar > Jun 20, 2012 3:43:18 PM org.apache.catalina.core.AprLifecycleListener init > INFO: The APR based Apache Tomcat Native library which allows optimal > performance in production environments was not found on the > java.library.path: > .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java > Jun 20, 2012 3:43:19 PM org.apache.coyote.AbstractProtocol init > INFO: Initializing ProtocolHandler ["http-bio-8080"] > . etc. . > > So with the new install, what does your startup log look like? > > > -- > Hassan Schroeder hassan.schroe...@gmail.com > http://about.me/hassanschroeder > twitter: @hassan > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Apache tomcat (7.0.27) is not loading the user and role class for JAASRealm
The HttpServletRequest.logout function was added in Servlet 3.0. I don't know what your citation is talking about but there is no HttpSession.logout() method in the Servlet Specification 2.4 or anywhere else. EJP -Original Message- From: javed Ansari [mailto:javid@gmail.com] Sent: Wednesday, 20 June 2012 7:58 PM To: Tomcat Users List Subject: Re: Apache tomcat (7.0.27) is not loading the user and role class for JAASRealm This logout function was added in Servlet Spec 2.4 http://mail-archives.apache.org/mod_mbox/tomcat-dev/200208.mbox/%3C102903496 4.4749.754.ca...@hue.jadn.com%3E But even after pointing to Dynamic web module 2.4, and Tomcat 7.0, I am not able to access that API. Regards, Javed - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat shutdown.sh troubleshooting on AS/400
On 6/19/2012 8:07 PM, André Warnier wrote: James Lampert wrote: . . . and when I looked back at the box I was testing, Tomcat *had* finally shut down. And when I ran both the start and stop scripts this time, the stop script worked perfectly (and promptly). Weird. Why would the shutdown take so long as to give the impression it had failed entirely, then eventually work, then later work promptly? 1) Gremlins. You need to exorcise your datacenter. or 2) because the first time, Tomcat had been running for a while, so it had a lot of things to shut down nicely and cleanup; while the second time, it had only be running for a much shorter time, and had less to clean up ? It's not gremlins, it's magic. I see this all the time on windows: it shuts down in the time I'm willing to wait for it ~50% of the time. The other 50% I end up killing the task. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
On Wed, Jun 20, 2012 at 3:28 PM, Samuel Green wrote: > This afternoon I did a reinstall at /usr/local > and still am not able to get it started. 15:41 ~/Downloads $ tar xfz apache-tomcat-7.0.28.tar.gz 15:42 ~/Downloads $ sudo mv apache-tomcat-7.0.28/ /usr/local Password: 15:42 ~/Downloads $ cd /usr/local 15:42 /usr/local (master)$ cd apache-tomcat-7.0.28/ 15:42 /usr/local/apache-tomcat-7.0.28 (master)$ export CATALINA_HOME=`pwd` 15:43 /usr/local/apache-tomcat-7.0.28 (master)$ $CATALINA_HOME/bin/catalina.sh run Using CATALINA_BASE: /usr/local/apache-tomcat-7.0.28 Using CATALINA_HOME: /usr/local/apache-tomcat-7.0.28 Using CATALINA_TMPDIR: /usr/local/apache-tomcat-7.0.28/temp Using JRE_HOME: /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home Using CLASSPATH: /usr/local/apache-tomcat-7.0.28/bin/bootstrap.jar:/usr/local/apache-tomcat-7.0.28/bin/tomcat-juli.jar Jun 20, 2012 3:43:18 PM org.apache.catalina.core.AprLifecycleListener init INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java Jun 20, 2012 3:43:19 PM org.apache.coyote.AbstractProtocol init INFO: Initializing ProtocolHandler ["http-bio-8080"] . etc. . So with the new install, what does your startup log look like? -- Hassan Schroeder hassan.schroe...@gmail.com http://about.me/hassanschroeder twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
This afternoon I did a reinstall at /usr/local and still am not able to get it started. No system links this time. Interestingly enough I had to create a "log" directory. Package did not include one. Easy enough. I'll try your new install recommend, but I still like to know why it won't load from /usr /local where "others" apparently have no problem. Thanks again ! Samuel. On Wed, Jun 20, 2012 at 3:17 PM, Christopher Schultz wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Samuel, > > On 6/20/12 11:55 AM, Samuel Green wrote: >> Thanks guys , I'll try a fresh install tonight and attempt to run >> JUST from my /usr/local and report back to the list my results. > > Just install it into ~/apache-tomcat-7.0.27 and call it a day. You > won't have to worry about file permissions or any of that stuff > because a) you will untar it as yourself and b) you will run it as > yourself. > > Just be aware that he effective uid must have wrx access to work/, > logs/, and probably temp/ > > That's why it's best to run it as yourself. Also, not running as root > gives you a significant security boost because in the unlikely event > of a Tomcat vulnerability, only your account can be trashed, not the > entire machine. > > - -chris > -BEGIN PGP SIGNATURE- > Version: GnuPG/MacGPG2 v2.0.17 (Darwin) > Comment: GPGTools - http://gpgtools.org > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ > > iEYEARECAAYFAk/iS+0ACgkQ9CaO5/Lv0PClbgCcDXLBC+IeobtWd9igtseYCxCV > RcEAnRgtHnxpOxpSqOpVLW0Rq2cF54BY > =ZtN6 > -END PGP SIGNATURE- > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Creating separate log for each request
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Lahiru, On 6/20/12 5:39 PM, Lahiru Gunathilake wrote: > Hi Caldarale, > > Its not a website.. I am hosting a middleware which will be used > by scientist to run their application in the Grid. So Ideal > scenario is like 2--30 requests per day but they are long running > and very time consuming (Some jobs would take 2,3 days or one week > to finish), so the logs are very important. If you need requests to take 2-3 days, then HTTP is not the protocol for you. Are you accepting batch requests via HTTP and then working on them after the request/response has completed? That would make more sense. In any case, most logging frameworks create "Log" (or Logger) objects that live for a long time: they aren't set up to create a Log/Logger, use it for a bit and then discard it, since loggers tend to get used for the life of the JVM. I think what you want is a simple FileWriter. You can even use the existing logging framework's log-level-checks if you want, like this: PrintWriter out = null; try { if(logger.isDebugEnabled()) = new PrintWriter(FileWriter("/logs/job-" + jobId)); ... if(null != out) out.println("Got an interesting value: " + interestingValue); ... } finally { if(null != out) try { out.close(); } catch (IOException ioe) { logger.error("Couldn't close job log", ioe); } } - -chris -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk/iTTkACgkQ9CaO5/Lv0PDW2gCfRuyYHaUZ8hNbmeKSw/wBmdsD XuIAnRG0NjBmPrsNT8RCDFuvZIbzYIGH =k33J -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Samuel, On 6/20/12 11:55 AM, Samuel Green wrote: > Thanks guys , I'll try a fresh install tonight and attempt to run > JUST from my /usr/local and report back to the list my results. Just install it into ~/apache-tomcat-7.0.27 and call it a day. You won't have to worry about file permissions or any of that stuff because a) you will untar it as yourself and b) you will run it as yourself. Just be aware that he effective uid must have wrx access to work/, logs/, and probably temp/ That's why it's best to run it as yourself. Also, not running as root gives you a significant security boost because in the unlikely event of a Tomcat vulnerability, only your account can be trashed, not the entire machine. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk/iS+0ACgkQ9CaO5/Lv0PClbgCcDXLBC+IeobtWd9igtseYCxCV RcEAnRgtHnxpOxpSqOpVLW0Rq2cF54BY =ZtN6 -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Samuel, On 6/19/12 10:20 PM, Samuel V Green III wrote: > I was trying to follow the instructions here: > http://wolfpaulus.com/journal/mac/tomcat7 where it mentions "Change > ownership of the /Libaray/Tomcat folder hierarchy: > > sudo chown -R /Library/Tomcat" That might not do anything, since /Library/Tomcat is a symlink. $ sudo chown -R your_username /Library/Tomcat/ ...might work better (note the trailing / which causes the symlink to be followed, rather than just changing the permissions on the link itself). Do you really even need that symlink? > So I'm wondering if I need to change chown the > /usr/local/tomcatversion directory to match my user id instead of > "root" ? Here's my setup: $ echo $CATALINA_HOME /usr/local/apache-tomcat-7.0.27 $ ls -l $CATALINA_HOME total 168 - -rw-r--r-- 1 root wheel 56797 Mar 31 10:45 LICENSE - -rw-r--r-- 1 root wheel 1192 Mar 31 10:45 NOTICE - -rw-r--r-- 1 root wheel 8826 Mar 31 10:45 RELEASE-NOTES - -rw-r--r-- 1 root wheel 10597 Mar 31 10:45 RUNNING.txt drwxr-xr-x 26 root wheel884 Apr 2 17:46 bin drwxr-xr-x 9 root wheel306 Mar 31 10:45 conf drwxr-xr-x 22 root wheel748 Apr 3 10:05 lib drwxr-xr-x 2 root wheel 68 Mar 31 10:44 logs drwxr-xr-x 3 root wheel102 Mar 31 10:44 temp drwxr-xr-x 7 root wheel238 Mar 31 10:44 webapps drwxr-xr-x 2 root wheel 68 Mar 31 10:44 work $ echo $CATALINA_BASE /home/chris/.webapps/mywebapp $ ls -l $CATALINA_BASE total 0 drwxr-xr-x 5 chris staff 170 May 11 15:21 conf drwxr-xr-x 16 chris staff 544 Jun 19 12:20 logs drwxr-xr-x 2 chris staff 68 May 11 15:21 temp drwxr-xr-x 4 chris staff 136 May 11 15:21 webapps drwxr-xr-x 3 chris staff 102 May 11 15:21 work conf/ contains server.xml and web.xml. webapps/ contains (surprise) my webapps. work/, logs/, and temp/ are empty before initial launch. With both CATALINA_HOME and CATALINA_BASE set, I can run $CATALINA_HOME/bin/startup.sh and everything runs without any issues. No sudo. No root. All is well. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk/iS1YACgkQ9CaO5/Lv0PB1pACfdmp5qyeUxPHC9JDJQZMJx9LF w8EAn3at7WGtdI/ZEWmQWGoO/Ditse9w =N9/r -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Issue with keep-alive connections, when using APR Connector on Windows and starting Processes from Servlets
Can you verify your 2 threads (reading input an error) are launched ? Can you confirm you are getting the problem only on Windows ? Jeff On Wed, Jun 20, 2012 at 4:19 PM, Laurent Petit wrote: > Hello, > > I have a problem with keep-alive connections, when starting a subprocess > (via JDK's default ProcessBuilder/Process API), while also having > started Tomcat with the APR HTTP/1.1 Connector. > > The problem symptom is with Keep-Alive connection, as follows: > > - the client (browser, jmeter, etc.) sends a first request > - the servlet starts a Process for e.g. wordpad.exe > - the servlet returns an acknowledgment html content, sets the content > length, flushes the writer, and returns > - the client displays the received acknowledgement html content, sends > the second request to the server. > - the server doesn't answer. No Tomcat log ever reports the start of > something received. > - Then when on the server you close the wordpad.exe instance, the server > finally handles the second request. > > I have created a small servlet code which reproduces the problem. > For the demo, it suffices to have the started subprocess be > "wordpad.exe". Of course my real process is more interesting than > that :-). > > You can find the servlet code for reproducing the test here: > > https://www.refheap.com/paste/3254 > > > To reproduce the problem deterministically, the ConnectionTimeout for > the APR HTTP Connector in servlet.xml must be set sufficiently low. > With my boxes, I get a 100% error hit when set at 200 ms. > > You can find here the jmeter script which hits the same page again and > again with "keep-alive" option set on: > > https://www.refheap.com/paste/3255 > > > So far, the only reliable solution we have found to work around this > problem is to not use the HTP/1.1 APR Connector. > > > My configuration : > Windows 2008 US std R2 64bits > Tomcat 6.0.32 64 bits > Java 6u30 64 bits(Oracle) > > Same issue has been observed on Windows 7 32 bits. > > Was not able to reproduce the issue on Linux Ubuntu Desktop 11.10 or > 12.04. > > > Thanks for your support, ideas, solutions, etc. > > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > -- Jeff MAURY "Legacy code" often differs from its suggested alternative by actually working and scaling. - Bjarne Stroustrup http://www.jeffmaury.com http://riadiscuss.jeffmaury.com http://www.twitter.com/jeffmaury
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Chuck, On 6/19/12 9:09 PM, Caldarale, Charles R wrote: >> From: Samuel V Green III [mailto:macun...@gmail.com] Subject: Re: >> apache-tomcat-7.0.27 start up errors on Mac OX "Lion" > >> issued command export Catalina_HOME=/Library/Tomcat > > That's not useful (or necessary). The variable name is > CATALINA_HOME, not Catalina_HOME (case matters). +1 >> Using JRE_HOME: >> /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home > >> > That looks suspicious, but I don't have a Mac at hand to compare > with. Exactly what JVM version do you have installed? Can it run > other Java programs? $ which java /usr/bin/java You don't need to set JRE_HOME or JAVA_HOME. >> Exception in thread "main" java.lang.NoClassDefFoundError: >> org/apache/catalina/startup/Bootstrap > > It's looking like your JVM installation might not be quite > right... He's likely using the JVM from Apple, which is currently: $ java -version java version "1.6.0_33" Java(TM) SE Runtime Environment (build 1.6.0_33-b03-424-11M3720) Java HotSpot(TM) 64-Bit Server VM (build 20.8-b03-424, mixed mode) - -chris -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk/iSa4ACgkQ9CaO5/Lv0PACJgCeLNDeFqlioFbrldaCv3rsLA64 91gAoIYvqqdZNqIuiczcNZ5zpPFQ1XIi =IbCz -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Creating separate log for each request
Hi Caldarale, Its not a website.. I am hosting a middleware which will be used by scientist to run their application in the Grid. So Ideal scenario is like 2--30 requests per day but they are long running and very time consuming (Some jobs would take 2,3 days or one week to finish), so the logs are very important. Lahiru On Wed, Jun 20, 2012 at 5:35 PM, Caldarale, Charles R < chuck.caldar...@unisys.com> wrote: > > From: Lahiru Gunathilake [mailto:glah...@gmail.com] > > Subject: Creating separate log for each request > > > I am using slf4j for my logging and everything works fine and all > > the logs comes to catalina.out. > > Which means that things are seriously broken or incredibly badly > configured. Logging should *never* go to catalina.out in a properly > configured system. > > > I simply want to create a separate log for each http request > > come to my tomcat instance. > > You can't be serious. How much traffic does your website get? > > - Chuck > > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY > MATERIAL and is thus for use only by the intended recipient. If you > received this in error, please contact the sender and delete the e-mail and > its attachments from all computers. > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > -- System Analyst Programmer PTI Lab Indiana University
RE: Creating separate log for each request
> From: Lahiru Gunathilake [mailto:glah...@gmail.com] > Subject: Creating separate log for each request > I am using slf4j for my logging and everything works fine and all > the logs comes to catalina.out. Which means that things are seriously broken or incredibly badly configured. Logging should *never* go to catalina.out in a properly configured system. > I simply want to create a separate log for each http request > come to my tomcat instance. You can't be serious. How much traffic does your website get? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Creating separate log for each request
Hi Jeff, Thanks for the response, actually my requirement is to make the life easier for the admin, and if something goes wrong he has an ID of the request which failed (This is not a system which is getting millions of http requests) and then he should be able to figure out the logs for that request based on the ID he has. If you have a solution for that, kindly let me know, I am happy to use it.. Regards Lahiru On Wed, Jun 20, 2012 at 5:12 PM, Jeff MAURY wrote: > Are you sure of that, a single file for a single HTTP request. I don't know > a file system capable to handle that ? > > Jeff > > > On Wed, Jun 20, 2012 at 10:38 PM, Lahiru Gunathilake >wrote: > > > Hi All, > > > > I have my webapp deployed on tomcat. I am using slf4j for my logging and > > everything works fine and all the logs comes to catalina.out. But I have > a > > requirement of creating a separate log for each request comes to my > > webapp... I only have single webapp, so I simply want to create a > separate > > log for each http request come to my tomcat instance. > > > > Anybody knows how to do this in tomcat configuration ? > > > > Regards > > Lahiru > > > > -- > > System Analyst Programmer > > PTI Lab > > Indiana University > > > > > > -- > Jeff MAURY > > > "Legacy code" often differs from its suggested alternative by actually > working and scaling. > - Bjarne Stroustrup > > http://www.jeffmaury.com > http://riadiscuss.jeffmaury.com > http://www.twitter.com/jeffmaury > -- System Analyst Programmer PTI Lab Indiana University
Re: Creating separate log for each request
Are you sure of that, a single file for a single HTTP request. I don't know a file system capable to handle that ? Jeff On Wed, Jun 20, 2012 at 10:38 PM, Lahiru Gunathilake wrote: > Hi All, > > I have my webapp deployed on tomcat. I am using slf4j for my logging and > everything works fine and all the logs comes to catalina.out. But I have a > requirement of creating a separate log for each request comes to my > webapp... I only have single webapp, so I simply want to create a separate > log for each http request come to my tomcat instance. > > Anybody knows how to do this in tomcat configuration ? > > Regards > Lahiru > > -- > System Analyst Programmer > PTI Lab > Indiana University > -- Jeff MAURY "Legacy code" often differs from its suggested alternative by actually working and scaling. - Bjarne Stroustrup http://www.jeffmaury.com http://riadiscuss.jeffmaury.com http://www.twitter.com/jeffmaury
Creating separate log for each request
Hi All, I have my webapp deployed on tomcat. I am using slf4j for my logging and everything works fine and all the logs comes to catalina.out. But I have a requirement of creating a separate log for each request comes to my webapp... I only have single webapp, so I simply want to create a separate log for each http request come to my tomcat instance. Anybody knows how to do this in tomcat configuration ? Regards Lahiru -- System Analyst Programmer PTI Lab Indiana University
Confusing tomcat error - can't find javax.servlet.http.HttpSessionAttributeListener
Hi, I'm getting a fatal error when I start tomcat. Now I would think that servlet-api.jar is missing from the tomcat classpath but if I do -verbose:class I can clearly see tomcat using other classes from that jar so I know it's already included: [Loaded javax.servlet.http.HttpServletRequest from file:/C:/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/lib/servlet-api.jar] The exact error I'm getting is: java.lang.Error: Unresolved compilation problems: The import javax.servlet.http.HttpSessionAttributeListener cannot be resolved The import javax.servlet.http.HttpSessionBindingEvent cannot be resolved HttpSessionAttributeListener cannot be resolved to a type HttpSessionBindingEvent cannot be resolved to a type HttpSessionBindingEvent cannot be resolved to a type HttpSessionBindingEvent cannot be resolved to a type HttpSessionBindingEvent cannot be resolved to a type The file that gives this error has import javax.servlet.http.*; at the top so it appears that I've already imported the necessary classes. How can I fix this fatal error? Why does tomcat see javax.servlet.http.HttpServletRequest but not javax.servlet.http.HttpSessionAttributeListener? I'm using Tomcat version 6.0 on Windows XP SP3. Thank you
RE: Moodle & Tomcat
> From: Peli [mailto:fabian...@gmail.com] > Subject: Moodle & Tomcat > Moodle requires to create the resource directory outside of the > deployment directory [webapps], the moodledata directory is created > directly in [...\apache-tomcat-7.0.27\moodledata] > moodle upload files to that directory but in the course when you want > to download one of these files, it displays a 404 error resource not > found. > the files can be accessed from outside the webapps directory? > what I need to configure? Look at the aliases attribute for the element: http://tomcat.apache.org/tomcat-7.0-doc/config/context.html#Standard_Implementation - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
High CPU usage in Tomcat 7
We just had a report of extremely high CPU usage from the Tomcat job on one of our customer installations. A WRKACTJOB screen shot from before we forcibly shut Tomcat down and restarted it shows: Subsystem/Job Type CPU % FunctionStatus CATALINA BCH .0 CMD-QSH TIMW QP0ZSPWT BCI 112.2 JVM-org.apache TIMW (QP0ZSPWT being the system-generated job that's doing the actual work for the CATALINA job.) Of particular interest is that, at least at the moment the screen shot was taken, the QP0ZSPWT job was taking up what appears to be more than an entire processor, even though it's in a "time-wait" state. Based on a Google search on "tomcat 7 high cpu usage," I'm suspecting a previously unknown tightloop in our application (which was what I suspected even before I did the Google search). The pages I looked at also said something about profiling and thread dumps, to find the offending thread, but since the job has been terminated and restarted, and is not currently malfunctioning, I wouldn't be able to do so even if I knew how (which at present I don't). I've passed on the log files generated by our application itself to someone better equipped to deal with them than I, and I've asked the Java-400 List at Midrange.com about AS/400-specific steps to track down the offending thread if the problem is observed again, but I would also value any insights this list might offer. -- JHHL - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
Thanks guys , I'll try a fresh install tonight and attempt to run JUST from my /usr/local and report back to the list my results. Samuel. On Wed, Jun 20, 2012 at 5:30 AM, Daniel Mikusa wrote: > > - Original Message - > > > From: Samuel V Green III [mailto:macun...@gmail.com] > > > Subject: Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion" > > > > > I was trying to follow the instructions here: > > > http://wolfpaulus.com/journal/mac/tomcat7 > > > > I would strongly recommend (as did Chris) that you _not_ follow > > someone else's questionable installation instructions, but instead > > just use the ones from the Tomcat website. Don't make your life > > more complicated than it needs to be. > > > > Remove whatever you've done to install Tomcat, download a fresh > > .tar.gz file (7.0.28 is now available), and just do what Chris said: > > > > 1. Download tarball > > 2. Un-tar tarball > > > > $ bin/startup.sh > > > > - Chuck > > > > +1 > > Is there a reason you are trying to install to "/Library/Tomcat" and > "/usr/local"? or is it just because that is what the tutorial you found is > doing? > > If you're doing development, it's easy enough to just run Tomcat from your > user directory. > > Dan > > > > > > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE > > PROPRIETARY MATERIAL and is thus for use only by the intended > > recipient. If you received this in error, please contact the sender > > and delete the e-mail and its attachments from all computers. > > > > > > - > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > > For additional commands, e-mail: users-h...@tomcat.apache.org > > > > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Issue with keep-alive connections, when using APR Connector on Windows and starting Processes from Servlets
Hello, I have a problem with keep-alive connections, when starting a subprocess (via JDK's default ProcessBuilder/Process API), while also having started Tomcat with the APR HTTP/1.1 Connector. The problem symptom is with Keep-Alive connection, as follows: - the client (browser, jmeter, etc.) sends a first request - the servlet starts a Process for e.g. wordpad.exe - the servlet returns an acknowledgment html content, sets the content length, flushes the writer, and returns - the client displays the received acknowledgement html content, sends the second request to the server. - the server doesn't answer. No Tomcat log ever reports the start of something received. - Then when on the server you close the wordpad.exe instance, the server finally handles the second request. I have created a small servlet code which reproduces the problem. For the demo, it suffices to have the started subprocess be "wordpad.exe". Of course my real process is more interesting than that :-). You can find the servlet code for reproducing the test here: https://www.refheap.com/paste/3254 To reproduce the problem deterministically, the ConnectionTimeout for the APR HTTP Connector in servlet.xml must be set sufficiently low. With my boxes, I get a 100% error hit when set at 200 ms. You can find here the jmeter script which hits the same page again and again with "keep-alive" option set on: https://www.refheap.com/paste/3255 So far, the only reliable solution we have found to work around this problem is to not use the HTP/1.1 APR Connector. My configuration : Windows 2008 US std R2 64bits Tomcat 6.0.32 64 bits Java 6u30 64 bits(Oracle) Same issue has been observed on Windows 7 32 bits. Was not able to reproduce the issue on Linux Ubuntu Desktop 11.10 or 12.04. Thanks for your support, ideas, solutions, etc. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
- Original Message - > > From: Samuel V Green III [mailto:macun...@gmail.com] > > Subject: Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion" > > > I was trying to follow the instructions here: > > http://wolfpaulus.com/journal/mac/tomcat7 > > I would strongly recommend (as did Chris) that you _not_ follow > someone else's questionable installation instructions, but instead > just use the ones from the Tomcat website. Don't make your life > more complicated than it needs to be. > > Remove whatever you've done to install Tomcat, download a fresh > .tar.gz file (7.0.28 is now available), and just do what Chris said: > > 1. Download tarball > 2. Un-tar tarball > > $ bin/startup.sh > > - Chuck > +1 Is there a reason you are trying to install to "/Library/Tomcat" and "/usr/local"? or is it just because that is what the tutorial you found is doing? If you're doing development, it's easy enough to just run Tomcat from your user directory. Dan > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE > PROPRIETARY MATERIAL and is thus for use only by the intended > recipient. If you received this in error, please contact the sender > and delete the e-mail and its attachments from all computers. > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion"
- Original Message - > > /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home > Not sure? > I have sub directories: > > bin bundle lib man > Try running "$JAVA_HOME/bin/java -version". Dan > the install of tomcat at /usr/local is listed user "root" and owner > "wheel" > > The permissions at the symbolic link of /Library/Tomcat are user > "myusr name" and owner "wheel". > > So I have to either change permission to match at the symbolic link > to the /usr/local install or vise versa ? > > Thanks, > > Samuel. > > > > On Jun 19, 2012, at 6:57 PM, Caldarale, Charles R wrote: > > >> From: Samuel V Green III [mailto:macun...@gmail.com] > >> Subject: Re: apache-tomcat-7.0.27 start up errors on Mac OX "Lion" > > > >> Java(TM) SE Runtime Environment (build 1.6.0_33-b03-424-11M3720) > >> Java HotSpot(TM) 64-Bit Server VM (build 20.8-b03-424, mixed mode) > > > > That looks quite reasonable. Can you tell if that's really what's > > installed at: > > /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home > > > > (Wouldn't normally happen on a Mac, but on Linux it's not uncommon > > to have several JVMs installed, and you can end up using a > > different one than you expect.) > > > > Is there possibly a permissions problem - trying to run Tomcat > > under a different userid than what the installation was done with? > > > > - Chuck > > > > > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE > > PROPRIETARY MATERIAL and is thus for use only by the intended > > recipient. If you received this in error, please contact the > > sender and delete the e-mail and its attachments from all > > computers. > > > > > > - > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > > For additional commands, e-mail: users-h...@tomcat.apache.org > > > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Apache tomcat (7.0.27) is not loading the user and role class for JAASRealm
This logout function was added in Servlet Spec 2.4 http://mail-archives.apache.org/mod_mbox/tomcat-dev/200208.mbox/%3c1029034964.4749.754.ca...@hue.jadn.com%3E But even after pointing to Dynamic web module 2.4, and Tomcat 7.0, I am not able to access that API. Regards, Javed On Wed, Jun 20, 2012 at 1:00 PM, javed Ansari wrote: > These settings I already have. > Does that mean logout has been removed from the Servlet 3.0. > The book I am referring uses servlet 2.0. Can anybody confirm this? > > On Wed, Jun 20, 2012 at 12:44 PM, Konstantin Kolinko < > knst.koli...@gmail.com> wrote: > >> 2012/6/20 javed Ansari : >> > It seems I am invalidating another servlet than the one which >> authenticated >> > the webapp. This confusion is because I am using Google Web Toolkit >> > application template which not just a plain servlet application. >> > I am now trying to invalidate all the sessions by calling >> > HttpSession.logout(). I can see this API in a servlet book but in >> Eclipse >> > it is not able to find out even with the latest JDK 1.7. >> > May be I need to post this onto some Java forum... >> >> Servlet API is not part of Java SE, so JDK version does not matter much. >> >> To use Servlet 3.0 methods your app must be a "Servlet 3.0" web >> application (in your web.xml and in your Eclipse Project settings) >> and must use jars from Tomcat 7. (in your Java Build Path in your >> Eclipse Project settings) >> >> E.g. to create a new project (using Eclipse for Java EE Developers) >> menu File > New > Project... -> Web > Dynamic Web Project -> >> and the "New Dynamic Web Project" dialog needs the following values >> Target runtime = Tomcat 7, >> Dynamic web module version = 3.0. >> >> >> Best regards, >> Konstantin Kolinko >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: users-h...@tomcat.apache.org >> >> >
heap memory issues
>>Hi, Miguel- >>Your comment about how mail is handled made the application suspect in my >>mind. Beyond making sure it's stable, I would check that the application is >>at least reasonably efficient. Yes, when I said stable, I really meant efficient too. I suspect there are other inefficiencies that I'm not aware of (I don't have access to the source code) Miguel - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Apache tomcat (7.0.27) is not loading the user and role class for JAASRealm
These settings I already have. Does that mean logout has been removed from the Servlet 3.0. The book I am referring uses servlet 2.0. Can anybody confirm this? On Wed, Jun 20, 2012 at 12:44 PM, Konstantin Kolinko wrote: > 2012/6/20 javed Ansari : > > It seems I am invalidating another servlet than the one which > authenticated > > the webapp. This confusion is because I am using Google Web Toolkit > > application template which not just a plain servlet application. > > I am now trying to invalidate all the sessions by calling > > HttpSession.logout(). I can see this API in a servlet book but in Eclipse > > it is not able to find out even with the latest JDK 1.7. > > May be I need to post this onto some Java forum... > > Servlet API is not part of Java SE, so JDK version does not matter much. > > To use Servlet 3.0 methods your app must be a "Servlet 3.0" web > application (in your web.xml and in your Eclipse Project settings) > and must use jars from Tomcat 7. (in your Java Build Path in your > Eclipse Project settings) > > E.g. to create a new project (using Eclipse for Java EE Developers) > menu File > New > Project... -> Web > Dynamic Web Project -> > and the "New Dynamic Web Project" dialog needs the following values > Target runtime = Tomcat 7, > Dynamic web module version = 3.0. > > > Best regards, > Konstantin Kolinko > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > >
Re: Apache tomcat (7.0.27) is not loading the user and role class for JAASRealm
2012/6/20 javed Ansari : > It seems I am invalidating another servlet than the one which authenticated > the webapp. This confusion is because I am using Google Web Toolkit > application template which not just a plain servlet application. > I am now trying to invalidate all the sessions by calling > HttpSession.logout(). I can see this API in a servlet book but in Eclipse > it is not able to find out even with the latest JDK 1.7. > May be I need to post this onto some Java forum... Servlet API is not part of Java SE, so JDK version does not matter much. To use Servlet 3.0 methods your app must be a "Servlet 3.0" web application (in your web.xml and in your Eclipse Project settings) and must use jars from Tomcat 7. (in your Java Build Path in your Eclipse Project settings) E.g. to create a new project (using Eclipse for Java EE Developers) menu File > New > Project... -> Web > Dynamic Web Project -> and the "New Dynamic Web Project" dialog needs the following values Target runtime = Tomcat 7, Dynamic web module version = 3.0. Best regards, Konstantin Kolinko - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org