.. _example_service_dhcp-server_failover: ######## Failover ######## These scenarios shows how to configure the failover feature in DHCP. This functionality provides more availability in case the connection to the main server is lost. ****************** Test DHCP Failover ****************** Description =========== Test scenario to check the DHCP Failover feature. The configuration for this feature has 2 peers, the main and the secondary server. The main server will provide the leases, while the secondary will help in case of error or act as backup if the main one fails. This scenario will check everything is properly configured, meaning it will check peer to peer whether its state and that of its partner are normal. Scenario ======== .. include:: failover/testdhcpfailover .. raw:: html
************************** Test DHCP Failover Disable ************************** Description =========== This scenario sets a configuration with the DHCP server service disabled. This means that the DHCP service is halted. The CLI will then send a message saying the server is not running. We will then restart this service and check everything works properly. Scenario ======== .. include:: failover/testdhcpfailoverdisable .. raw:: html
************************************************* Test DHCP Failover Recovery After Primary Restart ************************************************* Description =========== This scenario verifies that after a primary server restart, both servers successfully recover to normal state and synchronize their lease databases. The recovery process: 1. Primary disabled - secondary enters communications-interrupted 2. Primary re-enabled - both servers synchronize 3. Both servers return to normal state Scenario ======== .. include:: failover/testdhcpfailoverrecoveryafterprimaryrestart .. raw:: html
************************************* Test DHCP Failover Shows Correct Role ************************************* Description =========== This scenario verifies that the failover status correctly shows which server is primary and which is secondary. The 'service dhcp-server show failover' command should display: - Primary server shows "primary" role - Secondary server shows "secondary" role Scenario ======== .. include:: failover/testdhcpfailovershowscorrectrole .. raw:: html