public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Christian Ruppert" <idl0r@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/openrc:master commit in: init.d/, conf.d/
Date: Tue, 27 Sep 2011 16:16:14 +0000 (UTC)	[thread overview]
Message-ID: <c5fb64d61f1462d0f8790838424722e161ba4024.idl0r@gentoo> (raw)

commit:     c5fb64d61f1462d0f8790838424722e161ba4024
Author:     Christian Ruppert <idl0r <AT> gentoo <DOT> org>
AuthorDate: Tue Sep 27 16:15:08 2011 +0000
Commit:     Christian Ruppert <idl0r <AT> gentoo <DOT> org>
CommitDate: Tue Sep 27 16:15:08 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/openrc.git;a=commit;h=c5fb64d6

Make dmesg log optional

Reported-by: Patrick <gentoo <AT> feystorm.net>
X-Gentoo-Bug: 384485
X-Gentoo-Bug-URL: https://bugs.gentoo.org/384485

---
 conf.d/bootmisc    |    4 ++++
 init.d/bootmisc.in |   13 ++++++++-----
 2 files changed, 12 insertions(+), 5 deletions(-)

diff --git a/conf.d/bootmisc b/conf.d/bootmisc
index 2c1670b..d79706c 100644
--- a/conf.d/bootmisc
+++ b/conf.d/bootmisc
@@ -4,3 +4,7 @@ clean_tmp_dirs="/tmp"
 # Should we wipe the tmp paths completely or just selectively remove known
 # locks / files / etc... ?
 wipe_tmp="YES"
+
+# Write the initial dmesg log into /var/log/dmesg after boot
+# This may be useful if you need the kernel boot log afterwards
+log_dmesg="YES"

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
 



             reply	other threads:[~2011-09-27 16:16 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-27 16:16 Christian Ruppert [this message]
  -- strict thread matches above, loose matches on Subject: below --
2017-10-06 19:44 [gentoo-commits] proj/openrc:master commit in: init.d/, conf.d/ William Hubbs
2017-05-22 17:54 William Hubbs
2016-04-25 17:12 William Hubbs
2016-01-19 19:37 William Hubbs
2016-01-13 17:02 William Hubbs
2014-08-22 19:10 William Hubbs
2014-08-08 23:19 ` William Hubbs
2014-01-05 21:59 William Hubbs
2012-10-26  0:58 William Hubbs
2012-02-18 19:11 William Hubbs
2012-02-18 19:11 William Hubbs
2011-11-26 18:22 Mike Frysinger
2011-11-23  0:55 William Hubbs
2011-11-07  4:07 William Hubbs
2011-11-06 20:04 William Hubbs
2011-07-04  7:52 Robin H. Johnson
2011-06-24  2:58 William Hubbs

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c5fb64d61f1462d0f8790838424722e161ba4024.idl0r@gentoo \
    --to=idl0r@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox