BASHPID=$(pstree -a| grep TPOS.POSApplication)
if [[ ! -z $BASHPID ]] ; then
echo "Application already running"
else
$JAVA_HOME/jre/bin/java -Dswing.noxp=true -Djava.library.path=/usr/local/OpenEPS:/usr/lib -classpath .:$CLASSPATH com.retailJava.ltd.javaPOS.UI.TPOS.POSApplication $DEVICE_ID
fi
Please make sure that the variables $JAVA_HOME, $CLASSPATH and $DEVICE_ID are set correctly! This is particularly important when starting the script via cron!
wmp