From owner-freebsd-questions@FreeBSD.ORG Thu Feb 2 05:18:17 2012 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 5B694106564A for ; Thu, 2 Feb 2012 05:18:17 +0000 (UTC) (envelope-from toomas.aas@raad.tartu.ee) Received: from kuller.raad.tartu.ee (kuller.raad.tartu.ee [213.184.43.8]) by mx1.freebsd.org (Postfix) with ESMTP id 091558FC14 for ; Thu, 2 Feb 2012 05:18:16 +0000 (UTC) Received: from kuller.raad.tartu.ee (localhost [127.0.0.1]) by kuller.raad.tartu.ee (Postfix) with ESMTP id EF630398FF for ; Thu, 2 Feb 2012 07:18:15 +0200 (EET) X-Virus-Scanned: amavisd-new at post.raad.tartu.ee Received: from kuller.raad.tartu.ee ([127.0.0.1]) by kuller.raad.tartu.ee (kuller.raad.tartu.ee [127.0.0.1]) (amavisd-new, port 10024) with LMTP id u0DG83__lXrx for ; Thu, 2 Feb 2012 07:18:14 +0200 (EET) Received: by kuller.raad.tartu.ee (Postfix, from userid 80) id 8663D398FE; Thu, 2 Feb 2012 07:18:14 +0200 (EET) Received: from 76.20.190.90.dyn.estpak.ee (76.20.190.90.dyn.estpak.ee [90.190.20.76]) by webmail.raad.tartu.ee (Horde Framework) with HTTP; Thu, 02 Feb 2012 07:18:14 +0200 Message-ID: <20120202071814.20673llnbpp31iw4@webmail.raad.tartu.ee> Date: Thu, 02 Feb 2012 07:18:14 +0200 From: Toomas Aas To: freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: 7bit User-Agent: Internet Messaging Program (IMP) H3 (4.3.7) X-Originating-IP: 90.190.20.76 Subject: Identifying at jobs 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: Thu, 02 Feb 2012 05:18:17 -0000 I've been curious about this for a long time. Say I have three jobs scheduled with at, as seen with atq: # atq Date Owner Queue Job# Thu Jan 12 22:12:00 EET 2012 root c 6931 Fri Jan 13 03:44:00 EET 2012 root c 6932 Fri Jan 13 04:01:00 EET 2012 root c 6933 How do I tell which job does what? I can see the files corresponding to jobs in /var/at/jobs: # ls -l /var/at/jobs total 8 -rw-r--r-- 1 root wheel 6 Jan 12 18:05 .SEQ -rw------- 1 root wheel 0 Dec 10 2007 .lockfile -rwx------ 1 root wheel 1096 Jan 12 12:15 c01b130151521c -rwx------ 1 root wheel 1096 Jan 12 17:45 c01b1401515368 -rwx------ 1 root wheel 1091 Jan 12 18:05 c01b1501515379 If I look into one of the files, say c01b1501515379, I can see the command I have scheduled at the end of the file. But how do I tell which of these files corresponds to which Job# in atq output? I'd like to remove one of the jobs with atrm, but I can't figure out, which job I need to remove. -- Toomas Aas