mod_proxy a risk?

2006-06-16 Thread Christoph Kukulies
I wonder whether mod_proxy can be a security risk in Apache2.0.54,
when being enabled in conjunction with tomcat (5.5).

A machine which is open to the world (on port 80 only) is blacklisted
at cbl.abuseat.org and I wonder how come.

--
Chris Christoph P. U. Kukulies kuku_at_kukulies.org

-
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: Application stop via the manager

2006-06-16 Thread biai

Hello,

I have exactly the same problem.
when I find the answer I'll post it here.
Have you found anything on this?

Silvio
--
View this message in context: 
http://www.nabble.com/Application-stop-via-the-manager-t1257987.html#a4897281
Sent from the Tomcat - User forum at Nabble.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: Apache with Tomcat and session affinity problem

2006-06-16 Thread Filip Hanik - Dev Lists

have you set jvmRoute in your engine element (server.xml)?
this is how mod_jk does session affinity

filipp



Sharma, Siddharth wrote:
I have IBM HttpServer 2.0 (it is an apache essentially) fronting two 
tomcat instances (version 5.5.16) using mod_jk over ajp13. 
I have configured a load balancer worker to spray load across two workers
representing these two tomcat instances. 
And it works. 
The problem is I do not see a session id cookie in the response, so I am not
sure if it is maintaining session affinity. 
I have configured the load balancer worker for session affinity with this
directive in worker.properties: 
worker.lb_worker.sticky_session=True 

What am I missing? 
What is the exact name of the cookie that mod_jk injects?


I apologize if this is not the right mailing list for connector questions
and will appreciate if someone could point me to it.

Thanks in advance
-Sidd 




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


  



--


Filip Hanik

-
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: mod_proxy a risk?

2006-06-16 Thread Filip Hanik - Dev Lists

you should turn off your proxyrequests

ProxyRequests Off

first line in the documentation
http://httpd.apache.org/docs/2.0/mod/mod_proxy.html

you can still use ProxyPass without using proxyrequests

Christoph Kukulies wrote:

I wonder whether mod_proxy can be a security risk in Apache2.0.54,
when being enabled in conjunction with tomcat (5.5).

A machine which is open to the world (on port 80 only) is blacklisted
at cbl.abuseat.org and I wonder how come.

--
Chris Christoph P. U. Kukulies kuku_at_kukulies.org

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


  



--


Filip Hanik

-
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 configuration error

2006-06-16 Thread Filip Hanik - Dev Lists

Fredrik Andersson wrote:

Hi all

Ok so heres the deal. I want my tomcat installation (5.5.17) to load
pages from /var/www/webapps/R2M/SMC

I´m also running a virtual host setup so I edit my server.xml file and
point the appBase for the directory to /var/www/webapps and then I have
the context part of the configuration inside
$CATALINA_HOME/conf/appserve/R2M/SMC.xml in which I point the docBase
  

ok, this path is $CATALINA_HOME/Engine name/Host name

are you saying you renamed your engine element in server.xml to appserve?


variabel to R2M/SMC
  
this is a weird setup, by setting appBase to /var/www/webapps, tomcat 
would want webapps in that directory

so you would have the app in /var/www/webapps/SMC
and tomcat would auto deploy it


Now when I point my webbrowser to a jsp file in my directory I recieve a
404 error.. :(

What went wrong in my configuration?

Any tip/help is greatly appreciated.

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



  



--


Filip Hanik

-
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 configuration error

2006-06-16 Thread Fredrik Andersson
Hi, thanks for answering=)
I´m still a little confused so I will try to describe what kind of setup
I want and we will se if it becomes clearer.

I want my internet files to reside inside of
/var/www/webapps/R2M/SMC

