Bug 135845 - several problems with "crontab -e"
several problems with "crontab -e"
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: vixie-cron (Show other bugs)
4.0
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Jason Vas Dias
Brock Organ
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-10-15 07:59 EDT by Uwe Beck
Modified: 2007-11-30 17:07 EST (History)
0 users

See Also:
Fixed In Version: vixie-cron-4.1-19
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-10-15 10:16:54 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Uwe Beck 2004-10-15 07:59:39 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:1.4.3)
Gecko/20040924

Description of problem:
First look for "man crontab".

If the cron.allow file exists, then you must be listed there in order
to  be  allowed  to  use this command.  If the cron.allow file does
not exist but the cron.deny file does exist, then you must not be
listed in the  cron.deny  file in order to use this command.

If neither of these files exists, only the super user will be allowed
to use this  command.

[root] # crontab -e
You (root) are not allowed to use this program (crontab)
See crontab(1) for more information

After create /etc/cron.allow for user root it works. But the manual
tells me that I do not need /etc/cron.allow.

Put some lines in the user crontab over the command crontab -e and
also comment lines and save it.
At the next crontab -e you do not see the comment lines.
If you want temorary disable a command with "#" then you can not
activate it again with crontab -e You can only do this in the
/var/spool/cron userfile.


Version-Release number of selected component (if applicable):
vixie-cron-4.1-11

How reproducible:
Always

Steps to Reproduce:
1. create an user cronjob with crontab -e, use comments
2. disable a command line temporary with "#"
3.
    

Actual Results:  crontab -e as root need other then the manual tells
cron.allow
comments in own job not possible

Expected Results:  crontab -e should work correct

Additional info:
Comment 1 Jason Vas Dias 2004-10-15 09:55:07 EDT
There is a new version of cron for RHEL-4: vixie-cron-4.1-18
This should be available from up2date/yum .
4.1-18 fixed the problems with /etc/cron.{allow,deny} and root
not being able to run crontab -e .
The comments issue will be fixed in the next version (4.1-19).
It was caused by crontab assuming:
 /* ignore the top few comments since we probably put them there.
  */
ISC vixie-cron always adds default comments to every crontab file; 
a Red Hat patch stopped these default comments being generated, but
crontab still assumes they are there and removes them. Well spotted!
Comment 2 Jason Vas Dias 2004-10-15 10:16:54 EDT
This is now fixed in vixie-cron-4.1-19 
Comment 3 Uwe Beck 2004-10-16 17:18:15 EDT
The fixes in vixie-cron-4.1-19 works correct. Thanks.

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