Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@keithkim
Created August 27, 2020 19:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save keithkim/9210a84d68730f1a71c3cffe4fd4e681 to your computer and use it in GitHub Desktop.
Save keithkim/9210a84d68730f1a71c3cffe4fd4e681 to your computer and use it in GitHub Desktop.
APC UPS CGI outputs
Content-Type: text/html; charset=utf-8
Content-Language: en
Pragma: no-cache
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Multimon: UPS Status Page</title>
<meta http-equiv="Pragma" content="no-cache" />
<meta name="generator" content="apcupsd 3.14.14, See: http://www.apcupsd.com/" />
<meta http-equiv="Refresh" content="30" />
<style>
body {
color: black;
background: white;
}
div.Center {
text-align: center;
}
img {
border-style: none;
}
pre {
text-align: left;
}
strong {
color: red;
}
table.Outer {
color: black;
background: #60a0a0;
empty-cells: show; border: solid #60a0a0
}
th.Outer {
color: black;
background: #60b0b0
}
.Title {
font-size: 18pt;
}
.SubTitle {
font-size: 12pt;
}
.Empty {
color: black;
background: aqua;
}
.Fault {
color: black;
background: red;
}
.Label {
color: black;
background: aqua;
}
.Normal {
color: black;
background: lime;
}
.Warning {
color: black;
background: yellow;
}
</style>
</head>
<body>
<table class="Outer" cellpadding="5">
<tr><th class="Outer" colspan="9">
<span class="Title">APCUPSD UPS Network Monitor</span>
<br /><span class="SubTitle">Tue Aug 11 23:42:16 EDT 2020</span></th></tr>
<tr>
<th class="Outer">System</th>
<th class="Outer">Model</th>
<th class="Outer">Status</th>
<th class="Outer">Battery Chg</th>
<th class="Outer">Utility</th>
<th class="Outer">UPS Load</th>
<th class="Outer">UPS Temp</th>
<th class="Outer">Batt. Run Time</th>
<th class="Outer">Data</th>
</tr>
<tr align="center">
<td class="Label"><a href="upsstats.cgi?host=127.0.0.1&amp;temp=C">Local Host</a></td>
<td class="Label">Back-UPS XS 1500M </td>
<td class="Normal"> ONLINE<br /></td>
<td class="Normal">97.0 %</td>
<td class="Normal">116.0 VAC</td>
<td class="Normal">10.0 %</td>
<td class="Empty">-</td>
<td class="Normal">72.8 min.</td>
<td class="Label"><a href="upsfstats.cgi?host=127.0.0.1">All data</a></td>
</tr>
</table>
</body></html>
Content-Type: text/html; charset=utf-8
Content-Language: en
Pragma: no-cache
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>APCUPSD Full Status Page</title>
<meta http-equiv="Pragma" content="no-cache" />
<meta name="generator" content="apcupsd 3.14.14, See: http://www.apcupsd.com/" />
<meta http-equiv="Refresh" content="30" />
<style>
body {
color: black;
background: white;
}
div.Center {
text-align: center;
}
img {
border-style: none;
}
pre {
text-align: left;
}
strong {
color: red;
}
table.Outer {
color: black;
background: #60a0a0;
empty-cells: show; border: solid #60a0a0
}
th.Outer {
color: black;
background: #60b0b0
}
.Title {
font-size: 18pt;
}
.SubTitle {
font-size: 12pt;
}
.Empty {
color: black;
background: aqua;
}
.Fault {
color: black;
background: red;
}
.Label {
color: black;
background: aqua;
}
.Normal {
color: black;
background: lime;
}
.Warning {
color: black;
background: yellow;
}
</style>
</head>
<body>
<blockquote><pre>APC : 001,036,0868
DATE : 2020-08-11 23:42:35 -0400
HOSTNAME : cherry
VERSION : 3.14.14 (31 May 2016) debian
UPSNAME : APC_BX1500M
CABLE : USB Cable
DRIVER : USB UPS Driver
UPSMODE : Stand Alone
STARTTIME: 2020-08-11 17:34:39 -0400
MODEL : Back-UPS XS 1500M
STATUS : ONLINE
LINEV : 115.0 Volts
LOADPCT : 12.0 Percent
BCHARGE : 97.0 Percent
TIMELEFT : 63.6 Minutes
MBATTCHG : 5 Percent
MINTIMEL : 3 Minutes
MAXTIME : 0 Seconds
SENSE : Medium
LOTRANS : 88.0 Volts
HITRANS : 139.0 Volts
ALARMDEL : 30 Seconds
BATTV : 27.3 Volts
LASTXFER : No transfers since turnon
NUMXFERS : 0
TONBATT : 0 Seconds
CUMONBATT: 0 Seconds
XOFFBATT : N/A
SELFTEST : NO
STATFLAG : 0x05000008
SERIALNO : 3B2019X69717
BATTDATE : 2020-05-09
NOMINV : 120 Volts
NOMBATTV : 24.0 Volts
NOMPOWER : 900 Watts
FIRMWARE : 947.d10 .D USB FW:d
END APC : 2020-08-11 23:42:37 -0400
</pre></blockquote>
</body></html>
Content-Type: text/html; charset=utf-8
Content-Language: en
Pragma: no-cache
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>127.0.0.1 UPS Status</title>
<meta http-equiv="Pragma" content="no-cache" />
<meta name="generator" content="apcupsd 3.14.14, See: http://www.apcupsd.com/" />
<meta http-equiv="Refresh" content="30" />
<style>
body {
color: black;
background: white;
}
div.Center {
text-align: center;
}
img {
border-style: none;
}
pre {
text-align: left;
}
strong {
color: red;
}
table.Outer {
color: black;
background: #60a0a0;
empty-cells: show; border: solid #60a0a0
}
th.Outer {
color: black;
background: #60b0b0
}
.Title {
font-size: 18pt;
}
.SubTitle {
font-size: 12pt;
}
.Empty {
color: black;
background: aqua;
}
.Fault {
color: black;
background: red;
}
.Label {
color: black;
background: aqua;
}
.Normal {
color: black;
background: lime;
}
.Warning {
color: black;
background: yellow;
}
</style>
</head>
<body>
<div class="Center">
<table border="2" cellspacing="10" cellpadding="5">
<tr><th>2020-08-11 23:42:38 -0400 </th>
<th>
<form method="get" action="upsstats.cgi"><div>
<input type="hidden" name="host" value="127.0.0.1" />
<select onchange="this.form.submit()" name="img1">
<option value="1" selected="selected">Battery Capacity</option>
<option value="2">Battery Voltage</option>
<option value="3">Utility Voltage</option>
<option value="4">Output Voltage</option>
<option value="5">UPS Load</option>
<option value="6">Run Time Remaining</option>
</select>
<input type="hidden" name="img2" value="6" />
<input type="hidden" name="img3" value="5" />
<input type="hidden" name="temp" value="C" />
<input type="hidden" name="refresh" value="30" />
</div></form>
</th>
<th>
<form method="get" action="upsstats.cgi"><div>
<input type="hidden" name="host" value="127.0.0.1" />
<input type="hidden" name="img1" value="1" />
<select onchange="this.form.submit()" name="img2">
<option value="1">Battery Capacity</option>
<option value="2">Battery Voltage</option>
<option value="3">Utility Voltage</option>
<option value="4">Output Voltage</option>
<option value="5">UPS Load</option>
<option value="6" selected="selected">Run Time Remaining</option>
</select>
<input type="hidden" name="img3" value="5" />
<input type="hidden" name="temp" value="C" />
<input type="hidden" name="refresh" value="30" />
</div></form>
</th>
<th>
<form method="get" action="upsstats.cgi"><div>
<input type="hidden" name="host" value="127.0.0.1" />
<input type="hidden" name="img1" value="1" />
<input type="hidden" name="img2" value="6" />
<select onchange="this.form.submit()" name="img3">
<option value="1">Battery Capacity</option>
<option value="2">Battery Voltage</option>
<option value="3">Utility Voltage</option>
<option value="4">Output Voltage</option>
<option value="5" selected="selected">UPS Load</option>
<option value="6">Run Time Remaining</option>
</select>
<input type="hidden" name="temp" value="C" />
<input type="hidden" name="refresh" value="30" />
</div></form>
</th></tr>
<tr><td><pre>
Monitoring: cherry
UPS Model: Back-UPS XS 1500M
UPS Name: APC_BX1500M
APCUPSD: Version 3.14.14
Status: ONLINE
</pre></td>
<td rowspan="3">
<img src="upsimage.cgi?display=battcap&amp;value=97.0&amp;value2=5" alt="Battery Capacity 97.0%" width="150" height="350" />
</td>
<td rowspan="3">
<img src="upsimage.cgi?display=runtime&amp;value=67.9&amp;value2=3" alt="Run time remaining 67.9 minutes" width="150" height="350" />
</td>
<td rowspan="3">
<img src="upsimage.cgi?display=upsload&amp;value=10.0" alt="UPS Load 10.0%" width="150" height="350" />
</td>
</tr>
<tr><td><pre>
Last UPS Self Test: NO
Last Test Date: Not found
</pre></td></tr>
<tr><td><pre>
Utility Voltage: 116.0 VAC
Line Minimum: Not found VAC
Line Maximum: Not found VAC
Output Freq: Not found Hz
</pre>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan="2">
<pre>
</select>
</div></form>
</td></tr></table>
</td></tr>
<tr><td colspan="4"><b>Recent Events</b><br />
<textarea rows="5" cols="95">
2020-08-11 17:34:39 -0400 apcupsd 3.14.14 (31 May 2016) debian startup succeeded
2020-08-11 17:32:36 -0400 apcupsd shutdown succeeded
2020-08-11 17:32:36 -0400 apcupsd exiting, signal 15
2020-08-11 17:10:50 -0400 apcupsd 3.14.14 (31 May 2016) debian startup succeeded
2020-08-11 17:08:46 -0400 apcupsd shutdown succeeded
2020-08-11 17:08:46 -0400 apcupsd exiting, signal 15
2020-08-11 17:03:46 -0400 Communications with UPS lost.
2020-08-11 17:02:35 -0400 apcupsd 3.14.14 (31 May 2016) debian startup succeeded
</textarea>
</td></tr>
</table></div>
</body></html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment