mass virtual hosting with rewrite

2005-09-02 Thread Oleg
I am running Apache 2 with Tomcat 5.5. Both are working fine and hosting 
about 200 domain names. The problem is that every time a new domain is added 
I have to edit server.xml file and restart tomcat. With Apache I am using 
RewriteMap files so I just edit those files and no need to restart it. I 
wanted to run it by you guys and see if anyone tried using Rewrite to avoid 
setting up virtual hosts in Tomcat server.xml file. Basically have Rewrite 
conditions in Apache say

user1.com http://user1.com rewrite to localhost/user1
user25.com http://user25.com rewrite to localhost/user25

This way Tomcat doesn't have to be setup with all those virtual domain 
names.
Any idea how to do it? Of course I would not want the URL to change in the 
browser address bar so the rewrite would have to be internal only.

What do you think?

Thanks
Oleg


Re: mass virtual hosting with rewrite

2005-09-02 Thread Oleg
I am not running Tomcat and Apache ont he same port, I have never tried 
doing that. I suggest you start a separate post, maybe someone will be able 
to help you.

Thanks,
Oleg

On 9/2/05, jmail [EMAIL PROTECTED] wrote:
 
 Adn howy did you do that? I've got a problem. I can't use tomcat and 
 Apache on the same port. :/ But I need to do this like that:
 
 somone make a question to my host and i would like that on this qusetion 
 my server shoul decide if thats for him or for Tomcat :/ How can I do this?
 
 thanks for any reply
 
 jmail
 
  Wiadomość Oryginalna 
 Od: Oleg [EMAIL PROTECTED]
 Do: Tomcat Users List tomcat-user@jakarta.apache.org
 Data: Fri, 2 Sep 2005 11:18:50 -0700
 Temat: mass virtual hosting with rewrite
 
  I am running Apache 2 with Tomcat 5.5. Both are working fine and hosting
  about 200 domain names. The problem is that every time a new domain is 
 added
  I have to edit server.xml file and restart tomcat. With Apache I am 
 using
  RewriteMap files so I just edit those files and no need to restart it. I
  wanted to run it by you guys and see if anyone tried using Rewrite to 
 avoid
  setting up virtual hosts in Tomcat server.xml file. Basically have 
 Rewrite
  conditions in Apache sayquot;
 
  user1.com http://user1.com lt;a href=http://user1.comgt;; 
 target='_blank'http://user1.comgt;/a rewrite to localhost/user1
  user25.com http://user25.com lt;a href=http://user25.comgt;; 
 target='_blank'http://user25.comgt;/a rewrite to localhost/user25
 
  This way Tomcat doesn't have to be setup with all those virtual domain
  names.
  Any idea how to do it? Of course I would not want the URL to change in 
 the
  browser address bar so the rewrite would have to be internal only.
 
  What do you think?
 
  Thanks
  Oleg
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 



Re: Calculating required memory

2005-08-18 Thread Oleg
Thank you very much for your input gentlemen. Increasing PermGen is a great 
idea, because I do see my server giving me out of memory permgen error at 
least twice a day and now it makes sense why, I was thinking my -Xmx 
settings 1024m should take care of my needs for now and that was wrong, I 
set MaxPermSize=256m and the server seem to be fine for now, keeping my 
fingers crossed. 
 Now regarding shared/lib directory I thought that every application loads 
its own copy of those libraries, but if its only one time load and since all 
my applications are identical copies (only data changes) I might as well 
move all my classes into shared, before I only had struts, hibernate jars 
and so on That wouldnt create any thread safety issues would it? Thanks 
again for your time, this helps a lot!
 Oleg

 On 8/17/05, Peter Crowther [EMAIL PROTECTED] wrote: 
 
  From: Oleg [mailto:[EMAIL PROTECTED]
  I am trying to approximate the amount of memory my server
  will need running
  tomcat. I understand that a lot depends on how the appication handles
  resources, however at this point I am trying to figure out
  what will be the
  mimimum needed. In my case I have virtual hosting setup, with
  all hosts
  sharing the same libraries, so I have struts, hibernate,...
  all sitting in
  shared/lib directory of Tomcat. Would I be correct to
  estimate that Tomcat
  will atleast need
 
  n(number of users/applications) * mb(total size of shared/lib)
 
 As Chuck has already pointed out, no (but I'm going to try a slightly
 different angle on it :-) ). Each class that is loaded from shared/lib
 will be loaded by the Shared classloader, so you'll only have one copy
 of the class in your JVM. Jars are compressed, so the sizes of the
 loaded classes will be larger than the bytes occupied on disk; but not
 all of the classes from a jar will be loaded, so the sizes will probably
 be smaller. Note, however, that any classes in the webapp's WEB-INF/lib
 *will* be loaded once per webapp. If you have large numbers of
 applications, you may want to put more common libraries in shared/lib,
 and you may also wish to increase the size of the permanent generation
 (PermGen) in the JVM's memory model as this is where the classes are
 stored.
 
 Your per-session and per-page data will dwarf the space required for
 classes; and, as Chuck pointed out, the only way to find out these sizes
 is to profile the app. This will also make sure that you're not going
 to fall foul of any other performance limits, such as CPU use or disk
 bandwidth.
 
 - Peter
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 



