LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-25-2013, 04:05 AM   #1
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 539

Rep: Reputation: 33
no crontab for root - using an empty one ?


Hi,

As I run the command

Code:
crontab -e
I got error message:
Code:
no crontab for root - using an empty one
crontab: no changes made to crontab
But I can open the /etc/crontab which has contents as follow:
Code:
SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=root
HOME=/

# run-parts
01 * * * * root run-parts /etc/cron.hourly
02 4 * * * root run-parts /etc/cron.daily
22 4 * * 0 root run-parts /etc/cron.weekly
42 4 1 * * root run-parts /etc/cron.monthly

What could be the problem?
 
Old 10-25-2013, 04:10 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
/etc/crontab is the system wide crontab not the crontab that belongs to user root.

Individual crontabs, if present, are stored in /var/spool/cron or /var/spool/cron/crontabs (do not edit these files!!!)
 
Old 10-25-2013, 04:53 AM   #3
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 539

Original Poster
Rep: Reputation: 33
you haven't answered my question.
 
Old 10-25-2013, 05:35 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Quote:
Originally Posted by thomas2004ch View Post
you haven't answered my question.
I didn't?

There is not error message, just 2 informative messages.

no crontab for root - using an empty one -> Message is self explanatory (phrased differently: This is the first time you use root's crontab or you emptied the previous one).

No modification made -> Also self explanatory (you did not change anything).

I already told you the difference between /etc/cronatb and crontab -e. crontab -e does not use /etc/crontab it use its own crontab.

If that doesn't suffice, please elaborate.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
No or empty root= argument abrinister Linux - Kernel 5 05-06-2011 03:49 PM
[crontab] emailing non-empty results G00fy Programming 5 09-20-2006 01:16 AM
crontab as root nutthick Linux - Newbie 2 03-03-2005 02:13 AM
Needing root to empty the bin??! hongman Linux - Newbie 2 03-01-2005 01:43 AM
root crontab plisken Slackware 8 05-02-2004 11:41 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:00 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration