Re: JNDI or LDAP services for tomcat
Shlomi Levi wrote: Does anybody knows if Tomcat 5.0 is supplying LDAP engine? definitely NO if it does, can you direct me to the documentation? if it doesn't, does anybody know of a pluging already written? no plugin needed, use a proper JNDI context put the required library in the tomcat classpath that's it!!! Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: source code exposure
unplug wrote: HI all, I am using Fedora Core 1 with tomcat 4.1.29, apache 2.0.48 and mod_jk2. I have created a simple jsp (code listed below) and put it under $CATALINA_HOME/webapps/examples. code: file name: test.jsp %= new java.util.Date() % It can be accessed in the browser using the following link http://company.com/examples/test.jsp However, its source code will be exposed when I type the following. http://company.com//examples/test.jsp How can I configure it to prevent such exposure? Anyone can give me an advise. I guess taht your JSP doesn't specify the content for the response so the browser doesn't layout the HTML but show the code source instead... So try to fix the content type in your response to text/html HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Hanging tomcat processes on heavy access
Oswald Campesato wrote: Hello, Chris: I have a couple of suggestions (but no answers). 1) you can attach to a process with the 'truss' command and monitor the read/write activity of the process. Syntax, options, and examples of truss can be had via man truss or Google Unix truss command. This *might* reveal something. 2) you can kill hanging processes and release the port via a Unix command (the name escapes me right now), which may help reduce the number of time you need to reboot 3) try experimenting with the min/max heap size for Java; perhaps you can set both of them to small values in a test environment to quickly reproduce the problem and use #1 Since other people can continue working normally, it does not appear that you've read the maximum number of socket connections (338, if I remember correctly). Did this problem start after having installed new software or changing the environment? Perhaps you can try rolling back to see if the problem disappears Cordially, Oswald Christoph Fischer [EMAIL PROTECTED] wrote: Hello everyone, here is my configuration: linux server with tomcat 4.1.29 connected to apache 1.3.29 via nod_jk java version 1.4.2_03 from tomcat server.xml port=8009 minProcessors=5 maxProcessors=500 acceptCount=10 debug=0/ At heavy access times the user gets a blank screen on the browser and on the server a java process is hanging. Tomcat is still working and responding to further tasks, but the 'hanging' processes will stay around until reboot. Unfortunately the hanging processes will also keep a socket connection on port 8009 to apache, so after some time the system hangs due to too much connections. I could rebuild this situation also with jmeter and a simple servlet which only responds a simple html site, so the problem couldn't come from my coding. How can I solve this problem ? Is it coming from tomcat, apache or mod_jk??? Hi christopher, I'd like to add that you may need to improve the mod_jk config using arguments (parameters) like the TIME_WAIT ? could be helpful to release more quickly connections have you setted the KEEP-ALIVE parameter ? I guess that a deep look to you mod_jk configuration may solve much troubles... HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Viewing errors
Leo Tomcat wrote: Hi all, I'm using Tomcat 4.0.6 and I've already installed it as a service. My problem now, is that I can't see the console that was so usefull for viewing when some exception was thrown, or just for debugging using System.out.println. I've searched the log files at $TOMCAT_HOME\logs and I couldn't find any of the logs that my webapp leaves. I've tried System.err and nothing happend. Does any one know, how to send my my error-logs or simplier logs to a file?? Is that configurable or a code matter?? I highly suggest you to use chainsaw to configure your logs using log4j After this you will be able to view your logs on the machine of your choice with a nice GUI... LOG4J resources (manual so on) may guide you HTH Jerome Thanks -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 3.3.1 vs Tomcat 4.1.29
Ralph Einfeldt wrote: It should be contained in the tomcat distribution. But the outdated one is found before the one that is delivered with tomcat. Search for servlet.jar, j2ee.jar on your machine. (e.g. in JAVA_HOME/jre/lib/ext) humm I suspect a malicious CLASSPATH mangling... could you try to set CLASSPATH to a nil value then restart TOMCAT 4 (or 5) Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to determine whether a file exist or not in a remote host by using java?
Howdy, hi, I want to confirm if there is a file in a romote machine, How could I do using Java? what is your context ? if you use tomcat (not uncommon on this mailing list :)) you may use a servlet to enable your client to ask to do something on the web server filesystem... If you use SMB protocol (samba or windows sharing) you may look at the excellent jcifs smaba project (jcifs.samba.org) HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Installing tomcat 5 on BSD 5
Bad major version numbers are result of classes compiled on 2 different version of jdk. yes you're Please upgrade you jvm and then see if it helps (preferable jdk1.4 and up). humm I guess that freebsd doesn't have a 1.4 JVM yet... so I'll suggest to recompile Tomcat on your machine (using the complete package or CVS code) HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: POST method not working
Hi, hi abhay, I am suing post method of sending data to servlet from a JSP page. I am unable to get the data by request.getParameter(). If I am sing get method I am able to retrieve data from JSP page Please let me know how to achieve this ? And what is the bug ? you may use the nice Commons HTTP Client package from the jakarta project to achieve this safely easily Abhay HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Apache-Tomcat integration vs Direct Tomcat
Hi Everybody, We can deploy a web application directly into Tomcat and use itself as web server.In second case we can integrate Tomcat with any web server(Apache or Tomcat) using AJP connector. there are many others available using the in-process approach for exemple (tomcat becoming achild of the apache process) Which approach is best under which circumstances? for your 2 architectures you must just consider your requirements: - delivering static pages or just dynamic pages (servlets/JSP) - using complex HTTP handlings (proxies/url rewritings) or direct HTTP requests if you answer A) to both questions use an AJP connector (or at least A) to second question) if answer B) to both questions, use tomcat stand alone Can i get any documentation which contains comparison of both approaches ? humm I guess, that you can find numerous books dealing with such topic (wrox press professional tomcat e.g) HTH Jerome Thanks and Regards Gurlal Brar - 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: upgrading java version
Hello all, hi david... I looked through the list archives and the jakarta docs, but didn't find any info. What changes, if any, do i have to make to my tomcat configuration if i want to upgrade my java SDK. I would like to do this because of the verisign root certificate expiration. don't see any changes to these configurations... on Unix using the magical symbolic links, change the link, stop tomcat, restart that's it!!! beware not having done ugly libraries copying to the JRE/JDK libs folder... if you use it in the good way (not changing config or librairies) no stuff required...otheriwse beware of copying libs config files (orb.properties e.g) for a good application work... HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: dramatic performance differences on development machines
Hi Johan It's very suspicious that websphere runs so fast and tomcat doesn't. I think there still might be a network issue. Can you modify your server.xml as follows changing the enableLookups=false instead of enableLookups=true Connector port=80 minProcessors=5 maxProcessors=75 enableLookups=true . .. /Connector Maybe the reverse lookup is failing? totally agree with that :) the enableLookup is one parameter that should be chnaged to a default value to false in the server.xml!!! All my customers are using default config file I change this parameter in every config (no meaning for a production server to have such data) I guess that incoming requests could be traced in a very efficient way by any router or firewall (hardware or software as with a small linux box ) Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Differences between jServ and Tomcat
Jan Behrens wrote: Hi List, hi jan, I wonder whether anyone out there could give me some insight on the main differences between jServ and Tomcat. As far as I understand, jServ is a Servlet Engine to be included with an instance of Apache, whereas Tomcat of course can be used as a Standalone Server doing more than just handling jsp/servlet requests from a webserver. Is that about right? yes you 're right but JSERV is an old product no more maintained I think, it 's compliant with old servlets/JSP specs while tomcat is the first implementation for every new API (Tomcat 5 which is in beta stage implements sthe new servlet API 2.4) Jserv 'name is still present but in the name of the protocol AJP (apache to jserv protocol) HTH jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [offtopic] Architecture Question
Laurent Michenaud wrote: Hi, Hi laurent, We have two tomcat servers. One is located at our enterprise. The other is located at our hosting provider. They can see each other by Internet. We would like to set up an unique authentification system for both server. The authentification system will be on the server at our entreprise. The web applications on both servers will query the authentification system. What's the best/clean/nice way to do this ? JAAS ? Web services ? SSL keys ? JAAS is obviously a good way (the smartest one maybe ? :) ) But using the configuration file with the same authentication configuration could be enough... That is to say using Realm tags in your server.xml config files (JDBCRealm or JNDIREalm if you set up LDAP ) are valuable solutions HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TOMCAT 3.3 crash daily
Sarel Bester wrote: Hi all I have an app running on the following config: - Windows 2000 Advanced server (Dual PIII 1GHz CPU with 4GB RAM) - IIS 5 - Tomcat 3.3 (NOT 3.3.x) - ISAPI redirector 1.2 (size = 128K) - JDK 1.3.1_09 - Oracle 8.1.7 Tomcat is locking up almost everyday. Log files show a lot of bad DB connections that cannot be reset. The app that I deployed gets connected to by about 130 - 140 users at peak times (which doesn't really seem to be that much.). Some advice that I received (not in the Tocat user forum) is the following : A) Confirm that TC uses Server version of JVM. (I presume this is the jvm.dll in the JAVA_HOME\JRE\BIN\SERVER folder?) I found the following line in the workers.properties : worker.inprocess.jvm_lib=$(workers.java_home)$(ps)jre$(ps)bin$(ps)classic$(p s)jvm.dll I changed it to : worker.inprocess.jvm_lib=$(workers.java_home)$(ps)jre$(ps)bin$(ps)server$(ps )jvm.dll Is this the correct place to make TC 3.3 use Server version of JVM? oops, there's a more trivial way for getting the JVM use server option, that is to say give the -server option to the java program while invoking (see your scripts catalina.bat) B) Set memory parameters -Xms and - Xmx to allocate TC more memory. I am not sure where to do this . . .:-0 I have seen in this forum previously that someone said it must be specified in the start parameters in the General Tab screen of the Tomcat Service properties. Is it possible to specify these parameters in the wrapper.properties file (which seem to be used by the Tomcat service for startup)? What is the correct place to do this? Even registry perhaps . . . ? Is this exact syntax correct for the Windows OS? -Xms128 -Xmx1024 like for your first question this is not a directly related question about tomcat but a question regarding howto setup/tune options to your JVM java -help will give you any details... I am not very experienced in using Tomcat and is hesitant to Upgrade to, say , 4.1x. But if you reckon it maybe a better alternative, I will certainly consider. I can't recommand you enough to look for JVM configurations tricks to ask about changing your JVM. I think that BEA Jrockit or latest JVM from Sun could be good solutions... Note that with BEA JVM the -option is deprecated , so leaving the default parameter (jrockit) is a good choice HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.eyrolles.com/php.informatique/Ouvrages/ouvrage.php3?ouv_ean13=9782212111941 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Signal 11 causing Tomcat crash
Jim Goodspeed wrote: Really hoping that someone might be able to help us with this. We are experiencing Signal 11 crashes on our tomcat server. We have tried almost every configuration that I can think of and we are still getting these crashes at least once a week, sometimes twice a day. Unfortunately we can not reproduce this anywhere except production. Here is the current setup: RedHat AS 2.1 Kernel: 2.4.18-3smp Memory: 2.5GB JDK: IBM 1.4.1 Tomcat 4.1.29 We are using mod_jk to talk to the Apache server (2.0.x) and the native DB2 jdbc driver to talk to our DB2 databases. We have also tried Tomcat 4.0.6 and Sun's JDK v. 1.4.1_01 and 1.4.2 on RH 7.3. We are passing the following settings to the JVM: -Xms512m -Xmx1024m. We have also tried running this on three different boxes to try and isolate hardware failures, but all machines experience crashes in the same way. Thanks in advance for any help. Here is the beginning of the error (full file is too big): JVMDG217: Dump Handler is Processing a Signal - Please Wait. JVMDG303: JVM Requesting Java core file JVMDG308: Error writing Java core buffer to file: Permission denied NULL 0SECTION TITLE subcomponent dump routine NULL === 1TISIGINFO signal 11 received 1TIDATETIMEDate: 2003/11/12 at 08:19:26 1TIFILENAMEJavacore filename: /usr/local/tomcat/javacore.20031112.081926.15871.txt NULL 0SECTION XHPI subcomponent dump routine NULL == 1HPTIMEWed Nov 12 08:19:26 2003 1HPSIGRECV SIGSEGV received in ?? at 0x41cc8e85 in /opt/IBMJava2-141/jre/bin/libjitc.so. Processing terminated. 1HPFULLVERSION J2RE 1.4.1 IBM build cxia32141-20030522 NULL 1HPOPENV Operating Environment NULL - 2HPHOSTNAMEHost : a002.(none) 2HPOSLEVEL OS Level : 2.4.18-3smp.#1 SMP Thu Apr 18 07:27:31 EDT 2002 2HPLIBCVER glibc Version: 2.2.4 2HPCPUSProcessors - 3HPARCH Architecture : (not implemented) 3HPNUMCPUS How Many : (not implemented) 3HPCPUSENABLED Enabled : 4 NULL 1HPMEMINFO Memory Info NULL --- 2HPMEMLINE total:used:free: shared: buffers: cached: 2HPMEMLINE Mem: 2644201472 537800704 2106400768 0 143089664 120524800 2HPMEMLINE Swap: 20968570880 2096857088 2HPMEMLINE MemTotal: 2582228 kB 2HPMEMLINE MemFree: 2057032 kB 2HPMEMLINE MemShared: 0 kB 2HPMEMLINE Buffers:139736 kB 2HPMEMLINE Cached: 117700 kB 2HPMEMLINE SwapCached: 0 kB 2HPMEMLINE Active: 409700 kB 2HPMEMLINE Inact_dirty: 33040 kB 2HPMEMLINE Inact_clean: 6028 kB 2HPMEMLINE Inact_target:89752 kB 2HPMEMLINE HighTotal: 1703860 kB 2HPMEMLINE HighFree: 1393124 kB 2HPMEMLINE LowTotal: 878368 kB 2HPMEMLINE LowFree:663908 kB 2HPMEMLINE SwapTotal: 2047712 kB 2HPMEMLINE SwapFree: 2047712 kB 2HPMEMLINE Committed_AS: 349996 kB Hi Jim, sounds bad, signal 11 on Linux is a warm up for material problems!!! It could mean : - machine overclocking with CPU overheated (I guess that's not the case for a production machine :) ) - or bad memory - any other ugly hardware problem But I can't see any Tomcat incidence with such problems... It 's a hardware one... The first thing to do is to chek cup your memory with any MS DOS floppy disk containing Goldmemory or such tool... Sorry for my poor english written HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.editions-eyrolles.com/php.informatique/index.php3?xd=d12eccd83077cb3683315026cd3b7586 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Signal 11 causing Tomcat crash
Jim Goodspeed wrote: Unfortunately we have also tried Sun's JVM and are experiencing the same Signal 11 errors (I've included two snippets of the Sun error - same error as the IBM Sig 11, just in a different format). Sometimes the dump specifies the library in question, other times it does not. another hint: what about ULIMITS on your machine ? I guess that your Linux box uses a bash shell ? JDK 1.4 had clever bugs with ulimit settings, may be your release had such problems too... but please check memory , motherboard temperature so on... HTH Jerome -- Auteur cahier du programmeur Java tome 2 - Eyrolles 10/2003 http://www.editions-eyrolles.com/php.informatique/index.php3?xd=d12eccd83077cb3683315026cd3b7586 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How could I solve this error
Javier wrote: I tried to run my first servlet and got this error: Hi Javier, snip trace root cause java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet java.lang.ClassLoader.defineClass0(Native Method) java.lang.ClassLoader.defineClass(Unknown Source) java.security.SecureClassLoader.defineClass(Unknown Source) java.net.URLClassLoader.defineClass(Unknown Source) java.net.URLClassLoader.access$100(Unknown Source) java.net.URLClassLoader$1.run(Unknown Source) java.security.AccessController.doPrivileged(Native Method) java.net.URLClassLoader.findClass(Unknown Source) java.lang.ClassLoader.loadClass(Unknown Source) java.lang.ClassLoader.loadClass(Unknown Source) sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) java.lang.ClassLoader.loadClass(Unknown Source) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.ja va:1278) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.ja va:1212) java.lang.ClassLoader.loadClassInternal(Unknown Source) java.lang.ClassLoader.defineClass0(Native Method) java.lang.ClassLoader.defineClass(Unknown Source) java.security.SecureClassLoader.defineClass(Unknown Source) org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassL oader.java:1652) org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.ja va:883) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.ja va:1332) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.ja va:1212) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:16 4) org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:578) org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:209) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:781) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConn ection(Http11Protocol.java:549) org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:589) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.ja va:666) java.lang.Thread.run(Unknown Source) humm sounds strangewhat is the exact version of tomcat you use ? have you changed something in the scripts launching tomcat ? did you change packaging of tomcat ? or removed any library ? (.jar files) Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 3.3 performance issues
1) Try the IBM JVM (At least thats what many say with respect to linux) 2) http://jakarta.apache.org/tomcat/faq/unix.html#ps if license conditions are not too restrictive try to have a look to the Jrockit from BEA VMincredible fast...large spectra of options (garbage collection so on) have you tried to launch the catalina.sh script with JAVA_OPTS setted ? HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 3.3 performance issues
catalina.sh?? I'm using Tomcat 3.X not 4.X. nevermind, i forget the name of script for this version (run.sh or something like size) But, what do you mean? I set heap size... -Xmx with a corresponding -Xms (equal value is a good idea)... I've already tried IBM VM and the result is almost the same. Using JRockit? I never thought about. But this is a commercial product, right? right but license is not very restrictive (like IBM VM which is not Open Source project) Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: IIS/Tomcat tuning
Hello, Hi Jean rene, I would like to know your feeling about the IIS/Tomcat installation. We know that Apache/Tomcat works well but what can we say about IIS/Tomcat ? Is it reliable into production systems ? good question TROLL is IIS production ready /TROLL seems to be a troll but this is the main question... mod_jk is a very reliable connector AJP (3) is a good protocol... so your debts turn to have an answer for this TROLL:question don't have much experience with IIS... Tomcat (3.3 or 4.1.2x) are production ready releases... tuning can be made by several tricks: -config of tomcat - JVM - connectors for robustness constraints don't forget to use: load balancer facilities of the connectors clustering features of Tomcat 4.1 version (is it useful for you ?) If you could inform me about this question or send me some links. Thanks for your job. HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What LDAP servers does JNDI realm support? -
Davi Leal wrote: jerome moliere wrote: I am trying to authenticate my webapps via a JNDI Realm, which connects to Microsoft Site Server (LDAP). :( As I am getting [LDAP: error code 2 - Protocol Error] (See below), I would like to know if that Micro$oft product is a certified LDAP server. as fai as i Know, like any other microsoft product, partially... :) I have been told the LDAP protocol is no-100% a standard. That is to say, a lot of providers have realized different offers, which share only 90% of the specification (the core standard). Nowdays, it is said, the Netscape's one being the more recognised/compatible/ standard. So, my question is now: What LDAP products does the JNDI Tomcat realm support? No problem with OpenLDAP ('from my experience), NDS or Sun implementations seem to work nicely. For microsoft active directory is quite a LDAP server, but you can't use the referral paradigm HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: MultipartRequest class with Tomcat 3.2.1
Fausto Zorzi wrote: Hi, I have a problem using the com.oreilly.servlet.MultipartRequest class by Jason Hunter (documentation at http://www.servlets.com/cos/index.html) with Tomcat 3.2.1 and Apache 1.3.20. The configuration I'm using is the following: - RedHat 7.3 - JDK 1.4.1_01 - Apache 1.3.20 - Tomcat 3.2.1 - Servlet 2.3 Hi fausto, excuse me but are you sure you use the servlet 2.3 API with the old ( good) Tomcat 3.2.1 ? I guess it's a typo because I used this release 4 years ago(3.2) No, Tomcat 3.2 is not a servlet 2.3 compliant engine... So you may use older releases from the Jason Hunter code (compliant with your Tomcat release) or upgrade your tomcat ... HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Clustering Tomcat - Loadbalancing and Failover
Hanasaki JiJi wrote: Hello, What is available, in Tomcat, or as an add-on, and preferably free/open-source to cluster tomcat for: load balancing fail over humm filip hanik could answer with more details (or remy maucherat) but as far as I know new Tomcat 5 code (backported to 4.1) use the Javagroups library for replication mechanism. For tomcat 4.1, adding jars (javagroups + patch) is enough to add theses features... For tomcat 5, nothing needed because it's one of the new features... how are session states replicated? It's one of the limits of this system, because every put made, induces replication for the entire object using broadcast (by default). So heavy traffic... Also, in general, and a bit off-topic (my apologies), are there any resources for the design, or open source implementation, of load balancing / fail-over frameworks? javagroups :) google may point you to the current address !!! I think that this porject recently joined the JBOSS project Thanks Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What LDAP servers does JNDI realm support? -
Equipment Lamp wrote: Hi Can youguys give some input on the following. I am using the following Tomcat: 4.1.27-LE-jdk14 Apache: 2.0.47 Java : 1.4.2 Linux OS: 7.3 iPlanet LDAP Server I am trying to configure LDAP authentication mechanism to my application. 1) In this regard i have downloaded the latest JNDI API and then copied the ldap.jar file to $CATALINA_HOME/server/lib directory. 2) The i have added the following entry to the server.xml file. Realm className=org.apache.catalina.realm.JNDIRealm connectionURL=ldap://ldap.mycompany.com:389; userBase=ou=active,ou=employees,ou=people,o=mycompany.com userSearch=(uid={0}) roleSearch=(uniqueMember={0}) roleName=cn debug=99 contextFactory=com.sun.jndi.ldap.LdapCtxFactory / 3) In my application web.xml file i have added the following security-constraint web-resource-collection web-resource-nameNrt/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-name*/role-name /auth-constraint /security-constraint login-config auth-methodBASIC/auth-method realm-nameCEC/realm-name /login-config But authentication is not working, any debug techniques or methods will be a great help. have you any log entries or anything helpful ? classnotfound exception or something like this woulmd be great (easy to fix) Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk2 connector config to connect to multiple tomcat-jboss instances
Boulatian, Misak wrote: Hi Jeromy, Hi misak, I am sorry. I thought my attachments made to the list. Here I am including them directly here. Please look at it and let me know if I have done anything wrong. When I point my browser to the link: http://[web-server-ip]/test1 it works. When I point my browser to the link: http://[web-server-ip]/test2 I get the following tomcat blue screen: HTTP Status 500 - No Context configured to process this request type Status report message No Context configured to process this request description The server encountered an internal error (No Context configured to process this request) that prevented it from fulfilling this request. And mapping error config logs go to the jboss's first instance's server.log. in fact what is your aim ? do you want to be able to switch from T1 to T2 or T3 for one request to the next one ? because this is what i suggested while deploying a load balancer Do you your 3 instances behave exctly from the same manner or do you want to deploy different web-apps on these 3 tomcat instances ? Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JNDI: LDAP Protocol Error (Microsoft LDAP)
David Diaz wrote: Hi all, hi david, I am trying to authenticate my webapps via a JNDI Realm, which connects to Microsoft Site Server (LDAP). :( As I am getting [LDAP: error code 2 - Protocol Error] (See below), I would like to know if that Micro$oft product is a certified LDAP server. as fai as i Know, like any other microsoft product, partially... :) If it is not so, do you advise me any solution to manage autenticating these webapps via JNDI-Microsoft Site Server?. Maybe develop a special Realm?. humm I think you may investigate any other class used in your factory I think that the ContextFactory class is not the right one ... I think you use the one for the Netscape Directory Server HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How can I configure multiple tomcat instances in workers2.properties file (separate web apps) (to developers of mod_jk2: please respond)
Boulatian, Misak wrote: Hi all, It seems like mod_jk2 is a buggy connector. There is no way to set up more than one instance of tomcat. It can connect on any port other than 8009 but it is a first-come first-served basis (whichever port comes first). I need a response from mod_jk2 developers themselves. Should I go back to mod_jk or there is a way of doing this simple thing??? take it easy man :) small question : what about using different virtual hosts in your apache config, then from these contexts , using different config files for mod_jk which will be very simple (you have already validated one of your tomcat instances) my 2 cents Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk2 connector config to connect to multiple tomcat-jboss instances
Boulatian, Misak wrote: Hi, I am trying to setup jk2 connector on a single apache instance to connect to multiple jboss instances running on the same machine using jboss-port-bindings.xml. Based on jboss-port-bindings.xml I have three instances having the following ports for jk2 connector: 8009, 8109, 8209. In the workers2.properties, I've created appropriate mappings (I am including as an attachment). The problem is: jk2 connects to only one port: whichever comes first. I am not able to connect on more than one ports. I am also including my jboss-port-bindings.xml file which is referenced through jboss-service.xml to allow multiple instances to run (which is successful). version of jboss: jboss-3.2.1_tomcat-4.1.24 version of apache: 2.0.45 version of java: 1.4.1_03 hi misak, do you use any load balancing mechnaism (round robin) to balance around your different ports ? to setup such thing in JK2 you should define your 3 tomcat instances (in fact jboss bundle with different port numbers) then adding one other which is the load balancer... HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk2 connector config to connect to multiple tomcat-jboss instances
Boulatian, Misak wrote: Hi Jerome, hi misak, do you use any load balancing mechnaism (round robin) to balance around your different ports ? to setup such thing in JK2 you should define your 3 tomcat instances (in fact jboss bundle with different port numbers) then adding one other which is the load balancer... Thanks for responding. At this point I am not using load-balancing. Please look at my workers2.properties file. sorry but can't find any properties file (removed by mailman program ? or mozilla 'bug ?) The jboss-port-bindings.xml does configure three jboss-tomcat bundles with different ajp ports. All of them work. correct The problem is jk2 only connects to the port which is specified first in the workers2.properties file. For the others I get tomcat error message: undefined context. how do you obtain this message ? any logs or test procedure welcomed Do I need to define load-balancing in order to make it work? yes if you want to let apache choose the port for you then stick to the session (keeping the same server after any session opening) Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Load balancing with 2xTC5, 1xIIS and jk2
Mats Andersson wrote: How do I define two workers for load balancing in workers2.properties? There is an example for the old jk, but I can't find any for jk2. Hi mats, i'm sure that the idea is the same define 1 worker for your first TC5 1 worker for the second TC5 1 worker as the load balancer then you can define weights for respecting differences of power for the 2 machines... HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Authentication strategies
Hi all, I'd like to authenticate users on a LDAP tree (using something like the JNDIRealm) that's OK But I'd like not to have the post 401 browser POPup window but a custom form (with links for retrieving its password some other gadgets) I guess that this is not a very uncommon thing ? So i wondered about setting up a filter ,getting the Authentication header comparing it with the values BASIC ... (constants exist) Is it the classic way for such job ? any other clue welcomed Cheers jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How deploy EJB on Tomcat?
Igor Grygorov wrote: Hi Igor Does the Tomcat-IIS support deploing Enterprise Java Beans? No, sorry Can you send me information or links about it, please? No :) have a look to any EJb container : JONAS or JBOSS could be reasonable choices My 2 pieces jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Sundararaman] [Help me]
Christopher Williams wrote: I would strongly advise against using the Swing timer object. Try using a java.util.Timer object instead. I use this in a servlet to perform automatic daily backups and other automated tasks. christopher is right you should not use SWING objetcts in your J2EE environement... a google search can point you to different projects with CRON implementations in Java my 2 pieces Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Unable to obtain a module (.so) for JK2 on Linux (RH9)
Eric J. Pinnell wrote: Hi, thanks eric, JK2 should compile with just the following: ./configure --with-apxs2=/path/to/apache/bin/apxs make yes ,it should . but I still can't have this fu... module compiled It should create mod_jk2.so in the build directory tree not in the directory that you ran configure and make from. I forget exactly where it puts it but a find ./ | grep so from the top level of the source should root it out quick fast. yes the location is ../build/jk2/apache2 but allways empty for me (no .so at all) the find keeps returning nothing for my .so can't spent much time for this problem so I'll use mod_proxy instead Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Unable to obtain a module (.so) for JK2 on Linux (RH9)
Hi all, i'm not sure that's the right place for such question but I'm unable for 2 days to get the compilation goes to end Everything seems to work but I don't have any so file generated... I'm using a configure with options: ./configure --with-tomcat40=/usr/local/tomcat/ --with-tomcat41=/usr/local/tomcat/ --with-tomcat40=/usr/local/tomcat/ --with-apxs2=/usr/local/apache2/bin/apxs --with-apr=/usr/local/apr-0.9.3 --with-apache2=/usr/local/httpd where /usr/local/apache2 contains binaries for apache (apxs2) /usr/local/httpd contains src files for apache I'm using the JK 2.0.2 files Apache 2.0.47 on redhat 9 (with GCC 2.96 or 3.2.2) any help greatly appreciated drives me crazy :) cheers Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk load balancing with multiple apache servers
Peter Anning wrote: Hi, I am trying to implement the following configuration: +++ Cisco Load Balancer +++ | | (http) | +++ Apache AApache B Apache Cluster Layer mod_jk mod_jk +++ | | (ajp13) | +++ TomcatI.myhost.com TomcatII.myhost.comJBoss Cluster Layer +++ I can configure mod_jk in each of the Apache instances to know about the two tomcat instances. So loadbalancing and failover would work with one instance of apache. Is there any way to have the Apache ``cluster'' layer know about other ``members'' in the layer and the current servlet connection status? Rgds Peter Hi peter, i'm in a context near from yours my opinion is that it isn't very logic because you introduce abstraction layers (like in a OO environment) getting knowledge from implementations (other tomcats from your second Apache server) will break those abstractions Moreover I think you could encounter network security problems with such things isn't it ? my 2 pieces... Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
mod_jk2 LVS load balancing
Hi all, I'm about deploying a web-app in a multi-layered netword, with LVS clustering Does someone has some significant experience in such context ? problems or any other feedback greatly appreciated Cheers jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Library management for Tomcat using ant
[EMAIL PROTECTED] wrote: Hi there, I know this is more a question about ant, but maybe a tomcat user here has faced the same issue as I do when using a central lib directory for all of the JAR files in the various webapps: In the prepare task I copy the JAR files I need for my webapp into the WEB-INF/lib folder in the build path: === copy todir=${build.home}/WEB-INF/lib fileset dir=${lib.home} include name=cos.jar / include name=cos2.jar / /fileset /copy = However, this library listing is the only thing which distinguishes the various build.xml files for my different webapps. I'd prefer to have only ONE build.xml file for all of my webapps so they all have the same structure. How can I import a fileset like above from a separate filename? (so I can have *) ONE build.xml for all of my webapps and *) a specific lib.xml for each of my webapps? thx alot Johannes Hi Johannes, why not coding your own task ? reading a single filename then copying files is an easy task to be coded in Java isn't it ? HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Listing all JNDI resources available
[EMAIL PROTECTED] wrote: Hi there, Is it somehow possible to look up all JNDI configuration values available in a servlet/context? This would be quite fine for debugging purposes, and it seems there is no function available for this, only for looking up a specific value. depending from your server config the corresponding xsource of data used as the naming server, this solution could be very expansive What about listing all resources available in your company LDAP server ? I think that every other solution should be preferred to this one... HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Http Session Replication : State of the Art
Hi all, searching through the archives of this mailing list, like using our friend google, point me to a single web page (article on theServerSide.com) and this solution is not part from the Jakarta project (uses Javagroups + add-on library with a custom Context Manager InSessionreplicationManager). I know that session replication induces a high load for J2EE servers but it's a customer requirement :) I found a product (commercial) aiming to deliver such feature to different J2EE servers (Weblogic,tomcat,jonas) My question is :what is the tomcat team position for this feature ? Who has put such solution in place ? Who can support such solution ? Sorry for this question (already asked) but with few answers (old ones moreover) Thanks for all help, clue or pointer Cheers Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Http Session Replication : State of the Art
Roberts, Eric wrote: Try http://www.filip.net/tomcat-clustering.html i know this site but google ignored this page ? it uses the same component than the one I tried... Session replication is a standard feature of Tomcat 5. Oho nice news!!! I will download install the pre release soon... Thanks for your help Eric Cheers Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with Session Clustering
Filip Hanik wrote: Looks like you got some funky shit going on, yes it seems :) listener local:tcp://localhost:4001 are you running your cluster on one or two machines? for tests ,just on one machine... if it works I will bench with 2 machines... can you send your server.xml files yep :) a little bit LONG sorry: Server port=9005 shutdown=SHUTDOWN debug=0 !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- Define a non-SSL HTTP/1.1 Connector on port 8080 -- Connector className=org.apache.catalina.connector.http.HttpConnector port=8090 minProcessors=5 maxProcessors=75 enableLookups=true redirectPort=8443 acceptCount=10 debug=0 connectionTimeout=6/ !-- Note : To disable connection timeouts, set connectionTimeout value to -1 -- !-- Define an AJP 1.3 Connector on port 8009 -- Connector className=org.apache.ajp.tomcat4.Ajp13Connector port=9009 minProcessors=5 maxProcessors=75 acceptCount=10 debug=0/ !-- Define the top level container in our container hierarchy -- Engine name=Standalone defaultHost=localhost debug=0 !-- Global logger unless overridden at lower levels -- Logger className=org.apache.catalina.logger.FileLogger prefix=catalina_log. suffix=.txt timestamp=true/ !-- Because this Realm is here, an instance will be shared globally -- Realm className=org.apache.catalina.realm.MemoryRealm / !-- Define the default virtual host -- Host name=localhost debug=0 appBase=webapps unpackWARs=true Valve className=org.apache.catalina.valves.AccessLogValve directory=logs prefix=localhost_access_log. suffix=.txt pattern=common/ Logger className=org.apache.catalina.logger.FileLogger directory=logs prefix=localhost_log. suffix=.txt timestamp=true/ !-- Tomcat Root Context -- !-- Context path= docBase=ROOT debug=0/ -- !-- Tomcat Manager Context -- Context path=/manager docBase=manager debug=0 privileged=true/ !-- Tomcat Examples Context -- Context path=/examples docBase=examples debug=0 reloadable=true crossContext=true Logger className=org.apache.catalina.logger.FileLogger prefix=localhost_examples_log. suffix=.txt timestamp=true/ Ejb name=ejb/EmplRecord type=Entity home=com.wombat.empl.EmployeeRecordHome remote=com.wombat.empl.EmployeeRecord/ Valve className=org.apache.catalina.session.ReplicationValve filter=.*\.gif;.*\.jpg;.*\.jpeg;.*\.js debug=0/ Manager className=org.apache.catalina.session.InMemoryReplicationManager debug=10 printToScreen=true saveOnRestart=false pathname=null printSessionInfo=true checkInterval=10 expireSessionsOnShutdown=false maxActiveSessions=-1 minIdleSwap=-1 maxIdleSwap=-1 maxIdleBackup=-1 serviceclass=org.apache.catalina.cluster.mcast.McastService mcastAddr=228.1.2.3 mcastPort=45566 mcastFrequency=500 mcastDropTime=5000 tcpListenAddress=localhost tcpListenPort=4002 tcpThreadCount=2 useDirtyFlag=true /Manager Environment name=maxExemptions type=java.lang.Integer value=15/ Parameter name=context.param.name value=context.param.value override=false/ Resource name=jdbc/EmployeeAppDb auth=SERVLET type=javax.sql.DataSource/ ResourceParams name=jdbc/EmployeeAppDb parameternameuser/namevaluesa/value/parameter parameternamepassword/namevalue/value/parameter parameternamedriverClassName/name valueorg.hsql.jdbcDriver/value/parameter parameternamedriverName/name valuejdbc:HypersonicSQL:database/value/parameter /ResourceParams Resource name=mail/Session auth=Container type=javax.mail.Session/ ResourceParams name=mail/Session parameter namemail.smtp.host/name valuelocalhost/value /parameter /ResourceParams /Context /Host /Engine /Service !-- Define an Apache-Connector Service -- Service name=Tomcat-Apache Connector className=org.apache.catalina.connector.warp.WarpConnector port=9008 minProcessors=5 maxProcessors=75 enableLookups=true appBase=webapps acceptCount=10 debug=0/ !-- Replace localhost with what your Apache ServerName is set to -- Engine
Re: APPLET using Text File
Alberto A C A S Magalhães wrote: ** Este email assim como os ficheiros que possa ter em anexo são confidenciais e para uso exclusivo da pessoa ou organização para o qual foi enviado. Se recebeu este email por engano por favor notifique [EMAIL PROTECTED] Esta nota confirma que esta mensagem foi verificada pelo MIMEsweeper não tendo sido encontrados virus. www.mimesweeper.com *** Hi, I am using TOMCAT in a Linux Machine, i have to develop a Applet, that have to access to a text file in the Linux Machine. why not ? any servlet should access to the desired file (if permissions are OK ) then send its contents to the client... It's one of the multiple usage of servlets...Give a partial access to the server filesystem for the client.. So it's up to you to code this servlet to stock your file on a convenient directory... H.T.H Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: best practices on rotating tomcat logs
I am wondering if this is pretty much what other people do and if there is a better way of doing it. i just found that apache can rotate its logs with its bin/rotatelogs where you can specify the rotation interval. does tomcat have a similar functionality? i searched for rotate in Tomcat's source and found the AccessLogValve class which could be i want, but i need help figuring it out. in fact Tomcat knows nothing about how its logs are managed... it just outputs logs which are treated by log4j using the common logging API so you can use the log4j feature for having your log files rotating.. Use a RollingFileAppender in the log4j properties file... HTH Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Monitoring Tomcat
At 12:18 PM 4/11/2002 +0200, you wrote: Hello, I made a search in the Tomcat User List Archive but for each message asking for some monitoring function in Tomcat, I didn't find any answer... Indeed, I would need a way to know about threads' managing I'm unsure of truly understanding your question but I can advise you to read about the servlets life cycle (in the servlets specification or in any valuable resource as the book from Jason Hunter O'Reilly editions). and what happens to received requests (are some of them delayed or even dropped ?), you can use a dummy filter (if you use the 2.3 servlets API aka Tomcat 4 -catalina) which logs any filter, adds trace for incoming request, responses... in order to tune up my configuration and to prevent any crash. that is the point where I can't see any links with your question!!! H.T.H Jerome -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Filter - Tomcat 4.01 Post methods
Hi all, I'm using filters in Tomcat 4.01 (bundled with Jboss 2.4.4) for a while, I just faced a problem with filters applied on servlets using POST requests. All other filters applied on servlets invoking GET methods work fine, but a working filter (with some other servlets) while applied to a servlet with a POST method just not work. It dumps an IOException: this inputstream has already been closed. This exception is raised from the org.apache.catalina.connector.RequestStream like the following trace says: at org.apache.catalina.connector.http.HttpRequestStream.read(HttpRequestStream.java:196) at com.viveo.defmod.server.web.servlets.defmodobjecthandling.DefmodObjectHandling.doPost(DefmodObjectHandling.java:136) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at com.viveo.mistral.server.actions.MistralActionsFilter.doFilter(MistralActionsFilter.java:90) Removing the filter , this servlet works fine, the client invokation works nicelly. So have you any idea about this problem ? cheers Jerome -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]