The user-sync command enables Portal authentication user information synchronization.
The undo user-sync command disables Portal authentication user information synchronization.
By default, Portal authentication user information synchronization is disabled.
Parameter | Description | Value |
---|---|---|
interval interval-period |
Specifies the user information synchronization interval. |
The value is an integer that ranges from 30 to 65535, in seconds. The default value is 300. |
max-times times |
Specifies the maximum number of user information synchronization failures. |
The value is an integer that ranges from 2 to 255. The default value is 3. |
Usage Scenario
If communication is interrupted because the network between the device and Portal server is disconnected or the Portal server is faulty, online Portal authentication users cannot go offline. Therefore, user information on the device and on the Portal server may be inconsistent and accounting may be inaccurate.
The user-sync command enables user information synchronization so that user information on the device and Portal server is synchronized at intervals to ensure user information consistency.
During information synchronization, the device does not disconnect the user immediately after detecting that the device has certain user information while the server does not have such information. Instead, the device disconnects the user when the maximum number of user information synchronization failures is reached.
Precautions
If users go online during the keepalive interval of the Portal server, the Portal server does not have their entries. After the Portal server goes Up and starts synchronizing user information, the device does not disconnect these users even if synchronization fails. The device retails these users until next time these users go online and performs Portal authentication, ensuring good user experience.
The value of interval-period*times configured on the device must be greater than the interval for the Portal server to send synchronization packets. Otherwise, the device may force users offline when it cannot receive any synchronization packet from the Portal server after the maximum failure number is reached.
When you run the user-sync command, make sure that the Portal server supports this function. Otherwise, the users will go offline.
# Enable user information synchronization in the Portal server template abc, set the interval for user information synchronization to 100s, and set the maximum number of synchronization failures to 5.
<HUAWEI> system-view [HUAWEI] web-auth-server abc [HUAWEI-web-auth-server-abc] user-sync interval 100 max-times 5