From owner-freebsd-hackers Thu Jul 25 01:02:01 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id BAA25272 for hackers-outgoing; Thu, 25 Jul 1996 01:02:01 -0700 (PDT) Received: from skye.hut.fi (vode@skye.hut.fi [130.233.224.74]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id BAA25267 for ; Thu, 25 Jul 1996 01:01:56 -0700 (PDT) Received: (from vode@localhost) by skye.hut.fi (8.7.3/8.7.3) id LAA23852; Thu, 25 Jul 1996 11:01:50 +0300 Date: Thu, 25 Jul 1996 11:01:50 +0300 Message-Id: <199607250801.LAA23852@skye.hut.fi> From: Kai Vorma To: hans@brandinnovators.com (Hans Zuidam) cc: hackers@freebsd.org Subject: Re: catching /etc/rc output Reply-to: Kai.Vorma@hut.fi Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Is there a convenient way to direct all output from the /etc/rc scripts to both the console and a file other than rewriting them? Scrollback is not always sufficient especially after lengthy fsck output. I have written a simple program that grabs console output and redirects it both to the console and a file. If the output file is not writable (partition is not yet mounted or read only) it saves console output to a circular buffer until the log file is available. It can also monitor its parent process and exit when the parent dies so it can be started at the head of /etc/rc and it exits automagically when rc is done. The code isn't very clean but I can send it to you if you want it. ..vode