Re: Tomcat 6.0.35 : Cluster and new node

2011-12-27 Thread Cédric SAMSON

Ok thanks for the informations :D

Le 27/12/2011 14:39, Pid * a écrit :

On 27 Dec 2011, at 12:07, Cédric SAMSONcedric.sam...@adeuxi.com  wrote:


Yes I tried and it works fine, but I just want all is automatic.

FarmWarDeployer doesn't do that.
It is a push mechanism rather than a repository of applications queued
for deployment.


p



I mean, a machine crash, we have to change it.
The new machine has :

1. the same IP
2. the same name
3. the same tomcat configuration (but without the war files already
   deployed)

as the previous machine (in order to not restart the load balancer and
not interrupt the service).

The best for me is that all the war in the watchdir of the master node
(the one with watchEnabled=true ) are deployed in this new machine
because the contexts don't yet exist on this node.
It's only for machine replacement purpose.

For a real new node, we are force to reboot the cluster after
declaring the new node in the balancer.

Thanks for helping

Le 27/12/2011 12:09, Pid * a écrit :

On 26 Dec 2011, at 14:33, Cédric SAMSONcedric.sam...@adeuxi.com   wrote:


Hi all,


Context :
  I have a cluster with 2 nodes (both on linux).

  * The master node is configured as below : *

Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
Realm className=org.apache.catalina.realm.UserDatabaseRealm 
resourceName=UserDatabase/

Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
channelSendOptions=8

Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

Channel className=org.apache.catalina.tribes.group.GroupChannel

Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.51
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

Sender className=org.apache.catalina.tribes.transport.ReplicationTransmitter
Transport 
className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/
/Sender
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor/
/Channel
Valve className=org.apache.catalina.ha.tcp.ReplicationValve filter= 
statistics=true/
Valve className=org.apache.catalina.ha.session.JvmRouteBinderValve/

Deployer className=org.apache.catalina.ha.deploy.FarmWarDeployer
tempDir=/usr/local/tomcat/webapps/tempdir
deployDir=/usr/local/tomcat/webapps/
watchDir=/usr/local/tomcat/watchdir/
watchEnabled=true/

ClusterListener 
className=org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener/
ClusterListener 
className=org.apache.catalina.ha.session.ClusterSessionListener/

/Cluster

/Host
/Engine

  * The slave node is configured as below : *

The term 'slave' is an odd one to use here.



Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
Realm className=org.apache.catalina.realm.UserDatabaseRealm 
resourceName=UserDatabase/

Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
channelSendOptions=8

Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

Channel className=org.apache.catalina.tribes.group.GroupChannel

Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.54
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

Sender className=org.apache.catalina.tribes.transport.ReplicationTransmitter
Transport 
className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/

Re: Tomcat 6.0.35 : Cluster and new node

2011-12-27 Thread Pid *
On 26 Dec 2011, at 14:33, Cédric SAMSON cedric.sam...@adeuxi.com wrote:

 Hi all,


 Context :
  I have a cluster with 2 nodes (both on linux).

  * The master node is configured as below : *

 Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
 Realm className=org.apache.catalina.realm.UserDatabaseRealm 
 resourceName=UserDatabase/

 Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

 Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
 channelSendOptions=8

 Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

 Channel className=org.apache.catalina.tribes.group.GroupChannel

 Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
 Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.51
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

 Sender 
 className=org.apache.catalina.tribes.transport.ReplicationTransmitter
 Transport 
 className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/
 /Sender
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor/
 /Channel
 Valve className=org.apache.catalina.ha.tcp.ReplicationValve filter= 
 statistics=true/
 Valve className=org.apache.catalina.ha.session.JvmRouteBinderValve/

 Deployer className=org.apache.catalina.ha.deploy.FarmWarDeployer
tempDir=/usr/local/tomcat/webapps/tempdir
deployDir=/usr/local/tomcat/webapps/
watchDir=/usr/local/tomcat/watchdir/
watchEnabled=true/

 ClusterListener 
 className=org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener/
 ClusterListener 
 className=org.apache.catalina.ha.session.ClusterSessionListener/

 /Cluster

 /Host
 /Engine

  * The slave node is configured as below : *

The term 'slave' is an odd one to use here.


 Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
 Realm className=org.apache.catalina.realm.UserDatabaseRealm 
 resourceName=UserDatabase/

 Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

 Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
 channelSendOptions=8

 Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

 Channel className=org.apache.catalina.tribes.group.GroupChannel

 Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
 Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.54
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

 Sender 
 className=org.apache.catalina.tribes.transport.ReplicationTransmitter
 Transport 
 className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/
 /Sender
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor/
 /Channel
 Valve className=org.apache.catalina.ha.tcp.ReplicationValve filter= 
 statistics=true/
 Valve className=org.apache.catalina.ha.session.JvmRouteBinderValve/

 Deployer className=org.apache.catalina.ha.deploy.FarmWarDeployer
tempDir=/usr/local/tomcat/webapps/tempdir
deployDir=/usr/local/tomcat/webapps/
watchDir=/usr/local/tomcat/watchdir/
watchEnabled=false/

 ClusterListener 
 className=org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener/
 ClusterListener 
 className=org.apache.catalina.ha.session.ClusterSessionListener/

 /Cluster

 /Host
 /Engine

 All works fine.

 I try 

Re: Tomcat 6.0.35 : Cluster and new node

2011-12-27 Thread Pid *
On 27 Dec 2011, at 12:07, Cédric SAMSON cedric.sam...@adeuxi.com wrote:

 Yes I tried and it works fine, but I just want all is automatic.

FarmWarDeployer doesn't do that.
It is a push mechanism rather than a repository of applications queued
for deployment.


p


 I mean, a machine crash, we have to change it.
 The new machine has :

 1. the same IP
 2. the same name
 3. the same tomcat configuration (but without the war files already
   deployed)

 as the previous machine (in order to not restart the load balancer and
 not interrupt the service).

 The best for me is that all the war in the watchdir of the master node
 (the one with watchEnabled=true ) are deployed in this new machine
 because the contexts don't yet exist on this node.
 It's only for machine replacement purpose.

 For a real new node, we are force to reboot the cluster after
 declaring the new node in the balancer.

 Thanks for helping

 Le 27/12/2011 12:09, Pid * a écrit :
 On 26 Dec 2011, at 14:33, Cédric SAMSONcedric.sam...@adeuxi.com  wrote:

 Hi all,


 Context :
  I have a cluster with 2 nodes (both on linux).

  * The master node is configured as below : *

 Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
 Realm className=org.apache.catalina.realm.UserDatabaseRealm 
 resourceName=UserDatabase/

 Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

 Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
 channelSendOptions=8

 Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

 Channel className=org.apache.catalina.tribes.group.GroupChannel

 Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
 Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.51
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

 Sender 
 className=org.apache.catalina.tribes.transport.ReplicationTransmitter
 Transport 
 className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/
 /Sender
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
 Interceptor 
 className=org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor/
 /Channel
 Valve className=org.apache.catalina.ha.tcp.ReplicationValve filter= 
 statistics=true/
 Valve className=org.apache.catalina.ha.session.JvmRouteBinderValve/

 Deployer className=org.apache.catalina.ha.deploy.FarmWarDeployer
tempDir=/usr/local/tomcat/webapps/tempdir
deployDir=/usr/local/tomcat/webapps/
watchDir=/usr/local/tomcat/watchdir/
watchEnabled=true/

 ClusterListener 
 className=org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener/
 ClusterListener 
 className=org.apache.catalina.ha.session.ClusterSessionListener/

 /Cluster

 /Host
 /Engine

  * The slave node is configured as below : *
 The term 'slave' is an odd one to use here.


 Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
 Realm className=org.apache.catalina.realm.UserDatabaseRealm 
 resourceName=UserDatabase/

 Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

 Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
 channelSendOptions=8

 Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

 Channel className=org.apache.catalina.tribes.group.GroupChannel

 Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
 Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.54
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

 Sender 
 className=org.apache.catalina.tribes.transport.ReplicationTransmitter
 Transport 
 className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/
 /Sender
 

Re: Tomcat 6.0.35 : Cluster and new node

2011-12-27 Thread Cédric SAMSON

Yes I tried and it works fine, but I just want all is automatic.

I mean, a machine crash, we have to change it.
The new machine has :

1. the same IP
2. the same name
3. the same tomcat configuration (but without the war files already
   deployed)

as the previous machine (in order to not restart the load balancer and 
not interrupt the service).


The best for me is that all the war in the watchdir of the master node 
(the one with watchEnabled=true ) are deployed in this new machine 
because the contexts don't yet exist on this node.

It's only for machine replacement purpose.

For a real new node, we are force to reboot the cluster after 
declaring the new node in the balancer.


Thanks for helping

Le 27/12/2011 12:09, Pid * a écrit :

On 26 Dec 2011, at 14:33, Cédric SAMSONcedric.sam...@adeuxi.com  wrote:


Hi all,


Context :
  I have a cluster with 2 nodes (both on linux).

  * The master node is configured as below : *

Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
Realm className=org.apache.catalina.realm.UserDatabaseRealm 
resourceName=UserDatabase/

Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
channelSendOptions=8

Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

