beautypg.com

Changing the read-write attribute of a file – Brocade Multi-Service IronWare Switching Configuration Guide (Supporting R05.6.00) User Manual

Page 103

background image

Multi-Service IronWare Switching Configuration Guide

73

53-1003036-02

Verifying available flash space on the management module before an image is copied

3

The software renames the file in the file system that has the current management focus flash
memory by default. However, you do not need to change the focus to rename the file in a file
system that does not currently have management focus. In this case, you can specify the
/directory/old-file-name /directory/new-file-name parameter with the rename or mv command to
rename the file in the desired file system.

For example, to rename a file in flash memory, if flash memory has the current management focus,
enter a command such as the following.

Brocade# rename oldname newname

If the command is successful, the CLI displays a new command prompt.

Syntax: [no] rename | mv [/directory/]old-file-name [/directory/]new-file-name

You can enter either rename or mv for the command name.

The /directory/ parameter specifies a directory in a file system that does not have current
management focus. When moving a file, the path must remain at the same directory level. You
cannot rename the directory and the directory can be nested a maximum of five levels.

NOTE

Moving files up to the root directory is not supported.

The old-file-name parameter specifies the original filename that you want to change.

The new-file-name parameter specifies the new filename that you want to assign to the original file.
The new filename must have an equal or greater number of characters than the old filename. The
new filename cannot exceed 32 characters.

NOTE

A new filename with fewer characters than the old filename is not supported.

For example, to rename a file on the flash card inserted in slot 2, if flash memory has the current
management focus, enter a command similar to the following.

Brocade# rename /slot2/oldname /slot2/newname

Changing the read-write attribute of a file

You can specify the read-write attribute of a file on a flash card as follows:

Read-only – You can display or copy the file but you cannot replace (copy over) or delete the
file.

Read-write – You can replace (copy over) or delete the file. This is the default.

NOTE

All files in flash memory are set to the read-write attribute, which cannot be changed. You cannot
change this attribute. Therefore, the attrib command does not apply to the flash memory file system.

To determine the current setting of the read-write attribute for a file, use the dir command to list the
directory information for the file. Files set to read-only are listed with “R” in front of the file name.
For information about the dir command, refer to

“Displaying a directory of the files”

.