Commit e0f67622 authored by Thibault VINCENT's avatar Thibault VINCENT
Browse files

init script: add message on start/stop

parent 306a10f4
Loading
Loading
Loading
Loading
+8 −6
Original line number Diff line number Diff line
@@ -26,8 +26,10 @@ GROUP=root
# Exit if the package is not installed
[ -x "$DAEMON" ] || exit 0

# Load the VERBOSE setting and other rcS variables
# Load various rcS variables
. /lib/init/vars.sh
# Override the VERBOSE variable so we always have feedback messages
VERBOSE=yes

# Define LSB log_* functions.
# Depend on lsb-base (>= 3.2-14) to ensure that this file is present
@@ -109,20 +111,20 @@ case "$1" in
        # If the "reload" option is implemented then remove the
        # 'force-reload' alias
        #
        log_daemon_msg "Restarting $DESC" "$NAME"
        [ "$VERBOSE" != no ] && log_daemon_msg "Restarting $DESC" "$NAME"
        do_stop
        case "$?" in
          0|1)
                do_start
                case "$?" in
                        0) log_end_msg 0 ;;
                        1) log_end_msg 1 ;; # Old process is still running
                        *) log_end_msg 1 ;; # Failed to start
                        0) [ "$VERBOSE" != no ] && log_end_msg 0 ;;
                        1) [ "$VERBOSE" != no ] && log_end_msg 1 ;; # Old process is still running
                        *) [ "$VERBOSE" != no ] && log_end_msg 1 ;; # Failed to start
                esac
                ;;
          *)
                # Failed to stop
                log_end_msg 1
                [ "$VERBOSE" != no ] && log_end_msg 1
                ;;
        esac
        ;;