Call now: 252-767-6166  
Oracle Training Oracle Support Development Oracle Apps

 
 Home
 E-mail Us
 Oracle Articles
New Oracle Articles


 Oracle Training
 Oracle Tips

 Oracle Forum
 Class Catalog


 Remote DBA
 Oracle Tuning
 Emergency 911
 RAC Support
 Apps Support
 Analysis
 Design
 Implementation
 Oracle Support


 SQL Tuning
 Security

 Oracle UNIX
 Oracle Linux
 Monitoring
 Remote s
upport
 Remote plans
 Remote
services
 Application Server

 Applications
 Oracle Forms
 Oracle Portal
 App Upgrades
 SQL Server
 Oracle Concepts
 Software Support

 Remote S
upport  
 Development  

 Implementation


 Consulting Staff
 Consulting Prices
 Help Wanted!

 


 Oracle Posters
 Oracle Books

 Oracle Scripts
 Ion
 Excel-DB  

Don Burleson Blog 


 

 

 


 

 

 
 

WebLogic Cluster Tips

Weblogic Tips by Donald BurlesonApril 7, 2015

WebLogic Cluster

Besides the administration server, managed-servers can be grouped into clusters.  Every WebLogic domain can host multiple clusters, but each managed-server can only be a member of one cluster (if at all).  Every cluster can (but does not need to) include a managed-server hosted on different machines. As described in the introduction, there are two different communication models for clusters: Unicast and Multicast.

 

First of all, let us create one cluster for each communication model with only the necessary configuration parameters.

 

Creating a unicast cluster:

 

cd('/')

cmo.createCluster('Cluster-UnicastTest')

 

cd('/Clusters/Cluster-UnicastTest')

cmo.setClusterMessagingMode('unicast')

 

In WLST, switch to root and use this MBean (cmo) to create a new cluster object. Afterwards we are only setting the cluster mode to 'unicast'.

 

Creating a multicast cluster:

 

cd('/')

cmo.createCluster('Cluster-MulticastTest')

 

cd('/Clusters/Cluster-MulticastTest')

cmo.setClusterMessagingMode('multicast')

cmo.setMulticastAddress('239.192.0.0')

cmo.setMulticastPort(12345)

 

In WLST, switch to root and use this MBean (cmo) to create a new cluster object. Afterwards we are setting the cluster mode to 'multicast'. In addition, we need to set the multicast broadcast address and port.

 

Multicast address: enter the multicast address for the cluster. Cluster members that communicate with each other use this multicast address. The default value is 239.192.0.0. You can choose valid multicast address range of 224.0.0.1 through 239.255.255.255.

 

Multicast port: enter the multicast port for the cluster. This multicast port is used for cluster members to communicate with each other. The default value is 7001. Here you can use any valid values for multicast ports ranging from 1 through 65534. The ports are not enabled to serve multicast for most machines in real-time. Multicast uses UDP protocol.

 

Now let us as add another unicast cluster with some more configuration options:

 

cd('/Clusters/Cluster-UnicastTest')

cmo.setNumberOfServersInClusterAddress(3)

cmo.setDefaultLoadAlgorithm('weight-based')

cmo.setClusterType('none')

See the book code download for full script

cmo.setPersistSessionsOnShutdown(false)

cmo.setReplicationChannel('ReplicationChannel')

cmo.setSecureReplicationEnabled(false)

 

NumberOfServersInClusterAddress: This is the amount of servers the cluster will include in the cluster address. This option will not be used if the address is explicitly set. Usually WebLogic maintains this setting automatically.

 

DefaultLoadAlgorithm: This option specifies the default way load-balancing is used between the appropriate servers of the cluster. This setting only takes effect if it is not overwritten. Options include round-robin (one after the other), weight-based (round-robin with defined weight for each server), or random (random access).

 

Note the attribute ClusterType. This specifies a possibility to cluster between clusters hosted in DIFFERENT WebLogic domains.  WebLogic supports three different settings: 'none' (own cluster only), 'man' (synchronous replication), and 'wan' (asynchronous replication).

 

Here is an example for setting up the cluster in order to replicate to a remote cluster in a different domain:

 

cd('/Clusters/MartinTest_Cluster')

cmo.setClusterType('man')

cmo.setPersistSessionsOnShutdown(false)

cmo.setReplicationChannel('ReplicationChannel')

cmo.setRemoteClusterAddress('192.178.34.123')

cmo.setSecureReplicationEnabled(false)

 

If 'wan' is used, which normally means replication across datacenters, the sessions must be stored in a database. Therefore a datasource must be provided for this type of replication:

 

cmo.setClusterType('wan')

cmo.setRemoteClusterAddress('11.22.33.44')

cmo.setDataSourceForSessionPersistence(getMBean('/SystemResources/Prototype_Datasource'))

 

Singleton services are special services you can implement which must be available only once in the whole cluster. Therefore these services will be migrated automatically if the server they are hosted on fails.

 

Define a singleton service:

 

cd('/')

cmo.createSingletonService('SingletonService-Test')

 

cd('/SingletonServices/SingletonService-Test')

cmo.setClassName('de.book.test.singleton1')

cmo.setCluster(getMBean('/Clusters/MartinTest_Cluster'))

See the book code download for full script

cmo.setUserPreferredServer(getMBean('/Servers/MartinTest_Domain_MS1'))

set('ConstrainedCandidateServers',jarray.array([ObjectName('com.bea:Name=MartinTest_Domain_MS2,Type=Server'), ObjectName('com.bea:Name=MartinTest_Domain_MS1,Type=Server')], ObjectName))

 

 
   
Advanced WebLogic Server Automation Book

The above is an excerpt from the book "Advanced WebLogic Server Automation: Administration and Monitoring with WLST and JMX". This book covers everything administrators need to know for WebLogic scripting and automation, and includes a comprehensive code download of powerful WLST and JMX scripts.
 


 

 

Burleson is the American Team

Note: This Oracle documentation was created as a support and Oracle training reference for use by our DBA performance tuning consulting professionals.  Feel free to ask questions on our Oracle forum.

Verify experience! Anyone considering using the services of an Oracle support expert should independently investigate their credentials and experience, and not rely on advertisements and self-proclaimed expertise. All legitimate Oracle experts publish their Oracle qualifications.

Errata?  Oracle technology is changing and we strive to update our BC Oracle support information.  If you find an error or have a suggestion for improving our content, we would appreciate your feedback.  Just  e-mail:  

and include the URL for the page.


                    









Burleson Consulting

The Oracle of Database Support

Oracle Performance Tuning

Remote DBA Services


 

Copyright © 1996 -  2020

All rights reserved by Burleson

Oracle ® is the registered trademark of Oracle Corporation.

 

 

��  
 
 
Oracle Training at Sea
 
 
 
 
oracle dba poster
 

 
Follow us on Twitter 
 
Oracle performance tuning software 
 
Oracle Linux poster