HP MSR2000/3000/4000 Router Series Fundamentals Command Reference
132
interface as the source IP address for outgoing packets. If you do not specify this option, the device uses
the outgoing interface as the source interface.
Usage guidelines
In non-FIPS mode, you can use the copy command to perform the following operations:
• Copy a local file and save it locally.
• Copy a local file and save it to an FTP or TFTP server.
• Copy a file on an FTP or TFTP server and save it locally.
In FIPS mode, you can only copy a local file and save it locally.
To specify a file or directory, use the following guidelines:
Location Name format Remarks
On the device
Use the file name guidelines in
Fundamentals Configuration Guide.
N/A
On an FTP server
Enter the URL in the format ftp://FTP
username[:password]@server
address[:port number]/file path[/file
name].
The username and password must be the same as
those configured on the FTP server. If the server
authenticates users only by the username, you are
not required to enter the password.
For example, to use the username 1 and password
1 and specify the startup.cfg file in the authorized
working directory on FTP server 1.1.1.1, enter the
URL ftp://1:1@1.1.1.1/startup.cfg.
To specify an IPv6 address, enclose the IPv6
address in square brackets ([ ]), for example,
ftp://test:test@[2001::1]:21/test.cfg.
On a TFTP server
Enter the URL in the format
tftp://server address[:port
number]/file path[/file name].
For example, to specify the startup.cfg file in the
working directory on TFTP server 1.1.1.1, enter
the URL tftp://1.1.1.1/startup.cfg.
To enter an IPv6 address, enclose the IPv6 address
in square brackets ([ ]), for example,
ftp://test:test@[2001::1]:21/test.cfg.
Examples
# Copy the test.cfg file in the current folder and save it to the current folder as testbackup.cfg.
<Sysname> copy test.cfg testbackup.cfg
Copy cfa0:/test.cfg to cfa0:/testbackup.cfg?[Y/N]:y
Copying file cfa0:/test.cfg to cfa0:/testbackup.cfg...Done.
# Copy the 1.cfg file from the test folder of the CF card and save it to the testbackup folder in the root
directory with the file name 1backup.cfg.
<Sysname> copy cfa0:/test/1.cfg cfa0:/testbackup/1backup.cfg
Copy cfa0:/test/1.cfg to cfa0:/testbackup/1backup.cfg?[Y/N]:y
Copying file cfa0:/test/1.cfg to cfa0:/testbackup/1backup.cfg...Done.
# Copy test.cfg from the working directory on FTP server 1.1.1.1 and save it to the local current folder as
testbackup.cfg. In this example, the FTP username and password are user and private.
<Sysname> copy ftp://user:private@1.1.1.1/test.cfg testbackup.cfg
Copy ftp://user:private@1.1.1.1/test.cfg to cfa0:/testbackup.cfg?[Y/N]:y
Copying file ftp://user:private@1.1.1.1/test.cfg to cfa0:/testbackup.cfg... Done.