Bug 35985 - "crontab -r" behavior
"crontab -r" behavior
Product: Red Hat Linux
Classification: Retired
Component: vixie-cron (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jason Vas Dias
David Lawrence
: FutureFeature
: 54119 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2001-04-15 21:19 EDT by Red Hat Bugzilla
Modified: 2008-03-13 15:18 EDT (History)
1 user (show)

See Also:
Fixed In Version: vixie-cron-4.1-8
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-08-10 17:55:30 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Red Hat Bugzilla 2001-04-15 21:19:38 EDT
The "-r" option of "crontab" command is USELESS and often HARMFUL.
(It's easy to mistype "-e" as "-r"!)

  disable "-r" option
  change to make backup file.
Comment 1 Red Hat Bugzilla 2001-09-27 14:02:44 EDT
I agree.
The R key is next to the E key.
At least there should be a confirmation prior to delete your crontab.
A crontab is a really usefull config, and is likelly that you will never
will want to delete a crontab file.

Please disable the -r option.

Comment 2 Red Hat Bugzilla 2002-08-14 06:40:34 EDT
*** Bug 54119 has been marked as a duplicate of this bug. ***
Comment 3 Red Hat Bugzilla 2002-12-10 18:17:22 EST
Please don't remove "crontab -r". It's a standard crontab option, and it makes 
programmatic manipulation of crontab files a lot easier. My site depends on it 
for some scripts which do automatic error-handling for our automated jobs.
Comment 4 Red Hat Bugzilla 2002-12-10 18:51:18 EST
I think a good solution would be to add an -i option, like cp and mv have.
Then, people wanting the new feature will only need to add:
alias crontab="crontab -i"
to the their /etc/bashrc file
Comment 5 Red Hat Bugzilla 2004-08-10 17:55:30 EDT
This is now fixed in vixie-cron-4.1-8 . 
There is now a '-i' modifier of the '-r' crontab delete 
option that will prompt for Y/y before actually deleting
the crontab, similar to 'cp -i' / 'mv -i'.

Note You need to log in before you can comment on or make changes to this bug.