Hi guys On Saturday 15 Nov 2008, Geert Stappers wrote: > > > Can you use ps -u $user instead of ps -e, to only check processes with > > > the aptproxy user? > > > > Yes we can. Do you think it's better? > > FWIW: stappers thinks it is better to test for the application. > > After all the aptproxy user could 'www-data' or 'nobody' that is used > also for other process.
Sorry I should have been more verbose. I meant using this in addition to the test for the application, not instead of. So: Replace ps -eo cmd | grep -q ^$process with ps -f "$user" -o cmd | grep -q "^$process" (Adding some quotes just in case these variables end up with spaces in them) Chris -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]