Now I wan´t apache to forward all pages that are jsp (*.jsp) and all
servlets thats are mapped through ip/servlets/* to tomcat.

As it is right now I have HelloWorld.html and HelloWorld.jsp inside the
SMC folder and apache finds them both and the .jsp file gets forwarded
to tomcat (it says that tomcat can´t find the file). Now where is tomcat
looking for the files?

$CATALINA_HOME/conf/server.xml (engine part)
 Engine name=appserver
debug=0
defaultHost=R2M

Host name=R2M
appBase=/var/www/webapps
autoDeploy=false
deployOnStartup=false
unpackWARs=false
deployXML=true
debug=0/

/Engine

then I read that it was good to seperate the context part into a
different file for every host and I understood that they were supposed
to reside inside of $CATALINA_HOME/conf/engine
name/application_name.xml

So I have the file $CATALINA_HOME/appserve/R2M/SMC.xml and it holds
Context path=/
docBase=R2M/SMC
reloadable=true
debug=0/

Did I set this up wrong?


Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:

Fredrik Andersson wrote:
 Hi all

 Ok so heres the deal. I want my tomcat installation (5.5.17) to load
 pages from /var/www/webapps/R2M/SMC

 I´m also running a virtual host setup so I edit my server.xml file and
 point the appBase for the directory to /var/www/webapps and then I have
 the context part of the configuration inside
 $CATALINA_HOME/conf/appserve/R2M/SMC.xml in which I point the docBase

ok, this path is $CATALINA_HOME/Engine name/Host name

are you saying you renamed your engine element in server.xml to appserve?

 variabel to R2M/SMC

this is a weird setup, by setting appBase to /var/www/webapps, tomcat
would want webapps in that directory
so you would have the app in /var/www/webapps/SMC
and tomcat would auto deploy it

 Now when I point my webbrowser to a jsp file in my directory I recieve a
 404 error.. :(

 What went wrong in my configuration?

 Any tip/help is greatly appreciated.

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






--


Filip Hanik

-
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: flushing system.out

2006-06-16 Thread Glenn Holliday
I frequently see it used for debugging.  It's an easy place to log to. 
That's also when you most want unbuffered output.  Is that practice 
discommended for other reasons?

--
Glenn Holliday
Computer Sciences Corporation
[EMAIL PROTECTED] 540-644-6636



This is a PRIVATE message. If you are not the intended recipient, please 
delete without copying and kindly advise us by e-mail of the mistake in 
delivery. NOTE: Regardless of content, this e-mail shall not operate to 
bind CSC to any order or other contract unless pursuant to explicit 
written agreement or government initiative expressly permitting the use of 
e-mail for such purpose.





Tim Funk [EMAIL PROTECTED] 
06/16/2006 07:14 AM
Please respond to
Tomcat Users List users@tomcat.apache.org


To
Tomcat Users List users@tomcat.apache.org
cc

Subject
Re: flushing system.out






I doubt you want to print to system.out in a servlet (or jsp).






-
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: Getting Tomcat to display a web page hosted by HTTPD

2006-06-16 Thread Mann, Bradley
The web application code is directly attempting to load the page with
the

HttpServletResponse.sendRedirect(URL)

method. It seems to be having trouble seeing the file that is hosted by
HTTPD (I assume that Tomcat has no knowledge that it is running behind
httpd).


Thanks,

Brad Mann
Software Engineer - Information Access Services
HARRIS Corporation / GCSD
(321) 984-6292

-Original Message-
From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 15, 2006 6:02 PM
To: Tomcat Users List
Subject: Re: Getting Tomcat to display a web page hosted by HTTPD

how are you redirecting to

http://localhost/Dir1/serverMessage.html

Filip



Mann, Bradley wrote:
 Hello,

 I have Tomcat running a web application behind HTTPD using the Jakarta
 connector. Here is my scenario:

 I navigate to http://localhost/Dir1/

 This is essentially a login page for my web application. The login
link
 directs to

 http://localhost/webapps/MyApp/servlet/Login?Tool=X

 And HTTPD uses this context path to start my web application.

 The problem I am having is getting my web application to display a web
 page that is located in a folder in the document_root of HTTPD, namely

 http://localhost/Dir1/serverMessage.html

 Every time the web application attempts to display this page I instead
 get a 404 error, stating Dir1/serverMessage.html cannot be found. How
 can I get my web application to display this page?

 Thanks,

 Brad Mann
 Software Engineer - Information Access Services
 HARRIS Corporation / GCSD
 (321) 984-6292


   



 No virus found in this incoming message.
 Checked by AVG Free Edition.
 Version: 7.1.394 / Virus Database: 268.8.4/364 - Release Date:
6/14/2006
   


-- 


Filip Hanik

-
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: flushing system.out

2006-06-16 Thread Filip Hanik - Dev Lists
System.out.println is a synchronized call, and will become a performance 
bottleneck on highly concurrent applications,

the ideal is to use a logging framework, and setup an async logger

Filip


Glenn Holliday wrote:
I frequently see it used for debugging.  It's an easy place to log to. 
That's also when you most want unbuffered output.  Is that practice 
discommended for other reasons?


--
Glenn Holliday
Computer Sciences Corporation
[EMAIL PROTECTED] 540-644-6636



This is a PRIVATE message. If you are not the intended recipient, please 
delete without copying and kindly advise us by e-mail of the mistake in 
delivery. NOTE: Regardless of content, this e-mail shall not operate to 
bind CSC to any order or other contract unless pursuant to explicit 
written agreement or government initiative expressly permitting the use of 
e-mail for such purpose.






Tim Funk [EMAIL PROTECTED] 
06/16/2006 07:14 AM

Please respond to
Tomcat Users List users@tomcat.apache.org


To
Tomcat Users List users@tomcat.apache.org
cc

Subject
Re: flushing system.out






I doubt you want to print to system.out in a servlet (or jsp).






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


  



--


Filip Hanik

-
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 configuration error

2006-06-16 Thread Fredrik Andersson
ok, and my R2M.xml configuration file should reside inside of
$CATALINA_HOME/appserver/R2M ? or did I missunderstand you on that part?
Will try it out, thanks a million. Really nice of you taking youre time
explaining this to me :)

Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:

the more logical setup would be (assuming the SMC is a webapp)

Engine name=appserver
debug=0
defaultHost=R2M

Host name=R2M
appBase=/var/www/webapps/RM2
autoDeploy=false
deployOnStartup=false
unpackWARs=false
deployXML=true
debug=0/

/Engine

Context path=
docBase=SMC
reloadable=true
debug=0/

I changed three things
1. Host.appBase
2. Context.path
3. Context.docBase

Filip



Fredrik Andersson wrote:
 Hi, thanks for answering=)
 I´m still a little confused so I will try to describe what kind of setup
 I want and we will se if it becomes clearer.

 I want my internet files to reside inside of
 /var/www/webapps/R2M/SMC

 Now I wan´t apache to forward all pages that are jsp (*.jsp) and all
 servlets thats are mapped through ip/servlets/* to tomcat.

 As it is right now I have HelloWorld.html and HelloWorld.jsp inside the
 SMC folder and apache finds them both and the .jsp file gets forwarded
 to tomcat (it says that tomcat can´t find the file). Now where is tomcat
 looking for the files?

 $CATALINA_HOME/conf/server.xml (engine part)
  Engine name=appserver
 debug=0
 defaultHost=R2M

 Host name=R2M
 appBase=/var/www/webapps/RM2
 autoDeploy=false
 deployOnStartup=false
 unpackWARs=false
 deployXML=true
 debug=0/

 /Engine

 then I read that it was good to seperate the context part into a
 different file for every host and I understood that they were supposed
 to reside inside of $CATALINA_HOME/conf/engine
 name/application_name.xml

 So I have the file $CATALINA_HOME/appserve/R2M/SMC.xml and it holds
 Context path=/
 docBase=SMC
 reloadable=true
 debug=0/

 Did I set this up wrong?


 Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:


 Fredrik Andersson wrote:

 Hi all

 Ok so heres the deal. I want my tomcat installation (5.5.17) to load
 pages from /var/www/webapps/R2M/SMC

 I´m also running a virtual host setup so I edit my server.xml file and
 point the appBase for the directory to /var/www/webapps and then I have
 the context part of the configuration inside
 $CATALINA_HOME/conf/appserve/R2M/SMC.xml in which I point the docBase


 ok, this path is $CATALINA_HOME/Engine name/Host name

 are you saying you renamed your engine element in server.xml to appserve?


 variabel to R2M/SMC


 this is a weird setup, by setting appBase to /var/www/webapps, tomcat
 would want webapps in that directory
 so you would have the app in /var/www/webapps/SMC
 and tomcat would auto deploy it


 Now when I point my webbrowser to a jsp file in my directory I recieve a
 404 error.. :(

 What went wrong in my configuration?

 Any tip/help is greatly appreciated.

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





 --


 Filip Hanik

 -
 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]






--


Filip Hanik

-
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]



Newbie - can't identify her problem -

2006-06-16 Thread carrie . latimer
I'm using tomcat 5.0.19...I get a 404 error but I cannot figure out why
when I run:
http://localhost:8080/SplitTransaction/login.jsp.   I am not getting any
errors when I compile and I can see my *.class files in .deployables.  I do
get unknown tag warnings (with any html or message prefix - an example is
html:cancel )..  I'm stuck I do not know where to go from here.  Please
point me in a direction to identify and resolve whatever my issue is.  Many
thanks in advance.
 Here are my files:
config.xml
?xml version=1.0 encoding=ISO-8859-1 ?

!DOCTYPE struts-config PUBLIC
  -//Apache Software Foundation//DTD Struts Configuration 1.2//EN
  c:\carrie\struts-config_1_2.dtd

!--
 This is a blank Struts configuration file with an example
 welcome action/page and other commented sample elements.

 Tiles and the Struts Validator are configured using the factory
defaults
 and are ready-to-use.

 NOTE: If you have a generator tool to create the corresponding Java
classes
 for you, you could include the details in the form-bean
declarations.
 Otherwise, you would only define the form-bean element itself, with
the
 corresponding name and type attributes, as shown here.
--


struts-config

!--  Data Source Configuration
--
!--
data-sources
data-source type=org.apache.commons.dbcp.BasicDataSource
set-property
  property=driverClassName
  value=org.postgresql.Driver /
set-property
  property=url
  value=jdbc:postgresql://localhost/mydatabase /
set-property
  property=username
  value=me /
set-property
  property=password
  value=test /
set-property
  property=maxActive
  value=10 /
set-property
  property=maxWait
  value=5000 /
set-property
  property=defaultAutoCommit
  value=false /
set-property
  property=defaultReadOnly
  value=false /
set-property
  property=validationQuery
  value=SELECT COUNT(*) FROM market /
/data-source
/data-sources
--

!--  Form Bean Definitions
--

form-beans
!-- sample form bean descriptor for an ActionForm
form-bean
name=inputForm
type=app.InputForm/
end sample --

!-- sample form bean descriptor for a DynaActionForm
form-bean
name=logonForm
type=org.apache.struts.action.DynaActionForm
form-property
name=username
type=java.lang.String/
form-property
name=password
type=java.lang.String/
   /form-bean
end sample --
form-bean
  name=LoginForm
  type=com.patron.split.login.LoginForm/
/form-beans


!-- = Global Exception Definitions
--

global-exceptions
!-- sample exception handler
exception
key=expired.password
type=app.ExpiredPasswordException
path=/changePassword.jsp/
end sample --
/global-exceptions


!-- === Global Forward Definitions
--

global-forwards
!-- Default forward to Welcome action --
!-- Demonstrates using index.jsp to forward --
forward
name=welcome
path=/Welcome.do/
/global-forwards


!-- === Action Mapping Definitions
--

action-mappings
!-- Default Welcome action --
!-- Forwards to Welcome.jsp --
action
path=/Welcome
forward=/pages/Welcome.jsp/

!-- sample input and input submit actions

action
path=/Input
type=org.apache.struts.actions.ForwardAction
parameter=/pages/Input.jsp/

action
path=/InputSubmit
type=app.InputAction
name=inputForm
scope=request
validate=true
input=/pages/Input.jsp/

action
path=/edit*
type=app.Edit{1}Action
name=inputForm
scope=request
validate=true
input=/pages/Edit{1}.jsp/

end samples --

action
  path=/login
  type=com.patron.split.login.LoginAction
  name=LoginForm
  scope=request
  validate=true
  input=/pages/login.jsp
  forward name=success path=/pages/split.jsp/
/action
/action-mappings


!-- = Controller Configuration
--

controller
   processorClass=org.apache.struts.tiles.TilesRequestProcessor/


!--  Message Resources Definitions
--

message-resources parameter=MessageResources /


!-- 

Re: Tomcat configuration error

2006-06-16 Thread Fredrik Andersson
ok, the application I want to launch is SMC so where should I place the
SMC.xml file?

I´m really confused, not because I dont know what I want to do, but there
are tons of different sources telling me different things and none
works.. :(

I understand that I must be anoying and it´s really nice of you to help
me. =)

Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:

R2M.xml? where did that come from? it should be SCM.xml, although the
name isn't important.

Your original setup was confusing, cause you have RM2/SCM (inside of
webapps)
so which one is the webapp, RM2 directory, or the SCM directory?

They key to your problem though, is probably the Context path=...
instead of Context path=/...

Filip


Fredrik Andersson wrote:
 ok, and my R2M.xml configuration file should reside inside of
 $CATALINA_HOME/appserver/R2M ? or did I missunderstand you on that part?
 Will try it out, thanks a million. Really nice of you taking youre time
 explaining this to me :)

 Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:


 the more logical setup would be (assuming the SMC is a webapp)

 Engine name=appserver
debug=0
defaultHost=R2M

Host name=R2M
appBase=/var/www/webapps/RM2
autoDeploy=false
deployOnStartup=false
unpackWARs=false
deployXML=true
debug=0/

/Engine

 Context path=
docBase=SMC
reloadable=true
debug=0/

 I changed three things
 1. Host.appBase
 2. Context.path
 3. Context.docBase

 Filip



 Fredrik Andersson wrote:

 Hi, thanks for answering=)
 I´m still a little confused so I will try to describe what kind of setup
 I want and we will se if it becomes clearer.

 I want my internet files to reside inside of
 /var/www/webapps/R2M/SMC

 Now I wan´t apache to forward all pages that are jsp (*.jsp) and all
 servlets thats are mapped through ip/servlets/* to tomcat.

 As it is right now I have HelloWorld.html and HelloWorld.jsp inside the
 SMC folder and apache finds them both and the .jsp file gets forwarded
 to tomcat (it says that tomcat can´t find the file). Now where is tomcat
 looking for the files?

 $CATALINA_HOME/conf/server.xml (engine part)
  Engine name=appserver
 debug=0
 defaultHost=R2M

 Host name=R2M
 appBase=/var/www/webapps/RM2
 autoDeploy=false
 deployOnStartup=false
 unpackWARs=false
 deployXML=true
 debug=0/

 /Engine

 then I read that it was good to seperate the context part into a
 different file for every host and I understood that they were supposed
 to reside inside of $CATALINA_HOME/conf/engine
 name/application_name.xml

 So I have the file $CATALINA_HOME/appserve/R2M/SMC.xml and it holds
 Context path=/
 docBase=SMC
 reloadable=true
 debug=0/

 Did I set this up wrong?


 Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:



 Fredrik Andersson wrote:


 Hi all

 Ok so heres the deal. I want my tomcat installation (5.5.17) to load
 pages from /var/www/webapps/R2M/SMC

 I´m also running a virtual host setup so I edit my server.xml file and
 point the appBase for the directory to /var/www/webapps and then I have
 the context part of the configuration inside
 $CATALINA_HOME/conf/appserve/R2M/SMC.xml in which I point the docBase



 ok, this path is $CATALINA_HOME/Engine name/Host name

 are you saying you renamed your engine element in server.xml to appserve?



 variabel to R2M/SMC



 this is a weird setup, by setting appBase to /var/www/webapps, tomcat
 would want webapps in that directory
 so you would have the app in /var/www/webapps/SMC
 and tomcat would auto deploy it



 Now when I point my webbrowser to a jsp file in my directory I recieve a
 404 error.. :(

 What went wrong in my configuration?

 Any tip/help is greatly appreciated.

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






 --


 Filip Hanik

 -
 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]





 --


 Filip Hanik


RE: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sanjeev Kumar Bhat, Noida

JSESSIONID is a non-persistent cookie and you can check its presence easily 
using a Netscape Navigator or FireFox. 
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right 
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.
 
If you don't see the cookie, then definitely there is some issue.
 



From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
  
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am

 not
  
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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


  



  


--


Filip Hanik

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





DISCLAIMER:
---
The contents of this e-mail and any attachment(s) are confidential and intended 
for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its affiliates. 
Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect the 
opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification, 
distribution and / or publication of 
this message without the prior written consent of the author of this e-mail is 
strictly prohibited. If you have 
received this email in error please delete it and notify the sender 
immediately. Before opening any mail and 
attachments please check them for viruses and defect.
---

Re: Tomcat configuration error

2006-06-16 Thread Filip Hanik - Dev Lists
no worries, lets start from the beginning, after that I will send you 
off to take a tomcat and/or servlet tutorial


Host appBase=/var/www/webapps...

The appbase is where tomcat will autodeploy applications from, an 
application, or webapp is defined by two means

1. A directory
2. A war file

So in your case, the directory SMC is your webapp, hence the path to the 
application would be:

/var/www/webapps/SMC (with subdirectories and files like below)
 - WEB-INF
   - web.xml
 - index.jsp

You have four choices to deploy this webapp

1. put the SCM directory inside Host.appBase, ie, /var/www/webapps/SCM
  The app will get deployed as /SCM

2. put the SCM directory inside Host.appBase, ie, /var/www/webapps/SCM
  and put SCM.xml inside TC_HOME/conf/appserver/RM2/
  The app will get deployed twice, /SCM and /

3. put the SCM directory inside Host.appBase, ie, /var/www/webapps/SCM
  Create a file named context.xml ie 
/var/www/webapps/SCM/META-INF/context.xml
  The app will get deployed once as /, tomcat will automatically 
create SCM.xml inside TC_HOME/conf/appserver/RM2/


4. Put the SCM directory anywhere on the file system, for example /tmp/SCM
  and put SCM.xml inside TC_HOME/conf/appserver/RM2/
  and inside SCM.xml do Context docBase=/tmp/SCM path=/
  The app will get deployed once as /

Filip


Fredrik Andersson wrote:

ok, the application I want to launch is SMC so where should I place the
SMC.xml file?

I´m really confused, not because I dont know what I want to do, but there
are tons of different sources telling me different things and none
works.. :(

I understand that I must be anoying and it´s really nice of you to help
me. =)

Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:

  

R2M.xml? where did that come from? it should be SCM.xml, although the
name isn't important.

Your original setup was confusing, cause you have RM2/SCM (inside of
webapps)
so which one is the webapp, RM2 directory, or the SCM directory?

They key to your problem though, is probably the Context path=...
instead of Context path=/...

Filip


Fredrik Andersson wrote:


ok, and my R2M.xml configuration file should reside inside of
$CATALINA_HOME/appserver/R2M ? or did I missunderstand you on that part?
Will try it out, thanks a million. Really nice of you taking youre time
explaining this to me :)

Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:


  

the more logical setup would be (assuming the SMC is a webapp)

Engine name=appserver
   debug=0
   defaultHost=R2M

   Host name=R2M
   appBase=/var/www/webapps/RM2
   autoDeploy=false
   deployOnStartup=false
   unpackWARs=false
   deployXML=true
   debug=0/

   /Engine

Context path=
   docBase=SMC
   reloadable=true
   debug=0/

I changed three things
1. Host.appBase
2. Context.path
3. Context.docBase

Filip



Fredrik Andersson wrote:



Hi, thanks for answering=)
I´m still a little confused so I will try to describe what kind of setup
I want and we will se if it becomes clearer.

I want my internet files to reside inside of
/var/www/webapps/R2M/SMC

Now I wan´t apache to forward all pages that are jsp (*.jsp) and all
servlets thats are mapped through ip/servlets/* to tomcat.

As it is right now I have HelloWorld.html and HelloWorld.jsp inside the
SMC folder and apache finds them both and the .jsp file gets forwarded
to tomcat (it says that tomcat can´t find the file). Now where is tomcat
looking for the files?

$CATALINA_HOME/conf/server.xml (engine part)
 Engine name=appserver
debug=0
defaultHost=R2M

Host name=R2M
appBase=/var/www/webapps/RM2
autoDeploy=false
deployOnStartup=false
unpackWARs=false
deployXML=true
debug=0/

/Engine

then I read that it was good to seperate the context part into a
different file for every host and I understood that they were supposed
to reside inside of $CATALINA_HOME/conf/engine
name/application_name.xml

So I have the file $CATALINA_HOME/appserve/R2M/SMC.xml and it holds
Context path=/
docBase=SMC
reloadable=true
debug=0/

Did I set this up wrong?


Den 6/16/2006, skrev Filip Hanik - Dev Lists [EMAIL PROTECTED]:



  

Fredrik Andersson wrote:




Hi all

Ok so heres the deal. I want my tomcat installation (5.5.17) to load
pages from /var/www/webapps/R2M/SMC

I´m also running a virtual host setup so I edit my server.xml file and
point the appBase for the directory to /var/www/webapps and then I have
the context part of the 

RE: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sharma, Siddharth
I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 10:15 AM
To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox. 
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.
 
If you don't see the cookie, then definitely there is some issue.
 



From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
  
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am

 not
  
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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


  



  


--


Filip Hanik

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





DISCLAIMER:

---
The contents of this e-mail and any attachment(s) are confidential and
intended for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its
affiliates. Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect
the opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification,
distribution and / or publication of 
this message without the prior written consent of the author of this e-mail
is strictly prohibited. If you have 
received this email in error please delete it and notify the sender
immediately. Before opening any mail and 
attachments please check them for viruses and defect.

---

-
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: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sharma, Siddharth
Ok here's a little confusion:

In server.xml, there are two Engine tags, one of them is commented out by
default.
As can be seen I left the commented out 'standalone' engine as is and added
jvmRoute to engine named 'Catalina'.
Is that the problem?
Should I add it to the 'standalone' engine and uncomment it and comment out
the 'Catalina' engine? 
Or should I have both uncommented?

I will try the permutations but if someone knows, it will save me some time
;)

!-- You should set jvmRoute to support load-balancing via AJP ie :
Engine name=Standalone defaultHost=localhost
jvmRoute=tomcat_worker_2 
-- 
 
!-- Define the top level container in our container hierarchy --
Engine name=Catalina defaultHost=localhost
jvmRoute=tomcat_worker_2

-Original Message-
From: Sharma, Siddharth 
Sent: Friday, June 16, 2006 10:40 AM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 10:15 AM
To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox. 
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.
 
If you don't see the cookie, then definitely there is some issue.
 



From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
  
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am

 not
  
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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


  



  


--


Filip Hanik

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





DISCLAIMER:

---
The contents of this e-mail and any attachment(s) are confidential and
intended for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its
affiliates. Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect
the opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification,
distribution and / or publication of 
this message without the prior written consent of the author of this e-mail
is strictly prohibited. If you have 
received this email in error please delete it and notify the 

Re: Apache with Tomcat and session affinity problem

2006-06-16 Thread Filip Hanik - Dev Lists
is your webapplication creating a session? if not, then there wont be a 
cookie, and mod_jk uses this cookie to determine server affinity.


and if you dont have sessions, you don't need session affinity

Filip


Sharma, Siddharth wrote:

I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 10:15 AM

To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox. 
In Firefox go to Tools-Options, Options Popup appears.

Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.
 
If you don't see the cookie, then definitely there is some issue.
 




From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
  

Yes I did
jvmRoute is set to the worker name.
still, no jsessionid cookie.





-Original Message-
From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Friday, June 16, 2006 7:18 AM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem

have you set jvmRoute in your engine element (server.xml)?
this is how mod_jk does session affinity

filipp



Sharma, Siddharth wrote:
 


I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
tomcat instances (version 5.5.16) using mod_jk over ajp13.
I have configured a load balancer worker to spray load across two workers
representing these two tomcat instances.
And it works.
The problem is I do not see a session id cookie in the response, so I am
   
  

not
 


sure if it is maintaining session affinity.
I have configured the load balancer worker for session affinity with this
directive in worker.properties:
worker.lb_worker.sticky_session=True

What am I missing?
What is the exact name of the cookie that mod_jk injects?

I apologize if this is not the right mailing list for connector questions
and will appreciate if someone could point me to it.

Thanks in advance
-Sidd



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


 
   
  
 




--


Filip Hanik

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





DISCLAIMER:

---
The contents of this e-mail and any attachment(s) are confidential and
intended for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its
affiliates. Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect
the opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification,
distribution and / or publication of 
this message without the prior written consent of the author of this e-mail
is strictly prohibited. If you have 
received this email in error please delete it and notify the sender
immediately. Before opening any mail and 
attachments please check them for viruses and defect.


---

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


  



--


Filip Hanik

-
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 SSL, after clientAuth=false worked, how to set up to true?

2006-06-16 Thread frankpeng
Gaël 
 
Sorry, I am so lazy I did not change the names. I will change it next time. 
 
Yes, I am working on Windows.
All of the command are translated into Windows commands and there is no error 
after I fixed some commands and type errors.
 
The problem is that Microsoft Internet Explore and Netscape now are serious 
about the Root Trust Authorities. Now both of the browsers are not working with 
the procudure you posted. I am looking for the procedure with CAcert.org. It is 
free to get their certificates for a server and a client. 
 
I believe the browsers and the Tomcat really talked, they failed because the 
root authority problems. The error # on Netscape is 8182. If you have an 
Openssl solution based on you procedure, that will be great. Otherwise we have 
to ask help from CAcert.org.
 
As you know I already typed all commands into Window's Batch file. It is easy 
to make a completely automatical program to set up everything. If you will work 
on OPenssl, I would assist with you to make the auto-configure program both on 
Windows and on Linux. That will be contribute to this community a lot. Right?
 
Thank you again. Sorry about that again.
 
Frank Peng.
 
-Original Message-
From: Gaël Lams [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Fri, 16 Jun 2006 13:48:03 +0200
Subject: Re: Tomcat SSL, after clientAuth=false worked, how to set up to 
true?


 Now, in this procedure, there are 3 aliases, itcilo_ca, map-test and 
 santiago, which I cannot understand. 
 
imagination please: map-test was the name of my host at that time, 
santiago was the name of one of the users used for the testing, itcilo 
is the acronym of my organization, that's why I named my certificate 
authority itcilo_ca ;-) 
 There already has an alias tomcat inside the keystore. Should we use it? 
  
 P.S. I have created ,BAT file for each command.  
 
I wrote what worked for me on my environment (SuSe 9.3, JRE 1.5, Tomcat 5.5.x). 
You give no indication on the OS/Tomcat version/ of your system 
but you are talking about BAT file, so I imagine it's windows, isn't 
it? I've no idea whether what I did could work on Windows, it should 
work on linux-based distribution. Anyway you really should try to read 
again what I wrote and understand what I'm trying to do, because I 
noticed a few typing mistakes in what I wrote, so copy-paste will not 
work. Also modify it to correspond to your system (giving name that 
makes sense to you). 
 
Kind regards 
 
Gaël 


RE: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sharma, Siddharth
It is slightly more complicated that that.
We are creating a session but not an HttpSession, a C++ session.
The Tomcat web app essentially has a servlet that delegates to the C++
component using JNI.

Should we create an HttpSession before delegating?
Is that the missing link?

Thanks
Sidd

-Original Message-
From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 10:59 AM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem

is your webapplication creating a session? if not, then there wont be a 
cookie, and mod_jk uses this cookie to determine server affinity.

and if you dont have sessions, you don't need session affinity

Filip


Sharma, Siddharth wrote:
 I have an http packet sniffer and it is reporting that there are no
cookies
 returned by apache.

 Just to recap what I have done:
 1. IBM HttpServer 2.0 with mod_jk on redhat linux
 2. worker.properties has a load-balancer worker fronting two tomcat
workers
 over ajp13. it's sticky session property is set to True.
 3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
 instances) have their respective worker names (no case difference or silly
 spelling mistakes).

 There is no cookie. Is there another step that I am missing to enable
 session affinity?




 -Original Message-
 From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
 Sent: Friday, June 16, 2006 10:15 AM
 To: Tomcat Users List; Tomcat Users List
 Subject: RE: Apache with Tomcat and session affinity problem


 JSESSIONID is a non-persistent cookie and you can check its presence
easily
 using a Netscape Navigator or FireFox. 
 In Firefox go to Tools-Options, Options Popup appears.
 Select Privacy in the left section, to get the privacy options on the
right
 side of the popup
 Expand the Node Cookies and click on button View Cookies.
 You can see the cookie JSESSIONID with its value.
  
 If you don't see the cookie, then definitely there is some issue.
  

 

 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Fri 6/16/2006 7:21 PM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem



 how do you verify that you don't have a cookie?

 I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

 Filip


 Sharma, Siddharth wrote:
   
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
  
 
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two
workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am

   
 not
  
 
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with
this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector
questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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


  

   
  
 


 --


 Filip Hanik

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





 DISCLAIMER:


 ---
 The contents of this e-mail and any attachment(s) are confidential and
 intended for the named recipient(s) only. 
 It shall not attach any liability on the originator or HCL or its
 affiliates. Any views or opinions presented in 
 this email are solely those of the author and may not necessarily reflect
 the opinions of HCL or its affiliates. 
 Any form of reproduction, dissemination, copying, disclosure,
modification,
 distribution and / or publication of 
 this message without the prior written consent of the author of this
e-mail
 is strictly prohibited. If you have 
 received this email in error please delete it and notify the sender
 immediately. Before opening any mail and 
 attachments please check them for viruses and defect.


RE: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sanjeev Kumar Bhat, Noida
---BeginMessage---
The names of your workers are not correct. It should be alphanumeric only. 
Refer to http://tomcat.apache.org/connectors-doc/config/workers.html
 
Sanjeev



From: Sharma, Siddharth [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 8:23 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem



Ok here's a little confusion:

In server.xml, there are two Engine tags, one of them is commented out by
default.
As can be seen I left the commented out 'standalone' engine as is and added
jvmRoute to engine named 'Catalina'.
Is that the problem?
Should I add it to the 'standalone' engine and uncomment it and comment out
the 'Catalina' engine?
Or should I have both uncommented?

I will try the permutations but if someone knows, it will save me some time
;)

!-- You should set jvmRoute to support load-balancing via AJP ie :
Engine name=Standalone defaultHost=localhost
jvmRoute=tomcat_worker_2
--

!-- Define the top level container in our container hierarchy --
Engine name=Catalina defaultHost=localhost
jvmRoute=tomcat_worker_2

-Original Message-
From: Sharma, Siddharth
Sent: Friday, June 16, 2006 10:40 AM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED]
Sent: Friday, June 16, 2006 10:15 AM
To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox.
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.

If you don't see the cookie, then definitely there is some issue.




From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
 
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am
   
 not
 
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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


 
   


 


--


Filip Hanik

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





DISCLAIMER:

---
The contents of this e-mail and any attachment(s) are confidential and
intended for the named recipient(s) only.
It shall not attach any liability on the originator or HCL or its
affiliates. Any views or opinions presented in
this email are solely those of the author and may 

Rising Active Sessions in Jboss ClusterManager

2006-06-16 Thread Sanjeev Kumar Bhat, Noida

Hi,
 
We have a cluster of JBoss Servers (2 in number) on AIX boxes using Apche + 
mod_jk. The server was restarted 24 hours ago and we executed a load test with 
350 users for 3 hours which has just finished.
 
I looked into the Cluster Manager view of the Jboss Web-Console (JMX MBEANS - 
JBoss-Web - jboss.web:service=ClusterManager) to see the Active Sessions. The 
MBEAN displayed the following information:
 
CreatedSessionCount   18501   
ActiveSessionCount  3437  .
ExpiredSessionCount 3536
 
I can understand that the Created session count and Expired Session Count can 
be a huge number because that is the number of times a session was created/ 
destroyed on the server ever since it started. My question is why is the Active 
Session Count so high when we are load testing with just 350 VUsers? 
 
Thanks
Sanjeev



DISCLAIMER:
---
The contents of this e-mail and any attachment(s) are confidential and intended 
for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its affiliates. 
Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect the 
opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification, 
distribution and / or publication of 
this message without the prior written consent of the author of this e-mail is 
strictly prohibited. If you have 
received this email in error please delete it and notify the sender 
immediately. Before opening any mail and 
attachments please check them for viruses and defect.
---

Re: Tomcat not setting session cookies ??

2006-06-16 Thread Len Popp

Are you sure it's not using session cookies at all, or is it only on
the welcome page that you see the jsessionid? The first request to the
server naturally doesn't include a session cookie, and the server
can't know that the browser has accepted the cookie until the browser
sends the cookie back in a subsequent request. So you have to click a
link or two from the welcome page before the jsessionids disappear
entirely from the URLs.
--
Len

On 6/16/06, Mon Cab [EMAIL PROTECTED] wrote:

Hi


All of a sudden tomcat has stopped settign session cookies.  I have
been developing on my local machine for approx 1yr. Now, When I goto my
webapps home page.  (http:/127.0.0.1:8080/webapp), tomcat is rewriting
the URL as
http://127.0.0.1:8080/webapp/Welcome.do;jsessionid=DAF0604E76E234C157A9BFDF53FD2617
indicating that it is not setting a session cookie.  When I check the
session cookie folder C:\Documents and Settings\user\Cookies, there is
no jsessionid cookie.

When I set a cookie from within webapp, the cookie is set as normal and
stored in the cookie folder C:\Documents and Settings\user\Cookies, and
is retrieved by my web application.

Why is Tomcat not setting a session cookie?

I configured my browser to accept all session cookies.  I am using
Windows XP Pro, with IE6.  j2sdk1.4.2_08, Tomcat 5.0.28.

This has been working as it is supposed to for 1 year.

Can anyone explain what is going on?





__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.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]



RE: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sanjeev Kumar Bhat, Noida

 
The names of your workers are not correct. It should be alphanumeric only. 
Refer to http://tomcat.apache.org/connectors-doc/config/workers.html
 
Sanjeev



From: Sharma, Siddharth [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 8:23 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem



Ok here's a little confusion:

In server.xml, there are two Engine tags, one of them is commented out by
default.
As can be seen I left the commented out 'standalone' engine as is and added
jvmRoute to engine named 'Catalina'.
Is that the problem?
Should I add it to the 'standalone' engine and uncomment it and comment out
the 'Catalina' engine?
Or should I have both uncommented?

I will try the permutations but if someone knows, it will save me some time
;)

!-- You should set jvmRoute to support load-balancing via AJP ie :
Engine name=Standalone defaultHost=localhost
jvmRoute=tomcat_worker_2
--

!-- Define the top level container in our container hierarchy --
Engine name=Catalina defaultHost=localhost
jvmRoute=tomcat_worker_2

-Original Message-
From: Sharma, Siddharth
Sent: Friday, June 16, 2006 10:40 AM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED]
Sent: Friday, June 16, 2006 10:15 AM
To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox.
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.

If you don't see the cookie, then definitely there is some issue.




From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
 
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am
   
 not
 
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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


 
   


 


--


Filip Hanik

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





DISCLAIMER:

---
The contents of this e-mail and any attachment(s) are confidential and
intended for the named recipient(s) only.
It shall not attach any liability on the originator or HCL or its
affiliates. Any views or opinions presented in
this email are solely those of the author and may not necessarily 

Tomcat 5.5 / IIS 6 web server log question

2006-06-16 Thread 0 8

Hello,

I have Tomcat 5.5 and IIS 6 integrated using isapi_redirect.dll.  So
far, they are working together just fine.

I noticed in my IIS web server logs that the GET requests are not
being recorded as I would expect.  I'm currently seeing...

GET /jakarta/isapi_redirect.dll

...when I expected to see...

GET /hello.jsp

...since hello.jsp is the file I actually requsted.

Is there a setting I've missed somewhere to keep the IIS logs as I
expected or do I have to now maintain both IIS and Tomcat access logs?

Thanks,
Matt

-
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: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sharma, Siddharth
My bad. Did not read documentation.

Thanks


-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 12:31 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


 
The names of your workers are not correct. It should be alphanumeric only.
Refer to http://tomcat.apache.org/connectors-doc/config/workers.html
 
Sanjeev



From: Sharma, Siddharth [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 8:23 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem



Ok here's a little confusion:

In server.xml, there are two Engine tags, one of them is commented out by
default.
As can be seen I left the commented out 'standalone' engine as is and added
jvmRoute to engine named 'Catalina'.
Is that the problem?
Should I add it to the 'standalone' engine and uncomment it and comment out
the 'Catalina' engine?
Or should I have both uncommented?

I will try the permutations but if someone knows, it will save me some time
;)

!-- You should set jvmRoute to support load-balancing via AJP ie :
Engine name=Standalone defaultHost=localhost
jvmRoute=tomcat_worker_2
--

!-- Define the top level container in our container hierarchy --
Engine name=Catalina defaultHost=localhost
jvmRoute=tomcat_worker_2

-Original Message-
From: Sharma, Siddharth
Sent: Friday, June 16, 2006 10:40 AM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED]
Sent: Friday, June 16, 2006 10:15 AM
To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox.
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.

If you don't see the cookie, then definitely there is some issue.




From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
 
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am
   
 not
 
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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


 
   


 


--


Filip Hanik

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





DISCLAIMER:

---
The contents of this e-mail and any 

problems with tomcat and JSF on Linux

2006-06-16 Thread Sorin Silaghi

Hello,

I have just started using Tomcat for developing JSF apps. I've
started by making some JSP pages to get the hang of that. And all was great
until I switched over to JSF (MyFaces). First of all the server has a bit of
a problem with new files added in the webapps directory. Alot of the time I
have to restart the server for it to see the new pages aded(dono if that's
normal but I was expecting something more responsive). When at last I
managed to get my hands on some examples that where sure to work, the server
started freezing. And by that I men that it dosen't respond to the browser
and when I try to restart it, the script has to force kill it. Right now I
can't get anything to work anymore: the server is dead and restarting it, or
even the computer dosen't help :(
I have an Ubuntu 6.06 on my box and java 1.5.0, Apache 2.0.55,
Tomcat 5.0.30-9.

bye

--
Don't talk it, Walk it!


Re: Multiple instances of servlets

2006-06-16 Thread Magnus Larsgården

Hi Len,

The SingleThreadModel Interface is _not_ used in the servlet.

Maybe I should write a bugreport?

Thanks for your help!

BR/Magnus




- Original Message - 
From: Len Popp [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Friday, June 16, 2006 6:30 PM
Subject: Re: Multiple instances of servlets


I don't see anything there that would cause the servlet in mydomain2
to be loaded 4 times. The only thing I can think of is that the
servlet might be running in single-thread mode (by implementing the
SingleThreadModel interface).
--
Len

On 6/14/06, Magnus Larsgården [EMAIL PROTECTED] wrote:

Hi Len!

This is how my two web.xml files look like:

/home/web/tomcat/webapps/ROOT/WEB-INF/web.xml

!--
**  --
!--
**  --
servlet

servlet-namecom.mydomain1.bookingManager.BookingManager/servlet-name

servlet-classcom.mydomain1.bookingManager.BookingManager/servlet-class
load-on-startup1/load-on-startup
/servlet
servlet-mapping

servlet-namecom.mydomain1.bookingManager.BookingManager/servlet-name

url-pattern/servlet/com.mydomain1.bookingManager.BookingManager/url-pattern
/servlet-mapping


!--
**  --
!--
**  --
servlet --
  servlet-namecom.mydomain1.log.Log/servlet-name
  servlet-classcom.mydomain1.log.Log/servlet-class
/servlet
servlet-mapping
servlet-namecom.mydomain1.log.Log/servlet-name
url-pattern/servlet/com.mydomain1.log.Log/url-pattern
/servlet-mapping

!--
**  --
!--
**  --
servlet --
  servlet-namecom.mydomain1.poll.PollMain/servlet-name
  servlet-classcom.mydomain1.poll.PollMain/servlet-class
/servlet
servlet-mapping
servlet-namecom.mydomain1.poll.PollMain/servlet-name
url-pattern/servlet/com.mydomain1.poll.PollMain/url-pattern
/servlet-mapping

!--
**  --
!--
**  --
servlet --

servlet-namecom.mydomain1.discgolf.bookingManager.BookingManager/servlet-name

servlet-classcom.mydomain1.discgolf.bookingManager.BookingManager/servlet-class
  load-on-startup2/load-on-startup
/servlet
servlet-mapping

servlet-namecom.mydomain1.discgolf.bookingManager.BookingManager/servlet-name

url-pattern/servlet/com.mydomain1.discgolf.bookingManager.BookingManager/url-pattern
/servlet-mapping

!--
**  --
!--
**  --
servlet --
  servlet-namecom.mydomain1.discgolf.poll.PollMain/servlet-name
  servlet-classcom.mydomain1.discgolf.poll.PollMain/servlet-class
/servlet
servlet-mapping
servlet-namecom.mydomain1.discgolf.poll.PollMain/servlet-name

url-pattern/servlet/com.mydomain1.discgolf.poll.PollMain/url-pattern
/servlet-mapping



/home/web/tomcat/webapps/mydomain2/WEB-INF/web.xml

!--
**  --
!--
**  --
servlet

servlet-namecom.mydomain2.bookingManager.BookingManager/servlet-name

servlet-classcom.mydomain2.bookingManager.BookingManager/servlet-class
load-on-startup1/load-on-startup
!-- load-on-startup1/load-on-startup --
/servlet
servlet-mapping

servlet-namecom.mydomain2.bookingManager.BookingManager/servlet-name

url-pattern/servlet/com.mydomain2.bookingManager.BookingManager/url-pattern
/servlet-mapping



As I mentioned earlier it is mydomain2 that get four instances of the
BookingManager servlet.

Comments?

Thanks
/Magnus







- Original Message -
From: Len Popp [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Wednesday, June 14, 2006 4:44 PM
Subject: Re: Multiple instances of servlets


How many web.xml files do you have, and how many servlet
declarations are there in those files? Each one of those is a
different servlet (even if some of them happen to be implemented by
similar Java classes). Normally, Tomcat will create one instance of
each of those servlets (or one per JVM in a distributed application).
Things are different if you use the single-thread model, but that's
not recommended.

See the servlet spec for the official details.
--
Len

On 6/14/06, Magnus Larsgården [EMAIL PROTECTED] wrote:
 Hi all,

 Is Tomcat supposed to create multiple instances of my servlet at 
 startup?

 Or
 is it a bug?

 Background:
 
 I have two different domains connected to my 

RE: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sharma, Siddharth
Ok, the httpsession is enabled with the code 
request.getSession(true);

but I still do not see a jsessionid cookie, even if tomcat is hit directly.
Same if hit via apache.

Do I have to enable sessions in Tomcat? How do I do that?
I do not want to enable session persistence.

Thanks
Sidd


-Original Message-
From: Sharma, Siddharth 
Sent: Friday, June 16, 2006 1:28 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

My bad. Did not read documentation.

Thanks


-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 12:31 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


 
The names of your workers are not correct. It should be alphanumeric only.
Refer to http://tomcat.apache.org/connectors-doc/config/workers.html
 
Sanjeev



From: Sharma, Siddharth [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 8:23 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem



Ok here's a little confusion:

In server.xml, there are two Engine tags, one of them is commented out by
default.
As can be seen I left the commented out 'standalone' engine as is and added
jvmRoute to engine named 'Catalina'.
Is that the problem?
Should I add it to the 'standalone' engine and uncomment it and comment out
the 'Catalina' engine?
Or should I have both uncommented?

I will try the permutations but if someone knows, it will save me some time
;)

!-- You should set jvmRoute to support load-balancing via AJP ie :
Engine name=Standalone defaultHost=localhost
jvmRoute=tomcat_worker_2
--

!-- Define the top level container in our container hierarchy --
Engine name=Catalina defaultHost=localhost
jvmRoute=tomcat_worker_2

-Original Message-
From: Sharma, Siddharth
Sent: Friday, June 16, 2006 10:40 AM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED]
Sent: Friday, June 16, 2006 10:15 AM
To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox.
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.

If you don't see the cookie, then definitely there is some issue.




From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:
 
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am
   
 not
 
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for session affinity with this
 directive in worker.properties:
 worker.lb_worker.sticky_session=True

 What am I missing?
 What is the exact name of the cookie that mod_jk injects?

 I apologize if this is not the right mailing list for connector questions
 and will appreciate if someone could point me to it.

 Thanks in advance
 -Sidd



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

Re: Apache with Tomcat and session affinity problem

2006-06-16 Thread Filip Hanik - Dev Lists

so if you create a jsp(or servlet) that looks like

%=request.getSession(true).getId()%

and run it, you get nothing?

Filip


Sharma, Siddharth wrote:
Ok, the httpsession is enabled with the code 
request.getSession(true);


but I still do not see a jsessionid cookie, even if tomcat is hit directly.
Same if hit via apache.

Do I have to enable sessions in Tomcat? How do I do that?
I do not want to enable session persistence.

Thanks
Sidd


-Original Message-
From: Sharma, Siddharth 
Sent: Friday, June 16, 2006 1:28 PM

To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

My bad. Did not read documentation.

Thanks


-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 12:31 PM

To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


 
The names of your workers are not correct. It should be alphanumeric only.

Refer to http://tomcat.apache.org/connectors-doc/config/workers.html
 
Sanjeev




From: Sharma, Siddharth [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 8:23 PM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem



Ok here's a little confusion:

In server.xml, there are two Engine tags, one of them is commented out by
default.
As can be seen I left the commented out 'standalone' engine as is and added
jvmRoute to engine named 'Catalina'.
Is that the problem?
Should I add it to the 'standalone' engine and uncomment it and comment out
the 'Catalina' engine?
Or should I have both uncommented?

I will try the permutations but if someone knows, it will save me some time
;)

!-- You should set jvmRoute to support load-balancing via AJP ie :
Engine name=Standalone defaultHost=localhost
jvmRoute=tomcat_worker_2
--

!-- Define the top level container in our container hierarchy --

Engine name=Catalina defaultHost=localhost
jvmRoute=tomcat_worker_2

-Original Message-
From: Sharma, Siddharth
Sent: Friday, June 16, 2006 10:40 AM
To: Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem

I have an http packet sniffer and it is reporting that there are no cookies
returned by apache.

Just to recap what I have done:
1. IBM HttpServer 2.0 with mod_jk on redhat linux
2. worker.properties has a load-balancer worker fronting two tomcat workers
over ajp13. it's sticky session property is set to True.
3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
instances) have their respective worker names (no case difference or silly
spelling mistakes).

There is no cookie. Is there another step that I am missing to enable
session affinity?




-Original Message-
From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED]
Sent: Friday, June 16, 2006 10:15 AM
To: Tomcat Users List; Tomcat Users List
Subject: RE: Apache with Tomcat and session affinity problem


JSESSIONID is a non-persistent cookie and you can check its presence easily
using a Netscape Navigator or FireFox.
In Firefox go to Tools-Options, Options Popup appears.
Select Privacy in the left section, to get the privacy options on the right
side of the popup
Expand the Node Cookies and click on button View Cookies.
You can see the cookie JSESSIONID with its value.

If you don't see the cookie, then definitely there is some issue.




From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Fri 6/16/2006 7:21 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem



how do you verify that you don't have a cookie?

I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

Filip


Sharma, Siddharth wrote:
  

Yes I did
jvmRoute is set to the worker name.
still, no jsessionid cookie.





-Original Message-
From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
Sent: Friday, June 16, 2006 7:18 AM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem

have you set jvmRoute in your engine element (server.xml)?
this is how mod_jk does session affinity

filipp



Sharma, Siddharth wrote:



I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
tomcat instances (version 5.5.16) using mod_jk over ajp13.
I have configured a load balancer worker to spray load across two workers
representing these two tomcat instances.
And it works.
The problem is I do not see a session id cookie in the response, so I am
  
  

not



sure if it is maintaining session affinity.
I have configured the load balancer worker for session affinity with this
directive in worker.properties:
worker.lb_worker.sticky_session=True

What am I missing?
What is the exact name of the cookie that mod_jk injects?

I apologize if this is not the right mailing list for connector questions
and will appreciate if someone could point me to it.

Thanks in advance
-Sidd




tomcat 5.0.28 with JDK 1.5?

2006-06-16 Thread Sunitha Kumar \(sunithak\)
Hi,
 
Wanted to check if tomcat 5.0.28 would work with JDK 1.5?
thnx
-sunitha


unsubscribe my email address from this forum

2006-06-16 Thread marcel_fiedler
I am not able to unsubscribe from this forum and I get 100 emails every day.
I never signed up.

I tried with [EMAIL PROTECTED] but this is not working!

Please help if you know how.

Thanks, Marcel 

FW: good resource for Tomcat startup on Redhat?

2006-06-16 Thread Tom Hickerson
 
We are installing Tomcat 5.0 on Red Hat Linux and setting up a daemon to run 
Tomcat on startup.  We are running into inexplicable execvp errors, though, and 
wanted to know if there was a good resource or startup script that someone can 
share.
 
Thanks in advance,
Tom Hickerson
 


Re: org.apache.catalina.valves.RemoteHostValve issue

2006-06-16 Thread Lars Huttar

On the tomcat-user list
(http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg158910.html): 







  Re: org.apache.catalina.valves.RemoteHostValve issue

Mark Thomas
Tue, 20 Sep 2005 14:09:45 -0700

Tony Tomcat wrote:
 
   ok. got off my lazy butt and looked at the code. RemoteHostValve

   uses request.getRequest().getRemoteHost() so just the javadoc
   needs updating for RemoteHostValve.java. I'm sure this was just a
   copy of RemoteAddrValve. ;-)
Looks like it. I have just committed a fix to CVS.

 
   Now i just need to figure out how to configure my tomcat to return

   values for getRemoteHost calls.
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/http.html
Look for enableLookups

Mark



I have been trying to do this, namely, use a RemoteHostValve to restrict
Tomcat to accept connections from only certain hosts.
My Context looks like this:

 Context docBase=../../cocoon-2.1.7 path=
  Valve
className=org.apache.catalina.valves.RemoteHostValve

allow=localhost,massah,massah\.sil\.org,massah\.dallas\.sil\.org,isaiah\.wycliffe\.org,it-huttar1\.sil\.org,it-huttar-d820\.sil\.org/ 




 /Context

I also put enableLookups=true in my connector, as instructed by the
documentation link you gave:
  Connector port=80 maxHttpHeaderSize=8192
 maxThreads=150 minSpareThreads=25 maxSpareThreads=75
 enableLookups=true redirectPort=8443 acceptCount=100
 connectionTimeout=2 disableUploadTimeout=true
allowTrace=true/

But Tomcat forbids me to connect, even from localhost. (Localhost is
massah.dallas.sil.org.)

Earlier I tried the RemoteAddrValve with IP addresses, and was able to
get it to work fine. However that won't meet our needs very well, as our
various dev machines change IP addresses now and then.

Any ideas? Can I somehow trace what hostname Tomcat thinks the request
is coming from? I turned on allowTrace in the http connector, as you can
see, but I can't find a log file that traces connection attempts. I've
looked in all those in Tomcat 5.5\logs.

If it matters, I'm on a Windows 2000 Server machine, and running Cocoon
as the servlet. I'm running Tomcat 5.5.9.

Thanks for your help,

Lars





-
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: Getting Tomcat to display a web page hosted by HTTPD

2006-06-16 Thread Guido Schoepp

Mann, Bradley schrieb:

The problem I am having is getting my web application to display a web
page that is located in a folder in the document_root of HTTPD, namely

http://localhost/Dir1/serverMessage.html

Every time the web application attempts to display this page I instead
get a 404 error, stating Dir1/serverMessage.html cannot be found. How
can I get my web application to display this page?


Does it print
  Dir1/serverMessage.html  (relative path)
or
  /Dir1/serverMessage.html (absolute path)
?

  Guido


-
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: Getting Tomcat to display a web page hosted by HTTPD

2006-06-16 Thread Mann, Bradley
I actually fixed the problem...I had a context path setup in Tomcat that
was overriding HTTPD. 


Brad Mann
Software Engineer - Information Access Services
HARRIS Corporation / GCSD
(321) 984-6292

-Original Message-
From: Guido Schoepp [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 6:42 AM
To: Tomcat Users List
Subject: Re: Getting Tomcat to display a web page hosted by HTTPD

Mann, Bradley schrieb:
 The problem I am having is getting my web application to display a web
 page that is located in a folder in the document_root of HTTPD, namely
 
 http://localhost/Dir1/serverMessage.html
 
 Every time the web application attempts to display this page I instead
 get a 404 error, stating Dir1/serverMessage.html cannot be found. How
 can I get my web application to display this page?

Does it print
   Dir1/serverMessage.html  (relative path)
or
   /Dir1/serverMessage.html (absolute path)
?

   Guido


-
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: flushing system.out

2006-06-16 Thread Nishant Deshpande

I'm using Tomcat 5.0.28 and SuSe Linux 9.3

On 6/15/06, Mir Kasim Ali [EMAIL PROTECTED] wrote:

Can u tell me which OS ure using and what version of Tomcat

On 6/16/06, Nishant Deshpande [EMAIL PROTECTED] wrote:

 i'm printing stuff out to system.out in tomcat, but it doesn't get
 flushed till the end of the request.

 (i've tried system.out.flush())

 has anyone got solutions to this problem? i'm not sure if its a tomcat
 problem or some OS / jvm thing...

 thanks

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




--
Mir Kasim Ali




-
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: Apache with Tomcat and session affinity problem

2006-06-16 Thread Sharma, Siddharth
I do now.
It's all working now.

Thanks a bunch
Sidd

-Original Message-
From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 16, 2006 2:06 PM
To: Tomcat Users List
Subject: Re: Apache with Tomcat and session affinity problem

so if you create a jsp(or servlet) that looks like

%=request.getSession(true).getId()%

and run it, you get nothing?

Filip


Sharma, Siddharth wrote:
 Ok, the httpsession is enabled with the code 
 request.getSession(true);

 but I still do not see a jsessionid cookie, even if tomcat is hit
directly.
 Same if hit via apache.

 Do I have to enable sessions in Tomcat? How do I do that?
 I do not want to enable session persistence.

 Thanks
 Sidd


 -Original Message-
 From: Sharma, Siddharth 
 Sent: Friday, June 16, 2006 1:28 PM
 To: Tomcat Users List
 Subject: RE: Apache with Tomcat and session affinity problem

 My bad. Did not read documentation.

 Thanks


 -Original Message-
 From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED] 
 Sent: Friday, June 16, 2006 12:31 PM
 To: Tomcat Users List
 Subject: RE: Apache with Tomcat and session affinity problem


  
 The names of your workers are not correct. It should be alphanumeric only.
 Refer to http://tomcat.apache.org/connectors-doc/config/workers.html
  
 Sanjeev

 

 From: Sharma, Siddharth [mailto:[EMAIL PROTECTED]
 Sent: Fri 6/16/2006 8:23 PM
 To: Tomcat Users List
 Subject: RE: Apache with Tomcat and session affinity problem



 Ok here's a little confusion:

 In server.xml, there are two Engine tags, one of them is commented out by
 default.
 As can be seen I left the commented out 'standalone' engine as is and
added
 jvmRoute to engine named 'Catalina'.
 Is that the problem?
 Should I add it to the 'standalone' engine and uncomment it and comment
out
 the 'Catalina' engine?
 Or should I have both uncommented?

 I will try the permutations but if someone knows, it will save me some
time
 ;)

 !-- You should set jvmRoute to support load-balancing via AJP ie :
 Engine name=Standalone defaultHost=localhost
 jvmRoute=tomcat_worker_2
 --
 
 !-- Define the top level container in our container hierarchy --
 Engine name=Catalina defaultHost=localhost
 jvmRoute=tomcat_worker_2

 -Original Message-
 From: Sharma, Siddharth
 Sent: Friday, June 16, 2006 10:40 AM
 To: Tomcat Users List
 Subject: RE: Apache with Tomcat and session affinity problem

 I have an http packet sniffer and it is reporting that there are no
cookies
 returned by apache.

 Just to recap what I have done:
 1. IBM HttpServer 2.0 with mod_jk on redhat linux
 2. worker.properties has a load-balancer worker fronting two tomcat
workers
 over ajp13. it's sticky session property is set to True.
 3. In the server.xml, the jvMRoute attribute of Engine (in both tomcat
 instances) have their respective worker names (no case difference or silly
 spelling mistakes).

 There is no cookie. Is there another step that I am missing to enable
 session affinity?




 -Original Message-
 From: Sanjeev Kumar Bhat, Noida [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 10:15 AM
 To: Tomcat Users List; Tomcat Users List
 Subject: RE: Apache with Tomcat and session affinity problem


 JSESSIONID is a non-persistent cookie and you can check its presence
easily
 using a Netscape Navigator or FireFox.
 In Firefox go to Tools-Options, Options Popup appears.
 Select Privacy in the left section, to get the privacy options on the
right
 side of the popup
 Expand the Node Cookies and click on button View Cookies.
 You can see the cookie JSESSIONID with its value.

 If you don't see the cookie, then definitely there is some issue.


 

 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Fri 6/16/2006 7:21 PM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem



 how do you verify that you don't have a cookie?

 I suggest using LiveHttpHeaders (firefox/mozilla) or TCPMonitor

 Filip


 Sharma, Siddharth wrote:
   
 Yes I did
 jvmRoute is set to the worker name.
 still, no jsessionid cookie.





 -Original Message-
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 16, 2006 7:18 AM
 To: Tomcat Users List
 Subject: Re: Apache with Tomcat and session affinity problem

 have you set jvmRoute in your engine element (server.xml)?
 this is how mod_jk does session affinity

 filipp



 Sharma, Siddharth wrote:

 
 I have IBM HttpServer 2.0 (it is an apache essentially) fronting two
 tomcat instances (version 5.5.16) using mod_jk over ajp13.
 I have configured a load balancer worker to spray load across two
workers
 representing these two tomcat instances.
 And it works.
 The problem is I do not see a session id cookie in the response, so I am
   
   
 not

 
 sure if it is maintaining session affinity.
 I have configured the load balancer worker for 

install of mod_jk through RPM, no valid checksums?

2006-06-16 Thread Tom Hickerson
Hi All,
 
We are installing mod_jk 1.2.15 on Fedora Core 2 through RPM, and we keep 
getting a problem with verifying the MD5 checksums:
 
rpm -i --test mod_jk-debuginfo-1.2.15-1jpp.i386.rpm

warning: mod_jk-debuginfo-1.2.15-1jpp.i386.rpm: V3 DSA signature: NOKEY, key ID 
c431416d
 
Does anyone know where we can find a RPM for mod_jk with a valid MD5?
 
Thanks in advance,
Tom Hickerson


unsubscribe my email address from this forum

2006-06-16 Thread marcel_fiedler



  I am not able to unsubscribe from this forum and I get 100 emails every day.
  I never signed up.

  I tried with [EMAIL PROTECTED] but this is not working!

  Please help if you know how.

  Thanks, Marcel 

Re: org.apache.catalina.valves.RemoteHostValve issue

2006-06-16 Thread Filip Hanik - Dev Lists




Hi Lars,
my guess is that it looks at 127.0.0.1, so adding 127\.0\.0\.1 to the
list would solve it
or, you can add enableLookups="true" to your Connector element,

although, I'm not sure why it just wouldn't look at the Host header

Filip



Lars Huttar wrote:
On the
tomcat-user list
  
(http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg158910.html):
  
  
  
  

 Re: org.apache.catalina.valves.RemoteHostValve issue


Mark Thomas

Tue, 20 Sep 2005 14:09:45 -0700


Tony Tomcat wrote:



 ok. got off my lazy butt and looked at the code. RemoteHostValve

 uses request.getRequest().getRemoteHost() so just the javadoc

 needs updating for RemoteHostValve.java. I'm sure this was just
a

 copy of RemoteAddrValve. ;-)

Looks like it. I have just committed a fix to CVS.




 Now i just need to figure out how to configure my tomcat to
return

 values for getRemoteHost calls.

http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/http.html

Look for enableLookups


Mark


  
  
I have been trying to do this, namely, use a RemoteHostValve to
restrict
  
Tomcat to accept connections from only certain hosts.
  
My Context looks like this:
  
  
 Context docBase="../../cocoon-2.1.7" path=""
  
 Valve
  
className="org.apache.catalina.valves.RemoteHostValve"
  
  
allow="localhost,massah,massah\.sil\.org,massah\.dallas\.sil\.org,isaiah\.wycliffe\.org,it-huttar1\.sil\.org,it-huttar-d820\.sil\.org"/
  
  
  
 /Context
  
  
I also put enableLookups="true" in my connector, as instructed by the
  
documentation link you gave:
  
 Connector port="80" maxHttpHeaderSize="8192"
  
 maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
  
 enableLookups="true" redirectPort="8443" acceptCount="100"
  
 connectionTimeout="2" disableUploadTimeout="true"
  
allowTrace="true"/
  
  
But Tomcat forbids me to connect, even from localhost. (Localhost is
  
massah.dallas.sil.org.)
  
  
Earlier I tried the RemoteAddrValve with IP addresses, and was able to
  
get it to work fine. However that won't meet our needs very well, as
our
  
various dev machines change IP addresses now and then.
  
  
Any ideas? Can I somehow trace what hostname Tomcat thinks the request
  
is coming from? I turned on allowTrace in the http connector, as you
can
  
see, but I can't find a log file that traces connection attempts. I've
  
looked in all those in Tomcat 5.5\logs.
  
  
If it matters, I'm on a Windows 2000 Server machine, and running Cocoon
  
as the servlet. I'm running Tomcat 5.5.9.
  
  
Thanks for your help,
  
  
Lars
  
  
  
  
  
  
-
  
To start a new topic, e-mail: users@tomcat.apache.org
  
To unsubscribe, e-mail: [EMAIL PROTECTED]
  
For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  



-- 


Filip Hanik






Re: org.apache.catalina.valves.RemoteHostValve issue

2006-06-16 Thread Lars Huttar

Filip Hanik - Dev Lists wrote:

Hi Lars,
my guess is that it looks at 127.0.0.1, so adding 127\.0\.0\.1 to the 
list would solve it
That worked! Thank you! The weird thing is, for other client machines, 
the hostname works. But for localhost, only the IP address works, even 
though I'm using RemoteHostValve instead of RemoteAddrValve.

or, you can add enableLookups=true to your Connector element,

It's already there.


although, I'm not sure why it just wouldn't look at the Host header

Filip


Thanks again!
Lars



Lars Huttar wrote:

On the tomcat-user list
(http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg158910.html): 







  Re: org.apache.catalina.valves.RemoteHostValve issue

Mark Thomas
Tue, 20 Sep 2005 14:09:45 -0700

Tony Tomcat wrote:
 
   ok. got off my lazy butt and looked at the code. RemoteHostValve

   uses request.getRequest().getRemoteHost() so just the javadoc
   needs updating for RemoteHostValve.java. I'm sure this was just a
   copy of RemoteAddrValve. ;-)
Looks like it. I have just committed a fix to CVS.

 
   Now i just need to figure out how to configure my tomcat to return

   values for getRemoteHost calls.
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/http.html
Look for enableLookups

Mark



I have been trying to do this, namely, use a RemoteHostValve to restrict
Tomcat to accept connections from only certain hosts.
My Context looks like this:

 Context docBase=../../cocoon-2.1.7 path=
  Valve
className=org.apache.catalina.valves.RemoteHostValve

allow=localhost,massah,massah\.sil\.org,massah\.dallas\.sil\.org,isaiah\.wycliffe\.org,it-huttar1\.sil\.org,it-huttar-d820\.sil\.org/ 




 /Context

I also put enableLookups=true in my connector, as instructed by the
documentation link you gave:
  Connector port=80 maxHttpHeaderSize=8192
 maxThreads=150 minSpareThreads=25 maxSpareThreads=75
 enableLookups=true redirectPort=8443 acceptCount=100
 connectionTimeout=2 disableUploadTimeout=true
allowTrace=true/

But Tomcat forbids me to connect, even from localhost. (Localhost is
massah.dallas.sil.org.)

Earlier I tried the RemoteAddrValve with IP addresses, and was able to
get it to work fine. However that won't meet our needs very well, as our
various dev machines change IP addresses now and then.

Any ideas? Can I somehow trace what hostname Tomcat thinks the request
is coming from? I turned on allowTrace in the http connector, as you can
see, but I can't find a log file that traces connection attempts. I've
looked in all those in Tomcat 5.5\logs.

If it matters, I'm on a Windows 2000 Server machine, and running Cocoon
as the servlet. I'm running Tomcat 5.5.9.

Thanks for your help,

Lars






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



Fwd: problems with tomcat and JSF on Linux

2006-06-16 Thread Sorin Silaghi

I just solved this by myself... I don't know what the problem was exactly
but I uninstalled the version I had and I downloaded the binarys for version
5.5 from the tomcat project site. It now works great and I suspect it might
be something related to ubuntu more than tomcat. I submited a bug to the
ubuntu guys so if anybody has or had this problem please let me know.

thank you


-- Forwarded message --
From: Sorin Silaghi [EMAIL PROTECTED]
Date: Jun 16, 2006 1:29 PM
Subject: problems with tomcat and JSF on Linux
To: users@tomcat.apache.org

Hello,

I have just started using Tomcat for developing JSF apps. I've
started by making some JSP pages to get the hang of that. And all was great
until I switched over to JSF (MyFaces). First of all the server has a bit of
a problem with new files added in the webapps directory. Alot of the time I
have to restart the server for it to see the new pages aded(dono if that's
normal but I was expecting something more responsive). When at last I
managed to get my hands on some examples that where sure to work, the server
started freezing. And by that I men that it dosen't respond to the browser
and when I try to restart it, the script has to force kill it. Right now I
can't get anything to work anymore: the server is dead and restarting it, or
even the computer dosen't help :(
I have an Ubuntu 6.06 on my box and java 1.5.0, Apache 2.0.55,
Tomcat 5.0.30-9.

bye

--
Don't talk it, Walk it!


--
Don't talk it, Walk it!