mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2026-10-07 23:14:48 +02:00
Update checkfiles.sh
This commit is contained in:
1 parent
f9b52677d7
commit
ea1227de9d
1 file changed
+9
@@ -1,5 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
APP=checkfiles
|
||||
lf=/tmp/$APP-pidLockFile
|
||||
# create empty lock file if none exists
|
||||
cat /dev/null >> $lf
|
||||
read lastPID < $lf
|
||||
# if lastPID is not null and a process with that pid exists , exit
|
||||
[ ! -z "$lastPID" -a -d /proc/$lastPID ] && exit
|
||||
echo $$ > $lf
|
||||
|
||||
FILES=$(ls -1x /host/nsm/faf/complete/ | wc -l)
|
||||
|
||||
echo "faffiles files=$FILES"
|
||||
Reference in new issue
Block a user