5-20
Configure FTP server authentication and authorization and enable FTP. The FTP server supports
multi-client access. When a remote FTP client sends a request to the FTP server, the FTP server
executes an action accordingly and returns the execution result to the client. Use the following
command to enable the FTP service.
[H3C]ftp server enable
% Start FTP server
Add an authorized FTP username and password:
[H3C]local-user guest
//
Create user account guest.
[H3C-luser-guest]service-type ftp
//
Set user type to FTP.
[H3C-luser-guest]password simple 123456
//
Set password to 123456 for the user.
[H3C-luser-guest]authorization-attribute level 3
//
Set the user level to 3.
3) Maintain the access controller.
After enabling the FTP service and configuring the username and password, start the FTP client
program on the PC.
Open a DOS window, and enter
ftp
at the DOS prompt:
C:\Documents and Settings\Administrator>ftp
ftp>
//
The system prompt changed to ftp>.
ftp> open 192.168.0.2
//
Connect to the access controller.
Connected to 192.168.0.2.
220 FTP service ready.
User (192.168.0.2:(none)): guest
//
Enter the user name guest.
331 Password required for guest
Password:
//
Enter the password 123456.
230 User logged in.
//
Successfully connected to the server.
Now, use the following commands to maintain the access controller: To back up
main.bin
on the access
controller to the PC, do the following:
ftp> binary
//
Specify the transfer mode as binary.
200 Type set to I.
ftp> lcd c:\temp
//
Change the local path.
Local directory now C:\temp.
ftp> get main.bin main.bin
//
Back up the file to the PC.
200 Port command okay.
150 Opening BINARY mode data connection for /main.bin.
226 Transfer complete.
ftp: 14323376 bytes received in 16.81Seconds 851.87Kbytes/sec.
To restore the backup file to the access controller, do the following:
ftp> put main.bin main.bin
//
Download the backup file to the access controller.
200 Port command okay.
150 Opening BINARY mode data connection for /main.bin.
226 Transfer complete.
ftp: 14323376 bytes sent in 8.29Seconds 1727.37Kbytes/sec.
ftp> quit
//Quit FTP.
221 Server closing.