Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
crontab and user
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
trumee
Guru
Guru


Joined: 02 Mar 2003
Posts: 551
Location: London,UK

PostPosted: Tue Oct 07, 2003 6:11 pm    Post subject: crontab and user Reply with quote

Hi,
I want a cron job to run as a normal user and execute every 5 minutes. Instead of messing with the crontab file, i tried webmin to setup the cronjob. A file with my user name was created in /var/spool//cron/crontabs/trumee, which works fine if i do a 'run cron' manually from the webmin page.
However if i leave the system as it is, the cron job is not executed. I feel that the crontab files in /var/spool/cron/crontabs/ is not getting recognised by the system and only /etc/crontab jobs are getting executed. So is there any way i can change the crontab file to /var/spool/cron/crontabs/ . Or alternatively can i specify the command in /etc/crontab to be run as SPECIFIC user?

Thanks
Back to top
View user's profile Send private message
neilhwatson
l33t
l33t


Joined: 06 Feb 2003
Posts: 719
Location: Canada

PostPosted: Tue Oct 07, 2003 6:15 pm    Post subject: Reply with quote

Is your cron daemon running?
Is your user account a member of the cron group?
_________________
The true guru is a teacher.
Neil Watson
Back to top
View user's profile Send private message
trumee
Guru
Guru


Joined: 02 Mar 2003
Posts: 551
Location: London,UK

PostPosted: Tue Oct 07, 2003 6:23 pm    Post subject: Reply with quote

cron daemon seems to be running
---------------------------------------------------------------
ps -ef |grep cron
root 1139 1 0 10:26 ? 00:00:00 /usr/sbin/crond
root 24531 24528 0 19:22 pts/3 00:00:00 grep cron
-----------------------------------------------------------------

However the user is not a member of cron group, is that necessary?
Back to top
View user's profile Send private message
neilhwatson
l33t
l33t


Joined: 06 Feb 2003
Posts: 719
Location: Canada

PostPosted: Tue Oct 07, 2003 6:26 pm    Post subject: Reply with quote

I believe so. This a security measure that prevents users from running cronjobs without authorization.
_________________
The true guru is a teacher.
Neil Watson
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum