Re: Can I change group and permissions on the messages file?



On Mon, 25 Sep 2006 02:35:32 +0000 (UTC), Ohmster wrote:

Uh well, I used webmin to add the script as a daily task and it does not
show up the way you show it, it does show up with a crontab -l though.

Yep, your method created a seperate cron entry to execute a script.

What I showed is the cron job which uses
run-parts
to execute each scrip indicated in the directory given as an argument.

On my system run-parts would run the jobs in the folling order.
$ ls -al /etc/cron.daily
-rwxr-xr-x 1 root root 1,024 certwatch
lrwxrwxrwx 1 root root 23 ckupdate_cron -> /site/bin/ckupdate_cron
-rwxr-xr-x 1 root root 180 logrotate
-rwxr-xr-x 1 root root 402 makewhatis.cron
-rwxr-xr-x 1 root root 126 mlocate.cron
lrwxrwxrwx 1 root root 27 msec -> /usr/share/msec/security.sh
-rwxr-xr-x 1 root root 118 rpm
-rwxr-xr-x 1 root root 101 tetex.cron
-rwxr-xr-x 1 root root 403 10:45 tmpwatch

Now if I have your chmod in ckupdate_cron script,
logrotate could come along and undo the priv change.
.