In the openafs-client init script, suppress errors from cat if the
modules_disabled flag file in /proc/sys/kernel doesn't exist, since
this was added in 2.6.31.
# Determine if kernel module loading is disabled. If it's not, don't attempt
# to stop or restart AFS, since we'll end up in a bad inconsistent state.
is_loading_disabled() {
- loading=`cat /proc/sys/kernel/modules_disabled`
+ loading=`cat /proc/sys/kernel/modules_disabled 2>/dev/null`
if [ "$loading" = 1 ] ; then
return 0
else