OXIESEC PANEL
- Current Dir:
/
/
snap
/
core
/
17200
/
etc
/
rc1.d
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
06/06/2024 02:31:58 PM
rwxr-xr-x
📄
K01cgmanager
3.48 KB
09/14/2015 10:15:39 PM
rwxr-xr-x
📄
K01cgproxy
3.28 KB
09/14/2015 10:15:39 PM
rwxr-xr-x
📄
K01ubuntu-fan
1.2 KB
10/28/2016 03:24:40 PM
rwxr-xr-x
📄
K03rsyslog
2.73 KB
02/03/2016 10:54:29 AM
rwxr-xr-x
📄
README
369 bytes
01/19/2016 06:33:50 PM
rw-r--r--
📄
S01killprocs
1.27 KB
01/19/2016 06:33:51 PM
rwxr-xr-x
📄
S02single
597 bytes
01/19/2016 06:33:50 PM
rwxr-xr-x
Editing: S01killprocs
Close
#! /bin/sh ### BEGIN INIT INFO # Provides: killprocs # Required-Start: $local_fs # Required-Stop: # Default-Start: 1 # Default-Stop: # Short-Description: executed by init(8) upon entering runlevel 1 (single). ### END INIT INFO PATH=/sbin:/usr/sbin:/bin:/usr/bin . /lib/lsb/init-functions do_start () { # Kill all processes. log_action_begin_msg "Asking all remaining processes to terminate" killall5 -15 # SIGTERM log_action_end_msg 0 alldead="" for seq in 1 2 3 4 5 6 7 8 9 10; do # use SIGCONT/signal 18 to check if there are # processes left. No need to check the exit code # value, because either killall5 work and it make # sense to wait for processes to die, or it fail and # there is nothing to wait for. if killall5 -18 ; then : else alldead=1 break fi sleep 1 done if [ -z "$alldead" ] ; then log_action_begin_msg "Killing all remaining processes" killall5 -9 # SIGKILL log_action_end_msg 1 else log_action_begin_msg "All processes ended within $seq seconds." log_action_end_msg 0 fi } case "$1" in start) do_start ;; restart|reload|force-reload) echo "Error: argument '$1' not supported" >&2 exit 3 ;; stop|status) # No-op ;; *) echo "Usage: $0 start|stop" >&2 exit 3 ;; esac