IBM Connections: Error running “setupCmdLine.sh”

by Michael Urspringer - 24.07.2013

While running the setupCmdLine.sh script to set your Websphere environment variables you get the error: “dirname: invalid option — ‘b'”.

This might happen if you start the script (as described in the documentation) from the directory “/opt/IBM/WebSphere/AppServer/bin/”. If you instead run it from the Deployment manager profile, then it should work:

. /opt/IBM/WebSphere/AppServer/profiles/Dmgr01/bin/setupCmdLine.sh

 

Do not forget the leading “. ” in front of the command!

You may check that the variables are set correctly by running

echo $WAS_HOME

 

This variable should now be set to you WAS install directory (e.g. “/opt/IBM/WebSphere/AppServer”)

Tagged with:  

2 Responses to IBM Connections: Error running “setupCmdLine.sh”

  1. Matthias Schneider says:

    Note: Starting with ./ might result in the effect that the variables asr not set correctly. If “echo $WAS_HOME” returns an empty string, navigate to “/opt/IBM/WebSphere/AppServer/profiles/Dmgr01/bin” from a console and run “. setupCmdLine.sh”.

  2. It is not “./” but “. /” – do not forget the blank between “.” and “/” which means that the environment variables should be copied to the current environment and not deleted after the script file ends.

Leave a Reply

© 2000-2015 Michael Urspringer