How to synchronize a node in WebSphere

Home > Search > How-to
  by

A synchronization is needed after a change is made to the master repository, to sync one or more managed nodes to the updated master repository. Only managed nodes can be synchronized - an unmanaged node cannot be sychronized. Following are the ways a synchronization can occur.

  • Auto synchronization
  • Using WebSphere web console
  • Using syncNode.sh or syncNode.bat command
  • Application Server startup with Startup Synchronization flag checked
  • Node federation by addNode process
  • Restart JMX call on NodeAgent MBean if syncFirst is set to true

An auto synchronization occurs shortly after a change is made to the master repository. For example, if a new app is deployed to a managed node, the node agent will usually automatically synchronized the managed node in one or two minutes.

Following are the synchronization types.

  • Partial synchronization
  • Full synchronization

 


Partial synchronization

With a partial synchronization, only files that the deployment manager thinks have changed will be synchronized. A partial synchronization takes less time than a full synchronization.

  1. In the left panel of the WebSphere web console, expand System administration.
  2. Select Nodes.
  3. Check the node that you would like to sync, and select Synchronize.

After selecting Synchronize, message "successfully initiated synchronization" should be displayed.

 

The managed node can also be synchronized using the syncNode.sh (Linux) or syncNode.bat (Windows) command. You will run this command from the server that contains the node that you want to sync with the deployment manager. Before issuing the syncNode.sh / syncNode.bat command, you will need to issue the stopNode.sh / stopNode.bat command.

~]# was_home/AppServer/profiles/your_profile/bin/stopNode.sh

 

Once the node has been stopped, you can then issue the syncNode.sh command. In this example, "example.com" is the hostname of the deployment manager, and 8879 is the SOAP port of the deployment manager. 8879 is the default SOAP port. To be absolutely certain that you have the correct port, check the was_home/profiles/your_profile/properties/portdef.props file on the dmgr.

~]# was_home/AppServer/profiles/your_profile/bin/syncNode.sh example.com 8879

 

After the node has been sycned, start the node.

~]# was_home/AppServer/profiles/your_profile/bin/startNode.sh

 

The managed node can also be synchronized using wsadmin. In this example, a variable named myNode which is associated with Node01, and then the node is synchronized.

# Jacl
set myNode [$AdminControl completeObjectName type=NodeSync,process=nodeagent,node=Node01,*]
$AdminControl invoke $myNode sync

# Jython
myNode = AdminControl.completeObjectName('type=NodeSync,process=nodeagent,node=Node01,*')
AdminControl.invoke(myNode, 'sync')

 


Full synchronization

With a full synchronization, all file will be synchronized. A full synchronization takes more time than a partial synchronization.

  1. In the left panel of the WebSphere web console, expand System administration.
  2. Select Nodes.
  3. Check the node that you would like to sync, and select Full Resynchronize.

After selecting Synchronize, message "successfully initiated synchronization" should be displayed.

 


Logs

When an attempt is made to sychronize, the following event will be in the dmgr SystemOut.log.

ADMN1006I: An attempt is made to synchronize the node_name node. (User ID = wasadmin)

 

The following events will be in the application server syncNode.log.

ADMU0401I: Begin syncNode operation for node node_name with Deployment Manager example.com: 8879
ADMU0016I: Synchronizing configuration between node and cell.
ADMS0003I: The configuration synchronization completed successfully.

 



Add a Comment




We will never share your name or email with anyone. Enter your email if you would like to be notified when we respond to your comment.




Please enter in the box below so that we can be sure you are a human.




Comments