Init: first commit
This commit is contained in:
parent
5f8cc15838
commit
8f5bbe1d6f
6 changed files with 76 additions and 0 deletions
23
force-stop.sh
Executable file
23
force-stop.sh
Executable file
|
|
@ -0,0 +1,23 @@
|
|||
#!/bin/bash
|
||||
# force stop rslsync process
|
||||
|
||||
# Check pid file exists
|
||||
if [ ! -f ./storage/sync.pid ]; then
|
||||
echo "./storage/sync.pid file not found"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Get pid from ./storage/sync.pid
|
||||
pid=$(cat ./storage/sync.pid)
|
||||
|
||||
# Echo
|
||||
echo "force stopping rslsync process (pid: $pid)"
|
||||
|
||||
# Send SIGKILL to the process
|
||||
kill -SIGKILL $pid
|
||||
|
||||
# Remove the pid file if exists
|
||||
#rm -f ./storage/sync.pid
|
||||
|
||||
# Echo
|
||||
echo "rslsync process force stopped"
|
||||
Loading…
Add table
Add a link
Reference in a new issue