Piszki Lab | EN

My case study in the clouds…

Synology Network UPS (NUT) and ESXi 5.5

| 2 Comments

In my home Lab recently appear first ESXi server. For now, it is a fairly simple design, disk resources are made ​​available from the Synology NAS. Both devices (NAS and ESXi) are plugged into the UPS CyberPower BS650E. Synology fully supports UPS (connected via USB) and can respond well to current decays. And what about the ESXi? Here we have the right solution. This solution is a ESXi client for Network UPS Tools prepared by Rene Garcia. The client (UPS Mon) is of course flexible and is able to connect to any NUT server. In this post I will describe the connection to the NUT running on Synology DSM.

ups0

On the Synology nothing to install, just check if our UPS is properly operated and enable the “Network UPS server”.

ups1

ups2

An IP address is the address of our ESXi 5.5. In the next step, download the NUT client installation file to the server. Before you install the client, think about whether you will be able to restart the ESXi? Restart is not mandatory, the client can run immediately. Advanced options introduced by the installer are visible in ESXi 5.5 settings after a reboot. If you can not restart ESXi, we need to set the appropriate options (default) directly in the file upsmon-install.sh.  Correct the first three options, the appropriate permissions from Synology are stored in the file /usr/syno/etc/ups/upsd.users.

esxcfg-advcfg -A string -E -T NutUpsName NUT ups remote name (eg: upsname @ nutserver) -F ups@nas.piszki.lab
esxcfg-advcfg -A -T string NutUser -E, NUT username to connect to remote ups -F monuser
esxcfg-advcfg -A string -E -T NutPassword NUT password to connect to remote ups -F secret

Of course nas.piszki.lab is the name of my Synology. After entering the correct default options as root, install client (sh upsmon-install.sh). Next log in to the ESXi server by vSphere client and under Configuration-> Security profile-> Firewall check whether the rule is enabled for UPS Mon:

ups3

If you set the proper options in the file upsmon-install.sh you can immediately start the client in the Configuration-> Security Profiles-> Services-> Network UPS Tools:

ups4

If this is not done, then after Esxi reboot, we can go to the Configuration-> Advanced-> UserVars and set the appropriate options, a reminder: The default parameters for Synology is:

ups@IP/FQDN monuser secret

ups5

All the necessary parameters can also be set from the vCenter Web client. At the end we can test on the ESXi console if everything is working properly (by command upsc ups@IP):

ups6

In case of problems, I recommend a long discussion in the comments under the Rene post.

Rate this article:
[Total: 1 Average: 5]

Author: Piotr Pisz

Computer always, since I got a Commodore 64 at the end of primary school, through his beloved Amiga and Linux infinite number of consoles, until today, fully virtual day. Since 2001, Unix/Linux Systems Administrator, for seven years a faithful companion and protector of Solaris system, until his sad end. In the year 2011 came in the depths of virtualization, then smoothly ascended into the clouds and continues there today. Professionally working as Systems Architect in the Polish Security Printing Works.

2 Comments

Leave a Reply to Piotr Pisz Cancel reply

Required fields are marked *.