Home > Linux, SUSE, Tech Tip > UPS Monitoring with SUSE. Quick & Dirty

UPS Monitoring with SUSE. Quick & Dirty

I recently had the need to query a bunch of UPSes to gather their current statistics using openSUSE. The Network UPS Tools packages (NUT for short) are available for openSUSE and that’s all you need (assuming your UPS is one of the supported ones).

# zypper install nut

Next you need to edit /etc/ups/ups.conf and make an entry for your UPS driver and serial port.

[myups]
driver = bcmxcp
port = /dev/ttyUSB0
desc = “Local UPS”

Next I started the UPS driver manually in debug mode so I could see what was going on. The nice thing about this driver is it will auto-discover the UPS serial port speed.

# /usr/lib/ups/driver/bcmxcp -a myups -D

In a separate terminal window, start upsd.

# upsd

Now you should be able to query the UPS:

# upsc myups@localhost

Because I was just collecting statistics, I wasn’t interested in using upsd to automatically shutdown servers or anything fancy but that is possible.

Categories: Linux, SUSE, Tech Tip

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.