Channel className=org.apache.catalina.tribes.group.GroupChannel

Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.51
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

Sender className=org.apache.catalina.tribes.transport.ReplicationTransmitter
Transport 
className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/
/Sender
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor/
/Channel
Valve className=org.apache.catalina.ha.tcp.ReplicationValve filter= 
statistics=true/
Valve className=org.apache.catalina.ha.session.JvmRouteBinderValve/

Deployer className=org.apache.catalina.ha.deploy.FarmWarDeployer
tempDir=/usr/local/tomcat/webapps/tempdir
deployDir=/usr/local/tomcat/webapps/
watchDir=/usr/local/tomcat/watchdir/
watchEnabled=true/

ClusterListener 
className=org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener/
ClusterListener 
className=org.apache.catalina.ha.session.ClusterSessionListener/

/Cluster

/Host
/Engine

  * The slave node is configured as below : *

The term 'slave' is an odd one to use here.



Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
Realm className=org.apache.catalina.realm.UserDatabaseRealm 
resourceName=UserDatabase/

Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
channelSendOptions=8

Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

Channel className=org.apache.catalina.tribes.group.GroupChannel

Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.54
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

Sender className=org.apache.catalina.tribes.transport.ReplicationTransmitter
Transport 
className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/
/Sender
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
Interceptor 

Tomcat 6.0.35 : Cluster and new node

2011-12-26 Thread Cédric SAMSON

Hi all,


Context :
  I have a cluster with 2 nodes (both on linux).

  * The master node is configured as below : *

Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
Realm className=org.apache.catalina.realm.UserDatabaseRealm 
resourceName=UserDatabase/


Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
channelSendOptions=8


Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

Channel className=org.apache.catalina.tribes.group.GroupChannel

Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.51
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

Sender 
className=org.apache.catalina.tribes.transport.ReplicationTransmitter
Transport 
className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/

/Sender
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor/

/Channel
Valve className=org.apache.catalina.ha.tcp.ReplicationValve filter= 
statistics=true/

Valve className=org.apache.catalina.ha.session.JvmRouteBinderValve/

Deployer className=org.apache.catalina.ha.deploy.FarmWarDeployer
tempDir=/usr/local/tomcat/webapps/tempdir
deployDir=/usr/local/tomcat/webapps/
watchDir=/usr/local/tomcat/watchdir/
watchEnabled=true/

ClusterListener 
className=org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener/
ClusterListener 
className=org.apache.catalina.ha.session.ClusterSessionListener/


/Cluster

/Host
/Engine

  * The slave node is configured as below : *

Engine name=Catalina defaultHost=localhost jvmRoute=Tomcat-1
Realm className=org.apache.catalina.realm.UserDatabaseRealm 
resourceName=UserDatabase/


Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false

Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster 
channelSendOptions=8


Manager className=org.apache.catalina.ha.session.DeltaManager
   expireSessionsOnShutdown=false
   notifyContainerListenersOnReplication=true
   notifySessionListenersOnReplication=true
   notifyListenersOnReplication=true/

Channel className=org.apache.catalina.tribes.group.GroupChannel

Membership className=org.apache.catalina.tribes.membership.McastService
address=228.0.0.3
port=45566
frequency=500
dropTime=3000/
Receiver className=org.apache.catalina.tribes.transport.nio.NioReceiver
  address=192.168.30.54
  port=3100
  autoBind=100
  selectorTimeout=5000
  maxThreads=6/

Sender 
className=org.apache.catalina.tribes.transport.ReplicationTransmitter
Transport 
className=org.apache.catalina.tribes.transport.nio.PooledParallelSender/

/Sender
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.TcpFailureDetector/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor/
Interceptor 
className=org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor/

/Channel
Valve className=org.apache.catalina.ha.tcp.ReplicationValve filter= 
statistics=true/

Valve className=org.apache.catalina.ha.session.JvmRouteBinderValve/

Deployer className=org.apache.catalina.ha.deploy.FarmWarDeployer
tempDir=/usr/local/tomcat/webapps/tempdir
deployDir=/usr/local/tomcat/webapps/
watchDir=/usr/local/tomcat/watchdir/
watchEnabled=false/

ClusterListener 
className=org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener/
ClusterListener 
className=org.apache.catalina.ha.session.ClusterSessionListener/


/Cluster

/Host
/Engine

All works fine.

I try to add a new war file in the master node folder 
/usr/local/tomcat/watchdir/, after few seconds, the war is correctly 
deployed on both nodes.
Now i try to add a third node