WorkshopSetup.sh script in the 6.x Extensions Lab exercises does not run successfully.
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
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 $*
Comments
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.
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.
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} $*
Thanks for sharing, Ryan!