Issue a clean shutdown from an APC UPS

SUMMARY

Shutdown a Unitrends physical appliance cleanly during an unplanned power outage.

ISSUE

 

During a power outage, the Unitrends physical appliance needs to be shutdown cleanly.  This article outlines how to implement this via APC UPS solutions.

RESOLUTION

A clean shutdown from an APS UPS can be implemented for either CentOS 6 or CentOS 7, however the procedure varies based on the Operating System.

 

First, determine which version of CentOS Linux your Unitrends physical appliance is running, following the steps in the kb article How can I tell my version of CentOS Linux? 

 

Quick links:

How to set up a APC UPS shutdown for CentOS7

How to set up a APC UPS shutdown for CentOS6

 

CentOS 7 APC UPS shutdown procedures

Follow the procedure to set up APC UPS support on a CentOS 7 Unitrends physical appliance.

  1. The APC ups must be directly connected to the Unitrends physical appliance via a USB using a USB cable provided by the APC UPS vendor.  The APC UPS must be connected prior to running the setup utility.
  2. If the Unitrends physical appliance is not a CentOS 7 system, stop here and see instructions for CentOS6. If the UPS is not connected to the Unitrends physical appliance, stop here and complete step 1. This process will not work if the prerequisites are not met.
  3. Access the Unitrends physical appliance remotely using PuTTY.  PuTTY will provide command line access to the system. Use the following command to verify the APC is connected using USB: 
    # ls /dev/usb | grep hid
    Note: If nothing shows after running this command, please try a different USB port on the appliance. You should see a result looking similar to, "hiddev0".
  4.  Go to UI and select the button "Activate APC UPS" at CONFIGURE --> Edit --> Advanced --> Support Toolbox.

 

 

CentOS 6 APC UPS shutdown procedures

Follow the procedure to set up APC UPS support on a CentOS 6 Unitrends physical appliance.

  1. The APC ups must be directly connected to the Unitrends physical appliance via a USB using a USB cable provided by the APC UPS vendor.  The APC UPS must be connected prior to running the setup utility.
  2. If the Unitrends physical appliance is not a CentOS 6 system, stop here and see instructions for CentOS7. If the UPS is not connected to the Unitrends physical appliance, stop here and complete step 1. This process will not work if the prerequisites are not met.
  3. Access the Unitrends physical appliance remotely using PuTTY.  PuTTY will provide command line access to the system. Use the following command to verify the APC is connected using USB: 
    # ls /dev/usb | grep hid
    Note: If nothing shows after running this command, please try a different USB port on the appliance. You should see a result looking similar to, "hiddev0".
  4. Download the setup utility from the Unitrends site as below. 
    # cd /tmp
    # wget https://repo.unitrends.com/apcupsd/gd-2.0.35-11.el6.x86_64.rpm
    # yum  localinstall --nogpgcheck gd-2.0.35-11.el6.x86_64.rpm
    # wget https://repo.unitrends.com/apcupsd/apcConfig.sh
    # chmod +x apcConfig.sh
  5. Execute the setup utility, then start the apcupsd service.  
    # ./apcConfig.sh
    # service apcupsd start (a reboot will also start the service)
    
  6. Verify the script is running.
    # ps aux | grep apc
    root      4649  0.0  0.0 104988   884 ?        Ssl  Nov05   0:07 /sbin/apcupsd -f /etc/apcupsd/apcupsd.conf
    root     22261  0.0  0.0 103248   904 pts/0    S+   09:37   0:00 grep apc


The script will configure the Unitrends physical appliance to support a shutdown from an APC UPS via USB cable.

 

 

NOTES

For Unitrends Backup or Unitrends Virtual Backup products, a shutdown command may be configured within the hypervisor.

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Contact us