01-Fundamentals Command Reference

HomeSupportSwitchesH3C S12500 Switch SeriesReference GuidesCommand ReferencesH3C S12500 Command References-Release1828P04-6W18201-Fundamentals Command Reference
04-File System Management Commands
Title Size Download
04-File System Management Commands 147.39 KB

Throughout this document, a filename can be entered as either of the following:

·     A fully qualified filename with a path included to indicate a file under a specific path. The filename can be 1 to 135 characters in length, excluding the ending character.

·     A short filename with no path to indicate a file in the current working path. The filename can be 1 to 91 characters in length, excluding the ending character.

cd

Syntax

cd { directory | .. | / }

View

User view

Default level

3: Manage level

Parameters

directory: Name of the target directory, in the format of [drive:/]path. For more information about the drive and path arguments, see Fundamentals Configuration Guide. If no drive information is provided, the argument represents a folder or subfolder in the current directory.

..: Returns to an upper directory. If the current working directory is the root directory, or no upper directory exists, the current working directory does not change when the cd .. command is executed. This argument does not support command online help.

/: Returns to the root directory of the storage medium. The keyword does not support command line online help.

Description

Use cd to change the current working directory.

Examples

# Enter the test folder after logging in to the switch.

<Sysname> cd test

# Return to the upper directory. (You must enter a space after the keyword cd.)

<Sysname> cd ..

# Return to the root directory.

<Sysname> cd /

# Enter the Flash root directory of the standby MPU that resides in slot 1 of member switch 1 in IRF mode.

<Sysname> cd chassis1#slot1#flash:/

After changing the current working directory with the cd command, use the pwd command to view the current directory.

copy

Syntax

copy fileurl-source fileurl-dest

View

User view

Default level

3: Manage level

Parameters

fileurl-source: Name of the source file.

fileurl-dest: Name of the target file or folder.

Description

Use copy to copy a file.

If you specify a target folder, the system copies the file to the specified folder and uses the name of the source file as the file name.

Examples

# Copy file test.cfg in the current folder and save it as testbackup.cfg.

<Sysname> copy testcfg.cfg testbackup.cfg

Copy flash:/test.cfg to flash:/testbackup.cfg?[Y/N]:y

....

%Copy file flash:/test.cfg to flash:/testbackup.cfg...Done.

# Copy file 1.cfg in the test folder on the Flash to the testbackup folder in the first partition of the CF card, and save it as 1backup.cfg.

<Sysname> copy flash:/test/1.cfg cfa0:/testbackup/1backup.cfg

Copy flash:/test/1.cfg to cfa0:/testbackup/1backup.cfg?[Y/N]:y

 

%Copy file flash:/test/1.cfg to cfa0:/testbackup/1backup.cfg...Done.

# Copy the configuration file of the IRF fabric's active MPU to the root directory of the standby MPU that resides in slot 1 of member switch 1.

<Sysname> copy vrcfg.cfg chassis1#slot1#flash:/

Copy flash:/vrcfg.cfg to chassis1#slot1#flash:/vrcfg.cfg?[Y/N]:y

 

%Copy file flash:/vrcfg.cfg to chassis1#slot1#flash:/vrcfg.cfg...Done.

crypto-digest

Syntax

crypto-digest sha256 file file-url

View

User view

Default level

2: System level

Parameters

sha256: Uses the SHA-256 algorithm.

file file-url: Specifies the name of a file.

Description

Use crypto-digest to compute the digest of a file.

The computed digest can be used to verify the integrity of the file. For example, you can use the command to compute the digest of the software image file of a device, and compare the digest with that on the website of the device vendor to verify whether the file is valid.

Examples

# Use the SHA-256 algorithm to compute the digest of the file 1.cfg.

<Sysname> crypto-digest sha256 file 1.cfg

  Computing digest...

  SHA256 digest(1.cfg)=

  7bcb92458222f91f9a09a807c4c4567efd4d5dc4e4abc06c2a741df7045433eb

delete

Syntax

delete [ /unreserved ] file-url

View

User view

Default level

3: Manage level

Parameters

/unreserved: Permanently deletes the specified file, and the deleted file can never be restored.

file-url: Name of the file to be deleted. Asterisks (*) are acceptable as wildcards. For example, to remove files with the extension of .txt in the current directory, use the delete *.txt command.

Description

Use delete file-url to temporarily delete a file. The deleted file is saved in the recycle bin. To restore it, use the undelete command.