Calculating required memory

2005-08-16 Thread Oleg
Hi,

I am trying to approximate the amount of memory my server will need running 
tomcat. I understand that a lot depends on how the appication handles 
resources, however at this point I am trying to figure out what will be the 
mimimum needed. In my case I have virtual hosting setup, with all hosts 
sharing the same libraries, so I have struts, hibernate,... all sitting in 
shared/lib directory of Tomcat. Would I be correct to estimate that Tomcat 
will atleast need

n(number of users/applications) * mb(total size of shared/lib)

I hope I am wrong because my shared is about 8MB, so to have 300 identical 
application deployed, I will need at least 2.4GB and than some

Could some one please explain how it actually works?

Thanks
Oleg


Re: virtual host memory usage

2005-08-15 Thread Oleg
Oh I see, well actually what I do, since all users with virtual hosts 
running identical applications, I place all application related libraries in 
shared/lib and WEB-INF/lib has only one jar which is application itself and 
its not in shared or common, common/lib only has Tomcat5 libraries plus 
database driver jar since I am using JNDI. Does that sound about right?

Thanks
Oleg

On 8/15/05, George Sexton [EMAIL PROTECTED] wrote:
 
 You are correct. My suggestion was that you in one case had a file in the
 common/lib directory, while in another you had it in the WEB-INF/lib
 directory.
 
 George Sexton
 MH Software, Inc.
 http://www.mhsoftware.com/
 Voice: 303 438 9585
 
 
  -Original Message-
  From: Oleg [mailto:[EMAIL PROTECTED]
  Sent: Sunday, August 14, 2005 7:39 PM
  To: Tomcat Users List
  Subject: Re: virtual host memory usage
 
  I am sorry, what do you mean by host class loader? From what
  I understand
  there are 3 ways to load classes, /common/lib (used by
  tomcat), shared/lib
  (used by all applications), webapp/web-inf/lib used by this
  one application.
  Thank you
  Oleg
 
  On 8/13/05, George Sexton [EMAIL PROTECTED] wrote:
  
   The obvious first guess is that you have a class that is in the host
   classloader, and not the common classloader, and that class
  is consuming
   large amounts of memory.
  
  
  
   George Sexton
   MH Software, Inc.
   http://www.mhsoftware.com/
   Voice: 303 438 9585
  
  
-Original Message-
From: Oleg [mailto:[EMAIL PROTECTED]
Sent: Saturday, August 13, 2005 11:20 AM
To: Tomcat Users List
Subject: virtual host memory usage
   
Why running 100 virutal hosts in Tomcat takes up much more
memory than
running a 100 identical applications under one host? Is there
a way to
configure Tomcat to run both the same?
   
Thank you
Oleg
   
  
  
  
  -
   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 host memory usage

2005-08-14 Thread Oleg
I am sorry, what do you mean by host class loader? From what I understand 
there are 3 ways to load classes, /common/lib (used by tomcat), shared/lib 
(used by all applications), webapp/web-inf/lib used by this one application.
 Thank you
Oleg

 On 8/13/05, George Sexton [EMAIL PROTECTED] wrote: 
 
 The obvious first guess is that you have a class that is in the host
 classloader, and not the common classloader, and that class is consuming
 large amounts of memory.
 
 
 
 George Sexton
 MH Software, Inc.
 http://www.mhsoftware.com/
 Voice: 303 438 9585
 
 
  -Original Message-
  From: Oleg [mailto:[EMAIL PROTECTED]
  Sent: Saturday, August 13, 2005 11:20 AM
  To: Tomcat Users List
  Subject: virtual host memory usage
 
  Why running 100 virutal hosts in Tomcat takes up much more
  memory than
  running a 100 identical applications under one host? Is there
  a way to
  configure Tomcat to run both the same?
 
  Thank you
  Oleg
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 



virtual host memory usage

2005-08-13 Thread Oleg
Why running 100 virutal hosts in Tomcat takes up much more memory than 
running a 100 identical applications under one host? Is there a way to 
configure Tomcat to run both the same?

Thank you
Oleg


Virtual hosts and shared libraries

2005-07-22 Thread Oleg
I got a problem with Tomcat using a huge amount of memory on startup. Of 
course I realize that it all depends on how large are the applications. 
However, I have lets say two identical machines with Tomcat 5.5 installed. 
One Tomcat has 100 virtual hosts running the same application and takes up 
400MB of ram after it finished loading, second Tomcat has 300 identical 
applications but deployed under localhost and it uses only 200MB of ram 
after loading. Can somebody explain me what is the case here? Does it mean 
that virtual hosts load all libraries in shared directory for every host 
into memory but all application running under localhost, simply load them 
once? I am a bit lost, I need to figure something out to cut down on memory 
use, any ideas? All users are running same application, application specific 
classes are in its own application WEB-INF/classes and all libraries needed 
to run the application, like struts and hibernate and so on are in shared. 
Thank you.


multiple contexts

2005-05-17 Thread Oleg
Hi,

I am running Tomcat 5.0.28. Our setup is somewhat similar to Virtual
hosting company. When a new user signs up, user's site is accessible
through localhost.com/user1 and after user registers the domain name
site is also available through user1.com.

My problem is that it seem to be double the load, each application is
deployed twice.

1. Application is deployed by adding a user1.xml file to
conf/Catalina/localhost for localhost.com/user1

2. Application is deployed for domain name bu adding user1.xml to
conf/Catalina/localhost.com/ and making appropriate changes to
server.xml file for a virtual host

Is there a better way to do it? to allow user access to a website both
ways but having the application deploy only once and somehow having
pointers to it?

Thank you for the help
Oleg

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Re: out of memory when there is plenty

2005-02-22 Thread Oleg
Any tips on optimizing usage of Virtual Hosts, I narrowed down the
problem a bit. I can have 500 users running without any memory
problems on the server if I set them all up under localhost/userXXX
but as soon as I start assigning virtual hosts to each user, I crash
at about a 100. Same problem 1GB ram avaiable but server crashes at
like 350MB, any ideas?

Thanks
Oleg


On Sun, 20 Feb 2005 0:02:48 -0500, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
 JProfiler is best in case of Tomcat.
 Shakeel.
 
  From: Oleg [EMAIL PROTECTED]
  Date: 2005/02/19 Sat PM 06:15:10 EST
  To: Tomcat Users List tomcat-user@jakarta.apache.org
  Subject: Re: out of memory when there is plenty
 
  Hey guys, thanks for response.
  Yes JVM is 1.4.2_06
  So it can be pretty much anything not just the memory, alright that
  makes perfect sense, but creates a bigger problem, how do I find out
  now whats wrong. Will memory profiling help? JProbe or Optimizeit I
  think  those are the only two I keep on hearing about.
 
  Thansk
  Oleg
 
 
  On Sat, 19 Feb 2005 08:38:34 -0600, Caldarale, Charles R
  [EMAIL PROTECTED] wrote:
From: Oleg [mailto:[EMAIL PROTECTED]
Subject: out of memory when there is plenty
   
My question is what can cause Tomcat to report out of memory error
when so much is still available.
  
   As has been discussed before on this mailing list, the OutOfMemory 
   exception is somewhat of a catch-all.  The JVM generates this exception 
   not just for overflowing heap space, but also pretty much anytime limits 
   imposed by the underlying OS are reached.  These limits include such 
   things as stack space, open files, and number of threads.
  
   You didn't mention the JVM version you're using (this is often critical), 
   but a 1.4 and above JVM can run out of space in the Permanent Generation 
   portion of the heap, even though there's plenty of room available in the 
   other portions.  This occurs more frequently in multiple classloader 
   environments such as Tomcat, and, again, has been discussed in some 
   detail on this mailing list.
  
   - 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]
 
 
 
 -
 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: moving all classes to shared

2005-02-21 Thread Oleg
Well regarding #1 from what I understand the class in webapp web-inf
will take priority, however, I can see how #2 can be a problem, but,
does it only work one way? Meaning a class in sared/classes will not
see webapp/web-inf/classes, so down the hierarchy, however, it will
work just fine going up, so class in webapp will see classes in
shared?

Thank you
Oleg 

On Mon, 21 Feb 2005 10:54:45 -0600, QM [EMAIL PROTECTED] wrote:
 On Sat, Feb 19, 2005 at 06:38:03PM -0800, Oleg wrote:
 : If I have 200 users deployed on tomcat with 99% using identical
 : classes, would it be ok to move all classes to shared/classes
 : directory? Will that give better memory usage? Also, can I later add
 : the classes that are different directly to WEB-INF/classes and will
 : they be given priority?
 
 You've already received answers to the other points, so I'll address
 just the last question:
 
it depends
 
 With hierarchical classloaders, you can get yourself into a right snit
 when 1/ there's version skew between the per-webapp class and the one in
 shared/lib; and 2/ when a class in shared/lib depends on a class that's
 in the per-webapp area (that is, it can't see a dependent class because
 it's out of the scope of the current classloader).
 
 IIRC, both result in NoClassDefFoundError, and both can be a mess to
 sort out if you don't know in advance where to start looking.
 
 -QM
 
 --
 
 software  -- http://www.brandxdev.net
 tech news -- http://www.RoarNetworX.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: moving all classes to shared

2005-02-21 Thread Oleg
Hmm, quick question, do you know of a reason why this ould not work
for Struts, I did it and for some reason I get an error

org.apache.struts.action.RequestProcessor - ERROR - No action instance
for path /selectTiles could be created

this class was moved to shared.

Thansk,
Oleg

On Mon, 21 Feb 2005 14:39:52 -0600, QM [EMAIL PROTECTED] wrote:
 On Mon, Feb 21, 2005 at 11:21:01AM -0800, Oleg wrote:
 : Well regarding #1 from what I understand the class in webapp web-inf
 : will take priority, however, I can see how #2 can be a problem, but,
 : does it only work one way? Meaning a class in sared/classes will not
 : see webapp/web-inf/classes, so down the hierarchy, however, it will
 : work just fine going up, so class in webapp will see classes in
 : shared?
 
 Correct -- the per-webapp classloader is the child of the shared/lib
 classloader.  (This is an oversimplification but please bear with me.)
 
 Really, there are more than two classloaders involved, forming several
 parent/child relationships in a hierarchy...
 
 Try to think of it as the GoF Chain of Responsiblity pattern: when the
 per-webapp classloader can't find a class, it delegates (passes the
 request) to its parent.  This keeps going until you hit a classloader
 that can successfully load the class, or until the innermost classloader
 -- which doesn't delegate to anyone else -- gives up and says there's no
 such class.
 
 Going the other way thus isn't possible: that innermost (parent)
 classloader can't see what its children see, and so on. If a class
 under shared/lib needs access to (depends on) a class in a child
 classloader, it will never find it, and the system throws a
 NoClassDefFoundError.
 
 It's for a similar reason one webapp can't see another webapp's classes:
 they only have a relationship with their parent classloader, and not
 that of their siblings.
 
 -QM
 
 -
 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]



out of memory when there is plenty

2005-02-19 Thread Oleg
Windows 2003
Tomcat 5.0.28

Ok I searched and searched endless and still cannot  understand what
the problem in my case. Ok, I understand that there can be a leak in
teh code and thats why Tomcat runs out of memory. However, the server
got total 2GB Ram memory, Tomcat is set to use min 512, max 1024. When
I start getting an out of memory error, Tomcat5 in task manager shows
anywhere 350MB to 390MB, I run a script on the server to check Runtime
and it shows that memeory usage is very low compared to max/min
settings and there are about 600MB available.

My question is what can cause Tomcat to report out of memory error
when so much is still available.

Thank you
Oleg

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: out of memory when there is plenty

2005-02-19 Thread Oleg
Hey guys, thanks for response.
Yes JVM is 1.4.2_06
So it can be pretty much anything not just the memory, alright that
makes perfect sense, but creates a bigger problem, how do I find out
now whats wrong. Will memory profiling help? JProbe or Optimizeit I
think  those are the only two I keep on hearing about.

Thansk
Oleg


On Sat, 19 Feb 2005 08:38:34 -0600, Caldarale, Charles R
[EMAIL PROTECTED] wrote:
  From: Oleg [mailto:[EMAIL PROTECTED]
  Subject: out of memory when there is plenty
 
  My question is what can cause Tomcat to report out of memory error
  when so much is still available.
 
 As has been discussed before on this mailing list, the OutOfMemory exception 
 is somewhat of a catch-all.  The JVM generates this exception not just for 
 overflowing heap space, but also pretty much anytime limits imposed by the 
 underlying OS are reached.  These limits include such things as stack space, 
 open files, and number of threads.
 
 You didn't mention the JVM version you're using (this is often critical), but 
 a 1.4 and above JVM can run out of space in the Permanent Generation portion 
 of the heap, even though there's plenty of room available in the other 
 portions.  This occurs more frequently in multiple classloader environments 
 such as Tomcat, and, again, has been discussed in some detail on this mailing 
 list.
 
 - 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: out of memory when there is plenty

2005-02-19 Thread Oleg
The out of memory errors all look like:

2005-02-17 14:55:48 StandardWrapperValve[jsp]: Servlet.service() for
servlet jsp threw exception
java.lang.OutOfMemoryError

or

2005-02-17 15:10:33 ApplicationDispatcher[/myuserapp1]
Servlet.service() for servlet jsp threw exception
java.lang.OutOfMemoryError


Any ideas?

On Sat, 19 Feb 2005 17:41:56 -0600, Caldarale, Charles R
[EMAIL PROTECTED] wrote:
  From: Oleg [mailto:[EMAIL PROTECTED]
  Subject: Re: out of memory when there is plenty
 
  how do I find out now whats wrong.
 
 Try specifying -verbose:gc on the command line; this will at least tell you 
 whether or not it is a heap memory problem.  Also, look at the stack trace 
 from the exception and see if it's related to some request for system 
 services (e.g., thread creation).
 
 If you really are running out of memory, then a profiler will help you 
 determine what's eating it up.
 
 - 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]



moving all classes to shared

2005-02-19 Thread Oleg
If I have 200 users deployed on tomcat with 99% using identical
classes, would it be ok to move all classes to shared/classes
directory? Will that give better memory usage? Also, can I later add
the classes that are different directly to WEB-INF/classes and will
they be given priority?

Thank you
Oleg

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



dynamic server.xml

2005-02-16 Thread Oleg
I know question was asked many times and I have read a lot of posts
people asking how to add a virtual host without restarting tomcat and
the answer, not possible.

So I am wondering, is it because its time expencive that tomcat doesnt
check virtual hosts names real time, or atleast refreshes the list
stored in memory. I am sure this is an ignorant question because I
dont know the first thing about Tomcat architecture, just thought you
folks can shed some light on this for me.

Thank you.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTMLArea v. fckeditor

2005-02-16 Thread Oleg
Isnt HTMLArea IE only? I used FCKeditor for about a year, love it.
After much searching, I think it is the best.


On Fri, 11 Feb 2005 11:28:25 -0800, David Wall [EMAIL PROTECTED] wrote:
  See http://www.fckeditor.net/
 
 Aside from the odd name (we do have to give credit after all!), that does 
 look like a nice one.  Has anybody used it enough to know how stable it is?  
 I noted that it's on 2.0, which is good, but it's not considered final.  I 
 like that it appears to be a bit more active than HTMLArea.
 
 David


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



url case sensitive

2005-02-08 Thread Oleg
I am running Windows2003, IIS6, Tomcat 5.0.28 connected through JSPISAPI.
The problem is only for Mac IE users when domain name (virtual) is
typed in using caps. For example www.mydomain.com works just fine, but
www.MyDomain.com is going to a site on the same server that is setup
as localhost path=.

I have endlessly searched for answers on past posts but couldnt come
up with anything. I dont think it has to do with IIS or JSPISAPI
connecter because going to MyDomain.com:8080 (Tomcat port) does the
same thing. And, again, this is only for Mac IE users. Any browser on
Windows has no problems, as well as Mozilla on Linux, Safari on Mac. I
Am really lost here, any ideas?

Thanks,
Oleg

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: outOfMemory exception under high load

2005-02-08 Thread Oleg
Just a thought, I was having the same problem using JNDI for database
connection. Our database pool was going crazy due to a lot of
connections left unterminated and database memory usage was enormous.
Restarting Tomcat would only help for a day or two and than
OutOfMemory errors would come up again. Restarting the database, gave
us several weeks until the error started coming up again once the
memory used by database grew. Thinking that it had something to do
with the memory it took to maintain the pool.

Oleg


On Mon, 7 Feb 2005 23:02:36 -0600, Caldarale, Charles R
[EMAIL PROTECTED] wrote:
  From: Dale, Matt [mailto:[EMAIL PROTECTED]
  Subject: RE: outOfMemory exception under high load
 
  It could be your permanent generation that is running out of
  space. Get a hold of jvmstat to determine if this is the case.
 
 Another possibility is that you're exceeding your limit on the number of open 
 files.  Exceeding any underlying OS limit is usually translated to an 
 OutOfMemory exception by the JVM.
 
 - Chuck
 
 THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY 
 MATERIAL and is thus for use only by the intended recipient. If you received 
 this in error, please contact the sender and delete the e-mail and its 
 attachments from all computers.
 
 -
 To 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 and apache+mod_jk on different servers - another story

2004-01-21 Thread Oleg Letsinsky
Hi,

I've read a lot of tomcat and apache+mod_jk howto's and threads, but so
far found nothing which would help me to find a solution to my problem.

All solutions I've seen include apache, handling static pages and usual
apache stuff + machine with tomcat, handling JSP's and servlets. Is it
possible to store JSP's on the server where apache is running? It's just
a matter of convenience - it would be nice to upload the whole site with
JSPs and have it running without remembering that you should upload all
JSPs to some special place on a second server. Am I dreaming? :-) Is it
possible at all? Thanks.

-- 
  May the bluebird of happiness twiddle your bits.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tomcat 5.0.4 fails to serve form-login-error page properly

2003-07-24 Thread Oleg S. Estehin
Hi

I am porting my application from Tomcat 4.1.24 to Tomcat 5.0.4 (i.e. porting
from Servlets 2.3/JSP 1.2 to Servlets 2.4/JSP 2.0).

I have a servlet mapped to /auth that produces the page with login form.
Form based authentication is set with the following fragment of the
deployment descriptor:

login-config
  auth-methodFORM/auth-method
  form-login-config
form-login-page/auth/form-login-page
form-error-page/auth?action=error/form-error-page
  /form-login-config
/login-config

When the servlet is called with ?action=error query string it displays
additional warning besides the login form.

It was working perfectly in Tomcat 4.1.24 but it works in Tomcat 5.0.4 only
in half:

When user tries to access protected page he is presented with login page. If
he enters valid login/password then he receives access to the resourse.

But if the user enters invalid login/password then instead of
form-error-page Tomcat displays HTTP Status 405 - HTTP method POST is not
supported by this URL error with URL http://myhost.here/j_security_check;.


I have tried to set up AccessLogValve and RequestDumpValve and to set debug
attribute on every element in servlet.xml and my context.xml (where
applicable) in order to try to understand what is going on inside Tomcat 5,
but no luck so far - request damp just shows that 1) there was request to
protected resourse 2) Tomcat returned form-login-page 3) user sent it back
with invalid login/password 4) Tomcat returned error 405.

I had expected that there should be output from Realm between 3) and 4) but
there is not.

So, at the moment the conclusion is that the code that worked perfectly in
Tomcat 4.1.24 doesn't work in Tomcat 5.0.4 and i don't know why but i would
be delighted if somebody will help me to find this out :)


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tomcat 5.0.4 fails to serve form-login-error page properly

2003-07-23 Thread Oleg S. Estehin
Hi

I am porting my application from Tomcat 4.1.24 to Tomcat 5.0.4 (i.e. porting
from Servlets 2.3/JSP 1.2 to Servlets 2.4/JSP 2.0).

I have a servlet mapped to /auth that produces the page with login form.
Form based authentication is set with the following fragment of the
deployment descriptor:

login-config
  auth-methodFORM/auth-method
  form-login-config
form-login-page/auth/form-login-page
form-error-page/auth?action=error/form-error-page
  /form-login-config
/login-config

When the servlet is called with ?action=error query string it displays
additional warning besides the login form.

It was working perfectly in Tomcat 4.1.24 but it works in Tomcat 5.0.4 only
in half:

When user tries to access protected page he is presented with login page. If
he enters valid login/password then he receives access to the resourse.

But if the user enters invalid login/password then instead of
form-error-page Tomcat displays HTTP Status 405 - HTTP method POST is not
supported by this URL error with URL http://myhost.here/j_security_check;.


I have tried to set up AccessLogValve and RequestDumpValve and to set debug
attribute on every element in servlet.xml and my context.xml (where
applicable) in order to try to understand what is going on inside Tomcat 5,
but no luck so far - request damp just shows that 1) there was request to
protected resourse 2) Tomcat returned form-login-page 3) user sent it back
with invalid login/password 4) Tomcat returned error 405.

I had expected that there should be output from Realm between 3) and 4) but
there is not.

So, at the moment the conclusion is that the code that worked perfectly in
Tomcat 4.1.24 doesn't work in Tomcat 5.0.4 and i don't know why but i would
be delighted if somebody will help me to find this out :)


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Please help save Tomcat for a high profile project in Switzerland: Problem compiling mod_webapp for IBM HTTP Server 1.9.19 running on AIX 4.3.3.

2001-11-17 Thread Oleg

My insufficient knowledge of AIX platforms prevents me from successfully 
compiling mod_webapp (as well mod_jk) on AIX 4.3.3 platform.
Hardware: IBM pSeries 660 model 6H1
OS: AIX 4.3.3 (not sure about exact maintenance level)
Web server: IBM HTTP Server 1.3.19
Servlet Engine: Tomcat 4.0.1
Tools  libraries: IBM's port of common GNU  other open-source packages 
available at
http://www-1.ibm.com/servers/aix/products/aixos/linux/download.html

Tomcat itself appears to be running flawlessly. Unfortunately due to my 
poor knowledge of AIX I have been so far unable to recompile neither 
mod_webapp nor mod_jk for the specified platform. Actually compilation 
worked fine in both cases. What did fail was the 'ld' linker. As far as 
I can judge about possible cause of failure, the linker requires a 
module export (.exp) file in order to be able successfully complete 
linking process. In this respect AIX appears to differ from Unixes, as I 
had no problems at all building mod_webapp  mod_jk under Linux 
(Mandrake 8.0  Mandrake 8.1) as well as Solaris 8. The problem is 
aggravated by the management's desire to use IBM HTTP Server instead of 
plain Apache mainly due to IBM's SSL support, which is perceived to be 
more secure.

Is my assumption right? If yes, is there a way I could generate that 
damn .exp file for mod_webapp or somehow do without it? Has anyone ever 
succeeded in compiling mod_webapp for IBM HTTP Server on AIX 4.3.3?

I have been informed by the management that if problem is not resolved 
by mid next week Tomcat will be replaced with WebSphere 3.5 Standard 
Edition. :(((

Please help save Tomcat for the project. Our work is highly visible. The 
system will serve population of an entire Swiss canton. If successful 
the system may be adopted by other cantons with Tomcat prominently 
featured alongside some leading commercial products.

Many thanks in advance

Oleg Kalnichevski


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




xtp in Tomcat

2001-05-24 Thread Oleg Okhotnikov

Hello!

Is anybody have HOWTO for using xsl stylesheets for jsp output in Tomcat?
I think about something like xtp in Resin.

Oleg.



Re: about the IIS (in win2000 professtional version) and tomcat installing

2001-03-19 Thread Oleg L. Sverdlov



Hello Mermaid,

Yes, it can work with Win2K Pro. 

1) Install location of ISAPIfilter DLL in 
registry in the following place: HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\W3SVC\Parameters\

FilterDLL=d:\jakarta-tomcat-3.2.1\bin\win32\isapi_redirect.dll

2) create virtual dir. "jakata" - point 
it to the same place.

3) restart IIS 



Oleg L. SverdlovWeb Development Dept.

Netmount Networks Raanana, Israel. 

http://www.netmount.comPhone: 
+972-9-745-5220Fax: +972-9-745-2521

  - Original Message - 
  From: 
  mermaid 
  
  To: [EMAIL PROTECTED] 
  Sent: Monday, February 12, 2001 1:38 
  PM
  Subject: about the IIS (in win2000 
  professtional version) and tomcat installing
  
  Dear Sir,
  
   I try to use to install the tomcat3.2.1 into win2000 
  Prof. IIS, but fail to do this.
   Thedocument I follow is 
  doc\tomcat-iis-howto.html.
   Could you tell me kindly that tomcat could execute in 
  2000 Professional?
   Thank you.
  
  Ms. Huang
  PS. BTW, I can runtomcat in 2000 server IIS, not 2000 
  Professional IIS.


Re: Stuck Combining Servlets and JavaScript

2001-03-13 Thread Oleg L. Sverdlov


- Original Message - 
Frank, I can think of conventional techniques:

1) add new Javascript section:

script language="javascript" src="/servlet/generatearray"/script

generatearray.class must produce MIME type for Javascript.

2) if the main file is HTML, try to use SHTML:

script language="javascript"
!--#include virtual="/servlet/generatearraydefinition" --
for(var k=0;ktitle.length;++k) document.write("p"+title[k]);
/script

