Re: Multiple IIS sites and ISAPI redirect problem

2008-10-24 Thread Gabe Wong

Mikko,
Please elaborate what you mean by doesn't work? Errors or IIS 404 or 
Tomcat Errors?
Multiple sites - is it multiple Tomcat instances or 1 Tomcat instance 
with multiple apps?


Mikko Pukki wrote:

Hi,

I have Tomcat installed on a server that already has Default Website 
configured for other use and I cannot use
it to redirect to Tomcat. So I created another website that should listen to 
port 80 and authenticate users via AD authentication.
After authentication it should redirect requests to Tomcat. Previously I have 
done such installations with one difference.
I have been able to use Default Website and  generally there have been little 
or no problems.

However with this installation it doesn't work. System is Windows Server 2003, 
IIS version is 6, tomcat version is 5.5.16,
ISAPI redirect version is 1.2.26. I did not use compatibility mode for IIS 5 
and first I got 404 (or maybe 403 or something)
from IIS, but I figured out that it was because of rights to read and execute 
dll. I corrected them and now IIS returns
internal server error. Both Tomcat and ISAPI redirect filter start ok. Filter 
has a green arrow in front of it and I can use
web application directly from port 8080.

All that appears on ISAPI redirctor's log on debug level is as follows:

[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_util.c (430): 
Pre-processed log time stamp format is '[%a %b %d %H:%M:%S.000 %Y] '
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_shm.c (169): Initialized 
shared memory size=28800 free=28672 addr=0x1eb
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1688): 
Using registry.
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1691): 
Using log file C:\foo\Tomcat\isapi\log\isapi_redirect.log.
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1692): 
Using log level 1.
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1693): 
Using extension uri /jakarta/isapi_redirect.dll.
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1694): 
Using worker file C:\foo\Tomcat\conf\workers.properties.minimal.
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1695): 
Using worker mount file C:\foo\Tomcat\conf\uriworkermap.properties.
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1697): 
Using rewrite rule file .
[Tue Oct 07 15:45:52.843 2008] [6728:6948] [debug] jk_isapi_plugin.c (1699): 
Using uri select 3.


So it starts ok? At lest it shows that keys in registery are correct; right 
property files are found and debug level is on. Should I see some more output 
here?
For example GET messages? Anyway that's all that filter outputs.

Content of workers.properties.minimal:

worker.list=wlb,jkstatus
worker.ajp13w.type=ajp13
worker.ajp13w.host=localhost
worker.ajp13w.port=8009

worker.wlb.type=lb
worker.wlb.balance_workers=ajp13w

worker.jkstatus.type=status

Content of uriworkermap.properties:

/*=wlb
/jkmanager=jkstatus



Same configuration files have previously (and still do) worked well with othes 
servers, so I have no reason to doubt that they are to blame.
Any idea what would be causing the behavior? Is the Isapi Filter supposed to be 
cinfigured for a spesific website if I do have multiple
websites? Or should it be configured for upper level (WebSites), or is this 
kind of configuration supposed to work in the first place?
I quess that IIS finds the filter ok, because first when rights for filter were 
incorrect, I got different error message than now. Any Ideas?


Best Regards,

Mikko Pukki

  



--
Regards

Gabe Wong
NGASI AppServer Manager
APPLICATION AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! APPLICATION LOAD-BALANCING NOW MADE EASY


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: tomcat6 + proxy issues

2008-10-02 Thread Gabe Wong
I would seldom dare to differ with Mark with regards to Tomcat issues 
but in this case, I prefer mod_AJP for its more
predictive behavior compared to mod_HTTP. Tomcat AJP's connector 
simulates almost the same behavior as Tomcat's HTTP connector.
So the all important request headers will look the same. Some of the 
differences in behavior when you use Tomcat HTTP as a proxy instead of AJP:
1)remoteAddr resolves to whatever host Apache connects from to Tomcat. 
So you have to retrieve the actual remote address from the raw headers.

2)scheme will always be HTTP
3)serverPort will always be the Tomcat HTTP port (so you would need to 
edit server.xml and add the proxyport value)
4)many applications construct links from the above  headers mentioned 
and you can see  the problems  the inconsistent behavior creates.


Unless  mod_proxy_ajp is  far inferior to mod_proxy_http in terms of 
stability (which has not been noticeable from my experience),

I would choose mod_proxy_ajp for the consistent behavior it provides.

Mark Thomas wrote:

Markus Schönhaber wrote:
  

Mark Thomas:



Actually, mod_proxy_http is usually a better choice than mod_proxy_ajp
  

Could you please explain a little further?
Since at one site I'm using mod_proxy_ajp I'm interested in what the
advantage of switching to mod_proxy_http might be.



Generally, and YMMV, mod_proxy_http is more stable. This is only a
generalisation though. I have used mod_proxy_ajp in the past without any
problems.

Other reasons include:
- you can use https for encryption
- it is easier (at least I find it easier) to read http in wireshark than ajp

Mark



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: tomcat6 + proxy issues

2008-10-01 Thread Gabe Wong

Jeff try:

ProxyPass /app1 http://localhost:8080/app1
ProxyPassReverse /app1 http://localhost:8080/app1


and better yet if your have mod_proxy_ajp:
ProxyPass /app1 ajp://localhost:8009/app1
ProxyPassReverse /app1 ajp://localhost:8009/app1



Jeff D wrote:

Hi All,

I'm having some issues with some apps I am running on my server. I'm
running multiple apps in tomcat and serving up each of them through
apache with mod_proxy.  Most of these are working great, but there are a
few that don't seem to want to co-operate.  I currently have my proxies set
up in this manner:

ProxyPass / http://localhost:8080/app1/
ProxyPassReverse / http://localhost:8080/app1/

The problem seems to happen during POSTs , it seems to put /app1/ into the
POST. For example, if I go to http://app1host/login , the post to the
login becomes http://app1host/app1/login .  If I do the same on
http://localhost:8080/app1/login , all works fine.

I've also tried adding to the server.xml:
Connector port=8081 proxyPort=80 proxyName=app1host /

But, that ends up sending me in redirect loops.

Anyone have any idea on how to solve this?

thanks
Jeff


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: redirector

2008-09-30 Thread Gabe Wong

Frank Uccello wrote:
Tomcat redirector for iss not working 


I can http://localhost:8080/app/servlet but not
http://localhost/app/servlet --  error page could not be found

I have no errors in the event viewer or tomcat logs
  

Is /app included in the uriworkermap.properties.
Also in the redirector directory, there should be a logs sub directory. 
Anything written there?

Also with version IIS and Windows?


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat outputs php to stderr

2008-09-29 Thread Gabe Wong

Hi Serge,
Besides using PHP/Apache, the next best thing is Quercus. More info 
could be found here:

http://quercus.caucho.com/
Regards
Serge Fonville wrote:

Hi,
I am developing a ticket system which should use servlets to connect to the
various resources.
Currently I am a php developer and busy to learn JSP/TLD/Servlets
I installed Tomcat 6.0.18 with PHP 5.2.6 on Windows Vista Business (the
production server will be running either Gentoo or CentOS).

Installation went fine, no errors. just one thing I couldn't resolve.
All output generated by php goes directly to the stderr log file instead of
the browser (JSP and servlets work fine)

I used
http://blog.taragana.com/index.php/archive/running-php-5x-on-windows-using-tomcat-4x-or-5x/
 and http://wiki.apache.org/tomcat/UsingPhp to configure the two.

I started reading about listeners, log4j and servlet mappings.
This seemed over the top to me, so I decided to just ask the  question here.

Any help is greatly appreciated

  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 5.5 war takes 4 to 7 minutes to deploy

2008-09-27 Thread Gabe Wong
Sure sounds like it. Exactly what your are lacking may be listed in the 
last column of the following command

cat /proc/user_beancounters
You may also want to ask your provider Say how many other accounts are 
sharing the server with me?


G Kontos wrote:

Hi Gabe, Thanks for the reply.  The application does live on a VPS -
Virtuozzo VPS.  The server has a total of 432 MB of memory, 90MB initial
Heap size for tomcat, 180MB max heap size.  The numbers for actual CPU speed
or my piece of that speed aren't published, but my current usage of the CPU
has been between 2% and 18% this morning.

In reference to disk io - We use the same VPS at work, and the applications
deploy much faster.  Outside of my anecdotal support of the VPS, I don't
know how I would get hard numbers for the disk io.  Of course, at work we
use way more memory.

Do you think I cut the resources a little too thin?

Thanks again.  - Greg

  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 5.5 war takes 4 to 7 minutes to deploy

2008-09-26 Thread Gabe Wong
 at classpath resource
INFO   | jvm 1| 2008/09/26 00:13:42 | Sep 26, 2008 4:13:42 AM
org.apache.catalina.startup.Catalina start
INFO   | jvm 1| 2008/09/26 00:13:42 | INFO: Server startup in 453702 ms


Thanks for your help.

  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Patch Management

2008-09-12 Thread Gabe Wong

Mark Thomas wrote:

Anand Gundanna wrote:
  

Dear Support,

I would request for your help in regards to Tomcat Patch Management. I 
hope you will be helpful in this regard. 

We have installed and configured an Tomcat web server on windows server 
platform for an application called Business Objects XI. Tomcat web servers 
will not be supported/maintained by our web services team as it is non 
strategic within our organisation. But still we have hosted the Tomcat 
servers as it is mandated by Business Objects application. 

Now the Tomcat Web server has been successfully installed and configured. 
We need to plan for Patch management for Tomcat. At the moment we do not 
have any external/third party tool to manage the patches automatically. 
So, could you please clarify the following queries..


1) What is the best procedure/practice to keep Tomcat up-to-date with 
patches?



There are no patches, only full releases.

  
2) How frequently does Tomcat releases patches/updates and how critical it 
is for an internal application?



~3 per year. How critical is your call. If it ain't broke...

  
3) Does Tomcat have any built in tool/feature to download and update 
patches automatically?



Nope.

  
Please let me know if you know any other easy option/solution for Tomcat 
Patch Management.



There are commercial support provides that will provide simpler patch
management options.
  
Or safer bet, depending on how well the application is designed (and how 
critical it is)...
install a  staging server with the new Tomcat release, and copy the 
application over and test.

I do not know of any 100% proof patch/upgrade for any software.

Mark



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: I WANT Tomcat to die when a given servlet fails to initialize

2008-08-22 Thread Gabe Wong
If possible, you may consider a monitor or cron in a separate process. 
It checks the state of the servlet by making
a HTTP GET to it; depending on response, it  could initiate the 
SHUTDOWN  command to Tomcat.



COHEN, STEVEN M (ATTSI) wrote:

Yeah, that was what I thought.  Apps aren't supposed to do that.  But in my
case where there is a one-to-one between Tomcat and my app, it's okay.  In
fact, I also need to launch Tomcat with a special script that sets a number
of parameters required by my app, because the one of the systems I'm
depending on requires it to be just 
so.  This whole contraption has a real Rube Goldberg feel to it, but dang,

it works just fine with System.exit(0).  Oh well, as they say, rules were
meant to be broken.

Steve
-Original Message-
From: Len Popp [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 22, 2008 2:46 PM

To: Tomcat Users List
Subject: Re: I WANT Tomcat to die when a given servlet fails to initialize

There isn't a clean way for webapps to shut down the server because they're
not really supposed to do that. :-)

If you thrown an UnavailableException from a servlet's init method, that
servlet won't run.
If you do app initialization in a ServletContextListener and throw an
exception from the contextInitialized method, the webapp won't run.
But in both these cases the Tomcat server keeps running.
--
Len



On Fri, Aug 22, 2008 at 15:08, COHEN, STEVEN M (ATTSI) [EMAIL PROTECTED]
wrote:
  

Yeah, that would work :-).  I guess I was looking for something a bit


more,
  

well, graceful.

-Original Message-
From: Lucas Galfaso [mailto:[EMAIL PROTECTED]
Sent: Friday, August 22, 2008 1:55 PM
To: Tomcat Users List
Subject: Re: I WANT Tomcat to die when a given servlet fails to initialize

try {
 [...]
} catch (Exception e) {
 System.exit(0);
}

??

:-)


-lg


On Fri, Aug 22, 2008 at 3:42 PM, COHEN, STEVEN M (ATTSI) [EMAIL PROTECTED]
wrote:


This may seem like an odd request and I'm sure it is nonstandard, but
it nonetheless something I'd like to be able to do.  We have an
instance of Tomcat running.  It runs one application.  This
application is NOT an application serving content over the www.  It is
basically a straight java application running inside of a web server.
The reason it runs in a Web server is because there is one subsidiary
use case that uses HTTP Gets to fire actions in the application via a
servlet.  No other applications are served off this web server.

The non-web application's main() is the servlet's init().  If this
servlet cannot initialize there is no point to keeping Tomcat running
and it would in fact make monitoring easier if it were not running.

Is there any easy way to achieve this in Tomcat?

  

-
To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe,
e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Manager configuration when using load balancer and clustering

2008-08-04 Thread Gabe Wong

Hi Pavan,
If you want to access a specific Application Server, then in Apache, 
just create individual VirtualHosts for each in addition to the LB.

Regards

Pavan Singaraju wrote:

Hi all,
I have successfully configured the load balancer using Apache and
clustering in Tomcat. I have a question here for managing the container of
Tomcat using Tomcat Manager.
If i want to do the management of the container, how can i specify the
specific web container of Tomcat 1. This is because all the requests will be
handled and forwarded by the Apache to each of the Tomcat. I know i can
provide the domain:port to access the specific container, but is there a way
to manage all the containers together??
I know something like this may sound a little stupid because each
container is different from the other and so it could not be possible.  But
if there is a way i don't want to miss it.
If i want to use the same, should all the 'tomcat-users.xml' be same on
all the clustered nodes?
Please provide me with some information and insight.
Thank you in advance
--
Pavan Kumar Singaraju

  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: configure tomcat

2008-08-03 Thread Gabe Wong

Hi Nadun,

Did you install a Tomcat version from tomcat.apache.org or is it from 
Ubuntu's repository?

If the latter you will find much more success with the former.
Also nothing good usually results from adding CLASSPATH with Tomcat


Nadun Herath wrote:

Thanks a lot Alessandro
When I type that command.
this appeared

tcp6   0  0 :::8080 :::*

It seems tomcat working well isn't it.? What is wrong.
Thanks again.

On Sun, Aug 3, 2008 at 7:43 PM, Alessandro Ferrucci 
[EMAIL PROTECTED] wrote:

  

Make sure none of the ports specified in conf/server.xml are being used.
You can check this by running

netstat -na | grep port

if nothing comes up then the port is free.

--
Signed,
Alessandro Ferrucci


On Sun, Aug 3, 2008 at 10:07 AM, Nadun Herath [EMAIL PROTECTED]
wrote:



I am a newbie to tomcat. I installed it ubuntu

added the following line to bashrc file

export

  

CLASSPATH=/usr/local/tomcat/common/lib/jsp-api.jar:/usr/local/tomcat/common/lib/servlet-api.jar


When I run startup.sh it runs ok. Giving this message

Using CATALINA_BASE:   /usr/local/tomcat
Using CATALINA_HOME:   /usr/local/tomcat
Using CATALINA_TMPDIR: /usr/local/tomcat/temp
Using JRE_HOME:   /usr/lib/jvm/java-6-sun

But when I type localhost/8080 it says can't connect. What is the
  

problem.


Please help. I thank you in advance.

  


  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: one webapp, many apache virtualhosts

2008-07-23 Thread Gabe Wong

Hi Jordan,
You just need to put the proxy directive outside the virtualhost once. 
So it would be globally available

in the Apache config.

Regards

Jordan Michaels wrote:

Hi Folks,

I have a situation where I want all jsp files on a particular system to
be served up by one context (webapp) in tomcat.

So in apache, I have a virtualhost who's files are stored in
/home/user1/public_html, and another apache virtualhost who's files are
stored in /home/user2/public_html. Is there a way that I can get the jsp
files in both apache VirtualHosts to get processed by the same tomcat
context WITHOUT having to make new host entries for each new site?

Basically, the customer wants the freedom to create new web sites using
the control panel software and just have tomcat process the JSP files as
necessary for each site. It would be ideal if they didn't have to modify
tomcat every time they added a new site to their server.

This is probably just my ignorance shining though, but could someone
point me in the right direction on how to set up tomcat to perform in
this way? I'm happy to read documentation  but it looks like there's a
lot that tomcat can do that just isn't necessary here. If I could get
just a little bit of direction on this, I would be in your debt.

Thank you for your help!

-Jordan

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: one webapp, many apache virtualhosts

2008-07-23 Thread Gabe Wong

Jordan Michaels wrote:

Hi Gabe,

Hmm... you mean add the following outside the VirtualHost directives:

ProxyPass / http://mydomain.com:8080/
ProxyPassreverse / http://mydomain.com:8080/
HostnameLookups Off

Wouldn't that just serve up the JSP files that are located in the ROOT
webapp? Maybe I'm confused. Maybe I'm asking the wrong question? I'm not
sure. =P

Is there any way that I can have tomcat serve up the JSP files that are
in each user's public_html directory without having to add host and
context tags to the server.xml file each time? That way, all the end
user has to do is add new VirtualHost's to Apache and not have to
worry about Tomcat configs?
  

I see what you are trying to achieve.
Yes you will have to edit the server.xml as you are trying to specify 
contexts off of Tomcat's default directory.


First of all I do not recommend putting Java code in the same 
public_html directory used for processing other resources by Apache.
Apart from being less than elegant, there are some inherent security 
risks involved with this approach.
I am assuming it is a single instance of  Tomcat shared by multiple 
users? That too is probably a security issue

depending on how the SecurityManager is configured.


Thanks again for the patient reply. I really appreciate it!

-Jordan



Gabe Wong wrote:
  

Hi Jordan,
You just need to put the proxy directive outside the virtualhost once.
So it would be globally available
in the Apache config.

Regards

Jordan Michaels wrote:


Hi Folks,

I have a situation where I want all jsp files on a particular system to
be served up by one context (webapp) in tomcat.

So in apache, I have a virtualhost who's files are stored in
/home/user1/public_html, and another apache virtualhost who's files are
stored in /home/user2/public_html. Is there a way that I can get the jsp
files in both apache VirtualHosts to get processed by the same tomcat
context WITHOUT having to make new host entries for each new site?

Basically, the customer wants the freedom to create new web sites using
the control panel software and just have tomcat process the JSP files as
necessary for each site. It would be ideal if they didn't have to modify
tomcat every time they added a new site to their server.

This is probably just my ignorance shining though, but could someone
point me in the right direction on how to set up tomcat to perform in
this way? I'm happy to read documentation  but it looks like there's a
lot that tomcat can do that just isn't necessary here. If I could get
just a little bit of direction on this, I would be in your debt.

Thank you for your help!

-Jordan

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  
  



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat PHP install

2008-07-21 Thread Gabe Wong

Hi Ryan,

Since you are already using Apache, why burden yourself with serving PHP 
through Tomcat. It would be so so much easier to serve PHP directly

from Apache.
Regards

Ryan Ollerenshaw wrote:

I am trying to get Tomcat and PHP running on the same server.  I am using to 
following tutorial: http://wiki.apache.org/tomcat/UsingPhp everything seems to 
be working but when i load my test.php page i get the following error:

java.lang.UnsatisfiedLinkError: libphp4: /usr/lib64/gcj-4.1.2/libphp4.so: 
undefined symbol: JNI_CreateJavaVM

I am using the following:
Tomcat 5
apache 2.2
java 1.4.2_18

Any suggestions on what i should try next?



  
  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat PHP install

2008-07-21 Thread Gabe Wong

Hi Ryan,

The common practice for such a scenario is to have Apache act as a proxy 
to Tomcat via mod_proxy or mod_jk.


Regards

Ryan Ollerenshaw wrote:

I am have installed ArcIMS on my server which requires Tomcat to handle all the 
calls to the default port 80.  With Tomcat handling the calls to port 80 there 
is no way to have apache running on the same port to handle the PHP calls so i 
need some way to have Tomcat handle PHP.

-Ryan



- Original Message 
From: Gabe Wong [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Monday, July 21, 2008 10:38:31 AM
Subject: Re: Tomcat PHP install

Hi Ryan,

Since you are already using Apache, why burden yourself with serving PHP 
through Tomcat. It would be so so much easier to serve PHP directly

from Apache.
Regards

Ryan Ollerenshaw wrote:
  

I am trying to get Tomcat and PHP running on the same server.  I am using to 
following tutorial: http://wiki.apache.org/tomcat/UsingPhp everything seems to 
be working but when i load my test.php page i get the following error:

java.lang.UnsatisfiedLinkError: libphp4: /usr/lib64/gcj-4.1.2/libphp4.so: 
undefined symbol: JNI_CreateJavaVM

I am using the following:
Tomcat 5
apache 2.2
java 1.4.2_18

Any suggestions on what i should try next?



 
 




  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about the connector Apache x Tomcat

2008-07-21 Thread Gabe Wong

Tan, Liao wrote:

Hi, All:
 My team has installed Apache 2.x and configured the connector with Tomcat 
4.1.x and when started the apache, it gives the following error:

/usr/local/apache2/bin ./apachectl start
httpd: Syntax error on line 471 of /usr/local/apache2/etc/httpd.conf: Syntax error on line 1 of /usr/local/apache2/etc/extra/bobj_apache_tomcat.conf: Cannot load /usr/local/apache2/lib/modules/mod_jk.sl into server: 

*try mod_jk.so instead of mod_jk.sl*

Unresolved external
/usr/local/apache2/bin 

Does anybody know what´s going on this time?
Thank you
Ingrid 



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Multiple websites in tomcat

2008-07-19 Thread Gabe Wong

Hi Ravi,
You need to proxy Tomcat with Apache by using mod_jk or mod_proxy 
(preferred)

Some pertinent links:
http://tomcat.apache.org/connectors-doc/webserver_howto/apache.html
http://marc.info/?l=tomcat-userm=121286145508630w=2

Ravi Sharma wrote:

Hi,
   I have a server running apache on port 80, and tomcat on 9080. Now apache
has setting that when i enter my domain www.mydomain.com, it point sto a
particular directoty on my server and shows the index.html from that dir.
And now i have created one java application which i want to use for that
site. But tomcat is running on 9080, so i need to enter
www.mydomain.com:9080, and i dont want that.i want to access my java
application using www.mydomain.com. Can you tell me how can i do that.

Thanks,
Ravi.

  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement for Cloud Computing
http://www.ngasi.com
NEW! FREE Developer account for Hosted version on Amazon EC2


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: BLACK ZONE alert on Stopping Tomcat Server

2008-06-02 Thread Gabe Wong

Hi Ghulam,
Virtuozzo, is an OS level based VPS. Which means available system 
resources are shared between the VPS.
During Shutdown, a Java process is created; this in turn utilizes a 
burst of RAM. So at that moment you have
3 JVMs running - TomcatA, TomcatB, and ShutdownA. That 3rd JVM may be 
stretching the available resources
on your System. Now after TomcatA is completely shutdown, when you go to 
shutdown TomcatB,
at that particular moment you have 2 JVMS (TomcatB,ShutdownB), which 
your system is able to easily handle.
It is essentially a matter of available system RAM. You may want to 
increase the RAM.


Ghulam_Hussain wrote:

I have configured multiple tomcat servers on a remote linux machine, and
monitors linux applications through Virtuozzo.

When I shutdown the TomcatA while TomcatB is running, the Virtuozzo shows
the Black Zone alert (indicating that linux server is in serious state,
related to system memory).

Similarly when I shutdown TomcatB while TomcatA is running, the same problem
occurs.

But when the one Tomcat server is already stopped, and other Tomcat server
is shutdown, then no problem occurs.

Any clue, that why Black Zone alert occurs.or the Tomcat
servers uses each other resources while being shutdown.

Any help will be appreciated
  



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.1 - Centrally manage Application Servers across multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Configuring one webapp in 2 instances, system properties

2008-05-29 Thread Gabe Wong

Bas Schulte wrote:

Hi,

I tend to agree with both you and Chuck. However... ;)

We're on a budget so separate servers is a no-op. Running multiple 
instances of Tomcat, with it's own start/stop script and it's own 
location for config files/libs etc. won't allow me to continue using 
debian's package management (I can already hear my sysadmin barfing at 
this solution). BTW, I do use this solution for activemq (there's no 
debian package for that ;)) and that's working fine.
Using a Tomcat build obtained directly from tomcat.apache.org will 
enable you to easily run multiple installs. There in lies one of the 
many problems and limitations
with the Linux Distros as they try to globalize the Java environment on 
a system Such conventions work great for scripting languages like PHP 
and Python.
Since Java applications are usually dependent on a specific version of 
app server, jvm, and library, that way of thinking leads to unnecessary 
problems.





The solution of building instance-specific war's using ant would work 
but my current skills (combined with my deadline) fall short. I've 
done ant scripts by hand but currently use NetBeans as my ide and 
haven't figured out how I can combine those two things.


I'll reconsider things, based on your input. Thanks.



On 29-mei-2008, at 22:39, Christopher Schultz wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Bas,

Bas Schulte wrote:
| I'd like to deploy my Spring-based webapp twice in the same Tomcat
| instance, one for production and one for development.

I agree with Chuck: you are asking for trouble with a production
configuration that includes development.

| Is there a way to set these properties in server.xml for both instance
| of my webapp? I plan on using 2 virtual hosts, something like blah.com
| and development.blah.com, each would get it's own set of system
properties.

System properties are, as the name might suggest, system-wide. So, you
can't set foo to bar for one webapp and baz for the other. You
have to choose.

This is one reason I eschew system properties for any application
configuration. We use ant to build our WAR files for deployment, and
find that ant's filter (string replacement) capabilities are a very
good way to configure for a particular environment.

For instance. Want a dev config? Easy:

$ ant -Drelease-type=dev war
(builds dev WAR)

How about a prod config? No problem:

$ and -Drelease-type=prod war

No muss, no fuss.

You maintain either different property values or entirely different
configuration files (which is what we have done) for each environment.
We have a prod/tomcat-server.xml and dev/tomcat-server.xml, each with
separate configuration (dev has only a single db connection in the pool,
for instance, while prod has many).

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkg/FHgACgkQ9CaO5/Lv0PDqrQCfd8G/RW/fpg0eETU8qLl8XVno
C7MAoLgzo2yZFByJ7RCQSPrLip72XA5p
=a/25
-END PGP SIGNATURE-

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]







--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.1 - Centrally manage Application Servers across multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: 503 under load

2008-05-07 Thread Gabe Wong

[EMAIL PROTECTED] wrote:

Hi,

We've started to stress test a new website, and are seeing 503's 
interspersed when we are under load.  We are running Apache - Tomcat 
combination.


Could someone give me an idea of what can cause this, and where to start 
looking?


cheers,

David

  

Number of possibilities some of which include:
1)What is the maxclients settings in httpd.conf (Apache)
2)Any specific errors in catalina logs (Tomcat)
3)Do you have ample RAM and CPU for the test (please elaborate on hardware)
4)Database overload? (elaborate on DB if any)


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.1 - Centrally manage Application Servers across multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Are there issues with running multiple instances of tomcat?

2008-04-18 Thread Gabe Wong

David Brown wrote:

We are currently running two instances of tomcat on our systems. One is for
a vendor specific application and the other is for in-house written
applications. We are careful to make sure the ports do not conflict and
there are plenty of resources to support both; memory and CPU.

Recently the statement has been made that the two instances can conflict
with each other and cause issues and instability with the applications.

 Is this true? I was under the impression that since they are in their own
JVM's neither tomcat would have any affect on the other. If there are issues
in what form may they take place?

  

David,
That is an unfounded superstition.
You can run multiple Tomcat (and different versions) on the same box.
Your only constraint is the available disk/RAM/CPU resources.

When you hear about private java hosting, it is essentially
a single box running 30 to 100 installations.


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: tomcat not able to connect to postgresql?

2008-04-09 Thread Gabe Wong

Dan Eriksson wrote:

Hi list!

I am trying to configure apache + tomcat using mod_jk on different machines 
with virtual hosts, i.e one frontend running apache (2.2.3-4+etch4), one 
backend running tomcat 6 (binary apache-tomcat-6.0.16) with postgresql 
(postgresql-8.1, 8.1.11-0etch1) on debian etch.

My virtual host is called myapp.mydomain.com.

The problem is that when I am using context in my virtual host config for 
tomcat I receive the following in my logfile, catalina.out,

javax.naming.NamingException: Cannot create resource instance
at 
org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:143)
at 
javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
at org.apache.naming.NamingContext.lookup(NamingContext.java:793)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at 
se.springmobil.groupadmin.servlets.ControlServlet.init(ControlServlet.java:86)
at javax.servlet.GenericServlet.init(GenericServlet.java:212)
at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1161)
at 
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:981)
at 
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4058)
at 
org.apache.catalina.core.StandardContext.start(StandardContext.java:4364)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at 
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at 
org.apache.catalina.core.StandardService.start(StandardService.java:516)
at 
org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at 
org.apache.commons.daemon.support.DaemonLoader.start(DaemonLoader.java:177)
ContextListener: attributeAdded('com.sun.faces.ApplicationAssociate', '[EMAIL 
PROTECTED]')

If I try to connect to my vhost now everything looks ok, no errors anywhere, 
but when I try to login I get a message that the database is not online and in 
my logfile I see this:

org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of 
class '' for connect UR
  

Dan,
This has been discussed many times before. Usually adding the database 
driver to $TOMCAT_HOME/lib or $TOMCAT_HOME/common/lib

solves the problem.
Also further information maybe found at the following URL from the 
mailing list archive, which is a good way to search for previously 
discussed issues and solutions:

http://marc.info/?l=tomcat-userm=119454595817475w=2



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat performance over VMWare

2008-04-01 Thread Gabe Wong

Karim Zaki wrote:

Hi all,

I'm experiencing poor performance with Tomcat 5.0.28 running on a Windows 2000 Server VM 
(Windows Server 2003 R2 host, VMWare Server 1.0.4). Tomcat takes up around 50% of the CPU 
and the System process takes up the other 50% when making requests that 
return relatively quickly on a physical server. The VM has 2.5GB of RAM assigned to it, 
and the host is a quad processor machine.

Is anyone familiar with any known performance issues with Tomcat on VMWare? Any 
recommendations?

Regards,
Karim

  

Karim,

How many processors were allocated to the VM (VMWare)?


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Memory allocation

2008-03-23 Thread Gabe Wong

Charl Gerber wrote:

Hi,

I'm setting up a Centos 5 server with Apache, MySQL
and Tomcat 6 (jre 1.6). I think we have joomla on it
as well. The machine will be used purely as a
webserver running a tomcat app and maybe some static
html from the apache server. Quite a bit of
interaction with the MySQL server will be done. We
have 2GB of memory in the machine. How much should I
allocate to Tomcat and where/how do I do it? I suspect
in the catalina.sh file? I am pretty new to managing a
linux machine, so I am not familiar with the
configurations. 


We'd like to optimize Tomcat's performance, but
obviously need to find a balance where MySQL and
Apache will have enough memory too. We don't have many
hard stats about connections expected etc, so we want
to start with a default configuration and memory
allocation that will ensure all apps involved will
have a decent chunk of the memory to work with, but
not too little or too much.

Thanks!

Charl
  

Hi Carl,
First thing,
Are you using a JDK and/or Tomcat distribution from the Centos repository?
If not please download and install the JDK from java.sun.com and
download and install Tomcat from tomcat.apache.org.

Using the default configuration, is a good starting point to determine 
the optimized settings as you do not presently have any metrics.

Depending, then you could increase the memory allocation.

--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RES: about java.lang.outofmemory error

2008-03-17 Thread Gabe Wong

Milanez, Marcus wrote:

Chuck,

Sorry if I haven't been clear enough, but we did have several situations in which such a thing happened in production. We'd specified too much memory to tomcat, and as our server shared its physical with other applications such as IIS, GC never (ever) ran and Tomcat proccess could never acquire the amout of memory we'd specified, causing java.lang.OutOfMemory error plenty of times. We could just solve it decreasing tomcat's proccess initial and maximum amount of memory, that's why I've warned about it. I really apologize if I'm wrong, but is there another explanation for it? 

  
It sounds like in your case, you were allocating more memory to the JVM 
that was available from the system. Thus quite naturally
when you lowered the allocation you encountered less problems. However 
if your application had indeed required the larger allocation,
you would have experienced OutOfMemory. Point is, larger memory 
allocation is a good thing, but it cannot exceed what is available

on the system.



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Simple File Server

2008-03-17 Thread Gabe Wong

Kelly.Graus wrote:

Hello,

I am trying to write a simple file server web app.  Basically, an
administrator can log in and upload files, and a user can log in and
download files that the administrator has given him access to.  I know how
to do the file uploading and downloading, what I really need to know is
where to actually put the files when they have been uploaded.  Is there a
best practice for this sort of thing?  Are there certain locations that are
off-limits to Tomcat?

  

Why re-invent the wheel. Check out:
http://jackrabbit.apache.org/
http://tomcat.apache.org/tomcat-6.0-doc/api/org/apache/catalina/servlets/WebdavServlet.html



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: multi-tenancy using tomcat

2008-03-12 Thread Gabe Wong

Sury Balasubramanian wrote:

Hello all,

if i want multiple tomcat instances running on the same machine (different
ports), can i potentially configure them to read off the same webapp (war)
directory? Is there a downside in doing that (separate work directories are
ok) ?? assume that each tomcat instance points to a single tenant (on a
multi-tenant app)? are there scalability issues?
  
Yes you can assuming all instances have read access to the directory. 
Problem would be if instances write to

the webapp directory.
Really not sure what you are trying to achieve by sharing one webapp 
directory.

I am curious how you can do a reasonable capacity plan for tenant sizes
ranging from 1-10 users to 50-100 users to somewhere close to 500 users
(memory to each instance, specific settings etc)
  
What do you mean by users? If you are referring to instances, then it 
depends primarily on the memory demands
of the application. The average application and application server 
instance requires about 128MB memory (RAM).
Plus you need about 512MB to 1GB RAM available to the system for other 
usage. So for a 4GB RAM Server,
you probably would be able to run 25 instances. Of course you have to 
consider other things such as database resource usage, etc.




--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HOWTO: install a Tomcat web application on Fedora 7 [was: ...]

2008-02-27 Thread Gabe Wong

John Pye wrote:

Here are some instructions that hopefully will be of use to future users:

   1. To install tomcat on Fedora 7, just run yum install tomcat5
  tomcat5-webapps tomcat5-admin-webapps.
   2. Your configuration files are in /etc/tomcat5. You may need to edit
  server-minimal.xml to set the port that Tomcat listens on. You
  will need to edit the file tomcat-users.xml and add a user with
  the role 'manager' if you want to be able to use the Tomcat
  Manager application.
   3. You can start and stop Tomcat by running '/etc/init.d/tomcat5
  start' (or stop,restart, etc).
   4. Any Tomcat web application that you want to serve should be
  dropped into /var/lib/tomcat5/webapps/
   5. You can view your Tomcat website via
  http://yourserver.example.com:8080/.

This webpage had some good instructions:
http://www.weiqigao.com/blog/2007/01/14/tomcat_5_on_fedora_core_6_in_five_easy_steps.html

I have often felt that Java developers, with their 'completely platform
independent' system don't acknowledge that platform-specific knowledge
is often a barrier to getting those Java applications up and running.
The above steps make maximum use of the packaging work that Fedora and
JPackage maintainers have done, and made this job very much easier for
me than downloading the platform independent packages and working out
their particular conventions etc.
  
The concern that some of us on this list has with the various Platform 
specific distros, is that they are usually altered from the
original Apache distribution. As soon as anything is altered, you have 
incompatibility issues.


Most applications are developed and tested on the Apache distributions.
You may not notice incompatibilities until you try to deploy a real 
complex application.


That said, I am not saying one is right or wrong. It is just that just 
as Java has become relatively stable (predictable), there
enters the various Linux based distros to add to the equation. Some of 
these distros do not
follow the generally accepted JAVA programming principles (what is 
acceptable today).
These distros usually follow the principles of traditional Linux based 
programming, such as PHP, Python, etc.
And that is primarily to make packages globally accessible on the 
system. This is where the distinction between
traditional linux applications and present day java applications are 
being missed. Most Java applications
are dependent on a specific version of an application server, JVM, 
libraries, etc. Thus a one package

for all creates issues.

So moving forward, are Java Applications now to be built for a specific 
Linux distro, in addition to supporting the traditional purist
java programming environment. Or is it that a new generation of java 
programmers under the Linux distro environment will
give raise. Will there then be two camps or platforms? Or will the new 
generation become the standard. I say this because
as I speak, more and more I see java questions on Linux lists instead of 
pure java lists.


I know I do not usually rant, but this is an issue that needs to be 
addressed.



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
http://www.ngasi.com
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Can Tomcat support multiple SSL certificates for multiple domains?

2008-02-09 Thread Gabe Wong

Dave wrote:

Hi,
   
  I have one JBoss instance (4.0.5GA) running on Linux. The machine has one IP with two domains.

  www.domain1.com
  www.domain2.com
   
  I have two SSL certificates, one for each domain, imported into keystore.

  I need to use both without any warnings from browser
  https://www.domain1.com
  https://www.domain2.com
   
  Can Tomcat pick the right certificate based on current domain name?
   
  But according to

  http://tomcat.apache.org/tomcat-5.5-doc/ssl-howto.html
   
  keyAlias  Add this element if your have more than one key in the KeyStore. If the element is not present the first key read in the KeyStore will be used.
   
  How to work around this?
   
  Thanks for help!

  Dave
  

Refer to the following link:
http://marc.info/?l=tomcat-userm=120239893800741w=2

For additional info:
http://marc.info/?l=tomcat-userw=2r=1s=sslq=b

--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat installation/deployment question

2008-01-24 Thread Gabe Wong

Sureka, Sushil wrote:


Hi,
	 
	We are intending to deploy our application on individual laptops

(to be used by field personnel who does not have internet connectivity
to connect to our central server). The idea is that a trimmed down
version of our core application will be deployed on individual laptops
running tomcat against a light weight Sybase database.
	 
	I wanted to see if you had any suggestions about - 
	1. How best to deploy the initial version (5.5) of Tomcat on

individual machines  - We understand our options are Microsoft SMS, Java
Web Start application, shell script or Ant script to install Tomcat on
these laptop boxes. We are leaning towards Microsoft SMS since 
	(a) It can easily mass deploy the app to hundreds of machine

(b) It is currently used in our organization to deploy some asp
application. 
	If you believe there are downsides to this approach or other

approaches are better please let me know
	 
	2. How best to deploy the upgraded version (6.x or higher) - We

potentially could use the same approach as the first one, but wanted to
see if the opinion differs.
	 
	3. And finally the rollout of initial app and upgraded app

version. Again probably use the same approach as before but wanted to
throw this out there in case there are better ideas.
	 
	Please let me know your thoughts on this.
	 
	Sushil



  

Sushil,

The Laptops I presume will be running Windows? If so which version(s)?


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Error encountered : JNDI on Tomcat 5.5 for Database Informix with Informix JDBC driver

2008-01-24 Thread Gabe Wong

Amitava Chakraborty wrote:

Hi All,

I am from IBM - Informix Product Interoperability team .  I tried to
create a JNDI connection from Tomcat to Database Informix. But it is
throwing error. I classified the error by the following way :

1. When I tried with type=javax.sql.DataSource  , I am getting error
Cannot create PoolableConnectionFactory (Can't load driver
java.lang.reflect.InvocationTargetException) .

2. When I tried with  type=com.informix.jdbcx.IfxConnectionPoolDataSource
, I am getting error  java.sql.SQLException: No suitable driver.

3. But we use JNDI connections from WAS , WAS CE and Web Logic also. There
it works fine.
  


You need to add the driver under ./common/lib/
More info can be found here:
http://marc.info/?l=tomcat-userw=2r=1s=No+suitable+driverq=b

--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about Tomcat/IIS and NTLM authentication

2008-01-23 Thread Gabe Wong

eborisow wrote:

Gabe Wong wrote:
  
I guess I misunderstood your objective. You are not interested in 
manipulating the user name.

You just want to check if the stripped user name is in a specific role?



Gabe,

Yeah, I guess that sums it up better than my original post.  I thought that
maybe if I could just manipulate the principal name that I could just pass
that along to hasRoles and everything would work similarly.

If you have any other ideas on how I could do that, I would be grateful.

Thanks,
Eric
  
Since the hasRole is being called, can you not do a super.hasRole 
against the stripped user name of the Principal.

If so won't that suffice?


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about Tomcat/IIS and NTLM authentication

2008-01-23 Thread Gabe Wong

eborisow wrote:

Gabe Wong wrote:
  
   
Since the hasRole is being called, can you not do a super.hasRole 
against the stripped user name of the Principal.

If so won't that suffice?




Gabe,

Yeah, I was thinking that.  The hasRole though takes two parameters... a
Principal and the role name.  I could not find any easy way to manipulate
the existing object name.  I also looked into creating a GenericPrincipal,
but that requires a password parameter.  The one thing I haven't tried is
'fudging' it by passing a user name and password that I know exists and see
if that works.  Although, that won't help me in the future when I don't know
the password.

  
Short of hacking Tomcat, another possibility, is if you can access the 
LDAP data - perhaps a thread
that populates a Database with the names with the group. Then check the 
data as the hasRole method is called.



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about Tomcat/IIS and NTLM authentication

2008-01-22 Thread Gabe Wong

eborisow wrote:

Gabe Wong wrote:
  

Check the syntax as it was just done on the fly.




Here's the latest.  I created a class that extends JNDIRealm and I can see
some debug messages in my constructor, but I don't see my authenticate
method getting invoked.  I just wanted to see if I could override the
authenticate method before I started messing around with the name.  Here is
my code:

public Principal authenticate(String arg0, String arg1)
{
System.out.println(Starting authenticate);
Principal principal = super.authenticate(arg0, arg1);
System.out.println(Principal Name:  + principal.getName());
System.out.println(Finished authenticate);

return principal;
}

  
Could be how logging output is setup. The constructor may be created 
before output gets redirected elsewhere.
Look in the other log files under the logs directory. Also is the realm 
configured in server.xml or context.xml?



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about Tomcat/IIS and NTLM authentication

2008-01-22 Thread Gabe Wong

eborisow wrote:

Gabe Wong wrote:
  
Could be how logging output is setup. The constructor may be created 
before output gets redirected elsewhere.
Look in the other log files under the logs directory. Also is the realm 
configured in server.xml or context.xml?





Gabe,br/br/

Here's the thing.  I also added logging (just System.out for right now) to
the hasRole method and I saw the output from that method.br/br/

The realm is defined in the server.xml.br/br/
  
Do you have the following set - tomcatAuthentication=false in the AJP 
connector in the server.xml


I believe as the user is already authenticated via IIS, the authenticate method 
is not called in this situation.
So you may try overriding:
protected Principal getPrincipal(String username)



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about Tomcat/IIS and NTLM authentication

2008-01-22 Thread Gabe Wong

eborisow wrote:


mgainty wrote:
  

NAMES: You cannot change to any names unknown to your (NTLM)
authentication
algorithm
http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/catalin
a/realm/RealmBase.html#authenticate(java.lang.String,%20java.lang.String)

Martin




Martin,

Thanks for the reply.  So, does what I'm thinking sound do-able?  I want to
use NTLM authentication which is returning:

DOMAIN\username

but, then I want to check to see if that user is in a role (group) from
LDAP.  The format for that user is something like:

Group dn: cn=manager,ou=groups,dc=mycompany,dc=com
member: cn=username,ou=people,dc=mycompany,dc=com

So, I want to go from my user autheticated as DOMAIN\username to finding out
if that user is contained in my LDAP group.  Does that sound possible?
  
I guess I misunderstood your objective. You are not interested in 
manipulating the user name.

You just want to check if the stripped user name is in a specific role?

--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about Tomcat/IIS and NTLM authentication

2008-01-21 Thread Gabe Wong

Mark Thomas wrote:

eborisow wrote:
If someone has been able to get this working and could provide some 
help,

that would be great.


Haven't tried it but you should be able to create a custom Realm by 
extending the existing JNDIRealm and manipulating the user name, 
probably by overriding the authenticate() methods.



The specific code my look like so:

import org.apache.catalina.realm.*;
import java.security.Principal;
import java.sql.*;
import java.util.*;
import java.io.*;

public class CustomTomcatRealm
   extends JDBCRealm {
public synchronized Principal authenticate(String username, String 
credentials) {

  Principal p = super.authenticate(username,credentials);
   if (p != null){
  String newName = //whatever;
   ArrayList roles = getRoles(newName);
  p = new GenericPrincipal(this, newName, credentials, roles);
}
return p;
}

}

Check the syntax as it was just done on the fly.

--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 5.5 classloading behavior

2008-01-16 Thread Gabe Wong

Johnny Kewl wrote:


What language is this guy talking  ha ha.
This has got to be for a thesis or something or its attempted 
suicide ;)


- Original Message - From: Michel Betancourt 
[EMAIL PROTECTED]

To: users@tomcat.apache.org
Sent: Thursday, January 17, 2008 3:33 AM
Subject: Tomcat 5.5 classloading behavior



Hi,

I am wondering if someone may be able to point me in the right direction
here...  after reviewing the J2SE spec, and the Servlet 2.4 Spec, its 
not
too clear whether circular dependecies  such as the one I am 
investigating
below are legal or supported by Tomcat.  Sun J2SE 5.0 classloader 
does not
seem to support such initialization although the Tomcat classloader 
(v5.5)

seems to an operation such as my example below.

An exert of the Java specification states:
12.4.2, #3 If initialization is in progress for the class or 
interface by

the current thread, then this must be a recursive request for
initialization. Release the lock on the Class object and complete 
normally.


You know what you should do... find a little custom class loader 
example on the web and run it through a debugger.
They look simple but when you actually watch them work, and how 
reentrent the things are, this will hopefully all start to make sense.


I think most guys havnt even started thinking about this... 
ClassCircularityError Wow! dont trap that in my code ;)


This is what I think the normal system classloader, and the tomcat 
classloader when it comes to threads and reentrant code will
behave exactly the same... the reason is that one class loader 
inherets from another and thus one can expect the behavior to be similar.
The only diffirence is where the tomcat classloader will look for jars 
and class's.


ie the same stuff is happening but when it comes time to find Your 
Class... it will look for it in the web-app, after that i think

its much of a muchness.
Thats different because outside of web servlets... class loaders are 
not allowed to work like that... they always ask the classloader
above them if it has the class already, if not the parent class 
loader tries to find it, and ONLY if it cant find it, will the child 
classloader

try and get it.

If you watch a cl working you'll see that recursive request stuff 
happenning... and I'm no academic, in plain talk it just means
that all those dependencies must be gotten out of the way, before the 
next thread can come in and ask for a class to load.
So if A - B - C and thread one is busy with A, and thread 2 really 
just wants C it has to wait, because otherwise
C would load... and then A would eventually get to it and it would 
load again because its already kicked off that recursive pattern.
Then because C is waiting A will actually will have done it 
already... and the cl will then just say... thread 2, you lucky, class 
is loaded, you can go now.


Normal CL or Tomcat no diffs.

The other thing with these examples is that yes I guess it is possible 
to be surprised in the way STATIC variables are inited in complex
class structure... but remember is LOADING, not INSTANTIATING the 
class, that comes later outside of the CL, so in most cases

it not an issue one would even encounter.

I dont think its possible to make an ClassCircularityError error with 
a modern IDE... I dont think it will let you compile the code


Class A extends A

so if you actually making these classes and compiling them I dont 
think its possible to simulate it without hacking byte code.

 be interesting to hear if anyone ever seen that.

Thanks... I never ever thought about static variables before... and 
I've never seen it in practical code.
ie I think in normal code a programmer may go what the... I 
thought static A was going to be 5, why is it 10, or whatever...
and then eventually see the curcular RELATIONSHIP but I doubt that 
would cause an error.
If its compiling... I dont think you can break a classloader... short 
of it just cant find the Jar


interesting things these classloaders... good luck.
If its practical stuff... I can help you a little, heavy specs and 
theory... you on your own ;)
Nice analysis Johnny. To add to your thought (even though slightly off 
topic) -
Yes there is a big difference between theory (specification) and 
practice (implementation).

So it may be confusing for someone starting off from the theoretical side.


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: tomcat5.5, balancer

2008-01-09 Thread Gabe Wong
/prefork.html#minspareservers

   MinSpareServers  5
   # maximum number of server processes which are kept spare
   # 
http://httpd.apache.org/docs/2.2/mod/prefork.html#maxspareservers

   MaxSpareServers 10
   # highest possible MaxClients setting for the lifetime of the 
Apache process.
   # 
http://httpd.apache.org/docs/2.2/mod/mpm_common.html#serverlimit

   ServerLimit700
   # maximum number of server processes allowed to start
   # 
http://httpd.apache.org/docs/2.2/mod/mpm_common.html#maxclients

   MaxClients 700
   # maximum number of requests a server process serves
   # 
http://httpd.apache.org/docs/2.2/mod/mpm_common.html#maxrequestsperchild 


   MaxRequestsPerChild  1


We are trying to test this with 600 clients , when we reach 200 , 
everything gets stuck


any ideas?

Thanks in advance four your help

JulioC.



How do clients relate to parallel requests?
What's the throughput before it gets stuck?
What does a Java Thread Dump of Tomcat tell you?
What is the status in the jk status worker?
Which kind of errors in the jk log do you get?

Regards,

Rainer


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: tomcat5.5, balancer

2008-01-07 Thread Gabe Wong

Julio Cesar Leiva wrote:

Hi all

We have  this setup

1 web server apache 2.2.0
2 tomcat servers tomcat 5.5.20
mod_jk 1.2.25

This is our workers.properties

workers.java_home=/usr/lib64/jvm/java

worker.list=cbnbalancer,jkstatus

# Set properties for worker1 (ajp13)
worker.worker1.type=ajp13
worker.worker1.host=172.20.23.12
worker.worker1.port=8009
worker.worker1.lbfactor=1
#worker.worker1.connection_pool_timeout=600
#worker.worker1.socket_keepalive=1
#worker.worker1.socket_timeout=60
worker.worker1.socket_timeout=0
# Define prefered failover node for worker1
worker.worker1.redirect=worker2

# Set properties for worker2 (ajp13)
worker.worker2.type=ajp13
worker.worker2.host=172.20.21.211
worker.worker2.port=8009
worker.worker2.lbfactor=1
#worker.worker2.connection_pool_timeout=600
#worker.worker2.socket_keepalive=1
#worker.worker2.socket_timeout=60
worker.worker2.socket_timeout=0
# Define prefered failover node for worker2
worker.worker2.redirect=worker1

# Set properties for balancer which use worker1 and worker2
worker.cbnbalancer.type=lb
worker.cbnbalancer.method=T
worker.cbnbalancer.balance_workers=worker2,worker1
# Enable sticky-sessions (aka session affinity)
worker.cbnbalancer.sticky_session=1

# Define a 'jkstatus' worker using status
worker.jkstatus.type=status
# Add the jkstatus mount point
JkMount /jkmanager/* jkstatus
# Enable the JK manager access from localhost only
!-- Location /jkmanager/
 JkMount jkstatus
 Order deny,allow
 Deny from all
#  Allow from 127.0.0.1
 Allow from all
/Location --

This is part of one server.xml

Engine name=Catalina defaultHost=localhost jvmRoute=worker1 

Connector port=8009 minProcessors=5 maxThreads=2000 
minSpareThreads=100 maxSpareThreads=150 maxProcessors=0

protocol=AJP/1.3 connectionTimeout=0/

This is the second tomcat
Engine name=Catalina defaultHost=localhost jvmRoute=worker2 

Connector port=8009 minProcessors=5 maxThreads=2000 
minSpareThreads=100 maxSpareThreads=150 maxProcessors=0

protocol=AJP/1.3 connectionTimeout=0/

This is part of the apache conf

# number of server processes to start
   # 
http://httpd.apache.org/docs/2.2/mod/mpm_common.html#startservers

   StartServers 5
   # minimum number of server processes which are kept spare
   # 
http://httpd.apache.org/docs/2.2/mod/prefork.html#minspareservers

   MinSpareServers  5
   # maximum number of server processes which are kept spare
   # 
http://httpd.apache.org/docs/2.2/mod/prefork.html#maxspareservers

   MaxSpareServers 10
   # highest possible MaxClients setting for the lifetime of the 
Apache process.

   # http://httpd.apache.org/docs/2.2/mod/mpm_common.html#serverlimit
   ServerLimit700
   # maximum number of server processes allowed to start
   # http://httpd.apache.org/docs/2.2/mod/mpm_common.html#maxclients
   MaxClients 700
   # maximum number of requests a server process serves
   # 
http://httpd.apache.org/docs/2.2/mod/mpm_common.html#maxrequestsperchild

   MaxRequestsPerChild  1


We are trying to test this with 600 clients , when we reach 200 , 
everything gets stuck


any ideas?

Thanks in advance four your help

JulioC.


Hi Julio,
What is the MaxClients setting in httpd.conf?
Also is there a central Database - that could also be a possible 
bottleneck with regards to connections.


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 6 getRemoteUser() returns null

2007-12-21 Thread Gabe Wong

Natalie Wang wrote:

Hi,

We have to retrieve the userid of the remote user when
the user logs on. But request.getRemoteUser() is
returning null in Tomcat 6. Authentication is done
through LDAP.

It works fine in Tomcat 5 and 4.

Any suggestion?

Thanks,
Natalie

  

This me be an issue with the Web Framework your application might by using.
Try the following code:
   String r = request.getRemoteUser();
   if (r == null)
{
java.security.Principal pr =  request.getUserPrincipal();
   if (pr != null){
   r = pr.getName();
   }
   }

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 6 getRemoteUser() returns null

2007-12-21 Thread Gabe Wong

Natalie Wang wrote:

It does not work either.

Thanks,
Natalie

--- Gabe Wong [EMAIL PROTECTED] wrote:

  

Natalie Wang wrote:


Hi,

We have to retrieve the userid of the remote user
  

when


the user logs on. But request.getRemoteUser() is
returning null in Tomcat 6. Authentication is done
through LDAP.

It works fine in Tomcat 5 and 4.

Any suggestion?

Thanks,
Natalie

  
  

This me be an issue with the Web Framework your
application might by using.
Try the following code:
String r = request.getRemoteUser();
if (r == null)
 {
 java.security.Principal pr = 
request.getUserPrincipal();

if (pr != null){
r = pr.getName();
}
}




After the user logs in, is the user being redirected to another resource 
or is the user being forwarded?

Also are you using some Web Framework?

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: selecting java version

2007-12-19 Thread Gabe Wong

Lawrence A. Quinn wrote:

Can tomcat be configured to use a different version of java than what is
listed in java_home?   Where does that configuration information reside?
LAQ


  
Hi Lawrence, you never specified which OS you are on, but in general you 
set the JAVA_HOME environment variable by editing either

./bin/startup.sh or ./bin/startup.bat like so:
NIX:
export JAVA_HOME=/usr/java/custom_jdk
export JRE_HOME=$JAVA_HOME

WIN:
set JAVA_HOME=c:\usr\java\custom_jdk
set JRE_HOME=%JAVA_HOME%

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem with locating Datasource using servlet as ROOT in tomcat 6

2007-12-17 Thread Gabe Wong

Alan Chaney wrote:

Hi

I am using Eclipse 3.3, tomcat 6.0.14, linux and Java 1.5

I have a web app which uses a JNDI data source. I wrote a very simple 
test servlet to access the data source and display some values from 
the database. First time around I used a local application context in 
/META-INF/context.xml. This worked fine. I then moved the Resource 
definition to a GlobalNamingResource in server.xml and that worked 
fine with a ResourceRef in context.xml.


All well and good. I then renamed the app to ROOT with a path '/'.

The servlet still responds and renders text correctly at 
http://localhost:8080/ but I get a javax.naming.NameNotFoundException 
regardless of whether the resource definition in context.xml or 
GlobalNamingResource in server.xml and referenced in context.xml. 
Needless to say the database content is no longer displayed.


As a further test I exported the the war files as ROOT.war and 
deployed the war to a tomcat instance. It deployed OK but I still got 
the naming exception. I then deployed the original (non-ROOT) test app 
to the same server and that worked.


It seems that for some reason a ROOT app cannot access a JNDI 
DataSource. Has anyone seen anything like this or has any explanation


The exception report starts;



Failed to create datasource
javax.naming.NameNotFoundException: Name wrshowdbLink is not bound in 
this Context

at org.apache.naming.NamingContext.lookup(NamingContext.java:770)
at org.apache.naming.NamingContext.lookup(NamingContext.java:140)
at org.apache.naming.NamingContext.lookup(NamingContext.java:781)




The context.xml is displayed below:


?xml version=1.0 encoding=UTF-8?
Context 
ResourceLink name=wrshowdbLink global=jdbc/wrshowdb
type=javax.sql.DataSource
   
/

/Context


The web.xml for the ROOT app is:


?xml version=1.0 encoding=UTF-8?
web-app xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; 
xmlns=http://java.sun.com/xml/ns/javaee; 
xmlns:web=http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd; 
xsi:schemaLocation=http://java.sun.com/xml/ns/javaee 
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd; id=WebApp_ID 
version=2.5

  display-nameROOT/display-name
  welcome-file-list
welcome-fileindex.html/welcome-file
welcome-fileindex.htm/welcome-file
welcome-fileindex.jsp/welcome-file
welcome-filedefault.html/welcome-file
welcome-filedefault.htm/welcome-file
welcome-filedefault.jsp/welcome-file
  /welcome-file-list
  servlet
descriptionTest of using root jndi/description
display-nameRootJndi/display-name
servlet-nameRootJndi/servlet-name
servlet-classcom.writingshow.test.RootJndi/servlet-class
  /servlet
  servlet-mapping
servlet-nameRootJndi/servlet-name
url-pattern//url-pattern
  /servlet-mapping
/web-app


and the GlobalResourceDef is:

Resource auth=Container 
driverClassName=org.postgresql.Driver maxActive=20 
maxIdle=10 maxWait=3000 
name=jdbc/wrshowdb password=xxx 
removeAbandoned=true type=javax.sql.DataSource 
url=jdbc:postgresql://127.0.0.1:5432/wrshowdb 
username=wrshow/




Hi Alan,

Is there a ./conf/Catalina/host/ROOT.xml?

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 6 virtual host problem please help

2007-11-26 Thread Gabe Wong



Someone know why the pages that I get via reverse proxy are relative to
the real web server and not to the proxy server?

eg:

ProxyPass / http://localhost:8081/app/
ProxyPassReverse / http://localhost:8081/app/

when I access http://www.example.com (www.example.com resolves to proxy
server), I get the first page correctly, but every link to a rosouce in
it contained is relative to http://localhost:8081/app/.

eg:

there is a link to css/style.css in the home page of
http://www.example.com and it is not loaded because i try to get
http://www.example.com/app/.

thanks,

rocsca


Such a proxy configuration may require manipulation of the HTML links. 
Are the links being created dynamically or are they  hard coded with


css/style.css instead of  /app/css/style.css and so on.


--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat vs (other container) compatibility

2007-11-17 Thread Gabe Wong
That is more an Application design issue. In short, there are 
incompatibilities across the various containers.
So if you are developing a cross-container application, the simpler it 
is the more chances of less re-configuration on different containers.
However that may be contradictory as more requirements usually results 
in more complexities.
Simple difference, is JNDI. The following are differences in calling a 
jdbc object called defaultDS:


Tomcat/Jetty: java:comp/env/jdbc/defaultDS
Orion(Oracle-OC4J)/Tomcat: jdbc/defaultDS
JBoss: java:/defaultDS
Weblogic: defaultDS

And this is just one of the many differences. More off the top of my 
head, EJBs, Virtual Hosting configuration, etc.
Some containers also require container specific XML descriptor in the 
application e.g. jboss.xml, etc.


David Smith wrote:

Michael wrote:

Johnny Kewl wrote:


--- 


HARBOR: http://coolharbor.100free.com/index.htm
Now Tomcat is also a cool pojo application server
--- 


- Original Message - From: Jacob Rhoden [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Saturday, November 17, 2007 1:40 PM
Subject: Tomcat vs (other container) compatibility



Hi,

Just wondering if there is anyone who has been or is involved in 
cross JEE container work, how compatible are tomcat apps with other 
commercial apps such as OC4J, Websphere, BEA and so on? If you 
don't use tomcat specific things, does it just work, I ask 
because the compatibility issue might come up at work.


Heres an article from IBM site
http://www.ibm.com/developerworks/websphere/library/techarticles/0511_li1/0511_li1.html 



I have put quite a few TC servlets onto Glassfish... no problem.


no wonder, Glassfish uses TC as servlet container!


Actually I think Glassfish uses a fork of the tomcat code from some 
point in the past.  As long as the servlet spec is followed, I would 
think the servlets would work in either place.


--David

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem configuring JDBC DataSource Tomcat 5.5.23 / MySQL 5.0

2007-11-08 Thread Gabe Wong

NBW wrote:

Hi, I'm having difficulty configuring a container managed JDBC
resource. I've read several posts in the tomcat-users archives
(discussing similar issues) as well as the documentation at:

http://tomcat.apache.org/tomcat-5.5-doc/jndi-resources-howto.html
  
The MySQL driver JAR is deployed in %TOMCAT_HOME%/webapps/myApp/WEB-INF/lib

2007-11-08 12:41:31,593 [Thread-1] ERROR Unable get a SQL connection:
org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC
driver of class '' for connect URL 'null'
at 
org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:780)
at 
org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:540)
[SNIP]
at com.myApp.InitServlet.init(InitServlet.java:56)


Refer to the following topic in the same URL you provided above:
1. Install Your JDBC Driver
Use of the /JDBC Data Sources/ JNDI Resource Factory requires that you 
make an appropriate JDBC driver available to both Tomcat internal 
classes and to your web application. This is most easily accomplished by 
installing the driver's JAR file(s) into the |$CATALINA_HOME/common/lib| 
directory, which makes the driver available both to the resource factory 
and to your application.


--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: serving files through SSL

2007-11-07 Thread Gabe Wong

Roger Parkinson wrote:
In both cases the URL is invoke with some javascript that looks like 
this:

function downloadpdf(url)
{
   var pdfWindow = window.open( url 
,'pdf','top=0,left=0,width=1000,height=700,toolbar=no,status=no,scrollbars=yes,resizable=yes,menubar=no'); 


}
The application invokes a mix of html and servlet requests beforehand.
But the response to the static PDF always works regardless of when it 
is called

Regards
Roger
For further clarification, what exactly is the result when the dynamic 
PDF over SSL fails to work? blank page? Error? etc.



--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: serving files through SSL

2007-11-07 Thread Gabe Wong

Roger Parkinson wrote:
I'm opening the PDF in a new window (as the javascript shows) so what 
I see for the dynamic pdf is:

1) the new window (empty)
2) the download progress dialog
3) an error dialog referring the file name with the message 'cannot 
write the file to the cache'


On the static PDF I don't see 2 or 3 and the new window has the PDF 
displayed.
(I' using the terms dynamic and static as referred to in my initial 
question, ie static is the PDF in the war file that always works and 
dynamic is the one fetched from outside the war file by a servlet and 
this is the one with the problem).


I did search on that cache message and all the solutions told me to 
either upgrade my browser from 5.5 (I'm using 6), change the browser 
config, or set the cache headers that seem to be already set. It was 
when I realised that the static PDF was always just fine that I 
concluded that the problem did not need to be solved at the browser end.

1)response.setContentLength(10115);
Is 10115 a hard coded number or just there as an illustration. If it is 
hard coded then the content length should be set to the

correct value.
2)   response.addHeader(ETag,W/\963288-1194247031062);
Perhaps the missing \ at the end could be a problem?



--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Environment variables

2007-11-06 Thread Gabe Wong


Andrew Hole wrote:

I'm trying to execute a ssh command inside java code. SSH command must
know HOMEDRIVE environment variable to find know_hosts file... How can
I do that?
  

Hi Andrew,
You can pass the value as a Java Option. Click the Tomcat Service 
Manager icon (usually lower right of the Windows Taskbar).

Click the Java Tab. Then append to the bottom of Java Options.




--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: cant make tomcat accept https

2007-11-06 Thread Gabe Wong

Yavuz Kavus wrote:

2) and i uncommented the part related to https as:
Connector port=8443 maxHttpHeaderSize=8192
   maxThreads=150 minSpareThreads=25 maxSpareThreads=75
   enableLookups=true disableUploadTimeout=true
   acceptCount=100 scheme=https secure=true
   clientAuth=false sslProtocol=TLS /

3) restarted tomcat and tried https://localhost:8443/   i got  :
The connection was interrupted
The connection to localhost:8443 was interrupted while the page was loading.


when i try http://localhost:8443/ (http instead of https), everything is ok.

i wonder where i made mistake(s).
can any body see where is my mistake(s)?

thanks for any help.

  


You need to include the keystore path in the SSL confiiguration like so:
   Connector port=8443 maxHttpHeaderSize=8192
  maxThreads=150 minSpareThreads=25 maxSpareThreads=75
  enableLookups=false disableUploadTimeout=true
  acceptCount=100 scheme=https secure=true
  clientAuth=false sslProtocol=TLS 
keystoreFile=./conf/keystore/


--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: serving files through SSL

2007-11-06 Thread Gabe Wong

Roger Parkinson wrote:
I am trying to deliver some PDFs to the browser using my tomcat 
application. It works, but not always under SSL and IE.
One file is a static PDF and it lives inside my war file. That works 
just fine. The file is accessed using a url like /myapp/web/myfile.pdf 
and that always delivers the file.
Other files are generated by the app and live in a configured 
directory. They are delivered through a servlet that looks like this:


   String mimeType = sc.getMimeType(filename);
   FileHelper helper = new FileHelper();
   InputStream in = helper.fetch(filename, m_dir);
   response.setContentType(mimeType);
 response.setContentLength(10115);
 response.addHeader(ETag,W/\963288-1194247031062);
   OutputStream out = response.getOutputStream();
   byte[] buf = new byte[1024];
   int count = 0;
   while ((count = in.read(buf)) = 0)
   {
   out.write(buf, 0, count);
   }
   in.close();
   out.close();

So apart from some minor fiddling with the contentType etc I don't do 
very much. This works fine outside of SSL and it also works fine with 
SSL and Firefox, but not SSL+IE.
Thinking it was a problem with headers I did some research and found a 
lot of stuff about setting no cache etc. Tried it and it nothing made 
any difference (except that I managed to break it). I have taken all 
those out because the static file, the one I mentioned at first, is 
delivering okay to IE over SSL so I don't believe there is a problem 
at the IE end, or not one that cannot be overcome by getting my 
response right at the server end.


I used TCPMonitor to sniff the headers using non-SSL and found that 
the static file has this response:

HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
ETag: W/963288-1194247031062
Last-Modified: Mon, 05 Nov 2007 07:17:11 GMT
Content-Type: application/pdf
Content-Length: 963288
Date: Wed, 07 Nov 2007 04:54:39 GMT
... pdf file follows

So there doesn't seem to be too much going on there.

When I respond to the request for the dynamic file it looks like this:
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Pragma: No-cache
Cache-Control: no-cache
Expires: Thu, 01 Jan 1970 12:00:00 NZST
ETag: W/963288-1194247031062
Content-Type: application/pdf
Content-Length: 10115
Date: Wed, 07 Nov 2007 05:32:02 GMT

...pdf file follows.

I am getting some cache headers added for free otherwise there is no 
difference in the request.
Of course those headers may be making all the difference because IE's 
message is 'cannot write the file to cache' which is a bit odd because 
we've explicitly told it not to here.
Searching the web on this has a number of answers that suggest adding 
those no-cache headers anyway.


So, does anyone know what I need to do to make the two responses 
enough the same to stop IE complaining?
I am aware that I have faked the ETag and the length of the file and 
that I need to do something smarter there, but I'll do that when it 
starts working.


Version info: Tomcat 5.5, Java 1.5, WinXP SP2

Are you calling the dynamic PDF URL directly? For instance typing in the 
URL directly in the browser?
The reason I am asking, is that for mixed responses from SSL requests, 
IE puts up a warning, whereas FF does not.




--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CLASSPATH, .jar files, packages, and so forth

2007-11-01 Thread Gabe Wong

Mann, Ivan H wrote:

As we discovered earlier this morning, it is an applet question, not a
servlet question.

I looked in this spec and did not find any mention of applets, which is
not surprising since it is the servlet spec.  

Is there an applet spec?  
  

Follow this link:
http://www.google.com/search?hl=enq=java+applet+specificationbtnG=Search

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Can't Modify or Delete Files Running Tomcat on Vista

2007-11-01 Thread Gabe Wong

Jenna wrote:

Hi,
I'm pretty new to Tomcat and I just installed it on my Windows Vista machine using the 
Windows installer. I did the same thing on my XP machine previously and had no problems. 
I am able to start Tomcat and run my applications, however, I am not able to modify or 
delete any of the files in any of the Tomcat directories. I keep getting an error that 
says You need permission to perform this action. I am setup as the 
administrator on my computer. I tried disabling user account control in Vista but that 
did not help. I also copied the file msvcr71.dll from my jre bin folder to Tomcat's bin 
folder as I heard that was necessary on Vista but it did not help me. Any suggestions 
would be greatly appreciated.

Thank you.
Jenna 
  


Sorry that is a Vista problem (err I mean security feature :)) and not a 
Tomcat problem.

Some solutions from the Web:
http://paulstamatiou.com/2007/02/09/how-to-quickie-vista-permissions/
http://www.google.com/search?hl=enq=You+need+permission+to+perform+this+action+VistabtnG=Google+Search

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: What do I do with a heap dump? (OOM Permgen)

2007-11-01 Thread Gabe Wong

Greg Vilardi wrote:
Hello everyone. 

My team and I are trying to develop a new web application and the 
tomcat JVM is crashing every few days. We are deploying our separate 
versions of the application several times per hour, and by looking at
Please elaborate, are you undeploying the same application, then 
redeploying several times per hour,

are are you deploying several instances of the same application per hour.

I am also assuming these are hot deploys (without shutting down the app 
server)?


--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem installing tomcat 6

2007-10-31 Thread Gabe Wong

sunil chandran wrote:

Hi ,

  I went for jdk5.0 . but still when i type :  java -version it shows that

java version 1.4.2_12
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_12-b03)
Java HotSpot(TM) Client VM (build 1.4.2_12-b03, mixed mode)

why is it so.
i went for jdk1.5.0_13-linux-i586.rpm

please help me.
  


First which directory was jdk1.5.0_13 installed under? Assuming 
/usr/java/jdk1.5.0_13,

execute the following command
export PATH=/usr/java/jdk1.5.0_13:$PATH

However I am assuming you are trying to get /usr/java/jdk1.5.0_13 for 
Tomcat to run  under.
So in the Tomcat startup.sh or catalina.sh script add the following 
(towards the top part of the script)

export JAVA_HOME=/usr/java/jdk1.5.0_13

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
for Tomcat, JBoss, and Jetty.
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem installing tomcat 6

2007-10-31 Thread Gabe Wong

sunil chandran wrote:

Hi ,

I tried your command

  

First which directory was jdk1.5.0_13 installed under? Assuming
/usr/java/jdk1.5.0_13,
execute the following command
export PATH=/usr/java/jdk1.5.0_13:$PATH



Have you verified the jdk1.5.0_13 directory by doing a ls? Also have you 
added the JAVA_HOME environment code to the tomcat startup.sh script
as recommended in my previous message. With regards to the path setting, 
a corrected update should look like:


export PATH=/usr/java/jdk1.5.0_13/bin:$PATH




--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
for Tomcat, JBoss, and Jetty.
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Setting up multiple instances of Tomcat on one machine

2007-10-30 Thread Gabe Wong
Feel free to try my company's product, NGASI AppServer Manager 
(www.ngasi.com),

which enables you to do just that.

Verma, Sangeeta wrote:

Hello,
Is there a way to setup single installation of Tomcat to deploy multiple
applications running on different ports like app1 on 8080, app2 on 8090
etc.
This topology has been proposed for having a dev/test environment on a
single machine. I want to know if it's feasible and how it can be
achieved.

Your feedback is highly appreciated.
Thanks,
Sangeeta 


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
for Tomcat, JBoss, and Jetty.
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: help with apache-tomcat-6.0.14 install

2007-10-25 Thread Gabe Wong

[EMAIL PROTECTED] wrote:
All, 

I downloaded apache-tomcat-6.0.14 .trying to install it on AIX5.3 . I am 
not able to locate  any install doc . So I have untarted tar file which 
created directories below . I`m guessing that`s how u install it ?
when i try to start it I get java error Neither the JAVA_HOME nor the 
JRE_HOME environment variable is defined. it`s in the path . 

I`m new to the apache-tomcat , please point to the documentation or give 
me some tips .  thanks 



  

[cemcp62]/usr/apache-tomcat-6.0.14/binwhich java

/usr/java14/jre/bin/java
[cemcp62]/usr/apache-tomcat-6.0.14/bin
  
1)First it looks as though you have jdk 1.4 installed. You would 
probably need jdk5 or preferably jdk6. The download/install info for

JDK for AIX can be found at the following URL:
https://www14.software.ibm.com/iwm/web/cc/earlyprograms/ibm/java6/download.shtml

2)after installing JDK, add the following in the startup.sh script file:
export JAVA_HOME=/usr/java/jdk1.6.0/

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration automation
for Tomcat, JBoss, and Jetty.
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: help with apache-tomcat-6.0.14 install

2007-10-25 Thread Gabe Wong

[EMAIL PROTECTED] wrote:

[cemcp62]/usr/apache-tomcat-6.0.14/bin./startup.sh
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program


[cemcp62]/usr/apache-tomcat-6.0.14/binecho $PATH
/usr/java6_64/sdk/bin:/usr/java6_64/sdk/jre:/usr/sbin/acct:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin:/usr/java14/jre/bin:/usr/java14/bin:/usr/local/bin
[cemcp62]/usr/apache-tomcat-6.0.14/bin


  


Shekhar,
Have you added the following towards to the top of the startup.sh script 
file:

export JAVA_HOME=/usr/java6_64/sdk/

--
Regards

Gabe Wong
NGASI AppServer Manager
Application server installation and configuration AUTOMATION
for Tomcat, JBoss, and Jetty.
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Service on Windows Server 2003

2007-10-24 Thread Gabe Wong
if using jdk6, make sure msvcr71.dll is in the path of jvm.dll. The 
easiest thing to do is to copy msvcr71.dll to the jre directory from the 
jdk directory like so:

copy %JDK_HOME%\bin\msvcr71.dll %JDK_HOME%\jre\bin\server\
Dan Armbrust wrote:

I have a difficult but severe problem with the tomcat service launcher
on windows server 2003.

Our application installs itself, tomcat, and a jvm, and then runs a
bat file which registers the tomcat server, using our provided jvm.

I _know_ this code works fine almost everywhere - it has been in use
for years, on dozens of systems.

However, we have a new customer, a 1/2 a world away, who has installed
our application on a Windows Server 2003 box with 4 GB of ram that is
using a Spanish Locale.  The server is brand new - so its an almost
perfectly clean install on windows.

After we register the tomcat service - the service refuses to start
tomcat.  There are no useful error messages - just something along the
lines of the service failed to start.  I'm not sure exactly, because
it's in Spanish.

It looks rather similar to this bug:
http://issues.apache.org/bugzilla/show_bug.cgi?id=41538
which if you ask me, has been closed completely prematurely by someone
who didn't understand the real problem.

When I run the tomcat5w.exe command - all of the parameters are set
correctly.  I cannot find any reason why this service refuses to start
on this particular configuration, yet - it won't run.  And it also
happens on another one of their machines (which is identical).

I also cannot reproduce the problem locally on my test systems - so I
still haven't been able to pinpoint what is different about their
configuration that is triggering this.

Suggestions?

I have very limited ability to do debugging on the system that is
showing the problem.

Thanks,

Dan

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Webapp load order tomcat 4 vs tomcat 5

2007-10-04 Thread Gabe Wong

Sean,
From your description, it seems that communication between the 2 apps 
is done over the wire.
If that is the case, why not run each under a separate JVM/Application 
Server to avoid the class loading conflict.


King, Sean wrote:

Without giving away too much information...

I am working on an integration between the application that I develop
and a third party application. A requirement of the integration is that
my app receive unsolicited notifications from the third party app
relating to status changes. This is achieved via a Muse webservice. The
third party developers have provided my with all of the required Muse
stuff in a war file. The war file contains a class that registers and
maintains connections between my app and the other.

So, to cut a long story short, my app needs to register with the
supplied web app for the integration to work.

This seems to work seamlessly with tomcat5 and this methodology is what
we are planning to go into production with.

Now it sounds like a bad idea!! 


-Original Message-
From: Peter Crowther [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 04, 2007 9:36 AM

To: Tomcat Users List
Subject: RE: Webapp load order tomcat 4 vs tomcat 5

  
From: King, Sean [mailto:[EMAIL PROTECTED] For the application to run 
correctly, app2 must be deployed and start before app1. Using tomcat 5



  
this does not seem to be a problem. When I start tomcat, app2 is 
deployed and then app1 starts and is able to access jars in app2. I am



  

hoping that this start order is not just pure chance!!



It is, indeed, pure chance.

  
I am now trying to port the application back to tomcat 4. 
Unfortunately
I am consistently seeing that app1 starts first and then app2 is 
deployed from the war. Since app1 depends on app2 this is a major 
problem.
 
Is there any way in tomcat 4 to force the war file to be deployed 
first?



Hack the Tomcat source and recompile :-).

More seriously, no, you can't rely on the startup order of webapps.  As
I recall, you can't even assume that only one will be started at one
time (I'm sure the more experienced list members will correct me if the
spec disallows this).  You can try playing around with filenames until
the order magically reverses, or you can amend the apps so that app1
doesn't need to access jars in app2 (which is, anyway, a bit
unpleasant).

Can you give us more information about why app1 needs app2 to start
first?  There may well be ways round the problem.

- Peter

-
To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe,
e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Webapp load order tomcat 4 vs tomcat 5

2007-10-04 Thread Gabe Wong

Actually after re-reading your post, Chuck's suggestion makes better sense.

King, Sean wrote:

Gabe,

Could you provide a little more detail on this? Unfortunately I am no
tomcat expert.

How would running two JVM's help?

Sean

-Original Message-
From: Gabe Wong [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 04, 2007 10:21 AM

To: Tomcat Users List
Subject: Re: Webapp load order tomcat 4 vs tomcat 5

Sean,
 From your description, it seems that communication between the 2 apps
is done over the wire.
If that is the case, why not run each under a separate JVM/Application
Server to avoid the class loading conflict.

King, Sean wrote:
  

Without giving away too much information...

I am working on an integration between the application that I develop 
and a third party application. A requirement of the integration is 
that my app receive unsolicited notifications from the third party app



  
relating to status changes. This is achieved via a Muse webservice. 
The third party developers have provided my with all of the required 
Muse stuff in a war file. The war file contains a class that 
registers and maintains connections between my app and the other.


So, to cut a long story short, my app needs to register with the 
supplied web app for the integration to work.


This seems to work seamlessly with tomcat5 and this methodology is 
what we are planning to go into production with.


Now it sounds like a bad idea!! 


-Original Message-
From: Peter Crowther [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 04, 2007 9:36 AM
To: Tomcat Users List
Subject: RE: Webapp load order tomcat 4 vs tomcat 5

  


From: King, Sean [mailto:[EMAIL PROTECTED] For the application to run
  


  
correctly, app2 must be deployed and start before app1. Using tomcat 
5

  
  

this does not seem to be a problem. When I start tomcat, app2 is 
deployed and then app1 starts and is able to access jars in app2. I 
am

  
  


hoping that this start order is not just pure chance!!

  

It is, indeed, pure chance.

  

I am now trying to port the application back to tomcat 4. 
Unfortunately
I am consistently seeing that app1 starts first and then app2 is 
deployed from the war. Since app1 depends on app2 this is a major 
problem.
 
Is there any way in tomcat 4 to force the war file to be deployed 
first?

  

Hack the Tomcat source and recompile :-).

More seriously, no, you can't rely on the startup order of webapps.  
As I recall, you can't even assume that only one will be started at 
one time (I'm sure the more experienced list members will correct me 
if the spec disallows this).  You can try playing around with 
filenames until the order magically reverses, or you can amend the 
apps so that app1 doesn't need to access jars in app2 (which is, 
anyway, a bit unpleasant).


Can you give us more information about why app1 needs app2 to start 
first?  There may well be ways round the problem.


- Peter

-
To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe,
e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, 
e-mail: [EMAIL PROTECTED]

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



  




--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe,
e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Sending Mail from a Java WebApplication does not work

2007-10-04 Thread Gabe Wong

Arun,
Have you checked your gmail junk folder?

Arun wrote:

Chris,

My mail.log looks like this.(tail mail.log). This is the log created just
now as i send from my webapp.

Oct  4 20:51:07 venus sm-mta[17487]: l950p6C3017485: to=
[EMAIL PROTECTED], delay=00:00:01, xdelay=00:00:01, mailer=esmtp,
pri=120522, relay=gmail-smtp-in.l.google.com. [66.249.83.114], dsn=2.0.0,
stat=Sent (OK 1191517641 h9si2242792wxd)

It says that it is send . But still no mails..

On 10/4/07, Christopher Schultz [EMAIL PROTECTED] wrote:
  

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Arun,

Arun wrote:


I am using commons email and a class called SimpleEmail which is
  

extended


and used.
  

Then there is no Tomcat configuration to be changed. If you were getting
permission errors (for instance, from running under a SecurityManager),
then you'd be getting exceptions all over the place.



Here host name is localhost and portnumber is 25.
  

All I can suggest is adding more logging statements to convince yourself
that the code is actually running.

Make sure you check /all/ log files (if they exist): catalina.out,
localhost*.log|out yourapp_log_[date].txt, log4j.log etc. Also don't
forget to check the log file for sendmail (usually /var/log/mail).

- -chris

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHBRHq9CaO5/Lv0PARAlY2AKCuP2kJgQeKex3CFIIQHOrmEpiONgCeJhvP
HnmSz/Mc0a08gXL9d2CvP1g=
=zMxz
-END PGP SIGNATURE-

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






  



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: client footprint identification for statistic purposes behind a NAT-mode router

2007-10-03 Thread Gabe Wong

Hi,

I do not know what NAT router you are using, but I would check the 
configuration or manual to see that it is setup to forward source IP 
Addresses.



Jorge Martinez wrote:

Thanks Len,

My log entries correspond to clients from the internet. Local clients are
logged as 'localhost', but I have not yet tested what happens with LAN
clients. My problem is however internet clients.

Cheers,


2007/10/3, Len Popp [EMAIL PROTECTED]:
  

Are those log entries with the router's address coming from clients in
the local network, or from the internet?

With my NAT gateway, I see the correct IP addresses for clients coming
in from the internet, but local clients that use the internet site
name (www.mywhatever.com) show up as coming from the router's IP.
--
Len


On 10/3/07, Jorge Martinez [EMAIL PROTECTED] wrote:


Hi,

I have tomcat 5.5 installed and would like to exploit the log records it
  

is


registering.

My problem is that the webserver is behind a router with NAT activated,
  

so


what I see is the same host (actually the router) accessing hundreds of
times to the website, instead of seeing hundreds of single (but
  

different)


users.

Does any of you know anything about this issue? is Tomcat able to store
original host IP in the log files?

Any suggestion would be helpful. Thanks,

Jorge

  

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat/Plesk datasource setup problems

2007-10-03 Thread Gabe Wong
 commands, e-mail:
  

[EMAIL PROTECTED]

  
  


-
  

To start a new topic, e-mail:
users@tomcat.apache.org
To unsubscribe, e-mail:
[EMAIL PROTECTED]
For additional commands, e-mail:
[EMAIL PROTECTED]






-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat/Plesk datasource setup problems

2007-10-03 Thread Gabe Wong
Thanks for clarifying. Sound like you are caught between a rock and a 
hard place.

Good luck.

Charl Gerber wrote:

Costs - the only way I can get a private Tomcat JVM in
South Africa, is dedicated hosting. Ie, renting a
complete machine. Costs are about 10x as much as
shared VM.

As I said, I have a private VM at a US based account
and it works beautifully, but in South Africa (where
the app MUST be hosted), we do not have that option
without very high costs.


--- Gabe Wong [EMAIL PROTECTED] wrote:

  

I am not sure how a private JVM on a VPS or on a
regular shared OS can 
be more difficult than the challenges you are

facing with the present shared JVM. A shared JVM is
good for a very 
basic JSP/Servlet application. However by its nature

(shared), you will not be able to do certain
configurations required for 
more complex applications because that is only

possible
on your own private installation or instance.
Remember on a shared JVM, 
you as well as others are using the same application
server instance and 
JVM.

So image if everyone is able to make changes on the
global configuration 
file e.g. server.xml,etc.




Charl Gerber wrote:


I currently DO have my own Tomcat server, but the
application is now moved to South Africa (site for
  

a


business over there, makes it a lot faster for the
users who will 99% be based in SA) and Tomcat
  

hosting


alone is difficult, leave alone a private JVM.


--- Ken Bowen [EMAIL PROTECTED] wrote:

  
  

Why not move your hosting to an isp who provides


a


vps?
Then you get complete control of your own tomcat;
the whole thing looks and
feels like you have your own server, even though


you

are sharing the 
physical machine.:w


The prices I've seen are comparable to those


where

you have to share 
your tomcat.


My 2 cents...

Ken Bowen

Charl Gerber wrote:



Turns out datasource configuration is not
  

possible


using Plesk as a shared tomcat server, the guys
  

at


Plesk themselves told me.

That sucks. Means I have to create and manage
  

the


Datasource in my app... minor refactoring, but
  

not

  
  

a



nice way of doing it. I also use hibernate and
  
  

could



only get that working by defining its own
  
  

connection



pooling. So now I have two pools :((


--- Pid [EMAIL PROTECTED] wrote:

  
  
  

Charl Gerber wrote:




Hi,

I just moved my hosting from a provider where
  

I

  
  
  

had a




private Tomcat server with complete control
  

over

  
  
  

it to




a provider that uses Plesk and I share the
  
  

Tomcat



server with other users. The provider has no
  
  
  

Tomcat




knowledge in house and the Tomcat service is
  
  
  

rarely




used, so they couldn't help me with this
  
  

problem.


  
  
  

which version of tomcat?





I want to create a jdbc datasource for my
  
  
  

application.




If we manually create it in server.xml, the
  
  
  

provider




claims that the changes are overwritten and
  
  
  

removed




every time someone uploads a new .war file.
  

(Is

  
  
  

this



true?) 
  
  
  

AFAIK, server.xml is not altered by war file
deployments.
Tomcat would need to be restarted in order that
those alterations to
server.xml are evaluated.

I also do not want to define the datasource as




eg a global resource, as it would mean the
  

other

  
  
  

users




of the tomcat server can get access to my
  
  
  

database.




I tried to configure the datasource in the
  
  
  

context.xml




of my application and put it in my .war file.
  
  

This



works fine on my development server, but when
  
  
  

uploaded




to the Tomcat server with Plesk, a server.xml
  
  
  

entry




for my application is created without the
  

=== message truncated ===


-
To start a new topic, e-mail: users

Re: Tomcat hangs when shutting down

2007-09-25 Thread Gabe Wong
)

at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)

at java.net.Socket.connect(Socket.java:519)

at java.net.Socket.connect(Socket.java:469)

at java.net.Socket.init(Socket.java:366)

at java.net.Socket.init(Socket.java:208)

at
org.apache.jk.common.ChannelSocket.unLockSocket(ChannelSocket.java:460)

at org.apache.jk.common.ChannelSocket.pause(ChannelSocket.java:272)

at org.apache.jk.server.JkMain.pause(JkMain.java:657)

at
org.apache.jk.server.JkCoyoteHandler.pause(JkCoyoteHandler.java:202)

at
org.apache.coyote.tomcat5.CoyoteConnector.pause(CoyoteConnector.java:1444)

at
org.apache.catalina.core.StandardService.stop(StandardService.java:521)

at
org.apache.catalina.core.StandardServer.stop(StandardServer.java:2347)

at org.apache.catalina.startup.Catalina.stop(Catalina.java:605)

at org.apache.catalina.startup.Catalina.start(Catalina.java:580)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
)

at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:284)

at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:422)

Sep 26, 2007 9:06:48 AM org.apache.catalina.core.StandardService stop

INFO: Stopping service Catalina

Sep 26, 2007 9:06:48 AM org.apache.catalina.core.StandardHostDeployer remove

INFO: Removing web application at context path /admin

Sep 26, 2007 9:06:48 AM org.apache.catalina.logger.LoggerBase stop

INFO: unregistering logger Catalina:type=Logger,path=/admin,host=localhost

Sep 26, 2007 9:06:48 AM org.apache.catalina.core.StandardHostDeployer remove

INFO: Removing web application at context path /tmca

Sep 26, 2007 9:06:48 AM org.apache.catalina.core.StandardHostDeployer remove

INFO: Removing web application at context path /testcomms

Sep 26, 2007 9:06:48 AM org.apache.catalina.core.StandardHostDeployer remove

INFO: Removing web application at context path /AckMsg

Sep 26, 2007 9:06:48 AM org.apache.catalina.core.StandardHostDeployer remove

INFO: Removing web application at context path /manager

Sep 26, 2007 9:06:48 AM org.apache.catalina.logger.LoggerBase stop

INFO: unregistering logger Catalina:type=Logger,host=localhost

Sep 26, 2007 9:06:48 AM org.apache.catalina.logger.LoggerBase stop

INFO: unregistering logger Catalina:type=Logger

Sep 26, 2007 9:06:48 AM org.apache.coyote.http11.Http11Protocol destroy

INFO: Stopping Coyote HTTP/1.1 on http-80

 

 


Regards,

Andrew


  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat, IIS and Authentication

2007-09-24 Thread Gabe Wong

Jacqueline,
Just to follow your question, Are you asking if it is possible to create 
a custom Tomcat Realm,
where the user/password provided from the java application login page is 
checked against the windows user authentication system?


Preuss, Jacqueline - ENCOWAY wrote:

Hi all!

 


We have an application (hosted with Tomcat) which has to communicate
with the .NET world, i.e. our web application is integrated in an
Asp.Net application hosted by an IIS. So, to connect both we have an
Asp.Net Connector on the one side and a Java Connector on the other
side. If the user selects something on our application the JavaConnector
is called which creates an URLConnection to a specific Asp.Net site. At
the moment, the URLConnection is established with an empty username and
password because we created a specific IIS user which is always the same
for every request. Now, we want to use the integrated windows
authentication, i.e. we want to know which user is currently asking.
That's why we thought on NTLM authentication or something like that...
But we didn't know how to get the credentials in the Java Connector to
establish the connection with Asp.Net. What can we do? Is it generally
possible to use the integrated windows authentication in Java with IIS
and Tomcat? How? Can you give me some tips?

 


Regards,

Jacqueline.

 

 



  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 5.5.25 takes 5 minutes to shut down.

2007-09-24 Thread Gabe Wong

Hi Hermansen,

Check the solution in the following link:
http://www.ngasi.com/ngasihelp/ngasiuserguide/tomcat_fails_shutdown_complete.htm

Hermansen, Erik wrote:

Hello!

I'm running Tomcat 5.5.25 on SLED 10.  I performed the installation of Tomcat manually, 
using the apache-tomcat-5.5.25 archive from Apache's website.  Tomcat will start fine and 
operate as expected, but shutting down is unreliable and often takes about 5 minutes to 
complete.  If I run the $CATALINA_BASE/bin/shutdown.sh script, it will return immediately 
without errors, but checking for the process (ps aux | grep tomcat) shows it 
is still loaded for a long amount of time after the script is called.  On a different 
server with identical hardware and very similar tomcat installation, the shutdown script 
will bring Tomcat down in about 3 seconds.

Reading through catalina.out, I find this error which corresponds to calling 
the shutdown.sh script:

SEVERE: Protocol handler pause failed
java.net.ConnectException: Connection timed out
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
at java.net.Socket.connect(Socket.java:461)
at java.net.Socket.connect(Socket.java:411)
at java.net.Socket.init(Socket.java:310)
at java.net.Socket.init(Socket.java:154)
at org.apache.jk.common.ChannelSocket.unLockSocket(ChannelSocket.java:49
2)
at org.apache.jk.common.ChannelSocket.pause(ChannelSocket.java:289)
at org.apache.jk.server.JkMain.pause(JkMain.java:681)
at org.apache.jk.server.JkCoyoteHandler.pause(JkCoyoteHandler.java:163)
at org.apache.catalina.connector.Connector.pause(Connector.java:1032)
at org.apache.catalina.core.StandardService.stop(StandardService.java:48
9)
at org.apache.catalina.core.StandardServer.stop(StandardServer.java:734)
at org.apache.catalina.startup.Catalina.stop(Catalina.java:602)
at org.apache.catalina.startup.Catalina.start(Catalina.java:577)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:295)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:433)
Sep 19, 2007 3:11:55 AM org.apache.catalina.core.StandardService stop
INFO: Stopping service Catalina
Sep 19, 2007 3:11:56 AM org.apache.coyote.http11.Http11BaseProtocol destroy
INFO: Stopping Coyote HTTP/1.1 on http-8080
Sep 19, 2007 3:11:56 AM org.apache.catalina.core.AprLifecycleListener lifecycleE
vent
INFO: Failed shutdown of Apache Portable Runtime

I've found a couple similar cases where people had this problem.  They resolved 
it by doing something with their network configuration, but in both cases the 
description of their solution was very vague, so I'm not sure how I could 
proceed.

-Erik


  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Vmware and Tomcat 5.x 6.x

2007-09-24 Thread Gabe Wong

Mitesh,
The most important thing with regards to the JVM, is available memory. 
Of extra importance in this case is the amount of memory (REAL/PHYSICAL)
allocated to the Virtual Environment (VMWare). That said, you also need 
to determine the Memory Heap usage of each of the JVM instances.
Sluggishness usually indicates a memory shortage. At that point SWAP 
consumption increases. As you would image disk swap would be much
slower than real memory. Besides sluggishness, SWAP usage may increase 
the chance of disk failure because essentially you are using a 100% of
resources.  In short compare the total Memory Heaps of all the JVMS to 
the total memory allocated to the Virtual Environment of the VMWare 
instance.



Mitesh Shah wrote:

Thanks Chris for reply. Clarion is SAN, so all are data and OS partitions
are on SAN.

Whole server works fine but our application works using tomcat and I have
installed around 20 instances of tomcats on one virtual machine (2.66GHz and
4GB RAM). On similar line, does JDK takes advantage of two CPU compared to
one CPU?

I can reconfigure Swap file on separate disks than OS disk and see if it
performs better.

Please let me know if above info helps in understanding issue better?

Mitesh Shah
Hosted Services Engineer
-Original Message-
From: Christopher Schultz [mailto:[EMAIL PROTECTED] 
Sent: Monday, September 24, 2007 6:01 PM

To: Tomcat Users List
Subject: Re: Vmware and Tomcat 5.x  6.x

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Mitesh,

Mitesh Shah wrote:
  

This is first ever deployment of our product on virtual environment and we
are facing lots of issues of slowness. There are too many variables to
monitor and looking for some path to follow. 



Is the whole server slow, or do you notice that certain operations are slow?

  

I was hoping to get some input as if anyone is aware of such issue of


vmware
  

and tomcat.



AFAIK, there are no Tomcat-specific vmware issues. However, there could
be some problems with the JVM in general that you might be coming
across. For instance, if you are using a source of randomness that
blocks when used through the virtual environment, that might cause a
problem. Also, if you are using non-native disks (meaning a big file on
the host OS that holds the entire filesystem for the VM), you may
experience some slowdown, there.

I'm not sure what Clarion is... could that be a problem at all?

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFG+DOF9CaO5/Lv0PARAtSKAJ0T6KHaEBu8WC6c9QSnea0QWtj/8QCguIhp
VSqAodugC0GLy8LRk5In52I=
=nMgC
-END PGP SIGNATURE-

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  



--
Regards

Gabe Wong
Private JVM JAVA Hosting Automation
http://www.ngasi.com


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]