Debian: Crontab -e error: crontabs/myusername/: fdopen: Permission denied

From FVue
Jump to: navigation, search

Problem

When I try to edit my crontab with crontab -e, I get this error message:

$ crontab -e
crontabs/myusername/: fdopen: Permission denied

Environment

  • Debian-6.0.2 (Squeeze)

Solution

1. Add myusername to the crontab group:

$ sudo usermod -aG crontab myusername

2. Logout and login myusername. Now crontab -e works for me.

See also

Journal

20110707

Setting the "setgid bit" made does NOT resolve the error for me:

# ls -l /usr/bin/crontab
-rwxr-sr-x 1 root root 30248 Dec 19  2010 /usr/bin/crontab
# chmod g+s /usr/bin/crontab
# ls -l /usr/bin/crontab
-rwxr-sr-x 1 root root 30248 Dec 19  2010 /usr/bin/crontab
# # ...
# # I'm still getting the "Permission denied" error
# # ...
# chmod g-s /usr/bin/crontab  # Restoring/unsetting setgid

Comments

blog comments powered by Disqus