actual syntax of the include depends on your webserver.

and so on...




From: "Frank Morton" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, March 13, 2001 12:25 AM
Subject: Stuck Combining Servlets and JavaScript


 I have a servlet that can generate JavaScript arrays. I want to
 combine those arrays with html/javascript for final presentation.
 One of the catches is that the servlet uses an HttpSession to
 keep track of what has happened.
 
 So, say I have an html file containing this (less headers):
 
 script language="javascript"
 booktitle = new Array("title1","title2","title3","title4");
 for(var k=0;ktitle.length;++k) document.write("p"+title[k]);
 /script
 
 So, I want the servlet to generate the second line of the script.





 
 Frank
 


Oleg L. Sverdlov
Web Development Dept.

Netmount Networks 
Raanana, Israel. 

http://www.netmount.com
Phone: +972-9-745-5220
Fax: +972-9-745-2521




Re: memory and/or ms problem

2001-03-01 Thread Oleg L. Sverdlov

I have the same problem too. I use Windows 2000 Server, Tomcat 3.2.1 and 
isapi_connect.dll

I've already asked this question on the list, and nobody seems to know.

Oleg L. Sverdlov
Web Development Dept.

Netmount Networks 
Raanana, Israel. 

http://www.netmount.com
Phone: +972-9-745-5220
Fax: +972-9-745-2521

