Displaying The Last Lines In A File; Command Scripts; Executing Commands Specified In A Script - Cisco AP776A - Nexus Converged Network Switch 5020 Configuration Manual

Cisco mds 9000 family cli configuration guide - release 4.x (ol-18084-01, february 2009)
Hide thumbs Also See for AP776A - Nexus Converged Network Switch 5020:
Table of Contents

Advertisement

Chapter 2
Before You Begin
S e n d d o c u m e n t a t i o n c o m m e n t s t o m d s f e e d b a c k - d o c @ c i s c o . c o m
Building Configuration ...
switch# dir
Usage for volatile://
switch# gzip volatile:Samplefile
switch# dir
Usage for volatile://
The gunzip command uncompresses (unzips) LZ77 coded files.
This example unzips the file that was compressed in the previous example:
switch# gunzip samplefile
switch# dir
Usage for volatile://

Displaying the Last Lines in a File

The tail command displays the last lines (tail end) of a specified file.
The syntax for this command is tail filename [number-of-lines].
switch# tail mylog 10
You see the last 10 lines of the mylog file.

Command Scripts

This section includes the following sections:

Executing Commands Specified in a Script

The run-script command executes the commands specified in a file. To use this command, be sure to
create the file and specify commands in the required order.
Note
You cannot create the script files at the switch prompt. You can create the script file on an external
machine and copy it the bootflash: directory. This section assumes that the script file resides in the
bootflash: directory.
OL-18084-01, Cisco MDS NX-OS Release 4.x
1525859
Jul 04 00:51:03 2003 Samplefile
1527808 bytes used
19443712 bytes free
20971520 bytes total
266069
Jul 04 00:51:03 2003 Samplefile.gz
266240 bytes used
20705280 bytes free
20971520 bytes total
1525859
Jul 04 00:51:03 2003 Samplefile
1527808 bytes used
19443712 bytes free
20971520 bytes total
Executing Commands Specified in a Script, page 2-33
Using CLI Variables in Scripts, page 2-34
Setting the Delay Time, page 2-35
Cisco MDS 9000 Family CLI Configuration Guide
Command Scripts
2-33

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents