Linux FHS requires /var/lib/misc
Stop fuser from being chatty
This commit is contained in:
parent
43f6c2196e
commit
fc6cdefedb
@ -76,9 +76,10 @@ start()
|
|||||||
# Remove any added console dirs
|
# Remove any added console dirs
|
||||||
rm -rf "$RC_LIBEXECDIR"/console
|
rm -rf "$RC_LIBEXECDIR"/console
|
||||||
|
|
||||||
local logw=false runw=false
|
local logw=false runw=false extra=
|
||||||
# Ensure that our basic dirs exist
|
# Ensure that our basic dirs exist
|
||||||
for x in /var/log /var/run /tmp; do
|
[ "$RC_UNAME" = Linux ] && extra=/var/lib/misc # Satisfy Linux FHS
|
||||||
|
for x in /var/log /var/run /tmp $extra; do
|
||||||
if ! [ -d $x ]; then
|
if ! [ -d $x ]; then
|
||||||
if ! mkdir -p $x; then
|
if ! mkdir -p $x; then
|
||||||
eend 1 "failed to create needed directory $x"
|
eend 1 "failed to create needed directory $x"
|
||||||
@ -105,7 +106,7 @@ start()
|
|||||||
# Clean stale sockets
|
# Clean stale sockets
|
||||||
if [ -S "$x" ]; then
|
if [ -S "$x" ]; then
|
||||||
if type fuser >/dev/null 2>&1; then
|
if type fuser >/dev/null 2>&1; then
|
||||||
fuser "$x" 2>/dev/null || rm -- "$x"
|
fuser "$x" >/dev/null 2>&1 || rm -- "$x"
|
||||||
else
|
else
|
||||||
rm -- "$x"
|
rm -- "$x"
|
||||||
fi
|
fi
|
||||||
|
Loading…
x
Reference in New Issue
Block a user