환경Red Hat Enterprise Linux 5Red Hat Enterprise Linux 6문제The cron job wasnt executed successfully, and got these messages:RawJul 10 00:31:01 hostname1 crond[2860]: CRON (xxx) ERROR: failed to open PAM security session: SuccessJul 10 00:31:01 hostname1 crond[2860]: CRON (xxx) ERROR: cannot set security contextHow to let the cron job continue to run?Cron stop after user password expired.해결By default, the crond service will be failed to run if the users password has expired.There are error message in the/var/log/cronfile.For example:Raw# tailf /var/log/cron...Jul 10 00:31:01 hostname1 crond[2860]: Authentication token is no longer valid; new one requiredJul 10 00:31:01 hostname1 crond[2860]: CRON (xxx) ERROR: failed to open PAM security session: SuccessJul 10 00:31:01 hostname1 crond[2860]: CRON (xxx) ERROR: cannot set security contextActually, thepam_unix.sorefuses the crond service to continue to run when the users password has expired.To run cron job all time, modify the/etc/pam.d/system-authfile in order to skip thepam_unix.soauthentication.Modify the/etc/pam.d/system-authaccount section like following:Rawaccount required pam_access.soaccount [success1 defaultignore] pam_succeed_if.so service in crond quiet use_uidaccount required pam_unix.soaccount sufficient pam_localuser.soaccount sufficient pam_succeed_if.so uid 500 quietaccount required pam_permit.soNote:In RHEL6, modify the/etc/pam.d/password-authinstead.Then thepamauthentication forcrondservice will pass.