From owner-freebsd-questions@freebsd.org Wed Jan 25 13:14:07 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AC785CBE598 for ; Wed, 25 Jan 2017 13:14:07 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2A118ED for ; Wed, 25 Jan 2017 13:14:06 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id v0PDDtIO008571; Thu, 26 Jan 2017 00:13:55 +1100 (EST) (envelope-from smithi@nimnet.asn.au) Date: Thu, 26 Jan 2017 00:13:55 +1100 (EST) From: Ian Smith To: David Christensen cc: freebsd-questions@freebsd.org Subject: Re: How to capture console messages during boot? In-Reply-To: Message-ID: <20170125230947.T59687@sola.nimnet.asn.au> References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Jan 2017 13:14:07 -0000 In freebsd-questions Digest, Vol 660, Issue 3 Message: 19 On Tue, 24 Jan 2017 21:17:02 -0800 David Christensen wrote: > > On Tue, 24 Jan 2017 19:59:01 -0800 > > David Christensen wrote: > >> I am attempting to build a graphical workstation using: > >> [snip] > >> As I add software and adjust configuration settings, invariably I create > >> or encounter issues. Some of these generate warnings/ errors on the > >> console when the system boots. I'd like to capture console messages > >> during boot, so that I can review them and fix things. The old-fashioned way is to add to /etc/syslog.conf # uncomment this to log all writes to /dev/console to /var/log/console.log # touch /var/log/console.log and chmod it to mode 600 before it will work console.info /var/log/console.log and in /etc/newsyslog.conf perhaps (mode 640 so :wheel can read) /var/log/console.log 640 7 200 * J && service syslogd restart > On 01/24/17 20:45, Sergei Akhmatdinov wrote: > > 2. Use `dmesg -a`, maybe piped into `less` if you prefer. > > The -a switch should show you the boot process messages, which are normally > > suppressed. > > Yes, that's what I was looking for. That includes what's in both /var/log/messages and /var/log/consoie.log > On 01/24/17 21:07, Michael Sierchio wrote: > > cat /var/run/dmesg.boot > > That is incomplete -- I don't see all of the messages (just kernel, not > init?). If you choose verbose boot, or have added boot_verbose="YES" to /boot/loader.conf you'll get much more detailed messages (and dmesg) from boot and afterwards, but usually the same console.log - which is just what you'd see on the root console, if you were always looking :) cheers, Ian