The dir /all command displays the files deleted from the current directory and moved to the recycle bin. These files are enclosed in pairs of square brackets [ ]. To remove the files from the recycle bin, use the reset recycle-bin command.

Use the delete /unreserved file-url command with caution. This command permanently deletes a file, and the deleted file cannot be restored.

If you delete two files in different directories but with the same filename, only the second file is retained in the recycle bin.

Examples

# Remove file test.cfg from the root directory.

<Sysname> delete test.cfg

Delete flash:/test.cfg? [Y/N]:y

 

%Delete file flash:/test.cfg...Done.

# Remove file tt.cfg from the Flash root directory of the standby MPU that resides in slot 1 of member switch 1:

·     Method 1

<Sysname> delete chassis1#slot1#flash:/tt.cfg

Delete chassis1#slot2#flash:/tt.cfg?[Y/N]:y

%Delete file chassis1#slot1#flash:/tt.cfg...Done.

·     Method 2

<Sysname> cd chassis1#slot1#flash:/

<Sysname> delete tt.cfg

Delete chassis1#slot1#flash:/tt.cfg?[Y/N]:y

%Delete file chassis1#slot1#flash:/tt.cfg...Done.

dir

Syntax

dir [ /all ] [ file-url | /all-filesystems ]

View

User view

Default level

3: Manage level

Parameters

/all: Displays all files and folders in the current directory, including hidden files, hidden folders, files moved from the current directory to the recycle bin. Files in the recycle bin are enclosed in square brackets [ ].

file-url: Displays the specified file. Asterisks (*) are acceptable as wildcards. For example, to display files with the .txt extension in the current directory, use the dir *.txt command.

/all-filesystems: Displays files and folders in the root directory of all storage media on the device.

Description

Use dir to display files or folders.

If no parameter is specified, the command displays all visible files and folders in the current directory.

Examples

# Display information about all files and folders.

<Sysname> dir /all

Directory of flash:/

 

   0   -rw-   6985954  Apr 26 2005 21:06:29   mainup.bin

   1   -rwh      1842  Apr 27 2005 04:37:17   private-data.txt

   2   -rw-      1518  Apr 26 2005 12:05:38   config.cfg

   3   -rw-      2045  May 04 2005 15:50:01   backcfg.cfg

   4   -rwh       428  Apr 27 2005 16:41:21   hostkey

   5   -rwh       572  Apr 27 2005 16:41:31   serverkey

   6   -rw-   2737556  Oct 12 2005 01:31:44   [old.bin]

 

14605 KB total (5096 KB free)

# Display files and folders in the root directory of all storage media on the device.

<Sysname>dir /all-filesystems

Directory of flash:/

 

   0     -rw-  27496812  Aug 17 2007 13:08:18   mainup1.bin

   1     -rw-       151  Dec 24 2010 15:49:18   system.xml

   2     -rw-  39688708  Nov 29 2010 14:29:59   mainup2.bin

   3     -rw-  39741380  Dec 07 2010 11:14:06   mainup3.bin

 

129794 KB total (25356 KB free)

 

Directory of cfa0:/

 

   0     drw-         -  Jul 07 2007 07:07:18   logfile

   1     drw-         -  Jul 07 2007 07:07:18   diaglog

   2     -rw-       679  Jul 07 2007 07:54:18   aa.cfg

   3     -rw-  31873064  Nov 29 2010 09:57:18   mainup1.bin

   4     -rw-      5442  Dec 24 2010 15:49:20   config.cfg

   5     -rw-  39741380  Dec 07 2010 11:09:10   mainup2.bin

   6     -rw-  39788204  Dec 24 2010 13:41:40   mainup3.bin

   7     -rw-  37650052  Nov 26 2010 14:25:18   mainup4.bin

   8     drw-         -  Sep 06 2007 11:10:42   info

 

252900 KB total (38548 KB free)

 

File system type of cfa0: FAT16

Table 1 Command output

Field

Description

Directory of

Current working directory.

d

Directory. For a file, this field is not displayed.

r

The file or directory is readable.

w

The file or directory is writable.

h

The file or directory is hidden.

[ ]

The file is in the recycle bin.

 

execute

Syntax

execute filename

View

System view

Default level

2: System level

Parameters

filename: Name of a batch file with a .bat extension. You can use the rename command to change the suffix of the configuration file to .bat to use it as a batch file.

Description

Use execute to execute the specified batch file.

Batch files are command line files. Executing a batch file is to execute a set of command lines in the file.

You should not include invisible characters in a batch file. If an invisible character is found during the execution, the batch process will abort and the commands that have been executed cannot be cancelled.

Not every command in a batch file is sure to be executed. For example, if a certain command is not correctly configured, the command fails and the system goes to the next one.

The configuration generated after a batch file is executed is not automatically backed up to the standby MPU.

Each configuration command in a batch file must be a standard configuration command, meaning that the valid configuration information can be displayed with the display current-configuration command after this command is configured; otherwise, this command might not be executed.

Examples

# Execute the batch file test.bat in the root directory.

<Sysname> system-view

[Sysname] execute test.bat

fdisk

Syntax

fdisk device [ partition-number ]

View

User view

Default level

3: Manage level

Parameters

device: Name of the storage medium to be partitioned. It cannot be the name of a partition.

partition-number: Number of partitions, in the range of 1 to 4. Extended partitioning is not supported.

Description

Use fdisk to partition a storage medium.

Only the CF card and USB disk can be partitioned.

If partition-number is specified, the storage medium is divided into the specified number of partitions; otherwise, partitioning is performed in an interactive way.

The switch automatically formats each partition after partitioning is completed and all data on the storage medium is lost after this command is successfully executed.

Before removing a partitioned storage medium, unmount all the partitions. Otherwise, the file system on the storage medium might be damaged.

Before partitioning a USB disk, make sure the disk is not write protected. Otherwise, the partition operation fails, and you must remount or re-plug the disk to restore access to the USB disk.

The command does not support repartitioning of a partition.

H3C recommends that the first partition be equal to or larger than 128 MB.

Examples

# Divide the CF card on the switch into three partitions in simple mode.

<Sysname> fdisk cfa: 3

The capacity of cfa: : 244M bytes

cfa0: will be divided into the following partition(s):

DeviceName      Capacity   

cfa0:            81MB

cfa1:            81MB

cfa2:            81MB

All data on cfa: will be lost, proceed with fdisk? [Y/N]:y

% Now begin to fdisk cfa:, please wait... done.

Reset (default) paths for files as needed, such as log file, ftp root directory, etc.

# Divide the CF card on the switch into one partition in an interactive way.

<Sysname> fdisk cfa:

The capacity of cfa: : 244M bytes

Partition 1 (32MB~212MB, 244MB, CTRL+C to quit, Enter to use all space left):

// Press Enter or enter 244.

cfa: will be divided into the following partition(s):

DeviceName    Capacity

cfa0:          244MB

All data on cfa: will be lost, proceed with fdisk? [Y/N]:y

% Now begin to fdisk cfa:, please wait... done.

Reset (default) paths for files as needed, such as log file, ftp root directory, etc.

# Divide the CF card on the switch into three partitions in an interactive way.

<Sysname> fdisk cfa:

The capacity of cfa: : 244M bytes

Partition 1 (32MB~212MB, 244MB, CTRL+C to quit, Enter to use all space left):

// Enter 100 to specify the size of the first partition as 100 MB.

Partition 2 (32MB~112MB, 144MB, CTRL+C to quit, Enter to use all space left):

// Enter 31 to specify the size of the second partition as 31 MB.

The partition size should be greater than or equal to 32MB.

Partition 2 (32MB~112MB, 144MB, CTRL+C to quit, Enter to use all space left):

// Enter 1000 to specify the size of the second partition as 1000 MB.

The partition size should be less than or equal to 144MB.

Partition 2 (32MB~112MB, 144MB, CTRL+C to quit, Enter to use all space left):

// Enter 120 to specify the size of the second partition as 120 MB.

The remaining space is less than 32MB. Please reenter the size of partition 2.

Partition 2 (32MB~112MB, 144MB, CTRL+C to quit, Enter to use all space left):

// Enter 40 to respecify the size of the second partition as 40 MB.

Partition 3 (32MB~72MB, 104MB, CTRL+C to quit, Enter to use all space left):

// Press Enter to assign the remaining space to the third partition.

cfa: will be divided into the following partition(s):

DeviceName  Capacity       

cfa0:           100MB

cfa1:             40MB

cfa2:           104MB

All data on cfa: will be lost, proceed with fdisk? [Y/N]:y

Now begin to fdisk cfa:, please wait... done.

Reset (default) paths for files as needed, such as log file, ftp root directory, etc.

file prompt

Syntax

file prompt { alert | quiet }

View

System view

Default level

3: Manage level

Parameters

alert: Prompts for confirmation when a destructive file or folder operation is being performed.

quiet: Gives no confirmation prompt for file or folder operations.

Description

Use file prompt to set the file system operation mode.

By default, the file system operation mode is alert.

In quiet mode, the system does not prompt for confirmation when a user performs a file or folder operation. The alert mode provides an opportunity to cancel a disruptive operation.

Examples

# Set the file system operation prompt mode to alert.

<Sysname> system-view

[Sysname] file prompt alert

fixdisk

Syntax

fixdisk device

View

User view

Default level

3: Manage level

Parameters

device: Storage medium name.

Description

Use fixdisk to restore the space of a storage medium when it becomes unavailable.

Examples

# Restore the space of the Flash.

<Sysname> fixdisk flash:

format

Syntax

format device [ FAT16 | FAT32 ]

View

User view

Default level

3: Manage level

Parameters

device: Name of a partition (for example cf0 or cf1) of a storage medium that has been partitioned.

FAT16: Formats a storage medium using the FAT16 format. FAT16 does not support Tab matching but needs to be entered completely if used, and is not applicable to a Flash.

FAT32: Formats a storage medium using the FAT32 format. FAT32 does not support Tab matching but needs to be entered completely if used, and is not applicable to a Flash.

Description

Use format to format a storage medium.

To format a storage medium that has been partitioned, format each partition of the storage medium. For example, to format a CF card that has been partitioned, you must format each partition, instead of formatting the CF card.

When you format a partitioned storage medium that has a capacity smaller than 32.5 M, you can only use the FAT16 format to format the storage medium.

 

IMPORTANT:

·     Formatting a storage medium results in loss of all the files on the storage medium and these files cannot be restored. In particular, if there is a startup configuration file on a storage medium, formatting the storage medium results in loss of the startup configuration file.

·     H3C recommends using the default format for the storage medium after the medium is partitioned. Changing the format might result in lower read and write efficiency.

 

Examples

# Format the Flash.

<Sysname> format flash:

All data on flash: will be lost, proceed with format? [Y/N]:y

./

%Format flash: completed.

mkdir

Syntax

mkdir directory

View

User view

Default level

3: Manage level

Parameters

directory: Name of a folder.

Description

Use mkdir to create a folder under a specified directory on the storage medium.

The name of the folder to be created must be unique in the specified directory. Otherwise, you will fail to create the folder in the directory.

To use this command to create a folder, the specified directory must exist. For instance, to create folder flash:/test/mytest, the test folder must exist. Otherwise, you will fail to create folder mytest.

Examples

# Create a folder named test.

<Sysname> mkdir test

....

%Created dir flash:/test

# Create folder test/subtest.

<Sysname> mkdir test/subtest

....

%Created dir flash:/test/subtest

# Create folder test on the standby MPU that resides in slot 1 of member switch 2.

<Sysname> mkdir chassis2#slot1#flash:/test

....

%Created dir chassis2#slot1#flash:/test.

more

Syntax

more file-url [ | { begin | exclude | include } regular-expression ]

View

User view

Default level

3: Manage level

Parameters

file-url: File name.

|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.

begin: Displays the first line that matches the specified regular expression and all lines that follow.

exclude: Displays all lines that do not match the specified regular expression.

include: Displays all lines that match the specified regular expression.

regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.

Description

Use more to display the contents of the specified file.

This command is valid only for text files.

Examples

# Display the contents of file test.txt.

<Sysname> more test.txt

Welcome to H3C.

mount

Syntax

mount device

View

User view

Default level

3: Manage level

Parameters

device: Name of a partition of a storage medium that has been partitioned.

Description

Use mount to mount a hot swappable storage medium, such as a CF card or a USB device (excluding Flash). This command is effective only when the device is in unmounted state.

By default, a storage medium is automatically mounted and in mounted state after connected to the device, which means you can use it without mounting it.

Do not remove the storage medium or swap the card when mounting or unmounting the switch, or when you are processing files on the storage medium. Otherwise, the file system could be damaged.

When a storage medium is connected to a lower version system, the system might not be able to recognize the switch automatically, and you must use the mount command for the storage medium to function correctly.

Before removing a mounted storage medium from the system, you should first unmount it to avoid damaging the switch.

To mount a storage medium that has been partitioned, mount each partition of the storage medium. For example, to mount a CF card that has been partitioned, you must mount each partition, instead of issuing the mount cfa0: command.

Related commands: umount.

Examples

# On a partitioned device, mount the CF card.

<Sysname> mount cf2cfa0:

% Mount cf2cfa0: successfully.

# Mount the third partition of the CF card on the standby MPU that resides in slot 1 of member switch 2.

<Sysname> mount chassis2#slot1#cfa2:

% Mount chassis2#slot1#cfa2: successfully.

%Apr 23 01:50:00:628 2008 Sysname VFS/5/LOG:

cfa2: mounted into chassis 2 slot 1.

move

Syntax

move fileurl-source fileurl-dest

View

User view

Default level

3: Manage level

Parameters

fileurl-source: Name of the source file.

fileurl-dest: Name of the target file or folder.

Description

Use move to move a file.

If you specify a target folder, the system will move the source file to the specified folder, with the file name unchanged.

You cannot move files between storage media of different types or between different partitions of a CF card.

Examples

# Move file flash:/test/sample.txt to flash:/, and save it as 1.txt.

<Sysname> move test/sample.txt 1.txt

Move flash:/test/sample.txt to flash:/1.txt?[Y/N]:y

...

% Moved file flash:/test/sample.txt to flash:/1.txt

# Move file b.cfg to the subfolder test2.

<Sysname> move b.cfg test2

Move flash:/b.cfg to flash:/test2/b.cfg?[Y/N]:y

.

%Moved file flash:/b.cfg to flash:/test2/b.cfg.

pwd

Syntax

pwd

View

User view

Default level

3: Manage level

Parameters

None

Description

Use pwd to display the current path.

Examples

# Display the current path.

<Sysname> pwd

flash:

rename

Syntax

rename fileurl-source fileurl-dest

View

User view

Default level

3: Manage level

Parameters

fileurl-source: Name of the source file or folder.

fileurl-dest: Name of the target file or folder.

Description

Use rename to rename a file or folder.

The target file name must be unique in the current path.

Examples

# Rename file sample.txt as sample.bat.

<Sysname> rename sample.txt sample.bat

Rename flash:/sample.txt to flash:/sample.bat? [Y/N]:y

 

% Renamed file flash:/sample.txt to flash:/sample.bat

reset recycle-bin

Syntax

reset recycle-bin [ /force ]

View

User view

Default level

3: Manage level

Parameters

/force: Deletes all files in the recycle bin, including files that cannot be deleted by the command without the /force keyword.

Description

Use reset recycle-bin to delete a file in the recycle bin.

If a file is corrupted, you might not be able to delete the file by using the reset recycle-bin command. In this case, you can use the reset recycle-bin /force command, which can delete all the files in the recycle bin forcibly.

The delete file-url command only moves a file to the recycle bin. To permanently delete the file in the recycle bin, use the reset recycle-bin command in the original directory of the file.

The reset recycle-bin command deletes files in the current directory and in the recycle bin. If the original path of the file to be deleted is not the current directory, use the cd command to enter the original directory of the file, and then execute the reset recycle-bin command.

Examples

# Delete file test.txt in the recycle bin:

1.     Display all the files that are deleted from directory flash: to the recycle bin.

<Sysname> dir /all

Directory of flash:/

   0     -rwh      1696  Jul 30 2007 11:11:35   private-data.txt

   1     -rwh         4  Jul 12 2007 04:05:41   snmpboots

   2     -rwh       716  Aug 20 2007 03:27:23   hostkey

   3     -rwh       572  Aug 20 2007 03:27:29   serverkey

   4     -rw-       299  Jul 16 2007 03:37:34   devicea.pub

   5     -rwh       548  Aug 20 2007 03:29:30   dsakey

   6     -rw-    375489  Jul 18 2007 09:03:19   cmdtree.txt

   7     -rw-  41039544  Jul 18 2007 03:43:24   b05.bin

   8     drw-         -  Jul 19 2007 08:31:59   test

   9     -rw-      1577  Jul 30 2007 11:11:30   backup_new.cfg

   10    -rw-      2579  Jul 30 2007 10:26:29   backup202.cfg

   11    -rw-  19026768  Aug 07 2007 02:54:59   bt06.bin

   12    -rw-    131072  Aug 23 2007 07:24:14   [test.txt]

129794 KB total (70622 KB free)

//The above information shows that among files in directory flash:, one file test.txt is removed to the recycle bin.

2.     Execute the reset recycle-bin command in the current directory to delete files from the recycle bin.

<Sysname> reset recycle-bin

Clear flash:/~/test.txt ?[Y/N]:y

Clearing files from flash may take a long time. Please wait...

..

%Cleared file flash:/~/test.txt..

3.     In directory flash:, check whether all the files deleted from this directory to the recycle bin are deleted.

<Sysname> dir /all

