how to add a service on linux to run protege_server

Post Reply
vhquijia
Posts: 30
Joined: 15 Apr 2015, 20:39

Hi everibody

Please I need the script to add a service on linux RHEL to run or stop the protege server.
/etc/init.d/

Now, i execute the protege_server.sh from windows for console.
Thanks

Victor H
vhquijia
Posts: 30
Joined: 15 Apr 2015, 20:39

Hi

I'm trying, with script without success.
..................................
#!/bin/sh
#
# description: Demonio de arranque PROTEGE
#
# chkconfig: - 85 15
export JAVA_HOME=/datos/java/jdk1.6.0_16
export PROTEGE_HOME=/root/Protege_3.5
start(){
$ PROTEGE_HOME/run_protege_server.sh
}
stop(){
$ PROTEGE_HOME/shutdown_protege_server.sh
}

case "$1" in
start)
echo "Iniciado / Starting protege ..."
start
;;
stop)
echo "Deteniendo / Stopping protege ..."
stop
;;
restart)
echo "Reiniciando / Restarting protege ..."
stop
start
;;
*)
echo $"Uso / Using : $0 {start|stop}"
exit 1
esac
----------------
Regards

Victor H
User avatar
jonathan.carter
Posts: 1087
Joined: 04 Feb 2009, 15:44

Hi Victor,

I think removing that space between the '$' and 'PROTEGE_HOME' would be the first place to start.

Let us know if that helps

Jonathan
Essential Project Team
vhquijia
Posts: 30
Joined: 15 Apr 2015, 20:39

Ok, thanks Jonathan.

$PROTEGE_HOME/run_protege_server.sh

Regards

VH
:)
Post Reply