Table Of Contents
E Commands
echo
end
exit
exec-timeout
E Commands
This chapter describes the Cisco Nexus 1000V commands that begin with the letter E.
echo
To echo an argument back to the terminal screen, use the echo command.
echo [backslash-interpret] [text]
Syntax Description
-e
|
(Optional) Interprets any character following a backslash character (\) as a formatting option.
|
backslash-interpret
|
(Optional) Interprets any character following a backslash character (\) as a formatting option.
|
text
|
(Optional) Text string to display. The text string is alphanumeric, case sensitive, can contain spaces, and has a maximum length of 200 characters. The text string can also contain references to CLI variables.
|
Defaults
Displays a blank line.
Command Modes
Any
Supported User Roles
network-admin
Command History
Release
|
Modification
|
4.0(4)SV1(1)
|
This command was introduced.
|
Usage Guidelines
You can use this command in a command script to display information while the script is running.
Table 1 lists the formatting keywords that you can insert in the text when you include the -e or backslash-interpret keyword.
Table 1 Formatting Options for the echo Command
Formatting Option
|
Description
|
\b
|
Back spaces.
|
\c
|
Removes the new line character at the end of the text string.
|
\f
|
Inserts a form feed character.
|
\n
|
Inserts a new line character.
|
\r
|
Returns to the beginning of the text line.
|
\t
|
Inserts a horizontal tab character.
|
\v
|
Inserts a vertical tab character.
|
\\
|
Displays a backslash character.
|
\nnn
|
Displays the corresponding ASCII octal character.
|
Examples
This example shows how to display a blank line at the command prompt:
This example shows how to display a line of text at the command prompt:
n1000v# echo Script run at $(TIMESTAMP).
Script run at 2008-08-12-23.29.24.
This example shows how to use a formatting option in the text string:
n1000v# echo backslash-interpret This is line #1. \nThis is line #2.
Related Commands
Command
|
Description
|
run-script
|
Runs command scripts.
|
end
To exit a configuration mode and return to Privileged EXEC mode, use the end command.
end
Syntax Description
This command has no arguments or keywords.
Defaults
None
Command Modes
Any
Supported User Roles
network-admin
network-operator
Command History
Release
|
Modification
|
4.0(4)SV1(1)
|
This command was introduced.
|
Usage Guidelines
This command differs from the exit command in that the exit command returns you to the configuration mode you were previously in. The end command always takes you completely out of configuration mode and places you in Privileged EXEC mode.
Examples
This example shows how to end the session in Global Configuration mode and return to Privileged EXEC mode:
This example shows how to end the session in Interface Configuration mode and return to Privileged EXEC modee:
Related Commands
Command
|
Description
|
exit
|
Exits the current command mode and returns you to the previous command mode.
|
exit
To exit a configuration mode or exit the CLI, use the exit command.
exit
Syntax Description
This command has no arguments or keywords.
Defaults
None
Command Modes
Any
Supported User Roles
network-admin
network-operator
Command History
Release
|
Modification
|
4.0(4)SV1(1)
|
This command was introduced.
|
Usage Guidelines
Examples
This example shows how to exit Global Configuration mode. The CLI returns you to the EXEC mode.
This example shows how to exit Interface Configuration mode. The CLI returns you to the Global Configuration mode.
This example shows how to exit the CLI.
Related Commands
Command
|
Description
|
end
|
Returns to the EXEC command mode.
|
exec-timeout
To configure the length of time, in minutes, that an inactive Telnet or SSH session remains open before it is automatically shut down, use the exec-timeout command. To remove an exec timeout setting, use the no form of this command.
exec-timeout time
no exec-timeout [time]
Syntax Description
time
|
Timeout time, in minutes. The range of valid values is 0 to 525600.
If a session remains inactive longer than this specified time period, then it is automatically closed.
|
Defaults
No timeout is configured.
Command Modes
Console Configuration (config-console)
Supported User Roles
network-admin
Command History
Release
|
Modification
|
4.0(4)SV1(1)
|
This command was introduced.
|
Usage Guidelines
When you set time to 0, exec timeout is disabled.
Examples
This example shows how to configure an inactive session timeout for the console port:
n1000v# configure terminal
n1000v(config)# line console
n1000v(config-com1)# exec-timeout 20
This example shows how to configure an inactive session timeout for the virtual terminal:
n1000v# configure terminal
n1000v(config-line)# exec-timeout 20
This example shows how to remove an exec timeout on the console port:
n1000v(config)# configure terminal
DocTeamVSM(config)# line console
n1000v(config-console)# no exec-timeout
Related Commands
Command
|
Description
|
show terminal
|
Displays the terminal configuration, including the timeout value.
|
show users
|
Displays the currently active user sessions.
|