From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1R8aKV-0000vY-Fk for garchives@archives.gentoo.org; Tue, 27 Sep 2011 16:16:24 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 0E0E821C0C8; Tue, 27 Sep 2011 16:16:15 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id C2C3721C0C8 for ; Tue, 27 Sep 2011 16:16:15 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 4E4561B400D for ; Tue, 27 Sep 2011 16:16:15 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 4A16180042 for ; Tue, 27 Sep 2011 16:16:14 +0000 (UTC) From: "Christian Ruppert" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Christian Ruppert" Message-ID: Subject: [gentoo-commits] proj/openrc:master commit in: init.d/, conf.d/ X-VCS-Repository: proj/openrc X-VCS-Files: conf.d/bootmisc init.d/bootmisc.in X-VCS-Directories: init.d/ conf.d/ X-VCS-Committer: idl0r X-VCS-Committer-Name: Christian Ruppert X-VCS-Revision: c5fb64d61f1462d0f8790838424722e161ba4024 Date: Tue, 27 Sep 2011 16:16:14 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: X-Archives-Hash: 0eeeb614cceab03141609aee383e1335 commit: c5fb64d61f1462d0f8790838424722e161ba4024 Author: Christian Ruppert gentoo org> AuthorDate: Tue Sep 27 16:15:08 2011 +0000 Commit: Christian Ruppert gentoo org> CommitDate: Tue Sep 27 16:15:08 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/openrc.git;a=3D= commit;h=3Dc5fb64d6 Make dmesg log optional Reported-by: Patrick 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=3D"/tmp" # Should we wipe the tmp paths completely or just selectively remove kno= wn # locks / files / etc... ? wipe_tmp=3D"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=3D"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() } =20 : ${wipe_tmp:=3D${WIPE_TMP:-yes}} +: ${log_dmesg:=3D${LOG_DMESG:-yes}} =20 cleanup_tmp_dir() { @@ -142,11 +143,13 @@ start() fi fi =20 - if $logw || dir_writeable /var/log; then - # Create an 'after-boot' dmesg log - if [ "$RC_SYS" !=3D VSERVER -a "$RC_SYS" !=3D 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" !=3D VSERVER -a "$RC_SYS" !=3D OPENVZ ]; then + dmesg > /var/log/dmesg + chmod 640 /var/log/dmesg + fi fi fi =20