Websphere Restart – Stand Alone

WebSphere Restart for Software Deployments

WebSphere restarts are often used in software deployments. We saw some of our DeployHub customers running into issues in restarting a stand-alone server for their development environment.

WebSphere Exception Recieved

Stopping the server via wsadmin or the stop script worked but the start would fail. The failure from wsadmin for the start was:

WASX7017E: Exception received while running file "/tmp/deployws.py"; exception information: com.ibm.websphere.management.exception.ConnectorNotAvailableException
* org.apache.soap.SOAPException: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error opening socket: java.net.ConnectException: Connection refused; targetException=java.lang.IllegalArgumentException: Error opening socket: java.net.ConnectException: Connection refused]

Root of the Problem

This restart exception was thrown due to the server being stopped and the SOAP connection terminated.

The failure from the running the stop server shell script was:

*      Mar 15, 2017 7:55:19 PM com.ibm.ws.postinstall.runConfigActions.RunConfigActions setLogFile
* SEVERE: IOException java.io.FileNotFoundException: /herramientas/btt/IBM/WebSphere/AppServer/profiles/AppSrv01/properties/service/productDir/logs/runConfigActions.log.lck (Permission denied)
*
*      java.io.FileNotFoundException: /herramientas/btt/IBM/WebSphere/AppServer/profiles/AppSrv01/properties/service/productDir/logs/runConfigActions.log.lck (Permission denied)
*      at java.io.FileOutputStream.open(Native Method)
*      at java.io.FileOutputStream.(FileOutputStream.java:204)
*      at java.io.FileOutputStream.(FileOutputStream.java:94)
*      at java.util.logging.FileHandler.initOutputFiles(FileHandler.java:225)
*      at java.util.logging.FileHandler.init(FileHandler.java:195)
*      at java.util.logging.FileHandler.(FileHandler.java:445)
*      at com.ibm.ws.postinstall.runConfigActions.RunConfigActions.setLogFile(RunConfigActions.java:409)
*      at com.ibm.ws.postinstall.runConfigActions.RunConfigActions.main(RunConfigActions.java:77)

This exception was thrown due to permission issue with the AIX user id and the owner of the Websphere install.

The way to get around the restart issue was to change the Stand-alone Server into a Networked Node Server with one node. The Networked install adds another java process called the deployment manager. The deployment manager is what wsadmin jython and jacl scripts will talk to, so the connection is never broken when the server is stopped. The shell script would no longer be used, instead wsadmin is where everything would be done in. Using wsadmin and a networked install enables you to have full access to the AdminConfig and AdminControl objects even against a stopped server.

Here is a link from IBM that describes the differences between stand-alone and networked: IBM Documentation

In conclusion, you may not run into this with larger deployments, Websphere restart for a stand alone server offers a bit different challenge.

 

Join the discussion One Comment

  • DeployHub (https://www.deployhub.org) handles the Websphere server start and stop using the wsadmin and jython script. The jython script will recognize what updates have been made as part of the deployment and take the appropriate action. For example, an application deployment (ear) only would only require an application stop and start. A JVM parameter change would require a server stop and start to pick up the new parameter. DeployHub figures out the different triggers and runs the correct stop/start actions.

Leave a Reply