We no longer support pam_console directly. Also, we cannot use chgrp due to silly LDAP issues.
This commit is contained in:
parent
a8fcb36d72
commit
11a745ab0c
@ -93,11 +93,11 @@ start() {
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
# Setup login records
|
ebegin "Creating user login records"
|
||||||
printf "" >/var/run/utmp
|
printf "" >/var/run/utmp
|
||||||
[ -e /var/log/wtmp ] || printf "" >/var/log/wtmp
|
[ -e /var/log/wtmp ] || printf "" >/var/log/wtmp
|
||||||
chgrp utmp /var/run/utmp /var/log/wtmp
|
chmod 0644 /var/run/utmp /var/log/wtmp
|
||||||
chmod 0664 /var/run/utmp /var/log/wtmp
|
eend 0
|
||||||
|
|
||||||
ebegin "Cleaning /var/run"
|
ebegin "Cleaning /var/run"
|
||||||
for x in $(find /var/run ! -type d ! -name utmp ! -name innd.pid \
|
for x in $(find /var/run ! -type d ! -name utmp ! -name innd.pid \
|
||||||
@ -112,13 +112,6 @@ start() {
|
|||||||
esac
|
esac
|
||||||
rm -f "${x}"
|
rm -f "${x}"
|
||||||
done
|
done
|
||||||
|
|
||||||
# Reset pam_console permissions if we are actually using it
|
|
||||||
if [ -x /sbin/pam_console_apply ] && ! [ -c /dev/.devfsd ]; then
|
|
||||||
if grep -v -e '^[[:space:]]*#' /etc/pam.d/* | grep -q 'pam_console.so'; then
|
|
||||||
pam_console_apply -r
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
eend 0
|
eend 0
|
||||||
|
|
||||||
# Clean up /tmp directories
|
# Clean up /tmp directories
|
||||||
@ -147,13 +140,6 @@ start() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
stop() {
|
stop() {
|
||||||
# Reset pam_console permissions if we are actually using it
|
|
||||||
if [ -x /sbin/pam_console_apply ] && ! [ -c /dev/.devfsd ]; then
|
|
||||||
if grep -v -e '^[[:space:]]*#' /etc/pam.d/* | grep -q 'pam_console.so' ;then
|
|
||||||
/sbin/pam_console_apply -r
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Write a halt record if we're shutting down
|
# Write a halt record if we're shutting down
|
||||||
case "${RC_SOFTLEVEL}" in
|
case "${RC_SOFTLEVEL}" in
|
||||||
reboot|shutdown) [ "${RC_UNAME}" = "Linux" ] && halt -w;;
|
reboot|shutdown) [ "${RC_UNAME}" = "Linux" ] && halt -w;;
|
||||||
|
Loading…
Reference in New Issue
Block a user