Re: Callback (JAAS)
According to the Tomcat User Guide, only two callbacks are supported: NameCallback and PasswordCallback. I have an app that has to have another call back: ClientCallback. In other words my login window looks like this: Clietn : || User:|| Password:|| We had some similar problems and found out two possibilities to resolve this problem: 1)Simple: Add your Clientnumber to the username like: [EMAIL PROTECTED] You can split this string in your LoginModule -- username = ((NameCallbacl) callbacks[0].getName(); 2)Complicate: Add functionalities to the JAASRealm. The only point we found to put or to get information through JAAS is in the JAASRealm-class. So we write our own JAASRealm.class by extending it. To use your own JAASRealm-class change the entry in your server.xml-- Realm className = Path to your new JAASRealm. Though our problem was a bit different, I think it can work for you to (try it :-)). Hope this will help --Franck I am hoping to use CMA and JAAS with my own custom LoginModule. Can I configure Tomcat to support a thrid callback and still use CMA? Stefan Baramov Software Developer TRX - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Catalina vs. jsvc stand alone daemon
Hi Warren, thank you for referring me to the right download link. Not being a Java developer I certainly lack the Java fundamentals but to my excuse I may maintain that SUN's naming policy (this is also true for their Solaris OS) is quite bewildering so that I never quite know what interpreter (bundle) to look for, download and install. Maybe you can help me a little? What's the difference between Java2 or J2SE and, say Java 5, or Java 1.5. What's the difference between J2SE and J2EE (I guess Standard vs. Enterprise Edition)? Always thought J2EE required extra licensing, why I refrained from downloading it. Do I need the netBeans lib only for building jsvc (I assume not)? Again, what difference between JDK and SDK? If I download the Eclipse development suite for installation on a Linux development host does it already contain a full fledged JDK, or would its additional installation still be prerequisited? Then, I want to learn at least the basics of servlet programming not to be at the mercy of some third party app. developers but to deploy my own monitoring stuff (hopefully later even making use of JMX). I have some web application developing experience in Perl and am wary about security implications and client input. Also I know the basics of OO and at least can read and partly understand Java code (as far as I can guesstimate objects' methods purpose and mutating effects. I need a quick hands on approach at Java servlets. Are there any books, tutorials, or howtos you could reccommend? For a quick access to other web languages I found e.g. O'Reilly's Cookbooks quite useful. I noticed a bear book (i.e. such a beast on the cover) about servlets, but I don't know if the API used there is still applicable to e.g. Tomcat 5, or current Java releases. One thing that always kept me from catching up with Java was its extremly rapid release cycles as far as new buzz technologies were concerned that were supposed to revolutionize the Web etc. There seemed to be too much hype without letting things first settle and be stood the test of time. But this may be my biased misconception of Java. Outch, that's where the trouble starts again. I've been trying in vain for the last hour to find a download URI from SUN but their servers always refer me to the Linux JRE Download section. http://java.sun.com/j2se/1.5.0/download.jsp look for JDK 5.0 Update 6 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat and client certificates
Mark: Thank you for your link to the archive. It was my fault using the UserDatabase realm instead of the MemoryRealm. I'm, using tomcat 5.0.28 - is it still the case in 5.5.x that you MUST use the MemoryRealm for clientcert authentication? Anyway, there is still an issue when trying to access a restricted url without the proper certificate: 1) When there is the RIGHT client certificate in the browser keystore: it works :-) 2) When there is the WRONG client certificate I get: HTTP Status 401 - Cannot authenticate with the provided credentials (this is ok, too) 3) When there is NO client certificate I get: HTTP Status 400 - No client certificate chain in this request 400 usually stands for a bad request or bad syntax. I believe in this case 401 should be the appropriate reply. Is there any way to adjust the HTTP Status code for failed client-cert authentication? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Fwd: auth-constraint in web.xml in tomcat 5.5.15
Oops no it didn't, my mistake. The app now doesn't prompt for authentication at all. Is there a way of getting it to work so that the authentication is used but you don't have to hard code roles in web.xml? Regards, Oliver Begin forwarded message: From: Oliver Kohll [EMAIL PROTECTED] Date: 6 February 2006 10:54:55 GMT To: Tomcat Users List users@tomcat.apache.org Subject: Re: auth-constraint in web.xml in tomcat 5.5.15 Thanks. Commenting out the auth-constraint got the result I want. Oliver On 3 Feb 2006, at 17:54, Mark Thomas wrote: Oliver Kohll wrote: Hi, I have security for a web application managed by a DataSource database realm. Using tomcat 5.5.14 this works fine but in 5.5.15 there seems to be a problem. The problem seems to be the role-name*/role-name line. If I put a specific role in, users in that role can log in but the * wildcard doesn't work. A 403 HTTP rejection is issued if the user inputs a correct username and password (if they put in the wrong username/ password, it prompts again as expected). As users themselves can add roles to the database, I don't know what the roles may be so I have to use the wildcard. The special role * means all roles specified in web.xml. It does not mean all roles specified in the realm nor does it mean all authenticated users. The fix for 15570 was to correctly handle *. It used to be interpreted as all authenticated users. It is now correctly interpreted as all roles defined in web.xml. Mark - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] [EMAIL PROTECTED] / 0845 456 1810 / 07814 828608 Furze Bank, 34 Hanover Street, SWANSEA UK, SA1 6BA NOTE No contracts may be concluded on behalf of GT webMarque by means of e-mail communications. The contents of this e-mail are confidential to the intended recipient at the e-mail address to which it has been addressed; it may not be disclosed to or used by anyone other than this addressee, nor may it be copied in any way. If received in error please return to sender via e-mail. DISCLAIMER Please note that neither GT webMarque Ltd nor the sender accept any responsibility for viruses transmitted via e-mail. It is your responsibility to scan attachments (if any). [EMAIL PROTECTED] / 0845 456 1810 / 07814 828608 Furze Bank, 34 Hanover Street, SWANSEA UK, SA1 6BA NOTE No contracts may be concluded on behalf of GT webMarque by means of e- mail communications. The contents of this e-mail are confidential to the intended recipient at the e-mail address to which it has been addressed; it may not be disclosed to or used by anyone other than this addressee, nor may it be copied in any way. If received in error please return to sender via e-mail. DISCLAIMER Please note that neither GT webMarque Ltd nor the sender accept any responsibility for viruses transmitted via e-mail. It is your responsibility to scan attachments (if any).
Re: auth-constraint in web.xml in tomcat 5.5.15
*outch* This mean i will have to change my web.xml with future tomcat version. How do I allow access to a ressource to all authenticated users now? Mark Thomas a écrit : Oliver Kohll wrote: Hi, I have security for a web application managed by a DataSource database realm. Using tomcat 5.5.14 this works fine but in 5.5.15 there seems to be a problem. The problem seems to be the role-name*/role-name line. If I put a specific role in, users in that role can log in but the * wildcard doesn't work. A 403 HTTP rejection is issued if the user inputs a correct username and password (if they put in the wrong username/ password, it prompts again as expected). As users themselves can add roles to the database, I don't know what the roles may be so I have to use the wildcard. The special role * means all roles specified in web.xml. It does not mean all roles specified in the realm nor does it mean all authenticated users. The fix for 15570 was to correctly handle *. It used to be interpreted as all authenticated users. It is now correctly interpreted as all roles defined in web.xml. Mark - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Virtual Directory
Add a file, Tutorial.xml, to your C:\Program Files\Apache Group\Tomcat 4.1\webapps\ directory. It should contain at least the following: context docBase=E:\Tutorial... Please read here: http://tomcat.apache.org/tomcat-5.5-doc/appdev/deployment.html -Original Message- From: sumesh [mailto:[EMAIL PROTECTED] Sent: Sunday, February 05, 2006 10:48 AM To: Tomcat Users List Subject: Virtual Directory Dear friends, How can I create a Virtual Directory in Apache Tomcat? I have installed tomcat in C:\Program Files\Apache Group\Tomcat 4.1 and I have some Tutorials in E:\Tutorial .I want to publish the same using the same Web Server.How can I do that - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Catalina vs. jsvc stand alone daemon
What's the difference between Java2 or J2SE and, say Java 5, or Java 1.5. None. Java 5 (aka Java 1.5) is a version of Java2. The term Java2 was introduced at the release of Java 1.2 indicating a significant change in the api and distribution. This was the first version release to be made available in three packages -- J2SE, J2EE, and J2ME. What's the difference between J2SE and J2EE (I guess Standard vs. Enterprise Edition)? Always thought J2EE required extra licensing, why I refrained from downloading it. J2SE stands for Java 2 Standard Edition. J2EE stands for Java 2 Enterprise Edition and is essentially J2SE with a multitude of APIs added in including Tomcat. For the sake of this discussion, you want to use either J2SE and Tomcat OR J2EE. Don't try to use Tomcat with J2EE as the APIs in Tomcat may severely conflict with what's included in J2EE. Do I need the netBeans lib only for building jsvc (I assume not)? Not that I know of. All you really need to build is the platform native component if it's not available for binary download. The download distribution of Tomcat should already contain the Java classes required. Again, what difference between JDK and SDK? JDK Java Development Kit and is a superset of the JRE or Java Runtime Environment. Superset because it is the JRE with a compiler and development utilities included. SDK stands for Software Development Kit and is an industry wide acronym for the dev tools needed to build software. For the purposes of this discussion, JDK is a SDK. If I download the Eclipse development suite for installation on a Linux development host does it already contain a full fledged JDK, or would its additional installation still be prerequisited? As far as I know, you'll need to get the JDK separately from Sun's website. The J2SE package should do fine. There are a lot of tutorials, blogs, and books on the subject. Most of what I know comes from lurking here on the list and reading the issues other people have, reading the servlet spec, and digging around the documentation. I'm sure others on the list have their favorite materials to recommend. An excellent reference to keep around is the Servlet 2.4 spec. I highly recommend reading it in conjunction with whatever other materials you find: http://www.jcp.org/en/jsr/detail?id=154 The docs at http://tomcat.apache.org are also well developed and should be the best reference when things aren't working. Especially if you have a book that might be a little bit dated, using older versions of Tomcat. --David [EMAIL PROTECTED] wrote: Hi Warren, thank you for referring me to the right download link. Not being a Java developer I certainly lack the Java fundamentals but to my excuse I may maintain that SUN's naming policy (this is also true for their Solaris OS) is quite bewildering so that I never quite know what interpreter (bundle) to look for, download and install. Maybe you can help me a little? What's the difference between Java2 or J2SE and, say Java 5, or Java 1.5. What's the difference between J2SE and J2EE (I guess Standard vs. Enterprise Edition)? Always thought J2EE required extra licensing, why I refrained from downloading it. Do I need the netBeans lib only for building jsvc (I assume not)? Again, what difference between JDK and SDK? If I download the Eclipse development suite for installation on a Linux development host does it already contain a full fledged JDK, or would its additional installation still be prerequisited? Then, I want to learn at least the basics of servlet programming not to be at the mercy of some third party app. developers but to deploy my own monitoring stuff (hopefully later even making use of JMX). I have some web application developing experience in Perl and am wary about security implications and client input. Also I know the basics of OO and at least can read and partly understand Java code (as far as I can guesstimate objects' methods purpose and mutating effects. I need a quick hands on approach at Java servlets. Are there any books, tutorials, or howtos you could reccommend? For a quick access to other web languages I found e.g. O'Reilly's Cookbooks quite useful. I noticed a bear book (i.e. such a beast on the cover) about servlets, but I don't know if the API used there is still applicable to e.g. Tomcat 5, or current Java releases. One thing that always kept me from catching up with Java was its extremly rapid release cycles as far as new buzz technologies were concerned that were supposed to revolutionize the Web etc. There seemed to be too much hype without letting things first settle and be stood the test of time. But this may be my biased misconception of Java. Outch, that's where the trouble starts again. I've been trying in vain for the last hour to find a download URI from SUN but their servers always refer me to the Linux JRE Download section.
Securing Tomcat
Hi, I want to secure a tomcat I have been setting up as a heartbeat resource. Because I lack any tomcat knowledge (only have the docs at my sight) first I was simply comparing how other tomcats of around were set up. But that only left me shudder as I seemed to glimpse into a gaping security abyss. Well for intranet usage this remotely might be passable. First I wondered why they were started as root process. For an Apache webserver this is plausible to me since there is a User directive (which is usually set to www, nobody or similar). Apache starts as root process because it needs to bind its listening socket to a priviledged port and open handles to logfiles, pipes, unix sockets etc. that usually reside in root-only-writable dirs. But it spawns child procs for servicing all clients as User. However, with Tomcat (owe to its threading nature?) things seem quite different. I first tried to run the catalina.sh by prepending a su tomcat in my wrapper script after having created a locked tomcat account with nologin as login shell, exactly like the apache account was set up. (n.b. this is on a Linux box, as can be seen) (because locked and passwordless no need to conceal the shadow entries here) # egrep apache\|tomcat /etc/{passwd,shadow} /etc/passwd:apache:x:48:48:Apache:/var/www/apache:/sbin/nologin /etc/passwd:tomcat:x:49:48:Tomcat:/var/www/tomcat:/sbin/nologin /etc/shadow:apache:!!:13172:: /etc/shadow:tomcat:!!:13185:: Although this works fine for Apache webserver # ps -o user,pid,ppid,tty,stime,comm -C httpd USER PID PPID TT STIME COMMAND root 22072 1 ?10:02 httpd apache 22074 22072 ?10:02 httpd apache 22075 22072 ?10:02 httpd apache 22076 22072 ?10:02 httpd apache 22077 22072 ?10:02 httpd apache 22078 22072 ?10:02 httpd apache 22079 22072 ?10:02 httpd apache 22080 22072 ?10:02 httpd apache 22081 22072 ?10:02 httpd this won't work for Tomcat # su tomcat $CATALINA_HOME/bin/catalina.sh start This account is currently not available. If I simply leave the login shell undefined # usermod -s tomcat # grep tomcat /etc/passwd tomcat:x:49:48:Tomcat:/var/www/tomcat: and do the su # su tomcat -c $CATALINA_HOME/bin/catalina.sh start Using CATALINA_BASE: /var/www/tomcat/5.5.15 Using CATALINA_HOME: /var/www/tomcat/5.5.15 Using CATALINA_TMPDIR: /var/www/tomcat/5.5.15/temp Using JRE_HOME: /usr/java/jre1.5.0_06 touch: cannot touch `/var/www/tomcat/5.5.15/logs/catalina.out': Permission denied /var/www/tomcat/5.5.15/bin/catalina.sh: line 249: /var/www/tomcat/5.5.15/logs/catalina.out: Permission denied tomcat naturally lacks write access to the logs dir. Well I could simply chown to tomcat for that dir but I wouldn't consider this desirable. The Apache webserver preforking mechanism is much more favourable. Besides, logfiles and similar should only be readable by root. Even if I set write access the immediately following question would be, to what other dirs Tomcat required write access too. I also read about the Security Manager in the Tomcat docs (Security Manager Howto), and the -security switch one could pass to catlina.sh. But here I am unfimiliar with the proper format of $CATALINA_HOME/conf/catalina.policy. Is Security Manager the preferred method to have Tomcat run in a sandbox? What policy options would one have to be especially careful about? Is there such thing as a chroot mechanism available for Tomcat? Regards Ralph - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How to install web application only on one port (both 8080 and 8443 ports opened)
Hi I wonder is it possible with apache tomcat to install two web-services (axis) one on port 8080 (and only 8080) and another on 8443 (and only that)? I have opened both porsts. Now when I install web-service it's available on both ports - how to change that without closing any of them in server.xml file? Regards Ania
Error reported in catalina.out: Invalid path /login was requested
Hi, Whenever i access the Tomcat Administration Tool I get the Error message: 06.02.2006 14:04:27 org.apache.struts.action.RequestProcessor processMapping SEVERE: Invalid path /login was requested 06.02.2006 14:04:50 org.apache.struts.action.RequestProcessor processMapping SEVERE: Invalid path /frameset was requested I am using Tomcat 5.5.12, and did search google on that issue but could not yet find the cause for this Error message. Access to the Administration Tool works fine as usual. Can anyone suppose how I could pin down the cause? Kind regards, Tobias Illik - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
wrapping manager undeploy Ant task
Hello, I'm using the manager tasks for Ant to undeploy and deploy my WAR file in Tomcat, as shown below. Sometimes, due to a previous processing error, there is nothing to undeploy (i.e., no webapp there) but the deploy task is still relevant and should still occur. However, in these cases, my Ant target fails because the undeploy task returns a nothing-to-undeploy error. Question: How do I wrap the undeploy/ task, so that if there is nothing to undeploy, the deploy task within this target will still activate? Currently I am just commenting out the undeploy task when that situation occurs. Thanks, Glen target name=deploy depends=war undeploy url=${tcManagerURL} username=${tcUsername} password=${tcPassword} path=${apppath}/ deploy url=${tcManagerURL} username=${tcUsername} password=${tcPassword} path=${apppath} war=${war.app.name}.war/ /target - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: KeepGenerated
I have, indeed, replicated this several times on several servers. David Morrow Technical Systems Lead Autodata Solutions Company [EMAIL PROTECTED] http://www.autodatasolutions.com Tel: (519) 963-3020 Fax: (519) 451-6615 Lead, follow or get out of the way! This message has originated from Autodata Solutions. The attached material is the Confidential and Proprietary Information of Autodata Solutions. This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please delete this message and notify the Autodata system administrator at [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] -Original Message- From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] Sent: Saturday, February 04, 2006 10:58 AM To: Tomcat Users List Subject: RE: KeepGenerated From: Dave Morrow [mailto:[EMAIL PROTECTED] Subject: KeepGenerated If my thinking is correct, the change in KeepGenerated should have decrease performance? Am I correct in this assumption? Does anyonw know of any drawbacks to what I have done? Changing keepgenerated shouldn't really have much of an effect at all, other than the very minor difference on the first reference to a .jsp due to deleting (or not) the generated .java source. Once the .jsp has been compiled into servlet form, I can't see any reason for a performance impact one way or the other. I suppose if the .java code is some kind of watched resource, that might have some small effect. Are you sure nothing else has changed? Can you readily reproduce the difference by changing only that attribute? This is strange. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Securing Tomcat
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Subject: Securing Tomcat First I wondered why they were started as root process. Only to allow access to ports below 1024. You can use iptables to reroute ports, or use jsvc to start Tomcat with some other userid. Google or search the archives for details: http://marc.theaimsgroup.com/?l=tomcat-userw=2r=1s=jsvcq=b - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Error reported in catalina.out: Invalid path /login was requested
From: Tobias Illik [mailto:[EMAIL PROTECTED] Subject: Error reported in catalina.out: Invalid path /login was requested Whenever i access the Tomcat Administration Tool I get the Error message: This is normal on the first access to the admin app. I haven't bothered to go through the code to find out why it happens, but it can be safely ignored. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AJP Connector problem
Greetings all. I have installed AJP connector v 1.2.15 into our test environment and I am not longer getting log information with log level info. If I set log level to debug, I get output, log level info I get a 0 kb sized log file with no entries. Is there a bug in v1.2.15? Earnie!
Two DNS Entries Two Sites?
Hello, Running Tomcat 5.5 @ home and running a website which has a DNS entry in it. I made the site the default webapp, and configured it in the server.xml. A week ago, I created another context (in the server.xml) for a dev-site, of my live site, and I am using that for QA. I want to run a second real-web site off this box, and same Tomcat. It has its own DNS entry, and want to know if this is doable? If so, what should I read about as far as configuration. I had read about the Engine, Server, Context but have not really seen how to put two site DNS entries in. Thanks, Scott
RE: Two DNS Entries Two Sites?
From: Scott Purcell [mailto:[EMAIL PROTECTED] Subject: Two DNS Entries Two Sites? A week ago, I created another context (in the server.xml) for a dev-site, of my live site, and I am using that for QA. I want to run a second real-web site off this box, and same Tomcat. It has its own DNS entry, and want to know if this is doable? If so, what should I read about as far as configuration. I had read about the Engine, Server, Context but have not really seen how to put two site DNS entries in. You may be confusing context with web site. A context is a web application; a given host may have many web apps (and therefore contexts). Tomcat, by default, listens on all IP addresses that are routed to the box, and all web apps (contexts) are available to all those IP addresses. If you want to segregate web apps by IP address, set up multiple Host tags in server.xml, and configure the appropriate IP addresses for each. Each host can (and probably should) have its own appBase setting to avoid inadvertent sharing of web apps across hosts. Take a look at: http://tomcat.apache.org/tomcat-5.5-doc/config/host.html By the way, putting Context tags in server.xml is strongly discouraged in the 5.5.x levels. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Two DNS Entries Two Sites?
Scott Purcell wrote: Hello, Running Tomcat 5.5 @ home and running a website which has a DNS entry in it. I made the site the default webapp, and configured it in the server.xml. A week ago, I created another context (in the server.xml) for a dev-site, of my live site, and I am using that for QA. I want to run a second real-web site off this box, and same Tomcat. It has its own DNS entry, and want to know if this is doable? If so, what should I read about as far as configuration. I had read about the Engine, Server, Context but have not really seen how to put two site DNS entries in. Thanks, Scott Do you have several IPs (one per site) or just several hostnames pointing to the same IP? In the first case, creating one Host section per IP should do the trick. In the second case you need name-based virtual hosts. I'm not sure whether this can (easily/at all) be achieved with multiple Host tags as well. So far I have only set up name virtual hosts with Apache HTTPD using the NameVirtualHost directive. Edmund - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Two DNS Entries Two Sites?
If it's 2 names, one IP, one server, you can simply have tomcat do virtual hosting. We did it here like that: Create 2 host Give each host a list of alias corresponding to the server the will act on Give each host a different Application Base (like webapps-hostX and webapps-hostY) this will prevent webapplication in one host to be visible in the other host Ensure the manager webapp is present in both Apllication Base (unless you don't need the manager webapp of course) Optionnally define a default host in Catalina engine properties. That's all, tomcat will redirect http requests to the correct virtual host. Scott Purcell a écrit : Hello, Running Tomcat 5.5 @ home and running a website which has a DNS entry in it. I made the site the default webapp, and configured it in the server.xml. A week ago, I created another context (in the server.xml) for a dev-site, of my live site, and I am using that for QA. I want to run a second real-web site off this box, and same Tomcat. It has its own DNS entry, and want to know if this is doable? If so, what should I read about as far as configuration. I had read about the Engine, Server, Context but have not really seen how to put two site DNS entries in. Thanks, Scott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: tomcat/linux no xserver problem
why not just install the Xserver Abhilash Kumar wrote: You have Batik (ships with FOP distribution itself) in Tomcat's classpath ? Pls see wheter this link is helpful. http://xmlgraphics.apache.org/fop/0.20.5/graphics.html#batik thanks and regards, -- Kannan. -Original Message- From: Eickvonder Bjoern [mailto:[EMAIL PROTECTED] Sent: Monday, February 06, 2006 11:50 AM To: users@tomcat.apache.org Subject: tomcat/linux no xserver problem Hi, one of our customers is using tomcat 5.0.28 with jdk 1.4.2_05 on linux without a running xserver. In fact there is not even one installed. Now our application produces the following exceptions on generating pdfs using fop: 1.) java.lang.UnsatisfiedLinkError: /usr/java/j2sdk1.4.2_05/jre/lib/i386/libawt.so: libXp.so.6: cannot open shared object file: No such file or directory 2.) java.lang.NoClassDefFoundError at org.apache.fop.svg.SVGUserAgent.getViewportSize(SVGUserAgent.java:145) [This line of code is just: return new Dimension(100, 100);] The first we solved by setting the headless parameter and installing some basic x-win libraries, but the second exception is still thrown in some cases. To be more precise it seems that now all pdfs are generated except those with embedded svg (using fo:foreign-instream-object). Anyone an idea what might be still missing or misconfigured on the server? Bjoern Eickvonder Besuchen Sie uns vom 14.02. bis zum 16.02.2006 auf der Learntec in Karlsruhe auf unserem Messestand 342. Vereinbaren Sie einen Termin mit uns... Diese E-Mail enthalt vertrauliche und/oder rechtlich geschutzte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtumlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail bzw. Inhalte hieraus ist nicht gestattet. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Amritha Institute of Medical Sciences, Cochin, India Sent using PostMaster by QuantumLink Communications One Internet account, unlimited personal e-mail addresses Get your free copy of PostMaster at http://www.mailserve.net/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Catalina vs. jsvc stand alone daemon
My notes for Eclipse: Eclipse is using some piece of code for compiling. I didn't assembly it, but I think, there is in the J2SE JRE, in the standard Java library several classes they provide compiling. This means, you DON'T NEED J2SE SDK or Java 5 JDK. I'm using this feature on windoze machines I have no administrative access which is needed for JDK (or SDK) installation. There is only one problem with no SDK development -- your custom build.xml (and other Ant or Maven scripts) will not work, because Ant (and Maven) are calling the compiler (and javadoc) which is missing. PETR On 2/6/06, David Smith [EMAIL PROTECTED] wrote: What's the difference between Java2 or J2SE and, say Java 5, or Java 1.5. None. Java 5 (aka Java 1.5) is a version of Java2. The term Java2 was introduced at the release of Java 1.2 indicating a significant change in the api and distribution. This was the first version release to be made available in three packages -- J2SE, J2EE, and J2ME. What's the difference between J2SE and J2EE (I guess Standard vs. Enterprise Edition)? Always thought J2EE required extra licensing, why I refrained from downloading it. J2SE stands for Java 2 Standard Edition. J2EE stands for Java 2 Enterprise Edition and is essentially J2SE with a multitude of APIs added in including Tomcat. For the sake of this discussion, you want to use either J2SE and Tomcat OR J2EE. Don't try to use Tomcat with J2EE as the APIs in Tomcat may severely conflict with what's included in J2EE. Do I need the netBeans lib only for building jsvc (I assume not)? Not that I know of. All you really need to build is the platform native component if it's not available for binary download. The download distribution of Tomcat should already contain the Java classes required. Again, what difference between JDK and SDK? JDK Java Development Kit and is a superset of the JRE or Java Runtime Environment. Superset because it is the JRE with a compiler and development utilities included. SDK stands for Software Development Kit and is an industry wide acronym for the dev tools needed to build software. For the purposes of this discussion, JDK is a SDK. If I download the Eclipse development suite for installation on a Linux development host does it already contain a full fledged JDK, or would its additional installation still be prerequisited? As far as I know, you'll need to get the JDK separately from Sun's website. The J2SE package should do fine. There are a lot of tutorials, blogs, and books on the subject. Most of what I know comes from lurking here on the list and reading the issues other people have, reading the servlet spec, and digging around the documentation. I'm sure others on the list have their favorite materials to recommend. An excellent reference to keep around is the Servlet 2.4 spec. I highly recommend reading it in conjunction with whatever other materials you find: http://www.jcp.org/en/jsr/detail?id=154 The docs at http://tomcat.apache.org are also well developed and should be the best reference when things aren't working. Especially if you have a book that might be a little bit dated, using older versions of Tomcat. --David [EMAIL PROTECTED] wrote: Hi Warren, thank you for referring me to the right download link. Not being a Java developer I certainly lack the Java fundamentals but to my excuse I may maintain that SUN's naming policy (this is also true for their Solaris OS) is quite bewildering so that I never quite know what interpreter (bundle) to look for, download and install. Maybe you can help me a little? What's the difference between Java2 or J2SE and, say Java 5, or Java 1.5. What's the difference between J2SE and J2EE (I guess Standard vs. Enterprise Edition)? Always thought J2EE required extra licensing, why I refrained from downloading it. Do I need the netBeans lib only for building jsvc (I assume not)? Again, what difference between JDK and SDK? If I download the Eclipse development suite for installation on a Linux development host does it already contain a full fledged JDK, or would its additional installation still be prerequisited? Then, I want to learn at least the basics of servlet programming not to be at the mercy of some third party app. developers but to deploy my own monitoring stuff (hopefully later even making use of JMX). I have some web application developing experience in Perl and am wary about security implications and client input. Also I know the basics of OO and at least can read and partly understand Java code (as far as I can guesstimate objects' methods purpose and mutating effects. I need a quick hands on approach at Java servlets. Are there any books, tutorials, or howtos you could reccommend? For a quick access to other web languages I found e.g. O'Reilly's Cookbooks quite useful. I noticed a bear book (i.e. such a beast on the cover) about
Re: jasper exception and root cause
Len Popp wrote: JasperException is a subclass of Exception, so you should be able to use the usual Exception methods on it. But it's not a NullPointerException. JasperException is what I get if I mess up the syntax in a JSP page. So, check for that. -- Len Actually, JasperException extends from ServletException which contains a method for retrieving the root cause. So that's what I was looking for. My bad. - Mott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to install web application only on one port (both 8080 and 8443 ports opened)
--- Anna Krajewska [EMAIL PROTECTED] wrote: Hi I wonder is it possible with apache tomcat to install two web-services (axis) one on port 8080 (and only 8080) and another on 8443 (and only that)? I have opened both porsts. Now when I install web-service it's available on both ports - how to change that without closing any of them in server.xml file? Regards Ania I may be wrong, but I think you would have to define two separate hosts and give them different port numbers. Like I said...I might be wrong, but you can try it or someone will surely correct me if I'm wrong. Wade - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat Startup Messages
Hello, although I didn't find an answer whether to have catalina run as root proc or under unprivileged uid (Charles Cladarale mentioned it was required for binding to low ports, for which there's no need in my setup since I so far used standard ports which are all well beyond 1023) I decided for the latter. So I eventually did a chown -R tomcat:apache $CATALINA_HOME and restarted the thing with su to tomcat, and with the -security switch set (albeit with the standard catalina.policy as it came out of the tarball so far) In the catalina.out I stumbled over these entries. Feb 6, 2006 4:55:17 PM org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java/jre1.5.0_06/lib/i386/client:/usr/java/jre1.5.0_06/lib/i 386:/usr/java/jre1.5.0_06/../lib/i386 Is it worthwhile installing the Apache Tomcat Native Lib, and where would I get it (probably somewhere beneath tomcat.apache.org)? I don't intend to install a JDK on this box (where the NatLib is probably shipped with?) since this shouldn't be a development box. Feb 6, 2006 4:55:17 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled Does it mean it would run a pre-flight check for non valid XML in config files? What would it take to enable XML validation? And finally, what about these errors marked severe? Feb 6, 2006 4:55:18 PM org.apache.catalina.core.StandardContext start SEVERE: Error filterStart Where would I have to setup filters? What filters? Kind of TCP wrapper, or ACLs? Feb 6, 2006 4:55:18 PM org.apache.catalina.core.StandardContext start SEVERE: Context [/balancer] startup failed due to previous errors Feb 6, 2006 4:55:19 PM org.apache.coyote.http11.Http11BaseProtocol start Right, I haven't yet set up a load balancer. But I guess this is optional stuff, isn't it? However, tomcat seems to have started # ps -fu tomcat UIDPID PPID C STIME TTY TIME CMD tomcat 22682 1 4 16:55 pts/100:00:02 /usr/java/jre1.5.0_06/bin/java -Djava.util.logging.ma as a wget of the /manager/list URL shows OK - Listed applications for virtual host localhost /webdav:running:0:webdav /servlets-examples:running:0:servlets-examples /jsp-examples:running:0:jsp-examples /balancer:stopped:0:balancer /host-manager:running:0:/var/www/tomcat/apache-tomcat-5.5.15/serv er/webapps/host-manager /tomcat-docs:running:0:tomcat-docs /:running:0:ROOT /manager:running:0:/var/www/tomcat/apache-tomcat-5.5.15/server/we bapps/manager - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat Startup Messages
In the catalina.out I stumbled over these entries. Feb 6, 2006 4:55:17 PM org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java/jre1.5.0_06/lib/i386/client:/usr/java/jre1.5.0_06/lib/i 386:/usr/java/jre1.5.0_06/../lib/i386 Is it worthwhile installing the Apache Tomcat Native Lib, and where would I get it (probably somewhere beneath tomcat.apache.org)? This lib allows for better performance of the TCs connectors, which is good in production. You would have to build this library and for that you need ANSI CC (GCC will do), Autoconf, maybe something else. I don't intend to install a JDK on this box (where the NatLib is probably shipped with?) No, it is not shipped, it needs to be built and linked to libapr (Apache Portable Runtime library), a part of Apache web server packages (don't forget the development versions, too. since this shouldn't be a development box. JDK won't harm you, but it is a superset of JRE. Nix. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Would like to know what might be causing this exception in servlet
Thank you Chuck and Tim for the information. I did wonder if it was a normal exception, now I know that it's at least nothing to worry about. I have one more. This *IS* a real error, and is caused by something breaking between MySQL and my servlets. SQL Problem: Communication link failure: java.net.SocketException, underlying cause: Connection reset ** BEGIN NESTED EXCEPTION ** java.net.SocketException MESSAGE: Connection reset STACKTRACE: java.net.SocketException: Connection reset at java.net.SocketInputStream.read(SocketInputStream.java:168) at java.io.BufferedInputStream.fill(BufferedInputStream.java:218) at java.io.BufferedInputStream.read(BufferedInputStream.java:235) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:1399) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:1775) at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1020) at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1109) at com.mysql.jdbc.MysqlIO.sqlQuery(MysqlIO.java:1070) at com.mysql.jdbc.Connection.execSQL(Connection.java:2027) at com.mysql.jdbc.Connection.execSQL(Connection.java:1984) at com.mysql.jdbc.Statement.executeUpdate(Statement.java:1248) at com.mysql.jdbc.Statement.executeUpdate(Statement.java:1194) at my.DBMS.keyUpdate(Unknown Source) at my.MyReport.doPost(Unknown Source) at javax.servlet.http.HttpServlet.service(HttpServlet.java:709) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.servlets.InvokerServlet.serveRequest(InvokerServlet.java:419) at org.apache.catalina.servlets.InvokerServlet.doPost(InvokerServlet.java:169) at javax.servlet.http.HttpServlet.service(HttpServlet.java:709) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:541) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:868) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) ** END NESTED EXCEPTION ** SQL State: 08S01 Vendor Error: 0 Only two classes here are mine, the rest are Tomcat and the JDBC driver. My code is simply trying to update a record in the database, when (it appears) the communication link to the database fails. When checked, MySQL is running just fine, and continues to run fine. The current workaround is to detect this condition, and simply stop and restart Tomcat (/etc/init.d/tomcat.server stop; /etc/init.d/tomcat.server start). Any ideas why the communication link to the database just dies? Again, Tomcat is still running, and the database is also still running just fine (other applications using the same database are still working when this happens). Thanks in advance, -Richard - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat logrotation
Hello, I haven't yet installed the lib4j and defind an appender. Since I'm more used to the old fashioned Unix way to rotate logs (and have it working this way for the Apache httpd logs) I would like to employ logrotate. However, in the logrotate.conf for any server's logfiles you usually have to specify a postrotate command or script which eventually would release locks on logfile handles and reinitialize the daemon. Since daemons are running dissociated of a controlling tty they actualy have no need for the SIGHUP why most daemon developers implement a signal handler that would reinitialize the daemon if it caught a SIGHUP. However, when I try to send the master Java thread it blatantly dies like any ordinary shell proc. I there another official signal or call to use, or will I have to run a full blown restart? N.b. when I send it SIGUSR1 it dies, whereas when I send SIGUSR2 it doesn't care at all. Rgds Ralph - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat Startup Messages
Thanks Nikola, I think I will get the Apache Native Tomcat lib. I cannot yet tell what the traffic is gonna be, but a performance boost can never hurt... -Original Message- From: Nikola Milutinovic [mailto:[EMAIL PROTECTED] Sent: Monday, February 06, 2006 5:25 PM To: Tomcat Users List Subject: Re: Tomcat Startup Messages In the catalina.out I stumbled over these entries. Feb 6, 2006 4:55:17 PM org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java/jre1.5.0_06/lib/i386/client:/usr/java/jre1.5.0_06/lib/i 386:/usr/java/jre1.5.0_06/../lib/i386 Is it worthwhile installing the Apache Tomcat Native Lib, and where would I get it (probably somewhere beneath tomcat.apache.org)? This lib allows for better performance of the TCs connectors, which is good in production. You would have to build this library and for that you need ANSI CC (GCC will do), Autoconf, maybe something else. I don't intend to install a JDK on this box (where the NatLib is probably shipped with?) No, it is not shipped, it needs to be built and linked to libapr (Apache Portable Runtime library), a part of Apache web server packages (don't forget the development versions, too. since this shouldn't be a development box. JDK won't harm you, but it is a superset of JRE. Nix. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat logrotation
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Subject: Tomcat logrotation I would like to employ logrotate. Have you read the doc: http://tomcat.apache.org/tomcat-5.5-doc/logging.html http://tomcat.apache.org/faq/logging.html http://minaret.biz/tips/tomcatLogging.html#tomcat_5_5_logging The last has specific, step by step, instructions for rotation. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
webapps/ROOT
Hello. I've encountered a web application, developed by someone else, that uses the webapps/ROOT directory for its own root directory. Can someone give me some info or opinions along the lines of the following three points: a) what is the standard purpose and use of the webapps/ROOT context b) why would someone want to deploy their app to this location c) what are the consequences of such a deployment? any? ___ Join Excite! - http://www.excite.com The most personalized portal on the Web! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: webapps/ROOT
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Subject: webapps/ROOT a) what is the standard purpose and use of the webapps/ROOT context It's the default application for the host. b) why would someone want to deploy their app to this location So that end users can use just the host name, and don't have to know an app name. c) what are the consequences of such a deployment? any? Loss of the standard Tomcat welcome page is about it. This is the recommended way of deploying the default app for a given host. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: webapps/ROOT
Hi Chuck, Sorry to bug you again. But all I was asking was, do you know where in the tomcat5.5 core download The servlets.jar is located so I can set my $CLASSPATH to it? If you do, It would be greatly appreciated if you could share this with me. Thanks, I know how important your time is... Regards, Joseph P. McTigue CBC Innovis, CIA Department [EMAIL PROTECTED] (614) 538-6032 -Original Message- From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] Sent: Monday, February 06, 2006 12:11 PM To: Tomcat Users List; [EMAIL PROTECTED] Subject: RE: webapps/ROOT From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Subject: webapps/ROOT a) what is the standard purpose and use of the webapps/ROOT context It's the default application for the host. b) why would someone want to deploy their app to this location So that end users can use just the host name, and don't have to know an app name. c) what are the consequences of such a deployment? any? Loss of the standard Tomcat welcome page is about it. This is the recommended way of deploying the default app for a given host. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Log4J output to SYSLOG
It looks more or less like mine. My properties file is: log4j.rootLogger=debug, SYSLOG log4j.logger.lucent.com.bean.UtilBean=DEBUG,SYSLOG log4j.appender.SYSLOG=org.apache.log4j.net.SyslogAppender log4j.appender.SYSLOG.syslogHost=localhost log4j.appender.SYSLOG.layout=org.apache.log4j.PatternLayout log4j.appender.SYSLOG.layout.ConversionPattern=%d{dd-MM- HH:mm:ss} %-5p (%C :%M:%L) - %m%n log4j.appender.SYSLOG.Facility=LOCAL1 Hope it helps Elisabeth -Original Message- From: Mark F [mailto:[EMAIL PROTECTED] Sent: lunes, 06 de febrero de 2006 16:06 To: Tomcat Users List; [EMAIL PROTECTED] Subject: Re: Log4J output to SYSLOG Bachler, Elisabeth (Elisabeth) wrote: I have modified the log4j.properties file to send the output to SYSLOG and I think it is working Thank you for your help Could you explain how it was that you accomplished this? I'm trying to do much the same thing with Tomcat 5.0.30. So far I have: 1. commons-logging.jar and log4j.jar are in the classpath and found by tomcat (CATALINA_HOME/bin) 2. Written (borrowed mostly) a script to start Tomcat via jsvc as user tomcat. 3. Configured log4j.properties file and placed in CATALINA_HOME/common/classes log4j.rootLogger=INFO, A1 log4j.appender.A1=org.apache.log4j.net.SyslogAppender log4j.appender.A1.SyslogHost=127.0.0.1 log4j.appender.A1.facility=LOCAL7 log4j.appender.A1.layout=org.apache.log4j.PatternLayout log4j.appender.A1.layout.ConversionPattern=%-4r %-5p %c{2} %M.%L %x - %m\n It does not seem to be sending anything to syslog Thanks, -Mark - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat logrotation
Yes Chuck, but not carefully read it yet. This is as I said all related to log4j. Not that I mind that the Java folks advocate their libs for doing common tasks like log rotation their way. It would only be quicker for me to set up logrotation using logrotate. But never mind, I guess I will soon recall the basic layout of log4j config files. I can remember to once have played with http://log4perl.sourceforge.net/ which is a Perl implementation of the log4j mechanism, and a very neat tool if you want to furnish your Perl modules with sophisticated logging. At least they both use the same syntax for their config files (i.e. Java kind of object attribute assignments) -Original Message- From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] Sent: Monday, February 06, 2006 5:51 PM To: Tomcat Users List Subject: RE: Tomcat logrotation From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Subject: Tomcat logrotation I would like to employ logrotate. Have you read the doc: http://tomcat.apache.org/tomcat-5.5-doc/logging.html http://tomcat.apache.org/faq/logging.html http://minaret.biz/tips/tomcatLogging.html#tomcat_5_5_logging The last has specific, step by step, instructions for rotation. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: servlet.jar
From: Joe McTigue [mailto:[EMAIL PROTECTED] Subject: RE: webapps/ROOT I think you just hijacked another thread. If you have a new question, please start a new thread, and not reuse an existing one. But all I was asking was, do you know where in the tomcat5.5 core download The servlets.jar is located so I can set my $CLASSPATH to it? There is no servlets.jar in Tomcat, but the servlet-api.jar is in the common/lib directory. You don't need to (and should not) set CLASSPATH to run Tomcat, although you usually will need to configure the location of the servlet-api.jar in your compilation mechanism. CBC Innovis, CIA Department A curious departmental acronym... - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat and client certificates
Markus wrote: Mark: Thank you for your link to the archive. It was my fault using the UserDatabase realm instead of the MemoryRealm. I'm, using tomcat 5.0.28 - is it still the case in 5.5.x that you MUST use the MemoryRealm for clientcert authentication? All realms should work with CLIENT-CERT. If they don't file a bug report and I'll look into it. 3) When there is NO client certificate I get: HTTP Status 400 - No client certificate chain in this request 400 usually stands for a bad request or bad syntax. I believe in this case 401 should be the appropriate reply. Hmm. I guess this could be debatable. Is there any way to adjust the HTTP Status code for failed client-cert authentication? No configuration option. I suspect it would require code changes. Mark - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Would like to know what might be causing this exception in servlet
From: Richard S. Huntrods [mailto:[EMAIL PROTECTED] Subject: RE: Would like to know what might be causing this exception in servlet I have one more. This *IS* a real error, and is caused by something breaking between MySQL and my servlets. (Should probably start a new thread for this, since it's a different issue.) It looks like the other end (MySQL) decided to drop the connection. Could be a timeout problem, or a network hiccup (e.g., somebody tripped over a cable). Is this reproducible? Can you get a network capture of the situation? - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Fwd: auth-constraint in web.xml in tomcat 5.5.15
Oliver Kohll wrote: Oops no it didn't, my mistake. The app now doesn't prompt for authentication at all. Is there a way of getting it to work so that the authentication is used but you don't have to hard code roles in web.xml? Make every user a member of the global role and use this role rather than *. Mark - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Help with clustering
hello Problems with my cluser I am using apache-tomcat-5.5.15 each server has this in the server.xml I have a couple of questions 1) these two machines are connected two different ways a) routable/public IPS 100M connection b) non routeable 192.169 Gigabit connection When i look at the log files, I see entries like INFO: Send stats from [66.123.123.180:4,001], Nr of bytes sent=1,182,166 over 900 = 1,313 bytes/request, processing time 0 msec, avg processing time 0 msec Feb 6, 2006 11:52:00 AM org.apache.catalina.cluster.tcp.ReplicationValve updateStats Is there a way to configure it so the syncing goes over the GigaBit Links??? Thanks Randy == Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Cluster className=org.apache.catalina.cluster.tcp.SimpleTcpCluster managerClassName=org.apache.catalina.cluster.session.DeltaManager expireSessionsOnShutdown=false useDirtyFlag=true notifyListenersOnReplication=true Membership className=org.apache.catalina.cluster.mcast.McastService mcastAddr=228.0.0.9 mcastPort=45564 mcastFrequency=500 mcastDropTime=3000/ Receiver className=org.apache.catalina.cluster.tcp.ReplicationListener tcpListenAddress=auto tcpListenPort=4001 tcpSelectorTimeout=100 tcpThreadCount=35/ Sender className=org.apache.catalina.cluster.tcp.ReplicationTransmitter replicationMode=pooled ackTimeout=15000/ Valve className=org.apache.catalina.cluster.tcp.ReplicationValve filter=.*\.gif;.*\.js;.*\.jpg;.*\.png;.*\.htm;.*\.html;.*\.css;.*\.txt;.*\.pdf;\*.wav;\*.mp3;/ Deployer className=org.apache.catalina.cluster.deploy.FarmWarDeployer tempDir=/tmp/war-temp/ deployDir=/tmp/war-deploy/ watchDir=/tmp/war-listen/ watchEnabled=false/ ClusterListener className=org.apache.catalina.cluster.session.ClusterSessionListener/ /Cluster - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: auth-constraint in web.xml in tomcat 5.5.15
David Delbecq wrote: *outch* This mean i will have to change my web.xml with future tomcat version. How do I allow access to a ressource to all authenticated users now? Create a global role. Assign all users to that role. Use the global role rather than *. Mark - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Help with clustering
Yes. Use their IP address in the replication listener, i.e., Receiver className=org.apache.catalina.cluster.tcp.ReplicationListener compress=false sendAck=true tcpListenAddress=10.0.1.58 === Make this IP be the interface you wish. tcpListenPort=41001 tcpSelectorTimeout=100 tcpThreadCount=6/ (you probably have it set to auto...) -Original Message- From: Randy Paries [mailto:[EMAIL PROTECTED] Sent: Monday, February 06, 2006 12:57 PM To: users@tomcat.apache.org Subject: Help with clustering hello Problems with my cluser I am using apache-tomcat-5.5.15 each server has this in the server.xml I have a couple of questions 1) these two machines are connected two different ways a) routable/public IPS 100M connection b) non routeable 192.169 Gigabit connection When i look at the log files, I see entries like INFO: Send stats from [66.123.123.180:4,001], Nr of bytes sent=1,182,166 over 900 = 1,313 bytes/request, processing time 0 msec, avg processing time 0 msec Feb 6, 2006 11:52:00 AM org.apache.catalina.cluster.tcp.ReplicationValve updateStats Is there a way to configure it so the syncing goes over the GigaBit Links??? Thanks Randy == Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Cluster className=org.apache.catalina.cluster.tcp.SimpleTcpCluster managerClassName=org.apache.catalina.cluster.session.DeltaManager expireSessionsOnShutdown=false useDirtyFlag=true notifyListenersOnReplication=true Membership className=org.apache.catalina.cluster.mcast.McastService mcastAddr=228.0.0.9 mcastPort=45564 mcastFrequency=500 mcastDropTime=3000/ Receiver className=org.apache.catalina.cluster.tcp.ReplicationListener tcpListenAddress=auto tcpListenPort=4001 tcpSelectorTimeout=100 tcpThreadCount=35/ Sender className=org.apache.catalina.cluster.tcp.ReplicationTransmitter replicationMode=pooled ackTimeout=15000/ Valve className=org.apache.catalina.cluster.tcp.ReplicationValve filter=.*\.gif;.*\.js;.*\.jpg;.*\.png;.*\.htm;.*\.html;.*\.css;.*\.txt;.*\. pdf;\*.wav;\*.mp3;/ Deployer className=org.apache.catalina.cluster.deploy.FarmWarDeployer tempDir=/tmp/war-temp/ deployDir=/tmp/war-deploy/ watchDir=/tmp/war-listen/ watchEnabled=false/ ClusterListener className=org.apache.catalina.cluster.session.ClusterSessionListener/ /Cluster - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
tomcat hosting
I want to find a web hosting place to put my web apps. What are the important criteria for determining a good web host -- most servlet hosts seem to use Tomcat. ___ Join Excite! - http://www.excite.com The most personalized portal on the Web! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
multiple domain names
I can read the tomcat docs myself to figure out the details, but I just want to know if this is something done within tomcat or not. I want to be able to map different domain names to the different web apps in the server. Can I do this? Is this a tomcat issue, or something else? ___ Join Excite! - http://www.excite.com The most personalized portal on the Web! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat stops automatically
Hi all; i am using Tomcat over 1 year but its the first time i have that big problem... my tomcat stops automatically everytime once between 5 to 20 minutes...The problem started today i didnt any make configuration...i just only runned a ssh script on my server which connects to some server with ssh protocol... i dont know really why?when i looked at the ram status it says low ram 40 mb remaining.so i added 512 ram more total 1 gb..now there is half of free ram(512 mb)..i have just uninstalled th tomcat and installed the latest one but still the same problemwhy it stops automatically without no reason...how can i understand and solve the problem please show me a way help:( thank you Burak - Yahoo! Mail - Helps protect you from nasty viruses.
RE: Re: Re: Re: APR Connector Shutdown Problem
That seems to have done the trick. Thanks for your help Bill! , Josh. -Original Message- From: news [mailto:[EMAIL PROTECTED] On Behalf Of Bill Barker Sent: Friday, February 03, 2006 9:50 PM To: users@tomcat.apache.org Subject: Re: Re: Re: APR Connector Shutdown Problem I was doing a cut-and paste from the code in Httpd. In tcnative, 's' is it's internal socket structure, and the APR socket is s-sock. Fenlason, Josh [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I added the following line to tomcat-native.1.1.1/jni/native/src/network.c (added at line 388): apr_socket_opt_set( s, APR_SO_REUSEADDR, 1 ); But I'm still running into the same problem. Does anyone who works on the APR Connector have any input on this? Or do I need to post this issue on the dev list? Thanks. , Josh. -Original Message- From: news [mailto:[EMAIL PROTECTED] On Behalf Of Bill Barker Sent: Monday, January 30, 2006 10:07 PM To: users@tomcat.apache.org Subject: Re: Re: APR Connector Shutdown Problem Not by me, I don't really work on the APR Connector ;-). In the bind method in network.c is probably easiest. If you want your patch to be accepted by the dev team, then you should probably wrap it in a '#ifndef WIN32' like httpd does (don't know why, and care even less :). Fenlason, Josh [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Is there no intent to fix this issue? Where would I need to make that patch? Thanks. , Josh. -Original Message- From: news [mailto:[EMAIL PROTECTED] On Behalf Of Bill Barker Sent: Friday, January 27, 2006 8:59 PM To: users@tomcat.apache.org Subject: Re: APR Connector Shutdown Problem Yeah, the difference is that Httpd calls: apr_socket_opt_set(s, APR_SO_REUSEADDR, one); on the Socket before binding it. That allows it to bind even though there are still half-closed sockets on systems like Solaris. About the only work-around is to hack the tcnative code, and recompile it. Fenlason, Josh [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I added the Listener you mentioned to server.xml, but I'm still seeing the issue. The problem is happening when run the shutdown.sh. I can understand if things aren't all clean and tidy if Tomcat crashed, but you shouldn't have to wait 4 minutes to restart Tomcat after a planned shutdown. Apache doesn't work like that. Any other suggestions on how to get this to shutdown properly? Thanks in advance. , Josh. -Original Message- From: Mladen Turk [mailto:[EMAIL PROTECTED] Sent: Friday, January 27, 2006 1:24 AM To: Tomcat Users List Subject: Re: APR Connector Shutdown Problem Fenlason, Josh wrote: I'm running into a problem with the APR connector not shutting down properly. Tomcat runs fine and there are no errors on shutdown, but if I shut Tomcat down and start it up again I get a socket bind failed error in the catalina log (attached). I have to wait for several minutes between shutdown and startup for Tomcat to be able to startup correctly. If I run Tomcat without the APR connector, I don't have this issue. This does not occur on Windows, but does on Solaris and AIX. Has anyone else seen this? One thing I noticed is that the first thing logged on shutdown is an AjpAprProtocol pause entry, but there is no shutdown, stop or destroy. Is there any chance the APR connector is just getting paused and nothing is actually stopping it? Any help would be greatly appreciated. Thanks in advance. I suppose you have: Listener className=org.apache.catalina.core.AprLifecycleListener / in your server.xml But of course it doesn't guarantee it will be executed in all cases, if the JVM crashes for example. On Solaris it can take up to 4 minutes until the OS recycles the zombie socket. You can use: ndd -set /dev/tcp tcp_time_wait_interval 6 To lower that value. APR does not try to fool the OS like JVM, but rather behaves like Apache httpd. Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL
Defining servlet as default web application
I have a servlet that I've developed that I want to define as the default application but am not sure how to achieve this. Specifically, I have a servlet as part of a package and is in webapps/ROOT/classes. I have defined a mapping so I can run the servlet my its name - http://192.168.0.6/MyApp. I understand how to modify the config files for welcome files but not to define a servlet to run automatically when going to http://192.168.0.6 http://192.168.0.6/ . Thanks! Gregg
RE: mod_jk weirdness
Chris, Not sure if this is helpful but it appears the next step that is failing is the actual connection to tomcat from apache (unless you've left this part of your mod_jk.log out of your post). Here's the mod_jk.log output of a test I did on my local machine. The first worker 'testworker' connects successfully; while the second 'newworker' fails at about the same point you appear to be failing. In the below case, 'newworker' fails because it can't resolve the tomcat address after it sets the contact for 'newworker'. Don't know if this helps or not... Darren [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_worker.c (141): about to create instance testworker of ajp13 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_worker.c (154): about to validate and init testworker [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1806): worker testworker contact is 'localhost:8009' [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1895): setting socket keepalive to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1934): setting socket timeout to -1 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1938): setting socket buffer size to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1942): setting connection recycle timeout to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1946): setting cache timeout to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1950): setting connect timeout to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1954): setting reply timeout to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1958): setting prepost timeout to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1962): setting recovery opts to 0 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1966): setting number of retries to 3 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1843): setting connection cache size to 250 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_worker.c (248): removing old testworker worker [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_worker.c (236): creating worker newworker [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_worker.c (141): about to create instance newworker of ajp13 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_worker.c (154): about to validate and init newworker [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (1806): worker newworker contact is 'www.local.org:8009' [Mon Feb 06 09:49:03 2006] [2756:3108] [error] jk_ajp_common.c (1815): can't resolve tomcat address localhost [Mon Feb 06 09:49:03 2006] [2756:3108] [error] jk_ajp_common.c (1818): invalid host and port www.local.org 8009 [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_ajp_common.c (2012): up to 0 endpoints to close [Mon Feb 06 09:49:03 2006] [2756:3108] [error] jk_worker.c (158): validate failed for newworker [Mon Feb 06 09:49:03 2006] [2756:3108] [error] jk_worker.c (256): failed to create worker newworker [Mon Feb 06 09:49:03 2006] [2756:3108] [debug] jk_worker.c (212): close_workers will destroy worker testworker -Original Message- From: Chris Pat [mailto:[EMAIL PROTECTED] Sent: Saturday, February 04, 2006 9:23 AM To: Tomcat Subject: mod_jk weirdness Hello Attached is the full trace, but can anyone please explain second below. The workers.properties file is immediately below. It eventually does some type of core dump. The site is up, working on the specified ip, just not working with the mod_jk. Any help much appreciated. workers.properties workers.tomcat_home e:\Program\Tomcat 5.5 workers.java_home=$JAVA_HOME ps\ worker.list=connect_op, connect_sb worker.connect_op.port=12345 worker.connect_op.host=localhost worker.connect_op.type=ajp13 worker.connect_sb.port=12346 worker.connect_sb.host=localhost worker.connect_sb.type=ajp13 from mod_jk.log [Sat Feb 04 07:54:00 2006] [8196:8192] [debug] jk_worker.c (236): creating worker connect_op [Sat Feb 04 07:54:00 2006] [8196:8192] [debug] jk_worker.c (141): about to create instance connect_op of ajp13 [Sat Feb 04 07:54:00 2006] [8196:8192] [debug] jk_worker.c (154): about to validate and init connect_op [Sat Feb 04 07:54:00 2006] [8196:8192] [debug] jk_ajp_common.c (1806): worker connect_op contact is 'localhost:12345' ... [Sat Feb 04 07:54:01 2006] [8196:8192] [debug] jk_worker.c (248): removing old connect_op worker __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat Startup Messages
From: [EMAIL PROTECTED] Date: 2006/02/06 Mon AM 11:17:08 EST To: users@tomcat.apache.org Subject: Tomcat Startup Messages Hello, although I didn't find an answer whether to have catalina run as root proc or under unprivileged uid (Charles Cladarale mentioned it was required for binding to low ports, for which there's no need in my setup since I so far used standard ports which are all well beyond 1023) I decided for the latter. So I eventually did a chown -R tomcat:apache $CATALINA_HOME and restarted the thing with su to tomcat, and with the -security switch set (albeit with the standard catalina.policy as it came out of the tarball so far) In the catalina.out I stumbled over these entries. Ralph, How are you starting Tomcat? Are you using startup.sh or catalina.sh? Did you happen to edit either of these files? Sounds as if classpath has been changed. warren Feb 6, 2006 4:55:17 PM org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java/jre1.5.0_06/lib/i386/client:/usr/java/jre1.5.0_06/lib/i 386:/usr/java/jre1.5.0_06/../lib/i386 Is it worthwhile installing the Apache Tomcat Native Lib, and where would I get it (probably somewhere beneath tomcat.apache.org)? I don't intend to install a JDK on this box (where the NatLib is probably shipped with?) since this shouldn't be a development box. Feb 6, 2006 4:55:17 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled Does it mean it would run a pre-flight check for non valid XML in config files? What would it take to enable XML validation? And finally, what about these errors marked severe? Feb 6, 2006 4:55:18 PM org.apache.catalina.core.StandardContext start SEVERE: Error filterStart Where would I have to setup filters? What filters? Kind of TCP wrapper, or ACLs? Feb 6, 2006 4:55:18 PM org.apache.catalina.core.StandardContext start SEVERE: Context [/balancer] startup failed due to previous errors Feb 6, 2006 4:55:19 PM org.apache.coyote.http11.Http11BaseProtocol start Right, I haven't yet set up a load balancer. But I guess this is optional stuff, isn't it? However, tomcat seems to have started # ps -fu tomcat UIDPID PPID C STIME TTY TIME CMD tomcat 22682 1 4 16:55 pts/100:00:02 /usr/java/jre1.5.0_06/bin/java -Djava.util.logging.ma as a wget of the /manager/list URL shows OK - Listed applications for virtual host localhost /webdav:running:0:webdav /servlets-examples:running:0:servlets-examples /jsp-examples:running:0:jsp-examples /balancer:stopped:0:balancer /host-manager:running:0:/var/www/tomcat/apache-tomcat-5.5.15/serv er/webapps/host-manager /tomcat-docs:running:0:tomcat-docs /:running:0:ROOT /manager:running:0:/var/www/tomcat/apache-tomcat-5.5.15/server/we bapps/manager - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
MySQL Database / Tomcat Exceptions
From: Richard S. Huntrods [mailto:[EMAIL PROTECTED] Subject: RE: Would like to know what might be causing this exception in servlet I have one more. This *IS* a real error, and is caused by something breaking between MySQL and my servlets. (Should probably start a new thread for this, since it's a different issue.) It looks like the other end (MySQL) decided to drop the connection. Could be a timeout problem, or a network hiccup (e.g., somebody tripped over a cable). Is this reproducible? Can you get a network capture of the situation? - Chuck Thanks, Chuck. I am thinking along similar lines. The only problem is that aside from the Java exception, there are no error messages in any other Tomcat logs or MySQL logs. Here's another one from today: DBMS SQLException. Time:Mon Feb 06 14:46:06 MST 2006 SQLException caught: keyLookup(login : 50768) DBMS SQLException. Time:Mon Feb 06 14:46:06 MST 2006 SQL Problem: Communication link failure: java.io.IOException, underlying cause: Unexpected end of input stream ** BEGIN NESTED EXCEPTION ** java.io.IOException MESSAGE: Unexpected end of input stream STACKTRACE: java.io.IOException: Unexpected end of input stream at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:1405) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:1775) at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1020) at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1109) at com.mysql.jdbc.MysqlIO.sqlQuery(MysqlIO.java:1070) at com.mysql.jdbc.Connection.execSQL(Connection.java:2027) at com.mysql.jdbc.Connection.execSQL(Connection.java:1984) at com.mysql.jdbc.Statement.executeQuery(Statement.java:1152) at my.DBMS.keyLookup(Unknown Source) at my.Person.lookup(Unknown Source) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.servlets.InvokerServlet.serveRequest(InvokerServlet.java:419) at org.apache.catalina.servlets.InvokerServlet.doGet(InvokerServlet.java:133) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:541) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:868) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) ** END NESTED EXCEPTION ** SQL State: 08S01 Vendor Error: 0 Again, basically Tomcat seems to just lose the connection to MySQL. Any suggestions? -Richard - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: MySQL Database / Tomcat Exceptions
How are you creating the connection and are you trying to maintain it? Unless you are using a pool that is designed to deal with MySQL you need to handle the timeout of the connection to the db. If you are trying to hold onto the connection, MySQL will drop it after some time. To you app it will appear as lost communication. - Original Message - From: Richard S. Huntrods [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Monday, February 06, 2006 5:55 PM Subject: MySQL Database / Tomcat Exceptions From: Richard S. Huntrods [mailto:[EMAIL PROTECTED] Subject: RE: Would like to know what might be causing this exception in servlet I have one more. This *IS* a real error, and is caused by something breaking between MySQL and my servlets. (Should probably start a new thread for this, since it's a different issue.) It looks like the other end (MySQL) decided to drop the connection. Could be a timeout problem, or a network hiccup (e.g., somebody tripped over a cable). Is this reproducible? Can you get a network capture of the situation? - Chuck Thanks, Chuck. I am thinking along similar lines. The only problem is that aside from the Java exception, there are no error messages in any other Tomcat logs or MySQL logs. Here's another one from today: DBMS SQLException. Time:Mon Feb 06 14:46:06 MST 2006 SQLException caught: keyLookup(login : 50768) DBMS SQLException. Time:Mon Feb 06 14:46:06 MST 2006 SQL Problem: Communication link failure: java.io.IOException, underlying cause: Unexpected end of input stream ** BEGIN NESTED EXCEPTION ** java.io.IOException MESSAGE: Unexpected end of input stream STACKTRACE: java.io.IOException: Unexpected end of input stream at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:1405) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:1775) at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1020) at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1109) at com.mysql.jdbc.MysqlIO.sqlQuery(MysqlIO.java:1070) at com.mysql.jdbc.Connection.execSQL(Connection.java:2027) at com.mysql.jdbc.Connection.execSQL(Connection.java:1984) at com.mysql.jdbc.Statement.executeQuery(Statement.java:1152) at my.DBMS.keyLookup(Unknown Source) at my.Person.lookup(Unknown Source) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.servlets.InvokerServlet.serveRequest(InvokerServlet.java:419) at org.apache.catalina.servlets.InvokerServlet.doGet(InvokerServlet.java:133) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:541) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:868) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) ** END NESTED EXCEPTION ** SQL State: 08S01 Vendor Error: 0 Again, basically Tomcat seems to just lose the connection to MySQL. Any suggestions? -Richard - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: wrapping manager undeploy Ant task
Add: failOnError=false -Original Message- From: Glen Mazza [mailto:[EMAIL PROTECTED] Sent: Monday, February 06, 2006 8:25 AM To: users@tomcat.apache.org Subject: wrapping manager undeploy Ant task Hello, I'm using the manager tasks for Ant to undeploy and deploy my WAR file in Tomcat, as shown below. Sometimes, due to a previous processing error, there is nothing to undeploy (i.e., no webapp there) but the deploy task is still relevant and should still occur. However, in these cases, my Ant target fails because the undeploy task returns a nothing-to-undeploy error. Question: How do I wrap the undeploy/ task, so that if there is nothing to undeploy, the deploy task within this target will still activate? Currently I am just commenting out the undeploy task when that situation occurs. Thanks, Glen target name=deploy depends=war undeploy url=${tcManagerURL} username=${tcUsername} password=${tcPassword} path=${apppath}/ deploy url=${tcManagerURL} username=${tcUsername} password=${tcPassword} path=${apppath} war=${war.app.name}.war/ /target - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
UserTransaction, JOTM and Tomcat 5.5.x
Howdy all, I'm trying to get JOTM working on Tomcat 5.5.x. I'm using 5.5.15 and I've run into some strange issues. More than anything, I'm looking for explanations and (hopefully) some help. I've updated the following tutorial for Tomcat 5.5.x: http://jotm.objectweb.org/current/jotm/doc/howto-tomcat-jotm.html My update: http://static.raibledesigns.com/downloads/howto-tomcat-jotm.html I uploaded this update only temporarily - hopefully the patch I submitted (http://tinyurl.com/9q4vl) will get committed to the JOTM project. ;-) Strange things: 1. it's no longer possible to put a Resource for UserTransaction in context.xml. Why is that? It works fine in Tomcat 5.0.x. For 5.5.x, it seems you have to put the UserTransaction resource in the GlobalNamingResources part of server.xml. Resource name=UserTransaction auth=Container type=javax.transaction.UserTransaction factory=org.objectweb.jotm.UserTransactionFactory jotm.timeout=60/ Then you have to link to it from your context.xml: ResourceLink name=UserTransaction global=UserTransaction type=javax.transaction.UserTransaction/ 2. For the demo (dbtest.war) listed in this howto to work, it seems it's essential that factory=org.objectweb.jndi.DataSource be specified on the jdbc/myDB Resource. However, if you specify that in context.xml for Tomcat 5.5.x, the DataSource doesn't get registered. Removing it gets the DS registered, but rollback doesn't occur properly in the application. Resource name=jdbc/myDB auth=Container type=javax.sql.DataSource factory=org.objectweb.jndi.DataSourceFactory driverClassName=com.mysql.jdbc.Driver username=mojo password=jojo url=jdbc:mysql://localhost/javatest/ To summarize: Why can't a UserTransaction resource be in context.xml with Tomcat 5.5.x? Why can't a factory attribute be specified on a datasource with Tomcat 5.5.x? Both of these settings work fine on Tomcat 5.0.28. I'm on OS X with JDK 5. Of course, if anyone knows of a easier transaction manager to integrate into Tomcat, I'm all ears. ;0) Thanks, Matt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multiple domain names
Yes. Virtual Hosts - Original Message - From: [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Monday, February 06, 2006 1:22 PM Subject: multiple domain names I can read the tomcat docs myself to figure out the details, but I just want to know if this is something done within tomcat or not. I want to be able to map different domain names to the different web apps in the server. Can I do this? Is this a tomcat issue, or something else? ___ Join Excite! - http://www.excite.com The most personalized portal on the Web! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat stops automatically
Check you logs. Decipher the script to determine exactly what it did. Check the FAQ for Tomcat Crash. If no one is browsing does it still crash? Watch your processes and see which one is using processor when Tomcat crashes. - Original Message - From: netsonic netsonic [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Monday, February 06, 2006 1:36 PM Subject: Tomcat stops automatically Hi all; i am using Tomcat over 1 year but its the first time i have that big problem... my tomcat stops automatically everytime once between 5 to 20 minutes...The problem started today i didnt any make configuration...i just only runned a ssh script on my server which connects to some server with ssh protocol... i dont know really why?when i looked at the ram status it says low ram 40 mb remaining.so i added 512 ram more total 1 gb..now there is half of free ram(512 mb)..i have just uninstalled th tomcat and installed the latest one but still the same problemwhy it stops automatically without no reason...how can i understand and solve the problem please show me a way help:( thank you Burak - Yahoo! Mail - Helps protect you from nasty viruses. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multiple domain names
Take a look at http://httpd.apache.org/docs/1.3/mod/core.html#virtualhost Martin- - Original Message - From: Parsons Technical Services [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org; [EMAIL PROTECTED] Sent: Monday, February 06, 2006 8:06 PM Subject: Re: multiple domain names Yes. Virtual Hosts - Original Message - From: [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Monday, February 06, 2006 1:22 PM Subject: multiple domain names I can read the tomcat docs myself to figure out the details, but I just want to know if this is something done within tomcat or not. I want to be able to map different domain names to the different web apps in the server. Can I do this? Is this a tomcat issue, or something else? ___ Join Excite! - http://www.excite.com The most personalized portal on the Web! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Disable support for low encryption ciphers in tomcat 4.1.30
Hi All, I am using Tomcat 4.1.30 stand-alone with j2re1.4.2_04 to serve HTTPS connections. I would like to disable the support for low encryption ciphers like SSL_RSA_EXPORT_WITH_RC4_40_MD5. I have seen from the following page that these are the supported ciphers: http://java.sun.com/j2se/1.4.2/docs/guide/security/jsse/JSSERefGuide.html I would only like to maintain support for Medium and High encryption ciphers which range with a strength of = 128. I looked at the attributes that Tomcat 4.1 uses and it doesn't have the cipher attribute which I could use to force the encryption suite to use. I am not looking to upgrade my Tomcat anytime soon. Any ideas would be greatly appreciated. Feel free to correct me if I am also taking the wrong way of solving this problem. Main goal here is to disable the support for any Low Encryption on the Tomcat server. This is for added security. Regards, reyus1
Re: Calling Realm.authenticate() doesn't register Principal in with the Session??
Mark Thomas wrote: Given users are going to have to modify their app to use this library, not modifying the associated context.xml looks to be a nice to have requirement that is making things more difficult. Removing this requirement opens up a number of alternative implementation options including custom realms. Mark Mark, are you saying that you agree, or disagree, with the usefulness of the idea? Your point about 'users have to modify their app' is true, but a one time requirement, and thereafter their app will be compatible with whatever underlying realm impl is used, which I find enticing. Currently there is no mechanism (that I can see) to programtically perform login - say from an html form - this 'new' proposed method fills that. And by the same token, a user would already have to modify their app (to use a custom POST url or form names or redirect), with the built-in form based login (or subclass of it's impl), so that doesn't seem to be a drawback. Sorry to be redundant of you're already agreeing with the idea. Ken - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]