Execute a previous command
Availability: This command is available to cluster and Vserver administrators at the admin privilege level.
Description
The
redo command
re-executes a command that has been executed previously
in the current CLI session.
Specify a previously run command using:
- A string that matches part of a previous command.
For example, if the only volume command
you have run is volume show, enter
redo vol
to re-execute the command.
- The numeric ID of a previous command,
as listed by the history command.
For example, enter
redo 4
to re-execute the fourth command in the history list.
- A negative offset from the end of the history list.
For example, enter
redo -2
to re-execute the command that you ran two commands ago.
Parameters
- [<text>] - String, Event Number, or Negative Offset
- Use this parameter to specify a string,
a numeric ID from the command history,
or a negative number
that identifies the command to be re-executed.
Examples
The following example re-executes command number 10 in the command history:
cluster1::> redo 10