[2024-feb-29] Sad news: Eric Layton aka Nocturnal Slacker aka vtel57 passed away on Feb 26th, shortly after hospitalization. He was one of our Wiki's most prominent admins. He will be missed.
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | Next revisionBoth sides next revision | ||
howtos:slackware_admin:service [2019/02/21 09:47 (UTC)] – use USER/GROUP markand | howtos:slackware_admin:service [2019/02/21 10:16 (UTC)] – add exit 1 markand | ||
---|---|---|---|
Line 29: | Line 29: | ||
* **reload** (optional): do some reload if applicable, | * **reload** (optional): do some reload if applicable, | ||
* **status** (optional): check wether the service is running. | * **status** (optional): check wether the service is running. | ||
+ | |||
+ | Return 1 from the service file if you were unable to perform the operation requested. | ||
====== Message formats ====== | ====== Message formats ====== | ||
Line 139: | Line 141: | ||
if [ ! -r $CONF ]; then | if [ ! -r $CONF ]; then | ||
echo "No configuration file available. Aborting" | echo "No configuration file available. Aborting" | ||
- | elif [ -s $PID; then | + | exit 1 |
+ | fi | ||
+ | |||
+ | if [ -s $PID ]; then | ||
echo " | echo " | ||
- | elif [ -x $BIN ]; then | + | exit 1 |
+ | fi | ||
+ | |||
+ | if [ -x $BIN ]; then | ||
echo " | echo " | ||
fi | fi |