summaryrefslogtreecommitdiff
path: root/init.d
diff options
context:
space:
mode:
authorChristian Ruppert <idl0r@gentoo.org>2011-09-27 18:15:08 +0200
committerChristian Ruppert <idl0r@gentoo.org>2011-09-27 18:15:08 +0200
commitc5fb64d61f1462d0f8790838424722e161ba4024 (patch)
tree478c11c327e14a93755e788f236efb3761e23af0 /init.d
parent4b6392987873107f83fa135b871ac137a6c29ba2 (diff)
downloadopenrc-c5fb64d61f1462d0f8790838424722e161ba4024.tar.gz
openrc-c5fb64d61f1462d0f8790838424722e161ba4024.tar.bz2
openrc-c5fb64d61f1462d0f8790838424722e161ba4024.tar.xz
Make dmesg log optional
Reported-by: Patrick <gentoo@feystorm.net> X-Gentoo-Bug: 384485 X-Gentoo-Bug-URL: https://bugs.gentoo.org/384485
Diffstat (limited to 'init.d')
-rw-r--r--init.d/bootmisc.in13
1 files changed, 8 insertions, 5 deletions
diff --git a/init.d/bootmisc.in b/init.d/bootmisc.in
index 6607f45..2ca7926 100644
--- a/init.d/bootmisc.in
+++ b/init.d/bootmisc.in
@@ -16,6 +16,7 @@ dir_writeable()
}
: ${wipe_tmp:=${WIPE_TMP:-yes}}
+: ${log_dmesg:=${LOG_DMESG:-yes}}
cleanup_tmp_dir()
{
@@ -142,11 +143,13 @@ start()
fi
fi
- if $logw || dir_writeable /var/log; then
- # Create an 'after-boot' dmesg log
- if [ "$RC_SYS" != VSERVER -a "$RC_SYS" != OPENVZ ]; then
- dmesg > /var/log/dmesg
- chmod 640 /var/log/dmesg
+ if yesno $log_dmesg; then
+ if $logw || dir_writeable /var/log; then
+ # Create an 'after-boot' dmesg log
+ if [ "$RC_SYS" != VSERVER -a "$RC_SYS" != OPENVZ ]; then
+ dmesg > /var/log/dmesg
+ chmod 640 /var/log/dmesg
+ fi
fi
fi