Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to get to the bottom of an issue with a non-root user running a cron job and I've stumbled upon /etc/security/access.conf. I have a couple of questions:

  • What service reads this file?
  • Do I need to restart anything after editing it?
  • How do I know it's even being used?


share|improve this question
what error messages are you seeing from your cron job ? – Iain Aug 14 '12 at 17:44

To see which PAM-based services are using it:

grep pam_access /etc/pam.d/*

If it's not mentioned in /etc/pam.d/cron (which I suspect it won't be) then it shouldn't be having any effect on cron jobs. If there are any @include directives in the pam.d files, follow them to make sure you don't miss anything.

share|improve this answer
In /etc/pam.d/crond there's this line: account required - what does that mean? Thanks – Tom Aug 15 '12 at 16:01
It means my guess was wrong and your cron is configured to use the access module. So /etc/security/access.conf will apply. – Alan Curry Aug 15 '12 at 16:11
And to answer the other question 'do I need to restart anything after editing it?'; No, you do not. The file is read every time a session is opened (in your case, when a cron job runs). – Patrick Aug 15 '12 at 18:27

[1] What service reads this file? It is used by pam

[chida@localhost ~]$ rpm -qf /etc/security/access.conf 

[2] Do I need to restart anything after editing it?

Nothing to restart. Once changed, on subsequent login event, the file is read.

[3] How do I know it's even being used?

$ stat /etc/security/access.conf

For more details, do man access.conf.

share|improve this answer
stat /etc/security/access.conf shows Access: 2012-08-15 08:35:01.762992895 +0000 - what causes the Access timestamp to be altered? It wasn't altered when I ran cat /etc/security/access.conf, which must involve reading/accessing the file, right? I'm confused about that. – Tom Aug 15 '12 at 16:04
Linux doesn't do access timestamps correctly anymore, unless you beg for them with the strictatime mount option. – Alan Curry Aug 15 '12 at 16:33

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.