blob: cc3ffde3fb0ff8bc2b4078958e4c187b85af6bd3 [file] [log] [blame]
Theodore Ts'of9ddad52003-04-14 18:05:12 -04001.\" -*- nroff -*-
2.\" Copyright 2003 by Theodore Ts'o. All Rights Reserved.
3.\" This file may be copied under the terms of the GNU Public License.
Theodore Ts'od04ad322017-08-04 01:51:50 -04004.\"
Theodore Ts'of9ddad52003-04-14 18:05:12 -04005.TH LOGSAVE 8 "@E2FSPROGS_MONTH@ @E2FSPROGS_YEAR@" "E2fsprogs version @E2FSPROGS_VERSION@"
6.SH NAME
7logsave \- save the output of a command in a logfile
8.SH SYNOPSIS
9.B logsave
10[
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040011.B \-asv
Theodore Ts'of9ddad52003-04-14 18:05:12 -040012]
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040013.I logfile cmd_prog [ ... ]
Theodore Ts'of9ddad52003-04-14 18:05:12 -040014.SH DESCRIPTION
15The
16.B logsave
17program will execute
Theodore Ts'od04ad322017-08-04 01:51:50 -040018.I cmd_prog
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040019with the specified argument(s), and save a copy of its output to
Theodore Ts'of9ddad52003-04-14 18:05:12 -040020.IR logfile .
21If the containing directory for
22.I logfile
Theodore Ts'od04ad322017-08-04 01:51:50 -040023does not exist,
Theodore Ts'of9ddad52003-04-14 18:05:12 -040024.B logsave
25will accumulate the output in memory until it can be written out.
26A copy of the output will also be written to standard output.
27.PP
Theodore Ts'od04ad322017-08-04 01:51:50 -040028If
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040029.I cmd_prog
Theodore Ts'of9ddad52003-04-14 18:05:12 -040030is a single hyphen ('-'), then instead of executing a program,
31.B logsave
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040032will take its input from standard input and save it in
33.I logfile
Theodore Ts'of9ddad52003-04-14 18:05:12 -040034.PP
35.B logsave
Theodore Ts'od04ad322017-08-04 01:51:50 -040036is useful for saving the output of initial boot scripts
37until the /var partition is mounted, so the output can be written to
Theodore Ts'of9ddad52003-04-14 18:05:12 -040038/var/log.
39.SH OPTIONS
40.TP
41.B \-a
Theodore Ts'od04ad322017-08-04 01:51:50 -040042This option will cause the output to be appended to
Theodore Ts'of9ddad52003-04-14 18:05:12 -040043.IR logfile ,
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040044instead of replacing its current contents.
45.TP
46.B \-s
Theodore Ts'od04ad322017-08-04 01:51:50 -040047This option will cause
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040048.B logsave
Theodore Ts'od04ad322017-08-04 01:51:50 -040049to skip writing to the log file text which is bracketed with a control-A
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040050(ASCII 001 or Start of Header) and control-B (ASCII 002 or Start of
51Text). This allows progress bar information to be visible to the user
52on the console, while not being written to the log file.
Theodore Ts'of9ddad52003-04-14 18:05:12 -040053.TP
54.B \-v
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040055This option will make
Theodore Ts'of9ddad52003-04-14 18:05:12 -040056.B logsave
Theodore Ts'obc34d6b2003-04-16 14:05:06 -040057to be more verbose in its output to the user.
Theodore Ts'of9ddad52003-04-14 18:05:12 -040058.SH AUTHOR
59Theodore Ts'o (tytso@mit.edu)
60.SH SEE ALSO
61.BR fsck (8)