===== Uninterruptible Power Supply ===== For critical applications, we recommend the use of uninterruptible power supply (UPS) with the server. An UPS can shorten downtime and perform a controlled power down in the event of a power failure. Software for the popular [[https://www.apc.com/us/en/|APC]] brand of UPSes is preinstalled on server image version 191001 and later. The software is enabled using [[blocks:server:advanced_server_configuration#introducing_webmin|webmin]]. * Open webmin and select "System/Bootup and Shutdown". * Click the filter symbol in the top right hand corner and search for //apcups//. * Check the apcups.service checkbox and click "Start Now and On Boot". {{:blocks:adv-conf:webminenableapcups.png?nolink |}} The settings for the apcups is stored in a file on the server. The initial settings should work with most APC UPS devices that connect using USB. If you want to edit these settings, use webmin to open a terminal window (Alt+K), then type nano /etc/apcupsd/apcupsd.config This opens up the settings file using the //nano// text editor. Edit the settings as required. Save the file by pressing ctrl+s, or click save, then close by clicking the X button in the top right hand corner. Restart the server to apply any changes. In the event of a longer power failure, the UPS will supply power until the remaining battery threshold is reached and then power down the computer. Once computer has beens shut down, the UPS will break the power to the computer until mains power is restored. To make the server start automatically once power returns, configure the computer to always start automatically when power is connected. This configuration is typically found in the BIOS settings. More information on //apcupsd//, the program that manages the UPS, can be found here: https://wiki.ubuntu.com/apcupsd http://www.apcupsd.org/manual/