Establishing an ftp connection, Managing directories on the ftp server – H3C Technologies H3C SecBlade NetStream Cards User Manual
Page 226

211
Establishing an FTP connection
Before you can access the FTP server, you must establish a connection from the FTP client to the FTP server.
You can either use the ftp command to establish the connection directly or use the open command in FTP
client view to establish the connection.
When using the ftp or ftp client source command, you can specify the source interface (such as a
loopback interface) or source IP address. The primary IP address of the specified source interface or the
specified source IP address is used as the source IP address of sent FTP packets.
The FTP client follows these rules to select the source IP address of packets sent to the FTP server:
•
If no source IP address is specified, the IP address of the output interface of the route to the server
is used as the source IP address.
•
The source IP address specified with the ftp client source or ftp command is used.
•
If you first use the ftp client source command to specify a source IP address and then use the ftp
command to specify another source IP address, the latter is used.
•
The source IP address specified with the ftp client source command applies to all FTP connections
while the one specified with the ftp command applies to the current FTP connection only.
Follow these steps to establish an IPv4 FTP connection:
To do…
Use the command…
Remarks
Enter system view
system-view
—
Specify the source IP address of
sent FTP packets
ftp client source { interface interface-type
interface-number | ip source-ip-address }
Optional
By default, the source IP
address is determined by the
route from the FTP client to the
FTP server.
Return to user view
quit
—
Log in to the remote FTP server
directly in user view
ftp [ server-address [ service-port ]
[ source { interface interface-type
interface-number | ip
source-ip-address } ] ]
Use either approach.
The ftp command is available
in user view, and the open
command is available in FTP
client view.
Log in to the remote FTP server
indirectly in FTP client view
ftp
open server-address [ service-port ]
NOTE:
•
If no primary IP address is configured on the specified source interface, you cannot establish an FTP
connection.
•
If you use the ftp client source command to configure a source interface and then use it to configure a
source IP address, the source IP address overwrites the source interface, and vice versa.
Managing directories on the FTP server
After the SecBlade card serving as the FTP client has established a connection with an FTP server, you
can create or delete folders under the authorized directory of the FTP server. For more information about
establishing an FTP connection, see “
Establishing an FTP connection
Follow these steps to manage the directories on an FTP server: