< Home

ftp server-source

Function

The ftp server-source command specifies the source IP address for an FTP server to send packets.

The undo ftp server-source command restores the default source IP address for an FTP server to send packets.

The default source IP address for the FTP server to send packets is 0.0.0.0.

Format

ftp server-source { -a source-ip-address | -i interface-type interface-number }

undo ftp server-source

Parameters

Parameter Description Value

-a source-ip-address

Specifies the IPv4 address of the source interface on the local device.

-

-i interface-type interface-number

Specifies the source interface of the local device.

-

Views

System view

Default Level

3: Management level

Usage Guidelines

Usage Scenario

If no source IP address (0.0.0.0 by default) is specified, the FTP server uses the source IP address specified by routes to send packets. The source IP address must be configured for an interface with stable performance, such as the loopback interface. Using the loopback interface as the source IP address simplifies the ACL rule and security policy configuration. This shields the IP address differences and interface status impact, filters incoming and outgoing packets, and implements security authentication.

Precautions

  • After the source IP address is specified for the FTP server, you must use the specified IP address to log in to the FTP server.
  • If the FTP service has been enabled, the FTP service restarts after the ftp server-source command is executed.
  • No source address or source interface is specified, so security risks exist.

Example

# Set the source IP address of the FTP server to LoopBack0.

<HUAWEI> system-view
[HUAWEI] ftp server-source -i loopback 0
Warning: To make the server source configuration take effect, the FTP server will be restarted. Continue? [Y/N]: y
Info: Succeeded in setting the source interface of the FTP server to LoopBack0.
Info: Succeeded in starting the FTP server.
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >