[PLUG] Cron advice needed

Michael Rasmussen michael at jamhome.us
Sat Apr 23 16:36:34 UTC 2016


On Sat, Apr 23, 2016 at 09:22:25AM -0700, John Jason Jordan wrote:
> The command executed, but this morning I decided to enhance it by
> adding your handy reminder and a couple additional # lines copying and
> pasting your explanation of '-auf' for future reference. When I went to
> save my crontab to disk (Crtl-o in nano) I noticed from the prompt that
> nano wanted to write the file as:
> 
> 	/tmp/crontab.2Atvun/crontab
> 
> This puzzles me. I thought things in /tmp were only for temporary use.
> Why is the file saved to /tmp? Shouldn't it be saved to someplace in ~/?

the command `crontab -e` creates a copy of your crontab file in /tmp. 
After you complete your editing and save it the crontab program checks it for 
validity before copying the version in /tmp to the real crontab - in your example
it is probably /var/spool/cron/jjj or /var/spool/cron/crontabs/jjj

No, not in ~/ the folks who created cron decided that all cron files on a system
should be stored in the same place.


-- 
      Michael Rasmussen, Portland Oregon  
    Be Appropriate && Follow Your Curiosity
Dogs are an explosive paradox composed of fur, teeth, and enthusiasm.
    ~ The Oatmeal



More information about the PLUG mailing list