wok-current view 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 source
1 #!/bin/sh
2 # /etc/init.d/vmtoolsd : Start, stop and restart Open VM Tools daemon on SliTaz, at
3 # boot time or with the command line.
4 #
5 # To start VMTools daemon at boot time, just put vmtoolsd in the $RUN_DAEMONS
6 # variable of /etc/rcS.conf and configure options with /etc/daemons.conf
7 #
8 . /etc/init.d/rc.functions
9 . /etc/daemons.conf
11 NAME=VMTools
12 DESC="$(_ '%s daemon' VMTools)"
13 DAEMON=/usr/bin/vmtoolsd
14 PIDFILE=/var/run/vmtoolsd.pid
15 OPTIONS="-b $PIDFILE"
17 case "$1" in
18 start)
19 if active_pidfile $PIDFILE vmtoolsd ; then
20 _ '%s is already running.' $NAME
21 exit 1
22 fi
23 action 'Starting %s: %s...' "$DESC" $NAME
24 modprobe vmblock
25 modprobe vmhgfs
26 modprobe vmci
27 modprobe vmsync
28 modprobe vsock
29 $DAEMON $OPTIONS
30 status
31 ;;
32 stop)
33 if ! active_pidfile $PIDFILE vmtoolsd ; then
34 _ '%s is not running.' $NAME
35 exit 1
36 fi
37 action 'Stopping %s: %s...' "$DESC" $NAME
38 kill `cat $PIDFILE`
39 status
40 ;;
41 restart)
42 if ! active_pidfile $PIDFILE vmtoolsd ; then
43 _ '%s is not running.' $NAME
44 exit 1
45 fi
46 action 'Restarting %s: %s...' "$DESC" $NAME
47 kill $(cat $PIDFILE)
48 sleep 2
49 $DAEMON $OPTIONS
50 status
51 ;;
52 *)
53 emsg "<n><b>$(_ 'Usage:')</b> $0 [start|stop|restart]"
54 newline
55 exit 1
56 ;;
57 esac
59 exit 0