Skip to main content

APC USV

Sammlung zu Skripten und Guides für APC USV Anlagen bzw. einzelne USV Geräte

apcd unter Ubuntu

Installation via apt install apcd -y direkt aus den Ubuntu Repos heraus.

USB2Serial Adapter (Smart-UPS)

Bei Verwendung einer Smart-UPS muss zwingend ein spezieller USB zu Seriell-Adapter mit dem Pinout von APC verwendet werden, da sonst beim Anschluss des Adapters an die USV jene herunterfährt.

Danach in der Datei /etc/apcupsd/apcupsd.conf folgende Einträge anpassen.

UPSCABLE smart

UPSTYPE apcsmart
DEVICE /dev/ttyUSB0

Danach ist ein Neustart des Daemons notwendig. (systemctl restart apcupsd.service)

Mithilfe 

Diagnoseprogramm

Mithilfe des Tools apctest lässt sich direkt mit der USV eine Verbindung herstellen. Dafür muss jedoch vorher der apcupsd Daemon mit systemctl stop apcdupsd.service beendet werden.

Durch Ausführen des Programms apctest wird eine Verbindung mit der USV hergestellt, je nach Kommunikationsart.

Der Umfang des angezeigten Menüs variiert stark anhand des Modells. Bei mir ist eine Smart-UPS SC 420 im Einsatz.

root@patrick-kubuntu:~# apctest 

2025-04-30 21:14:02 apctest 3.14.14 (31 May 2016) debian
Checking configuration ...
sharenet.type = Network & ShareUPS Disabled
cable.type = Custom Cable Smart
mode.type = APC Smart UPS (any)
Setting up the port ...
Doing prep_device() ...

You are using a SMART cable type, so I'm entering SMART test mode
Hello, this is the apcupsd Cable Test program.
This part of apctest is for testing Smart UPSes.
Please select the function you want to perform.

1) Query the UPS for all known values
2) Perform a Battery Runtime Calibration
3) Abort Battery Calibration
4) Monitor Battery Calibration progress
5) Program EEPROM
6) Enter TTY mode communicating with UPS
Q) Quit

Select function number: