AnsweredAssumed Answered

error al declarar solr6 como un servicio. solr6: unrecognized service

Question asked by antoniorodes on Nov 29, 2017
Latest reply on Nov 30, 2017 by cristinamr

# cat solr6
#!/bin/sh
#
# chkconfig: 2345 80 30
# description: Alfresco Community SOLR6
#
### BEGIN INIT INFO
# Provides:          solr6
# Required-Start:    $local_fs $remote_fs
# Required-Stop:     $local_fs $remote_fs
# Should-Start:      $all
# Should-Stop:       $all
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: Start/stop Alfresco SOLR6
# Description:       Start/stop Alfresco SOLR6
### END INIT INFO

 

RETVAL=0

 

start () {
    /mnt/datos/alfresco201701/solr6/solr/bin/solr start -m 2G -force "$2"
    RETVAL=$?
    if [ -d "/var/lock/subsys" ] && [ `id -u` = 0 ] && [ $RETVAL -eq 0 ] ; then
        touch /var/lock/subsys/solr6
    fi

 

}

 

stop () {
    /mnt/datos/alfresco201701/solr6/solr/bin/solr stop -all "$2"
    RETVAL=$?
}

 


case "$1" in
    start)
        start "$@"
        ;;
    stop)
        stop "$@"
        ;;
    restart)
        stop "$@"
        start "$@"
        ;;
    *)
        /mnt/datos/alfresco201701/solr6/solr/bin/solr "$@"
        RETVAL=$?
esac
exit $RETVAL

Outcomes