audit: sleep to wait for stop finished
PATCH 1/1 audit: sleep to wait for stop finished
From: Wenzong Fan <[email protected]>
This issue only occurs on Board Target that boot with local disk.
Steps to reproduce the issue:
$ for x in `seq 1 10`; do /etc/init.d/auditd restart; done $ ps -e | grep auditd
There will be many auditd processes running.
If stop is not finished completely, then start will generate two auditd processes in the case.
Signed-off-by Wenzong Fan <[email protected]>
--- recipes-security/audit/audit/auditd | 4 ++++ 1 file changed, 4 insertions(+)
recipes-security/audit/audit/auditd +4 -0
@@ -73,6 +73,10 @@ do_stop() no|NO) ;; *) /sbin/auditctl -D >/dev/null ;; esac + + # Waiting for start-stop-daemon finished + sleep 1 + return "$RETVAL" }
Signature · 1 line
1.9.1