Hello all,
I noticed what I donn't understand.
Let alice be a user of a system hebe,
and try an experiment on cron job.
STEP 1.
make /usr/alice/tmp/T that looks like:
hebe# ls -dl /usr/alice/tmp/T
d-rwxrwxrwx M 24 alice alice 0 Sep 3 01:00 /usr/alice/tmp/T
hebe#
STEP 2.
make a rc script /usr/alice/bin/rc/touchtest:
#!/bin/rc
rfork e
d=/usr/alice/tmp/T
t=`{date -n}
touch $d/$t
STEP 3.
make a cron job for alice on /cron/alice/cron such that:
0,10,20,30,40,50 * * * * local /usr/alice/bin/rc/touchtest
STEP 4.
observe files in /usr/alice/tmp/T
and you can confirm, owner of created files is host owner, not
alice.
my case:
hebe% cd /usr/alice/tmp
hebe% ls -l T
--rw-rw-rw- M 195329 arisawa alice 0 Sep 3 00:40 T/1630597201
--rw-rw-rw- M 195329 arisawa alice 0 Sep 3 00:50 T/1630597801
--rw-rw-rw- M 195329 arisawa alice 0 Sep 3 01:00 T/1630598401
hebe%
where "arisawa" is the host owner of "hebe".
Is this reasonable ?
additional info:
hebe# ps | grep cron
arisawa 366 0:00 0:00 128K Sleep cron
hebe#
Kenji Arisawa