From owner-freebsd-questions@FreeBSD.ORG Sun May 31 18:17:29 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 839C4106564A for ; Sun, 31 May 2009 18:17:29 +0000 (UTC) (envelope-from kelly.terry.jones@gmail.com) Received: from qw-out-2122.google.com (qw-out-2122.google.com [74.125.92.27]) by mx1.freebsd.org (Postfix) with ESMTP id 3FD178FC14 for ; Sun, 31 May 2009 18:17:29 +0000 (UTC) (envelope-from kelly.terry.jones@gmail.com) Received: by qw-out-2122.google.com with SMTP id 3so3788511qwe.7 for ; Sun, 31 May 2009 11:17:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type:content-transfer-encoding; bh=ayzukY4CXg17l4mQ8AqBBPDk5I1OQAc+n/0121UeSKg=; b=XXBeSQI9sfdUqqY+/pJ/TtSTBovXqjRWSHsfB1sIVOd9utz3q8/0lQ/B5SkK5aZw2y tSsQHea7t0vlLhhQVNKl7iYM6C8HOfKAJLsLHfCXg/vHxDsrqSfuJNKFMiVNDThiwq2H +P58bX09quiHL4i6Ozd+JYhUyRcWtPFCyO8TM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type :content-transfer-encoding; b=fNYpA4QiaCay3mDna5Tx/AMUqH7fVMRSnPuG92AO6mL8ZTaElzqTCZpz6n3aH8oCdE p5wkI7njg6hNBiYjWbHMFf9Q+TTFu+dPG9MIQlBvsAyjBklY3mqzykQN83jtUdqfhFXn ymJQ1aEgGBkC63XsOa/2xBUHEvXJQYMX5Ut+c= MIME-Version: 1.0 Received: by 10.229.82.79 with SMTP id a15mr1501572qcl.57.1243793848650; Sun, 31 May 2009 11:17:28 -0700 (PDT) Date: Sun, 31 May 2009 11:17:28 -0700 Message-ID: <26face530905311117te38a4faya92733fbfebd9597@mail.gmail.com> From: Kelly Jones To: freebsd-questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Waiting for a process to die X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 31 May 2009 18:17:29 -0000 How do I wait for a specific process to die? I want to do something like: waitpid 1234&&(echo "done!" | Mail -s "PROC DONE" kelly.terry.jones@gmail.com) I'm sure this is trivial, but I can't find a way to do it. I wrote a Perl script that checks every second if /proc/pid exists, but that only works if /proc is mounted + I'm now on VMs which can't easily mount /proc -- We're just a Bunch Of Regular Guys, a collective group that's trying to understand and assimilate technology. We feel that resistance to new ideas and technology is unwise and ultimately futile.