2019-12-11 13:36:26 -06:00
|
|
|
.TH SCRIPTREPLAY 1 "October 2019" "util-linux" "User Commands"
|
2020-05-19 03:31:19 -05:00
|
|
|
.SH NAME
|
2006-12-06 17:26:16 -06:00
|
|
|
scriptreplay \- play back typescripts, using timing information
|
2020-05-19 03:31:19 -05:00
|
|
|
.SH SYNOPSIS
|
2009-07-22 04:29:04 -05:00
|
|
|
.B scriptreplay
|
2014-07-15 16:07:37 -05:00
|
|
|
[options]
|
2011-08-20 04:29:50 -05:00
|
|
|
.RB [ \-t ]
|
2009-07-22 04:29:04 -05:00
|
|
|
.I timingfile
|
|
|
|
.RI [ typescript
|
|
|
|
.RI [ divisor ]]
|
2020-05-19 03:31:19 -05:00
|
|
|
.SH DESCRIPTION
|
2006-12-06 17:25:49 -06:00
|
|
|
This program replays a typescript, using timing information to ensure that
|
2014-07-15 16:07:37 -05:00
|
|
|
output happens in the same rhythm as it originally appeared when the script
|
2008-04-02 04:34:12 -05:00
|
|
|
was recorded.
|
|
|
|
.PP
|
|
|
|
The replay simply displays the information again; the programs
|
2019-06-20 05:48:21 -05:00
|
|
|
that were run when the typescript was being recorded are \fBnot run again\fR.
|
2008-04-02 04:34:12 -05:00
|
|
|
Since the same information is simply being displayed,
|
|
|
|
.B scriptreplay
|
|
|
|
is only guaranteed to work properly if run on the same type of
|
|
|
|
terminal the typescript was recorded on. Otherwise, any escape characters
|
|
|
|
in the typescript may be interpreted differently by the terminal to
|
|
|
|
which
|
|
|
|
.B scriptreplay
|
|
|
|
is sending its output.
|
2006-12-06 17:25:49 -06:00
|
|
|
.PP
|
2011-08-20 04:29:50 -05:00
|
|
|
The timing information is what
|
2009-07-22 04:29:04 -05:00
|
|
|
.BR script (1)
|
2019-06-20 05:48:21 -05:00
|
|
|
outputs to file specified by
|
|
|
|
.BR \-\-log-timing .
|
2006-12-06 17:25:49 -06:00
|
|
|
.PP
|
2011-09-17 16:44:33 -05:00
|
|
|
By default, the typescript to display is assumed to be named
|
2020-07-15 03:15:46 -05:00
|
|
|
.IR typescript ,
|
2011-08-20 04:29:50 -05:00
|
|
|
but other filenames may be specified, as the second parameter or with option
|
2019-06-20 05:48:21 -05:00
|
|
|
.BR \-\-log\-out .
|
2006-12-06 17:25:49 -06:00
|
|
|
.PP
|
2019-06-20 05:48:21 -05:00
|
|
|
If the third parameter or
|
2019-12-13 18:14:40 -06:00
|
|
|
.B \-\-divisor
|
2019-06-20 05:48:21 -05:00
|
|
|
is specified, it is used as a speed-up multiplier.
|
2011-08-20 04:29:50 -05:00
|
|
|
For example, a speed-up of 2 makes
|
2008-04-02 04:34:12 -05:00
|
|
|
.B scriptreplay
|
2011-08-20 04:29:50 -05:00
|
|
|
go twice as fast, and a speed-up of 0.1 makes it go ten times slower
|
2008-04-02 04:34:12 -05:00
|
|
|
than the original session.
|
2011-04-09 14:40:42 -05:00
|
|
|
.SH OPTIONS
|
2019-06-20 05:48:21 -05:00
|
|
|
.TP
|
|
|
|
.BR \-I , " \-\-log-in " \fIfile\fR
|
|
|
|
File containing \fBscript\fR's terminal input.
|
|
|
|
.TP
|
|
|
|
.BR \-O , " \-\-log-out " \fIfile\fR
|
|
|
|
File containing \fBscript\fR's terminal output.
|
|
|
|
.TP
|
|
|
|
.BR \-B , " \-\-log-io " \fIfile\fR
|
|
|
|
File containing \fBscript\fR's terminal output and input.
|
2011-04-09 14:40:44 -05:00
|
|
|
.TP
|
2011-08-20 04:29:50 -05:00
|
|
|
.BR \-t , " \-\-timing " \fIfile\fR
|
2019-06-20 05:48:21 -05:00
|
|
|
File containing \fBscript\fR's timing output. This option overrides old-style arguments.
|
2011-04-09 14:40:44 -05:00
|
|
|
.TP
|
2019-07-30 07:59:34 -05:00
|
|
|
.BR \-T , " \-\-log\-timing " \fIfile\fR
|
2020-07-15 03:15:46 -05:00
|
|
|
This is an alias for \fB\-t\fR, maintained for compatibility with
|
|
|
|
.BR script (1)
|
|
|
|
command-line options.
|
2019-07-30 07:59:34 -05:00
|
|
|
.TP
|
2011-08-20 04:29:50 -05:00
|
|
|
.BR \-s , " \-\-typescript " \fIfile\fR
|
2019-06-20 05:48:21 -05:00
|
|
|
File containing \fBscript\fR's terminal output. Deprecated alias to \fB\-\-log-out\fR.
|
|
|
|
This option overrides old-style arguments.
|
2011-04-09 14:40:44 -05:00
|
|
|
.TP
|
2019-06-20 06:08:00 -05:00
|
|
|
.BR \-c , " \-\-cr\-mode " \fImode\fR
|
2020-07-15 03:15:46 -05:00
|
|
|
Specifies how to use the CR (0x0D, carriage return) character from log files.
|
2019-12-11 13:36:26 -06:00
|
|
|
The default mode is
|
|
|
|
.IR auto ,
|
|
|
|
in this case CR is replaced with line break for stdin log, because otherwise
|
2020-07-15 03:15:46 -05:00
|
|
|
.B scriptreplay
|
|
|
|
would overwrite the same line. The other modes are
|
2019-12-11 13:36:26 -06:00
|
|
|
.I never
|
|
|
|
and
|
|
|
|
.IR always .
|
2019-06-20 06:08:00 -05:00
|
|
|
.TP
|
2011-08-20 04:29:50 -05:00
|
|
|
.BR \-d , " \-\-divisor " \fInumber\fR
|
2011-09-17 16:44:33 -05:00
|
|
|
Speed up the replay displaying this
|
|
|
|
.I number
|
2020-07-15 03:15:46 -05:00
|
|
|
of times. The argument is a floating-point number. It's called divisor
|
2019-06-20 05:48:21 -05:00
|
|
|
because it divides the timings by this factor. This option overrides old-style arguments.
|
2011-04-09 14:40:42 -05:00
|
|
|
.TP
|
2014-02-10 04:53:18 -06:00
|
|
|
.BR \-m , " \-\-maxdelay " \fInumber\fR
|
2020-04-14 04:40:38 -05:00
|
|
|
Set the maximum delay between updates to
|
2014-02-10 04:53:18 -06:00
|
|
|
.I number
|
2020-07-15 03:15:46 -05:00
|
|
|
of seconds. The argument is a floating-point number. This can be used to
|
2020-04-14 04:40:38 -05:00
|
|
|
avoid long pauses in the typescript replay.
|
2014-02-10 04:53:18 -06:00
|
|
|
.TP
|
2019-12-13 18:14:40 -06:00
|
|
|
.B \-\-summary
|
2020-07-15 03:15:46 -05:00
|
|
|
Display details about the session recorded in the specified timing file
|
|
|
|
and exit. The session has to be recorded using
|
2019-12-11 13:36:26 -06:00
|
|
|
.I advanced
|
|
|
|
format (see
|
|
|
|
.BR script (1))
|
2019-06-28 03:19:40 -05:00
|
|
|
option \fB\-\-logging\-format\fR for more details).
|
|
|
|
.TP
|
2019-06-20 06:19:56 -05:00
|
|
|
.BR \-x , " \-\-stream " \fItype\fR
|
2020-07-15 03:15:46 -05:00
|
|
|
Forces
|
|
|
|
.B scriptreplay
|
|
|
|
to print only the specified stream. The supported stream types
|
2019-12-11 13:36:26 -06:00
|
|
|
are
|
|
|
|
.IR in ,
|
|
|
|
.IR out ,
|
|
|
|
.IR signal ,
|
|
|
|
or
|
|
|
|
.IR info .
|
2020-07-15 03:15:46 -05:00
|
|
|
This option is recommended for multi-stream logs (e.g.,
|
|
|
|
.BR \-\-log-io )
|
|
|
|
in order to print only specified data.
|
2019-06-20 06:19:56 -05:00
|
|
|
.TP
|
2011-04-09 14:40:42 -05:00
|
|
|
.BR \-V , " \-\-version"
|
2011-08-20 04:29:50 -05:00
|
|
|
Display version information and exit.
|
2011-04-09 14:40:42 -05:00
|
|
|
.TP
|
|
|
|
.BR \-h , " \-\-help"
|
2013-10-14 14:34:39 -05:00
|
|
|
Display help text and exit.
|
2020-05-25 07:59:12 -05:00
|
|
|
.SH EXAMPLES
|
2011-09-17 16:44:33 -05:00
|
|
|
.nf
|
2019-06-20 05:48:21 -05:00
|
|
|
% script --log-timing file.tm --log-out script.out
|
2011-09-17 16:44:33 -05:00
|
|
|
Script started, file is script.out
|
|
|
|
% ls
|
|
|
|
<etc, etc>
|
|
|
|
% exit
|
|
|
|
Script done, file is script.out
|
2019-10-02 09:55:15 -05:00
|
|
|
% scriptreplay --log-timing file.tm --log-out script.out
|
2020-06-10 20:26:37 -05:00
|
|
|
.fi
|
2020-05-19 07:51:28 -05:00
|
|
|
.SH AUTHORS
|
2008-04-02 04:34:12 -05:00
|
|
|
The original
|
|
|
|
.B scriptreplay
|
2011-09-17 16:44:33 -05:00
|
|
|
program was written by
|
2012-06-02 07:50:52 -05:00
|
|
|
.MT joey@\:kitenet.net
|
2011-09-17 16:44:33 -05:00
|
|
|
Joey Hess
|
2012-06-02 07:50:52 -05:00
|
|
|
.ME .
|
2011-09-17 16:44:33 -05:00
|
|
|
The program was re-written in C by
|
2012-06-02 07:50:52 -05:00
|
|
|
.MT jay@\:gnu.org
|
2011-09-17 16:44:33 -05:00
|
|
|
James Youngman
|
2012-06-02 07:50:52 -05:00
|
|
|
.ME
|
2011-09-17 16:44:33 -05:00
|
|
|
and
|
2012-06-02 07:50:52 -05:00
|
|
|
.MT kzak@\:redhat.com
|
2011-09-17 16:44:33 -05:00
|
|
|
Karel Zak
|
2012-06-02 07:50:52 -05:00
|
|
|
.ME .
|
2020-05-21 02:28:21 -05:00
|
|
|
.SH COPYRIGHT
|
|
|
|
Copyright \(co 2008 James Youngman
|
|
|
|
.br
|
|
|
|
Copyright \(co 2008-2019 Karel Zak
|
|
|
|
.PP
|
|
|
|
This is free software; see the source for copying conditions. There is NO
|
|
|
|
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
|
|
|
PURPOSE.
|
|
|
|
.PP
|
|
|
|
Released under the GNU General Public License version 2 or later.
|
|
|
|
.SH SEE ALSO
|
|
|
|
.BR script (1),
|
|
|
|
.BR scriptlive (1)
|
2007-07-02 18:17:04 -05:00
|
|
|
.SH AVAILABILITY
|
2013-03-17 16:05:19 -05:00
|
|
|
The scriptreplay command is part of the util-linux package and is available from
|
2016-12-17 02:06:57 -06:00
|
|
|
.UR https://\:www.kernel.org\:/pub\:/linux\:/utils\:/util-linux/
|
2011-09-17 16:44:33 -05:00
|
|
|
Linux Kernel Archive
|
|
|
|
.UE .
|