Directory of flash:/

   0     -rwh      1696  Jul 30 2007 11:11:35   private-data.txt

   1     -rwh         4  Jul 12 2007 04:05:41   snmpboots

   2     -rwh       716  Aug 20 2007 03:27:23   hostkey

   3     -rwh       572  Aug 20 2007 03:27:29   serverkey

   4     -rw-       299  Jul 16 2007 03:37:34   devicea.pub

   5     -rwh       548  Aug 20 2007 03:29:30   dsakey

   6     -rw-    375489  Jul 18 2007 09:03:19   cmdtree.txt

   7     -rw-  41039544  Jul 18 2007 03:43:24   b05.bin

   8     drw-         -  Jul 19 2007 08:31:59   test

   9     -rw-      1577  Jul 30 2007 11:11:30   backup_new.cfg

   10    -rw-      2579  Jul 30 2007 10:26:29   backup202.cfg

   11    -rw-  19026768  Aug 07 2007 02:54:59   bt06.bin

129794 KB total (70751 KB free)

// The output shows that file test.txt is deleted permanently.

rmdir

Syntax

rmdir directory

View

User view

Default level

3: Manage level

Parameters

directory: Name of the folder.

Description

Use rmdir to remove a folder.

The folder must be empty. If not, delete all files and subfolders under it with the delete command.

After you execute the rmdir command successfully, the files deleted from the current folder to the recycle bin are automatically deleted.

Examples

# Remove folder mydir.

<Sysname> rmdir mydir

Rmdir flash:/mydir?[Y/N]:y

 

%Removed directory flash:/mydir.

umount

Syntax

umount device

View

User view

Default level

3: Manage level

Parameters

device: Name of a partition of a storage medium that has been partitioned.

Description

Use umount to unmount a hot swappable storage medium, such as a CF card or a USB device, excluding Flash. This command is effective only when the storage medium is in mounted state.

By default, a storage medium is automatically mounted and in mounted state. You must unmount it before removing it from the switch.

When mounting or unmounting a storage medium, or performing file operations on it, do not unplug or switchover the storage media or the card where the storage medium resides. Otherwise, the file system could be damaged.

When a storage medium is connected to a lower version system, the system might not be able to recognize the switch automatically, and you must use the mount command for the storage medium to function correctly.

Before removing a mounted storage medium from the system, first unmount it to avoid damaging the switch.

To unmount a storage medium that has been partitioned, unmount each partition of the storage medium. For example, to unmount a CF card that has been partitioned, you must unmount each partition, instead of issuing the umount cfa0: command.

Related commands: mount.

Examples

# Unmount the first partition on the CF card.

<Sysname> umount cfa0:

% Umount cfa0: successfully.

# Unmount the third partition of the CF card on the standby MPU that resides in slot 1 of member switch 2.

<Sysname> umount chassis2#slot1#cfa2:

% Umount chassis2#slot1#cfa2: successfully.

%Apr 23 01:49:20:929 2008 Sysname VFS/5/LOG:

cfa2: umounted from chassis 2 slot 1.

undelete

Syntax

undelete file-url

View

User view

Default level

3: Manage level

Parameters

file-url: Name of the file to be restored.

Description

Use undelete to restore a file from the recycle bin.

If another file with the same name exists in the same path, the command overwrites the file and the system prompts you whether to continue.

Examples

# Restore file a.cfg in directory flash: from the recycle bin.

<Sysname> undelete a.cfg

Undelete flash:/a.cfg?[Y/N]:y

.....

%Undeleted file flash:/a.cfg.  

# Restore file b.cfg in directory flash:/test from the recycle bin.

<Sysname> undelete flash:/test/b.cfg

Undelete flash:/test/b.cfg?[Y/N]:y

.......

%Undeleted file flash:/test/b.cfg.

Or, you can use the following steps to restore file flash:/test/b.cfg.

<Sysname> cd test

<Sysname> undelete b.cfg

Undelete flash:/test/b.cfg?[Y/N]:y

.....

%Undeleted file flash:/test/b.cfg.

usb disable

Syntax

usb disable

undo usb disable

View

System view

Default level

3: Manage level

Parameters

None

Description

Use usb disable to disable all UBS ports.

Use undo usb disable to enable all UBS ports.

By default, all USB ports are enabled.

Examples

# Disable all USB ports.

<Sysname> system-view

[Sysname] usb disable

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become A Partner
  • Partner Policy & Program
  • Global Learning
  • Partner Sales Resources
  • Partner Business Management
  • Service Business
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网