PQ95060: ONCE CLIENT SET THE COM.IBM.EJS.SM.ADMINSERVER.FORCERECONNECT= TRUE PROPERTY IN ADMIN.CONFIG FILE THE JLOOKUP.KSH SCRIPT FAILS.

APAR status
Closed as program error.

Error description
Customer saying if he sets the
com.ibm.ejs.sm.adminServer.forceReconnect=true property in
admin.config file the jlookup.ksh script is not working
correctly. He pointed out the defect in code.



<WAS_HOME>/bin/jlookup.ksh
Original script

####################################################
lookForstartupServer ()
{
    set +x
    jrc=88
    jentry "lookForstartupServer"
    ps -ef --width 10000 |grep startupServer.sh|awk '
      BEGIN {rc = 0;count = 0}
      ($NF ~ /startupServer.sh$/) && (NF == 9) && ($8 ~ /sh$/){
          if (++count >= 2){
              rc = 1;
              exit
          }
      }

      END{exit rc}
    '
    jrc=$?
    jexit $jrc lookForstartupServer
    return
}
####################################################

Customer things script should be this.

      ($NF ~ /startupServer.sh$/) && (NF == 9) && ($8 == "sh"){
<<<<<<<  should be /bin/sh
          if (++count >= 2){
              rc = 1;
              exit
          }
      }
      ($NF ~ /startupServer.sh$/) && (NF == 10) && ($9 == "sh"){
<<<<<<<< should be /bin/sh
          if (++count >= 2){
              rc = 1;
              exit
          }
      }
      END{exit rc}
Local fix
Corrected script should look like (in jlookup.ksh)

lookForstartupServer ()
{
    set +x
    jrc=88
    jentry "lookForstartupServer"
    ps -ef --width 10000 |grep startupServer.sh|awk '
      BEGIN {rc = 0;count = 0}
      ($NF ~ /startupServer.sh$/) && (NF == 9) && ($8 ~ /sh$/){
          if (++count >= 2){
              rc = 1;
              exit
          }
      }

      END{exit rc}
    '
    jrc=$?
    jexit $jrc lookForstartupServer
    return



Only change is $8 == "sh" , $9 == "sh
should be changed to $8 ~ /sh$/ , $9 ~ /sh$/ meaning 8th/9th
field should end with sh
Problem summary
****************************************************************
* USERS AFFECTED: WebSphere Application Server users of        *
*                 version 4.0.x                                *
****************************************************************
* PROBLEM DESCRIPTION: startupServer.sh can be invoked more    *
*                      than once even when                     *
*                      com.ibm.ejs.adminserver.force           *
*                      reconnect=true is set                   *
****************************************************************
* RECOMMENDATION:                                              *
****************************************************************
startupServer.sh can be invoked more than once when
com.ibm.ejs.adminserver.forcereconnect=true is set
Problem conclusion
Bug in jlookup.ksh in identifying an existing running
startupServer.sh is corrected now.
This fix is available via iFix PQ95060
Temporary fix
Temporary fix has been uploaded into 
pq99999 site
Comments
APAR information
APAR number PQ95060
Reported component name WAS NETWRK DEPL
Reported component ID 5630A3601
Reported release 400
Status CLOSED PER
PE NoPE
HIPER NoHIPER
Submitted date 2004-09-29
Closed date 2004-11-10
Last modified date 2004-11-10

APAR is sysrouted FROM one or more of the following:

APAR is sysrouted TO one or more of the following:

Modules/Macros
SCRIPT          

Fix information
Fixed component name WEBSPHERE AE AI
Fixed component ID 5630A2200

Applicable component levels
R400 PSY    UP


Document Information


Product categories: Software > Application Servers > Distributed Application & Web Servers > WebSphere Application Server > General
Operating system(s):
Software version: 400
Software edition:
Reference #: PQ95060
IBM Group: Software Group
Modified date: Nov 10, 2004