- Original Message - 
From: "Gerd Trautner" [EMAIL PROTECTED]
To: "tomcat-user" [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 1:16 PM
Subject: memory and/or ms problem


 Hi tomcat-users,
 
 I am having some memory related troubles with my servlets running on
 tomcat 3.2.1 on an win nt 4 workstation machine.
 I read all previous messages in the list with the term "memory" in it,
 but everything i try does not help.
 
 problem: the memory consumption of the java.exe increases slightly, the
 over all memory consumption of the system increases fast and memory is
 not released. after a week (and about 400 hits or so) the server runs
 out of memory (tomcat gives a OutOfMemoryError and quits).
 
 what i did:
 - set java max heap size (nothing changed)
 - set max_threads (30), max_spare_threads(20) and min_spare_threads(5)
   for both http and https ConnectionHandler
 - set session-timeout to 1 Minute
 - added System.gc() to end of every servlet
 
 my application uses servlets and mysql, i close every mysql connection
 and i am not able to find anything i could change to get the memory
 freed.
 
 I also use ms-stresstool and i can simulate this memory-problem.
 
 could anyone give me some assistance please?
 
 thanks,
 Gerd




Q: logging requests to servlet?

2001-03-01 Thread Oleg L. Sverdlov



Hello.

When using ISAPI redirector for Tomcat, all 
requests to servlets are written in IIS log file as
"... GET /jakarta/isapi_connect.dll ..." 
.

How to configure tomcat to see servlet name and 
parameters passed?


Thanks.

Oleg L. SverdlovWeb Development 
Dept.

Netmount Networks Raanana, Israel. 


http://www.netmount.comPhone: 
+972-9-745-5220Fax: +972-9-745-2521


Re: Installing Tomcat to run as an IIS-ISAPI filter on Win2000.

2001-02-21 Thread Oleg L. Sverdlov

Hello,

All the documentation you need to install  ISAPI redirector for Tomcat is contained in 

tomcat-iis-howto. I used that manual when installing T.


- Original Message - 
From: "Tomer Cohen" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, February 21, 2001 12:00 PM
Subject: Installing Tomcat to run as an IIS-ISAPI filter on Win2000.


 Hi,
 
 I'm Tomer Cohen, from Exent Technologies Ltd. 
 
 We are currently looking for a Servlets/JSPs engine to run as an ISAPI
 filter/redirector on Win2k IIS's web server.
 I'd highly appreciate if you could send me the URL where information is
 available for installing and running Tomcat on this configuration/platform.
 Moreover, any further tips regarding this usage would be very welcome.
 
 
 Thank you in advance,
 
 Tomer Cohen.
 
 __
 
 Tomer Cohen
 RD, Exent Technologies Ltd.
 E-Mail: [EMAIL PROTECTED]
 Phone no.: 03-9243935 ext.153
 Mobile: 058-316566
 __
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 
 


Oleg L. Sverdlov
Web Development Dept.

Netmount Networks 
Raanana, Israel. 

http://www.netmount.com
Phone: +972-9-745-5220
Fax: +972-9-745-2521




[Windows 2000] Is that Tomcat eating memory ?

2001-02-07 Thread Oleg L. Sverdlov

Hello.
The machine runs Tomcat 3.2.1 + jdk 1.3 + iis_redirect + Win2K Professional

Every time a browser reloads a page, "Java" process eats out a few bytes of memory.
Simple hello.jsp consumes a few bytes. Pages dealing with Java beans or db 
connections, consume more memory.

On Win2K Server,  I can see that memory pool of "Java" process does NOT grow, whereas 
"inetinfo" process eats out a few bytes of memory with every request.

In the same time, iis_redirect.log contains following entries:

[jk_isapi_plugin.c (261)]: jk_ws_service_t::start_response, ServerSupportFunction 
failed
[jk_ajp13_worker.c (314)]: Error ajp13_process_callback - start_response failed
[jk_isapi_plugin.c (554)]: HttpExtensionProc error, service() failed
[jk_isapi_plugin.c (355)]: jk_ws_service_t::write, WriteClient failed
[jk_ajp13_worker.c (325)]: Error ajp13_process_callback - write failed
[jk_isapi_plugin.c (554)]: HttpExtensionProc error, service() failed

Anybody know anything about this problem? 

Oleg L. Sverdlov
Web Development Dept.

Netmount Networks 
Raanana, Israel. 

http://www.netmount.com
Phone: +972-9-745-5220
Fax: +972-9-745-2521

- Original Message - 
From: "John Golubenko" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, February 06, 2001 12:15 AM
Subject: Re: Connection pooling - simplified?


 Well, creating a JavaBean, with DatabaseManager class, and load 
 DatabaseManager and that
 JavaBean class on startup. (web.xml file), you can put all connectivity 
 to DatabaseManager
 class, make up a doInsert(), doUpdate(), getValue() methods in it, with 
 empty query.
 Once those puppies are loaded, them will be up all the time. Next thing 
 is to refer from JSP pages to those poppies, such as getValue(email), and 
 dbmanager will return it... 
 Now you can have them available to whole site, w/o reloading or 
 overloading your server.
 got the point? 
 
 
  Original Message 
 
 On 2/5/01, 2:03:48 PM, "John Coonrod" [EMAIL PROTECTED] wrote regarding 
 Connection pooling - simplified?:
 
 
  Perhaps there is a way to do this very simply.
 
  I have only one database, and so little traffic that one connection is 
 all
  my webserver needs.
 
  I presume there might then be a way to establish a connection when 
 jakarta
  starts up, that is available to any jsp that wants it? Sort of a globally
  available connection? Could someone walk me through doing this?
 
  (Meanwhile - I've ordered the book from Amazon. Thanks.)
 
  Thanks.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, email: [EMAIL PROTECTED]
 
 NOTICE:  This communication may contain confidential or other privileged 
information.  If you are not the intended recipient, or believe that you have 
received this communication in error, please do not print, copy, retransmit, 
disseminate, or otherwise use the information.  Also, please indicate to the sender 
that you have received this email in error, and delete the copy you received.  Any 
communication that does not relate to official Columbia business is that of the 
sender and is neither given nor endorsed by Columbia.  Thank you.
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 
 



JSP 404 error with TOMCAT standalone

2001-01-23 Thread Oleg Timofeyev

Hello, I need a little help here please. I just installed TOMCAT and use it  
as standalone. Problem is that examples of Servlets work fine but when I try 
example of JSP it gives me:

Not Found (404)Original request: /examples/jsp/sessions/carts.jsp
Not found request: /examples/jsp/sessions/carts.jsp

Linux
JDK 1.3
all .jsp file are present in the directory
my server.xml has
---
Context path="/examples"
 docBase="webapps/examples"
 crossContext="false"
 debug="0"
 reloadable="true" 
/Context   
  . 
   Host name="127.0.0.1" 
   Context path=""
docBase="webapps/ROOT" /
   Context path="/examples"
    docBase="webapps/examples" /
/Host   



-- 
-- 
Oleg Timofeyev
ReadySetNet
[EMAIL PROTECTED]
http://www.readysetnet.com
Phone : 323 469 2000
Fax : 323 469 2155

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: JSP 404 error with TOMCAT standalone

2001-01-23 Thread Oleg Timofeyev

Perfect, you absolutelly right, ROOT and path tools.jar took care of the 
problem :)
Thank you very much.

-- 
-- 
Oleg Timofeyev
ReadySetNet
[EMAIL PROTECTED]
http://www.readysetnet.com
Phone : 323 469 2000
Fax : 323 469 2155

On Tuesday 23 January 2001 18:16, you wrote:
 Oleg Timofeyev wrote:
  Hello, I need a little help here please. I just installed TOMCAT and use
  it as standalone. Problem is that examples of Servlets work fine but when
  I try example of JSP it gives me:
 
  Not Found (404)Original request: /examples/jsp/sessions/carts.jsp
  Not found request: /examples/jsp/sessions/carts.jsp
 
  Linux
  JDK 1.3
  all .jsp file are present in the directory
  my server.xml has
  ---
  Context path="/examples"
   docBase="webapps/examples"
   crossContext="false"
   debug="0"
   reloadable="true" 
  /Context
.
 Host name="127.0.0.1" 
 Context path=""
  docBase="webapps/ROOT" /
 Context path="/examples"
  docBase="webapps/examples" /
  /Host
  
 
  --
  --
  Oleg Timofeyev
  ReadySetNet
  [EMAIL PROTECTED]
  http://www.readysetnet.com
  Phone : 323 469 2000
  Fax : 323 469 2155
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, email: [EMAIL PROTECTED]

 Oleg,

 Are you starting Tomcat as nobody or root?
 When I re-start Tomcat as root my problem disappear.
 Also if tools.jar is not in the path you will get an error when you attempt
 to run *jsp file.


 Good Luck


 Anthony Scott


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]