It's all about the answers!

Ask a question

WorkshopSetup.sh script in the 6.x Extensions Lab exercises does not run successfully.


0
1
Ryan McFadden (191318) | asked Feb 27 '18, 10:02 p.m.

I'm working through the lab exercises in a Linux environment. I have done everything up to page 26.

When I run the WorkshopSetup.sh script, it lists all the environment variables then displays the following two lines of output:

WorkshopSetup.sh: line 9: fg: no job control
WorkshopSetup.sh: line 9: ./Data: is a directory

Then execution terminates and returns to the command prompt.

Did I miss something in the setup prior to this step? 

The directions indicate that if this script doesn't run successfully, the lab exercises are possible.

Is it possible to duplicate the setup manually?

Accepted answer


permanent link
Ralph Schoon (63.5k33646) | answered Feb 28 '18, 2:54 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Ryan,

the workshop was designed and tested in Windows.
I basically don't have a Linux machine available and was not able to test the shell script. I think I basically did a copy error and no one noticed so far.

While you could run the workshop in a limp along mode I think it is much more easy to fix the shell script.

Please see if you can fix the line that calls the jar file. There are % characters that should not be there, that is a copy/paste error from windows. So the script should rather look as below.

!/bin/sh

export JAVA_HOME=..JazzTeamServer/server/jre export PLAIN_JAVA=../PlainJavaAPI export REPOSITORY="https://localhost:9443/ccm" export USERID="myadmin" export PASSWORD="myadmin"

env $JAVA_HOME/bin/java -cp $PLAIN_JAVA/;./ com.ibm.js.rtcext.serversetup.ServerSetup $REPOSITORY $USERID $PASSWORD $*

Ryan McFadden selected this answer as the correct answer

Comments
Ralph Schoon commented Feb 28 '18, 2:59 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Note, I don't understand the reference to

WorkshopSetup.sh: line 9: fg: no job control
WorkshopSetup.sh: line 9: ./Data: is a directory


./Data is nowhere in the call and should not be a folder in any of the paths.



Ralph Schoon commented Feb 28 '18, 5:53 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

With the following initial lines:

!/bin/sh

export JAVA_HOME=../JazzTeamServer/server/jre export PLAIN_JAVA=../PlainJavaAPI export REPOSITORY="https://localhost:9443/ccm" export USERID="myadmin" export PASSWORD="myadmin"

env

you want to run something like

../JazzTeamServer/server/jre/bin/java -cp ../PlainJavaAPI/*:./* com.ibm.js.rtcext.serversetup.ServerSetup "https://localhost:9443/ccm" "myadmin" "myadmin"  

You might have to check. In Unix there might be slight differences e.g. the delimiter is : as in the new example, if I am not mistaken.


Ryan McFadden commented Feb 28 '18, 2:17 p.m.

This is what my script looks like when it worked on my RedHat 6.6 machine

#!/bin/sh

export JAVA_HOME="<RELATIVE PATH TO JRE>"
export PLAIN_JAVA="<RELATIVE PATH TO PLAIN JAVA API>"
export REPOSITORY=https://localhost:9443/ccm
export USERID="myadmin"
export PASSWORD="myadmin"

env

${JAVA_HOME}/bin/java -cp ${PLAIN_JAVA}/*:/* com.ibm.js.rtcert.serversetup.ServerSetup ${REPOSITORY} ${USERID} ${PASSWORD} $*


Ralph Schoon commented Mar 01 '18, 2:15 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Thanks for sharing, Ryan!

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.