From 6d0e36962bcce42b7c0458b16e3e8a42278db477 Mon Sep 17 00:00:00 2001 From: Scott Ullrich Date: Sat, 25 Mar 2006 23:17:13 +0000 Subject: Use awk --- usr/local/bin/kill_ghosts.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'usr') diff --git a/usr/local/bin/kill_ghosts.sh b/usr/local/bin/kill_ghosts.sh index 51ceda4..5b484ac 100755 --- a/usr/local/bin/kill_ghosts.sh +++ b/usr/local/bin/kill_ghosts.sh @@ -1,5 +1,5 @@ #!/bin/sh # Kill ghost shells -/bin/kill -9 `/bin/ps awux | grep "(sh)" | /usr/bin/grep -v grep | /usr/bin/cut -d" " -f5` +/bin/kill -9 `/bin/ps awux | grep "(sh)" | /usr/bin/grep -v grep | ps awux | grep "(sh)" | grep -v grep | /usr/bin/awk '{ print $2 }'` -- cgit v1.1