Scripting Connections wsadmin commands in a clustered environment

Recently I was creating a script to deactivate and reactivate a specific user (base of the script thanks to Christoph Stoetner)

This script was running nicely on my Dev environment, but once I transferred it to my Pre-prod the script would prompt me with the following:

As I have Activities, and all other services running on multiple nodes it wants to know what server I want to connect to. I tried to fiddle around trying to respond in my script but that approach did not work. I opened a pmr with support and they knew the issue and have already created an enhancement request. They also have a workaround, but no technote, I have asked to keep the pmr open until the technote is published.

They gave me some example code to alter the activitiesAdmin.py script in your $WebSphereProfilesDirecotry\Dmgr01\bin directory. This needs to be done for all scripts and you will have to redo this every time IBM decides to update these scripts with a CR.

For Activities replace the following block of code in activitiesAdmin.py:

With the following:

This process can be reused for the following files where similar code can be found:

  • dogearAdmin.py
  • filesAdmin.py
  • forumsAdmin.py
  • gadgetAdmin.py
  • homepageAdmin.py
  • metricsAdmin.py
  • newsAdmin.py (block is in there multiple times for all subservices)
  • searchAdmin.py

For some of the files, that block of code cannot be found and I ended up changing as follows:

blogsAdmin.py

communitiesAdmin.py

Leave a Reply

Your email address will not be published. Required fields are marked *