1 2 rm -f /tmp/sem_* >/dev/null 2>&1 3 rm -f a.out >/dev/null 2>&1 4 5 for sem_id in `ipcs -s | awk '{print $2}'` ; do 6 ipcrm sem $sem_id > /dev/null 2>&1 7 done 8 9