Hi, Here is the working script of start and and stop Jboss. Please copy and paste the below code in agular brackets in run.sh file in exact place.
if $useprofiler; then
# Hand over control to profiler
# Execute the JVM
if [ "$1" = "start" ] ; then
exec $JAVA $JAVA_OPTS \
-classpath "$JBOSS_CLASSPATH" \
org.jboss.Main "$@" 2>&1 &
echo $! > /var/run/jboss.pid
elif [ "$1" = "stop" ] ; then
kill -9 $(cat /var/run/jboss.pid)
echo "JBoss is successully stopped"
Sorry forgot to mention. After placing the above code you would start the server as "./run.sh start" and similarly you stop it by issuing command "./run.sh stop".