Crontab permission problem

8,722

Correct right to /usr/bin/crontab are -rwsr-xr-x. So use chmod 4755 /usr/bin/crontab to set them.

Share:
8,722

Related videos on Youtube

user3918478
Author by

user3918478

Updated on September 18, 2022

Comments

  • user3918478
    user3918478 over 1 year

    I have a fc19 host at work.
    This morning crontab did not work.

    $ ls -l /usr/bin/crontab
    ----------. 1 root root 53472 Jun 11  2013 /usr/bin/crontab
    

    The permissions -------- means no one has access and can't change rights or rename etc.

    To have access to this should the permission be changed to rwxr-xr-x?
    What can do ?

    • geedoubleya
      geedoubleya over 9 years
      As the root user you will need to use the chmod command to change it to -rwsr-xr-x. 1 root root 53472 Jun 11 2013 /usr/bin/crontab Notice the rws This is the setuid (set user id) bit.
    • Gilles 'SO- stop being evil'
      Gilles 'SO- stop being evil' over 9 years
      Beyond fixing the symptom, you should investigate why the permissions were changed. Also, note that the file has an SELinux context, which may or may not be correct.
    • user3918478
      user3918478 over 9 years
      i dont have any idea what is reason to change the file but now i can't edit, remove, delete, rename, or do anything as root
  • user3918478
    user3918478 over 9 years
    chmod 4755 /usr/bin/crontab after that chmod: changing permissions of â/usr/bin/crontabâ: Operation not permitted
  • Scyld de Fraud
    Scyld de Fraud over 9 years
    You need to run that command as root user.
  • Gilles 'SO- stop being evil'
    Gilles 'SO- stop being evil' over 9 years
    What about the SELinux context?