[cups.general] delete old print jobs
Amy Tanner
amy.tanner at netaspx.com
Fri May 18 09:43:30 PDT 2007
On Thu, May 17, 2007 at 01:20:49PM -0500, Minatra, Pat H. (pminatra at hsutx.edu) wrote:
> Amy:
> You can use this:
>
> find /var/spool/cups -mtime +30 -exec rm {} \
>
> This would be thee modified time of the file to be GREATER than 30 days.
> This is the way we do it.
>
> Make sure this does exactly what you need it to (i.e. run without '-exec
> rm {} \'); just use the 'find /var/spool/cups -mtime +30' and you should
> get a pretty good listing. Your particular Unix may vary!
>
> HTH and have a GREAT day!
Thank you for this suggestion. I don't think restarting cups is a good
option in our situation. I'd rather do it with the cancel command. Something
like this:
lpstat -o |grep -v "10 May"|while read id junk; do sudo cancel $id; done
....works for deleting any job not on May 10 but I'm looking for
something to delete jobs older than 5 days.
Any other ideas?
--
Amy Tanner
amy.tanner at netaspx.com
More information about the cups
mailing list