wok-current diff open-vm-tools/stuff/vmtoolsd @ rev 24324

updated arp-scan (1.9.5 -> 1.9.7)
author Hans-G?nter Theisgen
date Thu Jan 27 09:24:22 2022 +0100 (2022-01-27)
parents 995a8662f5ad
children
line diff
     1.1 --- a/open-vm-tools/stuff/vmtoolsd	Fri Sep 18 23:31:50 2015 +0000
     1.2 +++ b/open-vm-tools/stuff/vmtoolsd	Thu Jan 27 09:24:22 2022 +0100
     1.3 @@ -1,5 +1,5 @@
     1.4  #!/bin/sh
     1.5 -# /etc/init.d/vmtoolsd : Start, stop and restart Open VM Tools daemon on SliTaz, at 
     1.6 +# /etc/init.d/vmtoolsd : Start, stop and restart Open VM Tools daemon on SliTaz, at
     1.7  # boot time or with the command line.
     1.8  #
     1.9  # To start VMTools daemon at boot time, just put vmtoolsd in the $RUN_DAEMONS
    1.10 @@ -9,7 +9,7 @@
    1.11  . /etc/daemons.conf
    1.12  
    1.13  NAME=VMTools
    1.14 -DESC="VMTools"
    1.15 +DESC="$(_ '%s daemon' VMTools)"
    1.16  DAEMON=/usr/bin/vmtoolsd
    1.17  PIDFILE=/var/run/vmtoolsd.pid
    1.18  OPTIONS="-b $PIDFILE"
    1.19 @@ -17,10 +17,10 @@
    1.20  case "$1" in
    1.21    start)
    1.22      if active_pidfile $PIDFILE vmtoolsd ; then
    1.23 -      echo "$NAME already running."
    1.24 +      _ '%s is already running.' $NAME
    1.25        exit 1
    1.26      fi
    1.27 -    echo -n "Starting $DESC: $NAME... "
    1.28 +    action 'Starting %s: %s...' "$DESC" $NAME
    1.29      modprobe vmblock
    1.30      modprobe vmhgfs
    1.31      modprobe vmci
    1.32 @@ -31,28 +31,27 @@
    1.33      ;;
    1.34    stop)
    1.35      if ! active_pidfile $PIDFILE vmtoolsd ; then
    1.36 -      echo "$NAME is not running."
    1.37 +      _ '%s is not running.' $NAME
    1.38        exit 1
    1.39      fi
    1.40 -    echo -n "Stopping $DESC: $NAME... "
    1.41 +    action 'Stopping %s: %s...' "$DESC" $NAME
    1.42      kill `cat $PIDFILE`
    1.43      status
    1.44      ;;
    1.45    restart)
    1.46      if ! active_pidfile $PIDFILE vmtoolsd ; then
    1.47 -      echo "$NAME is not running."
    1.48 +      _ '%s is not running.' $NAME
    1.49        exit 1
    1.50      fi
    1.51 -    echo -n "Restarting $DESC: $NAME... "
    1.52 -    kill `cat $PIDFILE`
    1.53 +    action 'Restarting %s: %s...' "$DESC" $NAME
    1.54 +    kill $(cat $PIDFILE)
    1.55      sleep 2
    1.56      $DAEMON $OPTIONS
    1.57      status
    1.58      ;;
    1.59    *)
    1.60 -    echo ""
    1.61 -    echo -e "\033[1mUsage:\033[0m /etc/init.d/`basename $0` [start|stop|restart]"
    1.62 -    echo ""
    1.63 +    emsg "<n><b>$(_ 'Usage:')</b> $0 [start|stop|restart]"
    1.64 +    newline
    1.65      exit 1
    1.66      ;;
    1.67  esac