Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 16 Dec 2006 21:23:14 -0600
From:      Dan Nelson <dnelson@allantgroup.com>
To:        JAMES T RIENDEAU <jtriende@wisc.edu>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Translate job number from atq to commands that will run
Message-ID:  <20061217032314.GA43992@dan.emsphone.com>
In-Reply-To: <FEAAF0F6-92E0-4C83-80F4-65C8F0979D76@wisc.edu>
References:  <FEAAF0F6-92E0-4C83-80F4-65C8F0979D76@wisc.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
In the last episode (Dec 16), JAMES T RIENDEAU said:
> Does anybody know how I could translate the job # into the commands  
> that will run from the output of the atq command?  For example, here  
> is my current atq:
> 
> Date				Owner	Queue	Job #
> Mon Dec 18 09:00:00 CST 2006	root	c	34
...
> Sat Jan  6 09:00:00 CST 2007	root	c	47
> 
> I checked the /var/at/spool and /var/at/jobs, but it isn't obvious  
> which job is scheduled to run when.

"at -c n" will list the commands to be run for job n.

The filenames in /var/at/jobs are of the format "qnnnnntttttttt", where
q is the queue, n is the job number in hex, and t is the time the job
is scheduled in hex (in minutes from the Epoch, so multiply by 60 to
get the more-standard seconds from Epoch).  For more info, see at at
manpage and /usr/src/usr.bin/at/at.c .

-- 
	Dan Nelson
	dnelson@allantgroup.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061217032314.GA43992>