- Table of Contents
-
- 01-Fundamentals Command Reference
- 00-Preface
- 01-CLI commands
- 02-RBAC commands
- 03-Login management commands
- 04-FTP and TFTP commands
- 05-File system management commands
- 06-Configuration file management commands
- 07-Software upgrade commands
- 08-ISSU commands
- 09-Emergency shell commands
- 10-Device management commands
- 11-MDC commands
- 12-TCL commands
- 13-License management commands
- Related Documents
-
Title | Size | Download |
---|---|---|
09-Emergency shell commands | 160.74 KB |
Contents
copy
Use copy to copy a file.
Syntax
copy fileurl-source fileurl-dest
Views
User view
Parameters
fileurl-source: Specifies the name of the source file.
fileurl-dest: Specifies the name for the target file or directory. If you specify a target directory, the system copies the file to the specified directory and uses the name of the source file as the file name.
Examples
# Copy the test.cfg file and save it in the same directory as testbackup.cfg.
<boot> copy flash:/testcfg.cfg flash:/testbackup.cfg
Copy flash:/test.cfg to flash:/testbackup.cfg?[Y/N]:y
Start to copy flash:/test.cfg to flash:/testbackup.cfg...Done.
# Copy the test.cfg file and save it in the same directory by using the name of existing file testbackup.cfg. (The existing file is overwritten.)
<boot> copy flash:/testcfg.cfg flash:/testbackup.cfg
Copy flash:/test.cfg to flash:/testbackup.cfg?[Y/N]:y
flash:/testbackup.cfg already exists. Overwrite it?[Y/N]:y
Start to copy flash:/test.cfg to flash:/testbackup.cfg...Done.
# Copy the 1.cfg file in the test directory on the Flash to the testbackup directory in the first partition of the CF card.
<boot> copy flash:/test/1.cfg cfa0:/testbackup
Copy flash:/test/1.cfg to cfa0:/testbackup/1.cfg?[Y/N]:y
Start to copy flash:/test/1.cfg to cfa0:/testbackup/1.cfg...Done.
delete
Use delete to permanently delete a file.
Syntax
delete file-url
Views
User view
Parameters
file-url: Specifies the name of the file to be deleted.
Examples
# Delete the tt.cfg file from the current directory.
<boot> delete flash:/tt.cfg
Delete flash:/tt.cfg? [Y/N]:y
Start to delete flash:/tt.cfg...Done.
dir
Use dir to display files or directories.
Syntax
dir [ /all ] [ file-url ]
Views
User view
Parameters
/all: Displays all files and subdirectories under the current directory, including hidden files, hidden directories, files moved from the current directory to the recycle bin. Files in the recycle bin are enclosed in square brackets ([ ]).
file-url: Specifies a specific file.
Examples
# Display information about all files and directories in the system.
<boot> dir /all
Directory of flash:
0 drw- - Jan 02 2000 02:07:29 logfile
1 drw- - Jan 02 2000 01:35:34 diagfile
2 -rw- 290 Jan 04 2000 09:15:41 [index.txt]
3 -rw- 3929 Jan 04 2000 09:15:41 startup.cfg
4 -rw- 54892 Jan 04 2000 09:15:42 startup.mdb
5 drw- - Jan 02 2000 01:00:26 seclog
6 -rwh 17 Jan 06 2000 00:10:32 .pathfile
131072 KB total (120392 KB free)
# Display all unhidden files and directories in the system.
<boot> dir
Directory of flash:
0 drw- - Jan 02 2000 02:07:29 logfile
1 drw- - Jan 02 2000 01:35:34 diagfile
2 -rw- 3929 Jan 04 2000 09:15:41 startup.cfg
3 -rw- 54892 Jan 04 2000 09:15:42 startup.mdb
4 drw- - Jan 02 2000 01:00:26 seclog
131072 KB total (120392 KB free)
# Display information about the startup.cfg file.
<boot> dir flash:/startup.cfg
Directory of flash:
0 -rw- 3929 Jan 04 2000 09:15:41 startup.cfg
131072 KB total (120392 KB free)
Table 1 Command output
Field |
Description |
Directory of |
Current directory. |
3 -rw- 54892 Jan 04 2000 09:15:42 startup.mdb |
Information about a file or directory: · 3—Index number, automatically assigned by the system. · -rw-—Attributes of the file or directory. The first character is the directory indicator (d for directory and - for file). The second character indicates whether the file or directory is readable (r for readable). The third character indicates whether the file or directory is writable (w for writable). The last character indicates whether the file or directory is hidden (h for hidden and - for visible). · 54892—Size of the file, in bytes. For a directory, the value of this field is a hyphen (-). · Jan 04 2000 09:15:42—Time when the file was last modified. · startup.mdb—Name of the file or directory. A file or directory with its name in square brackets ([ ]) is in the recycle bin. |
131072 KB total (120392 KB free) |
Total size of the storage medium and size of the free space, in kilobytes. |
display copyright
Use display copyright to display the copyright information.
Syntax
display copyright
Views
Any view
Examples
# Display the copyright information.
<boot> display copyright
Copyright (c) 2003-2011 Hangzhou H3C Technologies Co., Ltd. All rights reserved.
This document provides copyright information regarding any third-party software
that is included, either in whole or in part, in this product.
This product contains third-party software components and they will be used
and distributed under their respective licenses. This product contains some
components under the GNU General Public License ("GPL") version 2.0, the GNU
Lesser General Public License("LGPL") version 2.1 or other open source licenses.
H3C agrees to provide the open source code which is under GPL for three (3)
years from the first release date of the software. If you want to obtain a copy
of GPL licensed source code associated with this product, please send a request
to [email protected] or write to Hangzhou H3C technology Co., Ltd. 310 of Liuhe Rd,
Zhijiang Science Park, Hangzhou 310005, P.R. China.The product name and version
number of the software, your name, phone number and address should be included
in the request. H3C reserves the right to charge an amount of cost for
distribution of source code , consistent with the GPL license terms. You can
also obtain a copy of the GPL and LGPL at http://www.gnu.org/licenses/.
--------------------------------------------------------------------------------
The following software may be included in this product:
FreeBSD domain stack framework
---- More ----
display install package
Use display install package to display information about a software package.
Syntax
display install package package
Views
Any view
Parameters
package: Specifies a software package name with the extension .bin, a case-insensitive string of 1 to 63 characters. This argument must indicate the name of the storage medium, such as flash:/a.bin. The software package must be saved in the root directory of the storage medium.
Examples
# Display information about the system.bin software package.
<boot> display install package flash:/system.bin
flash:/system.bin
[Package]
Vendor: ****
Product: xxxx
Service name: system
Platform version: 7.1.028
Product version: Alpha 7122
Supported board: mr, lc, sfc
[Component]
Component: Comware system
Description: system package
Table 2 Command output
Field |
Description |
Product |
Product name. |
Service name |
Type of the service package: · boot—Boot image. · system—System image. · patch—Patch package. The value of this field is any other value for feature packages. |
Platform version |
Platform version number. |
Product version |
Product version number. You determine whether the version of a system image matches that of a boot image by checking the value of this field. |
Supported board |
Types of boards that the software package supports: · mr—MPU. · lc—Interface board. · sfc—Switching fabric board. |
[Component] |
Information about the components of the software package. |
display interface m-eth0
Use display interface m-eth0 to display information about the management Ethernet port.
Syntax
display interface m-eth0
Views
Any view
Examples
# Display information about the management Ethernet port.
<boot> display interface m-eth0
m-eth0 current state: UP
Line protocol current state: UP
The Maximum Transmit Unit is 1500
Inet6 Address is FE80::202:3FF:FE04:506/10 Scope:Link
IP Packet Frame Type:PKTFMT_ETHNT_2, Hardware Address:0002-0304-0506
IPV6 Packet Frame Type:PKTFMT_ETHNT_2, Hardware Address:0002-0304-0506
Input:11 packets, 0 errors, 0 dropped, 0 overruns, 0 frame
Output:6 packets, 0 errors, 0 dropped, 0 overruns, 0 carrier
0 collisions, 1000 txqueuelen
Input bytes:1142
Output bytes:468
Table 3 Command output
Field |
Description |
m-eth0 current state |
Physical layer status of the management Ethernet interface: · Administratively DOWN—The interface has been shut down by using the shutdown command. · DOWN—The interface has been enabled by using the undo shutdown command but its physical status is down because, for example, no cable is connected or a line failure occurred. · UP—The interface has been enabled by using the undo shutdown command but its physical status is up. |
Line protocol current state |
Link layer status of the interface. The possible values are the same as those of the physical layer status. |
The Maximum Transmit Unit |
MTU of the interface. |
Inet4 Address |
IPv4 address of the interface. This field is displayed only when the device is configured with an IPv4 address. |
Inet6 Address |
IPv6 address of the interface. This field is displayed only when the device is configured with an IPv6 address. |
Inet6 Address is FE80::202:3FF:FE04:506/10 Scope:Link |
IPv6 link-local address of the interface. |
IP Packet Frame Type:PKTFMT_ETHNT_2, Hardware Address: |
Link layer encapsulation type and hardware address for IPv4 packets. |
IPV6 Packet Frame Type:PKTFMT_ETHNT_2, Hardware Address: |
Link layer encapsulation type and hardware address for IPv6 packets. |
Input:11 packets, 0 errors, 0 dropped, 0 overruns, 0 frame |
Statistics for received packets: · Total number. · Number of erroneous packets. · Number of dropped packets. · Number of packets encountering queue overflow errors. · Number of packets encountering frame queue errors. |
Output:6 packets, 0 errors, 0 dropped, 0 overruns, 0 carrier 0 collisions, 1000 txqueuelen |
Statistics for sent packets: · Total number. · Number of erroneous packets. · Number of dropped packets. · Number of packets encountering queue overflow errors. · Number of packets encountering carrier failures. · Number of packets with collision. · Number of packets permitted by the queue. |
Input bytes |
Total number of received bytes. |
Output bytes |
Total number of sent bytes. |
display ip routing-table
Use display ip routing-table to display IPv4 routing information.
Syntax
display ip routing-table
Views
Any view
Examples
# Display IPv4 routing information.
<boot> display ip routing-table
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.116.0 * 255.255.255.0 U 0 0 0 m-eth0
default 192.168.116.1 0.0.0.0 UG 0 0 0 m-eth0
The first route indicates that the device has a directly connected segment 192.168.116.0/24 and will send packets destined for this segment out of the management port M-Eth 0 to the destination segment, without using a gateway. The second route indicates that the device will send packets destined for segments other than the directly connected segment out of the management port M-Eth 0 to gateway 192.168.116.1.
Table 4 Command output
Field |
Description |
Kernel IP routing table |
IPv4 routing information. |
Destination |
Destination address. For the default route, the value of this field is default. |
Gateway |
Gateway address. If no gateway is needed, the value of this field is *. |
Genmask |
Subnet mask. For the default route, the value of this field is 0.0.0.0. |
Flags |
Flags: · G—The destination address is a gateway. · H—The route is a host route. · D—The route is the default route learned through the ND protocol. · A—The route was learnt by the route advertisement. · C—Cached. · U—Reserved. |
Metric |
Cost of the route. |
Ref |
Number of times the route has been referenced. |
Use |
Number of times the route has been used. |
Iface |
Outbound interface. |
display ipv6 routing-table
Use display ipv6 routing-table to display IPv6 routing information.
Syntax
display ipv6 routing-table
Views
Any view
Examples
# Display IPv6 routing information.
<boot> display ipv6 routing-table
Kernel IPv6 routing table
Destination Next Hop Flags Metric Ref Use Iface
::1/128 :: U 0 0 1 lo
FE80::201:2FF:FE03:406/128 :: U 0 0 1 lo
FE80::/64 :: U 256 0 0 m-eth0
FF02::1:2/128 FF02::1:2 UC 0 2888 0 m-eth0
FF00::/8 :: U 256 0 0 m-eth0
Table 5 Command output
Field |
Description |
Kernel IPv6 routing table |
IPv6 routing information. |
Flags |
Flags: · G—The destination address is a gateway. · H—The route is a host route. · D—The route is the default route learned through ND. · A—The route was learned by the RA. · C—Cached. · U—Reserved. |
Metric |
Cost of the route. |
Ref |
Number of times the route has been referenced. |
Use |
Number of times the route has been used. |
Iface |
Outbound interface. If it is a loopback interface, the value of this field is lo. |
display version
Use display version to display the version information of the boot image.
Syntax
display version
Views
Any view
Examples
# Display the version information of the boot image.
<Sysname> display version
H3C Comware Software
Copyright (c) 2004-2012 Hangzhou H3C Tech. Co., Ltd. All rights reserved.
H3C S12508 uptime is 0 weeks, 0 days, 0 hours, 13 minutes
Boot image: cfa0:/s12500-cmw710-boot-a7122.bin
Boot image version: 7.1.028
CPU: e500v2 with 1 Processor
2560M bytes SDRAM
128M bytes Nor Flash Memory
247M bytes CFA Memory
format
Use format to format a storage medium.
Syntax
format medium-name
Views
User view
Parameters
medium-name: Specifies the name of a storage medium.
Usage guidelines
Use the format command with caution. This command permanently deletes all files and directories from a storage medium, including the startup boot image and startup configuration files. The deleted files and directories cannot be restored. Without a boot image, the device cannot reboot.
Examples
# Format the CF card.
<boot> format cfa0:
ftp
Use ftp to access a remote FTP server.
Syntax
ftp { server-ipv4-address | ipv6 server-ipv6-address } user username password password { get remote-file local-file | put local-file remote-file }
Views
User view
Parameters
server-ipv4-address: Specifies the IPv4 address of the FTP server in dotted decimal notation.
server-ipv6-address: Specifies the IPv6 address of the FTP server.
user username: Specifies the login username, a case-sensitive string of 1 to 15 characters.
password password: Specifies the login password, a case-sensitive string of 1 to 15 characters.
get remote-file local-file: Downloads a file from the FTP server. The remote-file argument indicates the file to be downloaded. The local-file argument indicates the name for the downloaded file.
put local-file remote-file: Uploads a file to the FTP server. The local-file argument indicates the file to be uploaded. The remote-file argument indicates the name for the uploaded file.
Usage guidelines
If the traffic is heavy on the network and the file transfer speed is low, you can press Ctrl+C to abort the transfer and try again later.
Examples
# Log in to FTP server 192.168.1.100 by using the username test and password 123, download the 111.txt file, and save it to a local file named 222.txt.
<boot> ftp 192.168.1.100 user test password 123 get 111.txt flash:/222.txt
install load
Use install load to load a system image and start the Comware system.
Syntax
install load system-package
Views
User view
Parameters
system-package: Specifies the name of the system image, a case-insensitive string of 1 to 63 characters. This file must be saved in the root directory of the current MPU's storage medium, with the extension .bin. The file name must indicate the storage medium and cannot contain slot information, for example, flash:/startup-system.bin. (In standalone mode.)
system-package: Specifies the name of the system image, a case-insensitive string of 1 to 63 characters. This file must be saved in the root directory of the current MPU's storage medium, with the extension .bin. The file name must indicate the storage medium and cannot contain chassis or slot information, for example, flash:/startup-system.bin. (In IRF mode.)
Usage guidelines
When you execute this command, the system modifies the main startup software image set to include only the boot image and system image so the device can reboot normally.
After the Comware system is started, you can load feature images and patch images as described in the chapters about software upgrade and ISSU in Fundamentals Configuration Guide.
Examples
# Load a system image and start the Comware system.
<boot> install load cfa0:/system.bin
Check package cfa0:/system.bin ...
Extracting package ...
Loading...
System application is starting...
Set bootargs.
CPIO Length: 0x96e7d8.
cpio=0x96e7d8@0x13000000
CPIO Length: 0x96e7d8.
Starting application at 0x02000000 ..HA_Register OK, ulModuleID = 252772352, ulS
ubID = 6.HA_Register OK, ulModuleID = 254803968, ulSubID = 0.HA_Register OK, ulM
oduleID = 252706816, ulSubID = 0.HA_Register OK, ulModuleID = 255983616, ulSubID
= 2.HA_Register OK, ulModuleID = 256442368, ulSubID = 0.HA daemon start as 1 (b
uild Jul 29 2011 11:50:56).
System service initialization completed, cost 28 seconds.
Autorun service initialization completed, cost 5 seconds.
Ondemand service initialization completed, cost 30 seconds.
User interface con1 is available.
Press ENTER to get started.
interface m-eth0
Use interface m-eth0 to enter management Ethernet port view.
Syntax
interface m-eth0
Views
System view
Usage guidelines
In management Ethernet port view, you can assign an IP address to the port and specify a gateway.
Examples
# Enter management Ethernet port view.
<boot> system-view
[boot] interface m-eth0
[boot-m-eth0]
Related commands
quit
ip address
Use ip address to assign an IPv4 address to the management Ethernet port.
Use undo ip address to restore the default.
Syntax
ip address ip-address { mask-length | mask }
undo ip address
Default
The management Ethernet port has no IPv4 address.
Views
Management Ethernet port view
Parameters
ip-address: Specifies an IPv4 address in dotted decimal notation.
mask-length: Specifies the length of the subnet mask, in the range of 0 to 32.
mask: Specifies the subnet mask in dotted decimal notation.
Usage guidelines
The management Ethernet port can have only one IPv4 address. If you execute this command multiple times, the most recent configuration takes effect.
When the management Ethernet port is manually shut down, assigning it an IPv4 address or removing its IPv4 address activates it at the same time.
The IP address assigned to the management Ethernet port must be different from the IP addresses of the other devices on the network.
Examples
# Assign IPv4 address 192.168.1.1/24 to the management Ethernet port.
<boot> system-view
[boot] interface m-eth0
[boot-m-eth0] ip address 192.168.1.1 24
ip gateway
Use ip gateway to specify an IPv4 gateway for the management Ethernet port.
Use undo ip gateway to restore the default.
Syntax
ip gateway ip-address
undo ip gateway
Default
The management Ethernet port has no IPv4 gateway configured.
Views
Management Ethernet port view
Parameters
ip-address: Specifies an IPv4 gateway address in dotted decimal notation.
Usage guidelines
When the device needs to communicate with a device on a remote IPv4 network, you must specify an IPv4 gateway for the management Ethernet port.
The IPv4 gateway address must be on the same segment as the IPv4 address of the management Ethernet port.
Changing or removing the IPv4 address of the management Ethernet port removes the port's IPv4 gateway configuration.
If you execute this command multiple times, the most recent configuration takes effect.
Examples
# Configure the management Ethernet port to use IPv4 gateway 192.168.1.5.
<boot> system-view
[boot] interface m-eth0
[boot-m-eth0] ip gateway 192.168.1.5
ipv6 address
Use ipv6 address to assign an IPv6 address to the management Ethernet port.
Use undo ipv6 address to restore the default.
Syntax
ipv6 address ipv6-address prefix-length
undo ipv6 address
Default
The management Ethernet port has no IPv6 address.
Views
Management Ethernet port view
Parameters
ipv6-address: Specifies an IPv6 address.
prefix-length: Specifies a prefix length, in the range of 1 to 128.
Usage guidelines
The management Ethernet port can have only one IPv6 address. If you execute this command multiple times, the most recent configuration takes effect.
When the management Ethernet port is manually shut down, assigning it an IPv6 address or removing its IPv6 address activates it at the same time.
Examples
# Assign IPv6 address 2001::1/64 to the management Ethernet port.
<boot> system-view
[boot] interface m-eth0
[boot-m-eth0] ipv6 address 2001::1 64
ipv6 gateway
Use ipv6 gateway to specify an IPv6 gateway for the management Ethernet port.
Use undo ipv6 gateway to restore the default.
Syntax
ipv6 gateway link-local
undo ipv6 gateway
Default
The management Ethernet port has no IPv6 gateway configured.
Views
Management Ethernet port view
Parameters
link-local: Specifies the Link-local address of an IPv6 gateway.
Usage guidelines
When the device needs to communicate with a device on a remote IPv6 network, you must specify an IPv6 gateway for the management Ethernet port.
The IPv6 gateway address must be on the same segment as the IPv6 address of the management Ethernet port.
Changing or removing the IPv6 address of the management Ethernet port removes the port's IPv6 gateway configuration.
If you execute this command multiple times, the most recent configuration takes effect.
Examples
# Configure the management Ethernet port to use IPv6 gateway 2002::1.
<boot> system-view
[boot] interface m-eth0
[boot-m-eth0] ipv6 gateway 2002::1
mkdir
Use mkdir to create a directory on a storage medium.
Syntax
mkdir directory
Views
User view
Parameters
directory: Specifies a directory name.
Usage guidelines
The path must already exist. For example, to create the flash:/test/mytest directory, the directory test must already exist on the Flash.
The name for the new directory must be unique under the upper-level directory.
Examples
# Create a directory named test under the current directory.
<boot> mkdir flash:/test
Directory test created.
# Create a directory named subtest under the test directory.
<boot> mkdir flash:/test/subtest
Directory flash:/test/subtest created.
Related commands
· dir
· rmdir
more
Use more to display the contents of a file.
Syntax
more file-url
Views
User view
Parameters
file-url: Specifies the Name of the file.
Examples
# Display the contents of file test.txt.
<boot> more flash:/test.txt
Have a nice day.
move
Use move to move a file.
Syntax
move fileurl-source fileurl-dest
Views
User view
Parameters
fileurl-source: Specifies the name of the file to be moved, a case-insensitive string of 1 to 63 characters.
fileurl-dest: Specifies the name of the destination file or directory, a case-insensitive string of 1 to 63 characters.
Examples
# Move the config.cfg file to the flash:/002 directory.
<boot> move flash:/startup.cfg flash:/002
Move flash:/startup.cfg to flash:/002/startup.cfg?[Y/N]:Y
<boot> dir flash:/002
Directory of flash:/002:
2 -rw- 1518 Apr 26 2007 12:05:38 config.cfg
14605 KB total (5096 KB free)
ping
Use ping to check the connectivity to an IPv4 address.
Syntax
ping [ -c count | -s size ] * ip-address
Views
Any view
Parameters
-c count: Specifies the number of ICMP echo requests to send, in the range of 1 to 2147483647. The default is 5.
-s size: Specifies the length (in bytes) of each ICMP echo request, in the range of 20 to 8100. The default is 56.
ip-address: Specifies the IPv4 address of the destination in dotted decimal notation.
Usage guidelines
When you execute the ping command, the device sends ICMP echo requests to the destination. You can press Ctrl+C to abort the ping operation.
Examples
# Check the connectivity to destination 192.168.209.100.
<boot> ping 192.168.209.100
PING 192.168.209.100(192.168.209.100):56 data bytes
64 bytes from 192.168.209.100:seq=0 ttl=64 time=0.160 ms
64 bytes from 192.168.209.100:seq=1 ttl=64 time=0.062 ms
64 bytes from 192.168.209.100:seq=2 ttl=64 time=0.061 ms
64 bytes from 192.168.209.100:seq=3 ttl=64 time=0.065 ms
64 bytes from 192.168.209.100:seq=4 ttl=64 time=0.063 ms
--- 192.168.209.100 ping statistics ---
5 packets transmitted,5 packets received,0% packet loss
round-trip min/avg/max = 0.061/0.082/0.160 ms
Table 6 Command output
Field |
description |
PING 192.168.209.100(192.168.209.100) |
Checking the connectivity to the device at 192.168.209.100. |
56 data bytes |
Number of data bytes in each ICMP echo request. |
64 bytes from 192.168.209.100:seq=0 ttl=64 time=0.160 ms |
Received an ICMP reply from the device at 192.168.209.100. If no reply is received during the timeout period, this information is not displayed. Fields of the reply: · bytes—Number of data bytes in the ICMP reply. · seq—Sequence number of the reply. You can examine the sequence numbers of replies to determine whether packets are missing, disordered, or duplicated. · ttl—TTL value in the ICMP reply. · time—Response time. |
--- 192.168.209.100 ping statistics --- |
Statistics for packets sent and received during the ping operation. |
5 packets transmitted |
Number of ICMP echo requests sent. |
5 packets received |
Number of ICMP echo replies received. |
0.0% packet loss |
Percentage of echo requests that failed to be echoed back. |
round-trip min/avg/max = 0.061/0.082/0.160 ms |
Minimum/average/maximum response time, in milliseconds. |
ping ipv6
Use ping ipv6 to check the connectivity to an IPv6 address.
Syntax
ping ipv6 [ -c count | -s size ] * ipv6-address
Views
Any view
Parameters
-c count: Specifies the number of ICMPv6 echo requests to send, in the range of 1 to 2147483647. The default is 5.
-s size: Specifies the length (in bytes) of each ICMPv6 echo request, in the range of 20 to 8100. The default is 56.
Ipv6-address: Specifies the IPv6 address of the destination.
Usage guidelines
When you execute the ping ipv6 command, the device sends ICMPv6 echo requests to the destination. You can press Ctrl+C to abort the ping operation.
Examples
# Check the connectivity to destination 111:111::111:111.
<boot> ping ipv6 111:111::111:111
PING 111:111::111:111(111:111::111:111):56 data bytes
64 bytes from 111:111::111:111:seq=0 ttl=64 time=0.160 ms
64 bytes from 111:111::111:111:seq=1 ttl=64 time=0.062 ms
64 bytes from 111:111::111:111:seq=2 ttl=64 time=0.061 ms
64 bytes from 111:111::111:111:seq=3 ttl=64 time=0.065 ms
64 bytes from 1111:111::111:111:seq=4 ttl=64 time=0.063 ms
--- 111:111::111:111 ping statistics ---
5 packets transmitted,5 packets received,0% packet loss
round-trip min/avg/max = 0.061/0.082/0.160 ms
The output shows that the destination is reachable. All ICMP echo requests were echoed back and the minimum, average, and maximum response time values are 0.061 ms, 0.082 ms, and 0.160 ms, respectively.
pwd
Use pwd to display the current path.
Syntax
pwd
Views
User view
Examples
# Display the current path.
<boot> pwd
flash:
Related commands
· system-view
· interface m-eth0
quit
Use quit to return to the upper level view.
Syntax
quit
Default
After entering emergency shell mode, the device is in user view.
Views
System view, management Ethernet port view
Examples
# Return from management Ethernet port view to user view.
[boot-m-eth0] quit
[boot] quit
<boot>
reboot
Use the reboot command to reboot the current MPU.
Syntax
reboot
Views
User view
Examples
# Reboot the current MPU.
<boot> reboot
This Command will reboot the device. Continue? [Y/N]:Y
reset ssh public-key
Use reset ssh public-key to delete all server public keys saved on the device.
Syntax
reset ssh public-key
Views
User view
Usage guidelines
When you use the ssh2 command to connect to an SSH server for the first time, the device saves a copy of the server's public key locally so it can use the public key to authenticate the server when you connect to the server again. If the server changes its public key, the public keys will not match anymore and you cannot connect to the server. To solve this problem, use this command to delete all server public keys saved on the device.
Examples
# Delete all server public keys saved on the device.
<boot> reset ssh public-key
rmdir
Use rmdir to delete an existing directory.
Syntax
rmdir directory
Views
User view
Parameters
directory: Specifies the name of the directory to be deleted.
Usage guidelines
To delete a directory, first delete the files and subdirectories under the directory. To delete files, use the delete command.
Examples
# Delete the mydir directory.
<boot> rmdir flash:/mydir
Remove directory flash:/mydir?[Y/N]:y
Directory flash:/mydir removed.
Related commands
· delete
· dir
· mkdir
shutdown
Use shutdown to shut down the management Ethernet port.
Use undo shutdown to activate the management Ethernet port.
Syntax
shutdown
undo shutdown
Default
The management Ethernet port is active.
Views
Management Ethernet port view
Usage guidelines
When the management Ethernet port is not operating normally, you can re-activate it by using the shutdown command to shut it down and then using the undo shutdown command to bring it up.
Examples
# Shut down the management Ethernet port.
<boot> system-view
[boot] interface m-eth0
[boot-m-eth0] shutdown
# Activate the management Ethernet port.
[boot-m-eth0] undo shutdown
ssh2
Use ssh2 to log in to an SSH server.
Syntax
ssh2 { server-ipv4-address | ipv6 server-ipv6-address }
Views
User view
Parameters
server-ipv4-address: Specifies the IPv4 address of the SSH server in dotted decimal notation.
ipv6 server-ipv6-address: Specifies the IPv6 address of the SSH server.
Usage guidelines
If the SSH server does not respond, you can press Ctrl+C to abort the login attempt and try again later.
Examples
# Use SSH to connect to SSH server 192.168.100.128.
<boot> ssh2 192.168.100.128
[email protected]'s password:
Last login: Thu Mar 24 14:05:23 2011 from 192.168.100.199
system-view
Use system-view to switch from user view to system view.
Syntax
system-view
Default
After entering emergency shell mode, the device is in user view.
Views
User view
Examples
# Switch from user view to system view.
<boot> system-view
[boot]
Related commands
quit
telnet
Use telnet to log in to a Telnet server.
Syntax
telnet { server-ipv4-address | ipv6 server-ipv6-address }
Views
User view
Parameters
server-ipv4-address: Specifies the IPv4 address of the Telnet server in dotted decimal notation.
server-ipv6-address: Specifies the IPv6 address of the Telnet server.
Usage guidelines
If the Telnet server does not respond, you can press Ctrl+K to abort the login attempt and try again later.
Examples
# Telnet to Telnet server 192.168.100.1.
<boot> telnet 192.168.100.1
tftp
Use tftp to log in to a TFTP server.
Syntax
tftp server-ipv4-address { get remote-file local-file | put local-file remote-file }
tftp ipv6 server-ipv6-address { get remote-file local-file | put local-file remote-file }
Views
User view
Parameters
server-ipv4-address: Specifies the IPv4 address of the TFTP server in dotted decimal notation.
server-ipv6-address: Specifies the IPv6 address of the TFTP server.
get remote-file local-file: Downloads a file from the TFTP server. The remote-file argument indicates the file to be downloaded. The local-file argument indicates the name for the downloaded file.
put local-file remote-file: Uploads a file to the TFTP server. The local-file argument indicates the file to be uploaded. The remote-file argument indicates the name for the uploaded file.
Usage guidelines
If the traffic is heavy on the network and the file transfer speed is low, you can press Ctrl+C to abort the transfer and try again later.
Examples
# Log in to TFTP server 192.168.1.100, download the 111.txt file, and save it to a local file named 222.txt.
<boot> tftp 192.168.1.100 get 111.txt flash:/222.txt
# Upload the startup configuration file named startup.cfg to TFTP server 192.168.1.100.
<boot> tftp 192.168.1.100 put flash:/startup.cfg startup.cfg