Non-root users are unable to run cronjobs with custom PAM crond configuration on Red Hat Enterprise Linux 5

Solution Verified - Updated -


  • Cron not working for anything but root. It used to work. When cron jobs run, the following error is seen:
crond[32356]: Permission denied
crond[32356]: CRON (oracle) ERROR: failed to open PAM security session: Bad file descriptor
crond[32356]: CRON (oracle) ERROR: cannot set security context
crond[32368]: pam_access(crond:account): access denied for user `oracle' from `cron'


  • Red Hat Enterprise Linux 5 (RHEL5)
  • PAM (Pluggable Authentication Modules) changed for some services from defaults to reference different lists in /etc/security/access*.conf
  • List of users that should have access to run cronjobs is stored in /etc/security/access-cron.conf:
$ cat /etc/security/access-cron.conf 
  • PAM configuration is the default:
$ cat /etc/pam.d/crond
# The PAM configuration file for the cron daemon
auth       sufficient
auth       required
auth       include    system-auth
account    required
account    include    system-auth
session    required
session    include    system-auth

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.