Hi,
Something funny is happening over here: when a regular user edits his cron-file (crontab -e) saves and exits
vi the correct new cron-file gets installed and saved to disk. But if root does the same,
vi saves it but if I then check the cron-file it has the previous contents! I did strace (== truss on other platforms) and I see the following (edited for brievety):
chdir("/var/
spool/cron/crontabs") = 0
open("/var/
spool/cron/crontab.8195", O_RDWR|O_CREAT|O_TRUNC|O_EXCL, 0600) = 3
chown32("/var/
spool/cron/crontab.8195", 0, 0) = 0
open("root", O_RDONLY) = 4
/* fd 4 (original cron file) gets copied to fd 3, then
vi gets invoked on crontab.8195 */
/*
vi exits */
unlink("/var/
spool/cron/crontab.8195") = 0
lseek(3, 0, SEEK_SET) = 0
open("root.new", O_WRONLY|O_APPEND|O_CREAT|O_TRUNC, 0600) = 5
/* copies fd 3 to fd 5
rename("root.new", "root") = 0
So things DO get editted and written correctly but still the output-file is the original?!
crontab version 2.3.3
dcron version 2.3.3
Linux system.