Cron doesn't have a way to prompt for your sudo credentials. You'd probably have to run that as the true root user and not sudo. Cron usually has it's own user that execute things so you could also make it so that the cron user can do what you're trying to do and get rid of the sudo. --- Jon M. Hanson (N7ZVJ) Homepage: http://the-hansons-az.net/drupal Jabber IM: jon@the-hansons-az.net On May 26, 2009, at 5:22 PM, Jim March wrote: > Folks, > > Last time we wrestled with this, we learned that Zoneminder (camera > monitor app) can do purges of older files. Except it doesn't work. > I've tried three times now, it still fills the disk, I'm flat sick and > tired of it. > > There has to be a way in Ubuntu (Jaunty) to do a daily purge chron job > to the effect of: > > --- > sudo find /media/disk/* -mtime +45 -exec rm {} \; > --- > > That command works fine, executed manually. It purges files older > than 45 days on a particular hard disk formatted ReiserFS (due to the > high number of small files). > > Any way I can get it to kick off daily? > > Thanks, > > Jim > --------------------------------------------------- > PLUG-discuss mailing list - PLUG-discuss@lists.plug.phoenix.az.us > To subscribe, unsubscribe, or to change your mail settings: > http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss --------------------------------------------------- PLUG-discuss mailing list - PLUG-discuss@lists.plug.phoenix.az.us To subscribe, unsubscribe, or to change your mail settings: http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss