The source-interface command configures an IP address of a specified interface as the source IP address used by the device to communicate with the Portal server.
The undo source interface command restores the default configuration.
By default, no source IP address is configured for the device.
Parameter | Description | Value |
---|---|---|
interface-type interface-number | Configures an IP address of a specified interface as the source IP address used by the device to communicate with the Portal server:
|
- |
Usage Scenario
To enable the device to communicate with the Portal server normally, ensure that the source IP address in the packets sent by the device to the Portal server is consistent with the device IP address configured on the Portal server. By default, the device uses the IP address of an outbound interface as the source IP address to communicate with the Portal server. When there are multiple outbound interfaces and the outbound interface sending packets changes, the source IP address in the packets sent by the device to the Portal server becomes inconsistent with the device IP address configured on the Portal server. In this situation, communication between the device and Portal server is interrupted. To address this problem, run the source-interface command on the device to specify the IP address of a loopback interface as the source IP address used by the device to communicate with the Portal server.
Precautions
The specified interface must be a Layer 3 interface with an IP address configured.
# Configure an IP address of a specified interface as the source IP address used by the device to communicate with the Portal server.
<HUAWEI> system-view [HUAWEI] interface loopback 1 [HUAWEI-LoopBack1] ip address 10.1.2.25 24 [HUAWEI-LoopBack1] quit [HUAWEI] web-auth-server huawei [HUAWEI-web-auth-server-huawei] source-interface loopback 1