4 printf "Starting mosquitto: "
5 start-stop-daemon
-S -q -m -b -p /var
/run
/mosquitto.pid \
6 --exec /usr
/sbin
/mosquitto \
7 -- -c /etc
/mosquitto
/mosquitto.conf
8 [ $?
= 0 ] && echo "OK" ||
echo "FAIL"
11 printf "Stopping mosquitto: "
12 start-stop-daemon
-K -q -p /var
/run
/mosquitto.pid
13 [ $?
= 0 ] && echo "OK" ||
echo "FAIL"
31 echo "Usage: $0 {start|stop|restart}"