1 |
I'm having trouble getting cron to be usable by normal users. |
2 |
|
3 |
I'm running vixie-cron 4.1-r10 on Gentoo Linux. My user is a member of |
4 |
both cron and crontab groups (being unsure which I needed, but |
5 |
speculating the former). There is no cron.allow, and an empty |
6 |
cron.deny file in /etc. |
7 |
|
8 |
Every time I try "crontab -e" as my user, I get this: |
9 |
Code: |
10 |
|
11 |
~~~ |
12 |
no crontab for user - using an empty one |
13 |
crontab: installing new crontab |
14 |
chown: Operation not permitted |
15 |
crontab: edits left in /tmp/crontab.XXXXsXePXF |
16 |
|
17 |
~~~ |
18 |
|
19 |
Naturally, I'm guessing permissions problems. Here are the permissions: |
20 |
|
21 |
~~~ |
22 |
host2 spool # cd /var/spool |
23 |
host2 spool # ls -alR cron/ |
24 |
cron/: |
25 |
total 16 |
26 |
drwxr-x--- 4 root cron 4096 Mar 6 17:16 . |
27 |
drwxr-xr-x 6 root root 4096 Apr 13 16:02 .. |
28 |
-rw-r--r-- 1 root root 0 Mar 6 17:16 .keep_sys-process_cronbase-0 |
29 |
drwx-wx--T 2 root crontab 4096 May 16 14:39 crontabs |
30 |
drwxr-x--- 2 root root 4096 Mar 6 17:16 lastrun |
31 |
|
32 |
cron/crontabs: |
33 |
total 12 |
34 |
drwx-wx--T 2 root crontab 4096 May 16 14:39 . |
35 |
drwxr-x--- 4 root cron 4096 Mar 6 17:16 .. |
36 |
-rw-r--r-- 1 root crontab 0 Mar 6 17:16 .keep_sys-process_vixie-cron-0 |
37 |
-rw------- 1 root crontab 328 Apr 27 12:25 root |
38 |
|
39 |
cron/lastrun: |
40 |
total 8 |
41 |
drwxr-x--- 2 root root 4096 Mar 6 17:16 . |
42 |
drwxr-x--- 4 root cron 4096 Mar 6 17:16 .. |
43 |
-rw-r--r-- 1 root root 0 Mar 6 17:16 .keep_sys-process_cronbase-0 |
44 |
host2 spool # |
45 |
~~~ |
46 |
|
47 |
|
48 |
"crontab -e" does not error out when run as root. |
49 |
"crontab -u myuser -e", when run as root, does create a crontab, which |
50 |
appears to be owned by root, grouped by root, and with rw permissions |
51 |
for owner only. |
52 |
|
53 |
How can I fix this? |
54 |
Thanks. |
55 |
-- |
56 |
gentoo-user@l.g.o mailing list |