Bootstrap FreeKB - IBM WebSphere - Enable or Disable Synchronization
IBM WebSphere - Enable or Disable Synchronization

Updated:   |  IBM WebSphere articles

If you are not familiar with synchronization, check out my article IBM WebSphere - Synchronize a node (syncNode).

By default, after you federate is federate a manager node into the deployment manager (dmgr), the node will be configured to automatically synchronize, once every 1 minute. This can be seen in the WebSphere admin console, at System administration > Nodes > nodeagent File synchronization service, where Automatic synchronization is enable by default.

 

If you disable Automatic synchronization, the message says that the synchronization can be enabled in preferences. Refer to my article on preferences to enable synchronization by default.

 

When synchronization is enabled in preferences, the message will then instead say that synchronization can be disabled in preferences which is how you know that it's enabled in preferences.

 


wsadmin

This could also be done using wsadmin.sh (Linux) / wsadmin.bat (Windows) to list the node agents.  This example uses the -c option (inline command) and the jython language.

~]$ /opt/WebSphere/AppServer/profiles/myDmgrProfile/bin/wsadmin.sh -lang jython -c "print AdminTask.listServers('[-serverType NODE_AGENT]')"
nodeagent(cells/myCell01/nodes/myNode01/servers/nodeagent|server.xml)

 

And then use wsadmin to list the node agents Synchronization Service, using the nodeagent returned by the prior command.

~]$ /opt/WebSphere/AppServer/profiles/myDmgrProfile/bin/wsadmin.sh -lang jython -c "print AdminConfig.list('ConfigSynchronizationService', 'nodeagent(cells/myCell01/nodes/myNode01/servers/nodeagent|server.xml)')"
(cells/myCell01/nodes/myNode01/servers/nodeagent|server.xml#ConfigSynchronizationService_1482438539006)

 

Use wsadmin to enable or disable synchronization, using the ConfigSynchronizationService returned by the prior command.

/opt/WebSphere/AppServer/profiles/myDmgrProfile/bin/wsadmin.sh -lang jython -c "print AdminConfig.modify('(cells/myCell01/nodes/myNode01/servers/nodeagent|server.xml#ConfigSynchronizationService_1482438539006)', '[[synchInterval \"1\"] [exclusions \"\"] [enable \"true\"] [synchOnServerStartup \"false\"] [autoSynchEnabled \"false\"]]')"

 

Save the change to the master configuration.

/opt/WebSphere/AppServer/profiles/myDmgrProfile/bin/wsadmin.sh -lang jython -c "print AdminConfig.save()"

 

And finally, you may want to now synchronize the nodes.

/opt/WebSphere/AppServer/profiles/myDmgrProfile/bin/wsadmin.sh -lang jython -c "print dminNodeManagement.syncActiveNodes()"

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


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