Table Of Contents
D Commands
delete
dir
discover scsi-target
discover custom-list
do
D Commands
The commands in this chapter apply to the Cisco MDS 9000 Family of multilayer directors and fabric switches. All commands are shown here in alphabetical order regardless of command mode. See the "Command Modes" section to determine the appropriate mode for each command. For more information, refer to the Cisco MDS 9000 Family Configuration Guide.
•delete
•dir
•discover scsi-target
•discover custom-list
•do
delete
To delete a specified file or directory on a Flash memory device, use the delete command in EXEC mode.
delete {bootflash:filename | slot0:filename | volatile:filename}
Syntax Description
bootflash:
|
Flash image that resides on the supervisor module.
|
slot0:
|
Flash image that resides on another module.
|
volatile:
|
Flash image that resides on the volatile file system.
|
filename
|
The name of the file to be deleted.
|
Defaults
None.
Command Modes
EXEC mode.
Command History
This command was introduced in Cisco MDS SAN-OS Release 1.0(2).
Usage Guidelines
When you delete a file, the software erases the file.
If you attempt to delete the configuration file or image specified by the CONFIG_FILE or BOOTLDR environment variable, the system prompts you to confirm the deletion. Also, if you attempt to delete the last valid system image specified in the BOOT environment variable, the system prompts you to confirm the deletion.
Caution If you specify a directory, the
delete command deletes the entire directory and all its contents.
Examples
The following example deletes the file named test from the Flash card inserted in slot 0.
switch# delete slot0:test
Delete slot0:test? [confirm]
The following example deletes a file from a directory.
switch# delete dns_config.cfg
The following example deletes a file from an external CompactFlash (slot0).
switch# delete slot0:dns_config.cfg
The following example deletes the entire my-dir directory:
switch# delete bootflash:my-dir
dir
To display the contents of the current directory or the specified directory, use the dir command in EXEC mode.
dir [bootflash:directory or filename | slot0:directory or filename | volatile:directory or filename]
Syntax Description
bootflash:
|
(Optional) Flash image that resides on the supervisor module.
|
slot0:
|
(Optional) Flash image that resides on another module.
|
filename directory
|
(Optional) Name of the files or directories to display on a specified device. The files can be of any type. You can use wildcards in the filename. A wildcard character (*) matches all patterns. Strings after a wildcard are ignored.
|
volatile:
|
Flash image on the volatile file system.
|
Defaults
The default file system is specified by the cd command.
Command Modes
EXEC mode.
Command History
This command was introduced in Cisco MDS SAN-OS Release 1.0(2).
Usage Guidelines
None.
Examples
The following example shows how to list the files on the bootflash directory.
switch# dir bootflash:
total 100756
drwxrwxrwx 2 admin 1024 Fri Sep 27 17:35:13 2002 .ssh
drwxrwxrwx 2 admin 1024 Fri Sep 27 17:35:13 2002 .ssh2
-rw-r--r-- 1 admin 37 Thu Sep 19 12:16:36 2002 ^[[2C
-rw-r--r-- 1 admin 13636096 Fri Sep 20 19:58:56 2002 kickstart-233b
-rw-rw-rw- 1 admin 13636096 Wed Sep 25 17:26:47 2002 kickstart-233d
-rw-rw-rw- 1 admin 14340096 Fri Sep 27 17:28:41 2002 kickstart-240
drwxr-xr-x 2 admin 1024 Thu Apr 18 08:27:44 2002 harshabh
-rw-r--r-- 1 admin 19280051 Fri Sep 20 20:02:33 2002 san-ios-233b
-rw-rw-rw- 1 admin 19281464 Wed Sep 25 17:28:12 2002 san-ios-233d
-rw-rw-rw- 1 admin 21917189 Fri Sep 27 17:29:51 2002 san-ios-240
drwxr-xr-x 2 admin 3072 Tue Oct 01 10:54:18 2002 logs
drwxr-xr-x 2 admin 12288 Sun Mar 31 19:18:26 2002 lost+found
drwxr-xr-x 3 admin 1024 Wed Apr 10 20:17:44 2002 old-fs
drwxr-xr-x 3 admin 1024 Wed Sep 18 13:18:54 2002 old-fs-old
-rwxr-xr-x 1 admin 636579 Mon Sep 30 05:32:42 2002 rdl
drwxr-xr-x 2 admin 1024 Mon Sep 30 05:37:55 2002 src
124688384 bytes total used
459779072 bytes available
The following example is sample output from the dir command.
Related Commands
Command
|
Description
|
cd
|
Changes the default directory or file system.
|
delete
|
Deletes a file on a Flash memory device.
|
discover scsi-target
To discover SCSI targets on local storage to the switch or remote storage across the fabric, use the discover scsi-target command in EXEC mode.
discover scsi-target {custom-list | local | partial | remote | vsan vsan-id domain domain-id}
Syntax Description
custom-list
|
Discovers SCSI targets from the customized list.
|
local
|
Discovers local SCSI targets.
|
remote
|
Discovers remote SCSI targets.
|
vsan vsan-id
|
Discovers SCSI targets for the specified VSAN ID.
|
domain domain-id
|
Discovers SCSI targets for the specified domain ID. The domain ID is a number from 0 to 255 in decimal or a number from 0x0 to 0xFF in hex.
|
Defaults
None.
Command Modes
EXEC mode.
Command History
This command was modified in Cisco MDS SAN-OS Release 1.1(1).
Usage Guidelines
On-demand discovery only discovers Nx ports present in the name server database that have registered a FC4 Type = SCSI_FCP.
Examples
The following example shows how to discover local targets.
switch# discover scsi-target local
The following example shows how to discover remote targets.
switch# discover scsi-target remote
The following example shows how to discover both local and remote targets.
switch# discover scsi-target
The following example shows how to discover SCSI targets for the specified VSAN (1) and FC ID (0x9c03d6).
switch# discover scsi-target vsan 1 fcid 0x9c03d6
discover scsi-target vsan 1 fcid 0x9c03d6
VSAN: 1 FCID: 0x9c03d6 PWWN: 00:00:00:00:00:00:00:00
PRLI RSP: 0x01 SPARM: 0x0012...
The following example begins discovering targets from the customized list.
switch# discover scsi-target custom-list
discover custom-list
To selectively initiate discovery for specified domain IDs in a VSAN, use the discover custom-list command in EXEC mode.
discover custom-list [ add | delete ] vsan vsan-id domain fc-id}
Syntax Description
add
|
Add a targets to the customized list.
|
delete
|
Deletes a target from the customized list.
|
vsan vsan-id
|
Discovers SCSI targets for the specified VSAN ID.
|
domain fc-id
|
Discovers SCSI targets for the specified FC ID.
|
Defaults
None.
Command Modes
EXEC mode.
Command History
This command was introduced in Cisco MDS SAN-OS Release 1.1(1).
Usage Guidelines
None.
Examples
The following example selectively initiates discovery for the specified VSAN and domain ID.
switch# discover custom-list add vsan 1 domain 0X123456
The following example deletes the specified VSAN and domain ID from the customized list.
switch# discover custom-list delete vsan 1 domain 0X123456
do
Use the do command to execute an EXEC-level command from any configuration mode or submode.
do command
Syntax Description
command
|
Specifies the EXEC command to be executed.
|
Defaults
None.
Command Modes
All configuration modes.
Command History
This command was introduced in Cisco MDS SAN-OS Release 1.1(1).
Usage Guidelines
Use this command to execute EXEC commands while configuring your switch. After the EXEC command is executed, the system returns to the mode from which you issued the do command.
Examples
The following example disables the terminal session-timeout command using the do command in configuration mode.
switch(config)# do terminal session-timeout 0
The following example create, enables, and displays the interface from configuration mode.
switch(config)# int fc 3/1
switch(config-if)# no shut
switch(config-if)# do show interface fc 3/1
Hardware is Fibre Channel
Port WWN is 20:81:00:05:32:00:4a:9e
Peer port WWN is 20:43:00:0c:88:00:4a:e2
Admin port mode is auto, trunk mode is on
Receive B2B Credit is 255
Receive data field Size is 2112
Trunk vsans (admin allowed and active) (1-10)
Trunk vsans (isolated) ()
Trunk vsans (initializing) ()
5 minutes input rate 504 bits/sec, 63 bytes/sec, 0 frames/sec
5 minutes output rate 344 bits/sec, 43 bytes/sec, 0 frames/sec
69390 frames input, 4458680 bytes
69458 frames output, 3086812 bytes
2 input OLS, 1 LRR, 0 NOS, 2 loop inits
1 output OLS, 1 LRR, 1 NOS, 1 loop inits