Directing Show Command Output To A File; Compressing And Uncompressing Files - Cisco MDS 9000 series Command Reference Manual

Hide thumbs Also See for MDS 9000 series:
Table of Contents

Advertisement

Chapter 1
CLI Overview
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
Redirection is allowed only if the current directory is on the
Note
Redirection is not allowed if the current directory is on the
can be viewed using the pwd command and changed using the cd command.

Directing show Command Output to a File

You can direct show command output to a file, either on the volatile file system, on slot0 CompactFlash
memory, or on a remote server.
The following example shows how to direct the show running-config output to a file on the volatile file
system.
switch1# show running-config > volatile:switch1-run.cfg
The following example shows how to direct the show running-config output to a file on slot0
CompactFlash memory.
switch2# show running-config > slot0:switch2-run.cfg
The following example shows how to direct the show running-config output to a file on a TFTP server.
switch3# show running-config > tftp://10.10.1.1/home/suser/switch3-run.cfg
Preparing to copy...done

Compressing and Uncompressing Files

The gzip command compresses (zips) the specified file using LZ77 coding.
This example directs the output of the show tech-support command to a file (Samplefile) and then zips
the file and displays the difference in the space used up in the volatile: directory:
switch# show tech-support > Samplefile
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
/volatile/samplefile.gz: No such file or directory
switch# gunzip Samplefile
switch# dir
Usage for volatile://
OL-8413-07, Cisco MDS SAN-OS Release 3.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
(default) or
volatile:
file system. The current directory
bootflash:
Cisco MDS 9000 Family Command Reference
Using the File System
file systems.
slot0:
1-37

Advertisement

Table of Contents
loading

Table of Contents