[Nut-upsuser] Newbie question: real-time power usage monitoring?

Christian Convey christian.convey at gmail.com
Wed Oct 19 12:46:04 UTC 2011


I forgot to mention one thing about what I need:

I don't care how much about the latency between when the power meter
computes a result, and when it's available to my Linux box.  But I
*do* care a lot about the precision of the time sampling in the
report.

For example, it would be fine if I could only get an update from the
power meter every 10 seconds, but that update contained a time-stamped
log that reported power usage (either incremental or cummulative) in
0.1 or 0.5 -second intervals.



On Wed, Oct 19, 2011 at 8:40 AM, Christian Convey
<christian.convey at gmail.com> wrote:
> Thanks for the ideas.
>
> You're right - I *am* looking for total energy expenditure (Joules,
> Watt-hours, etc.)  I have no specific desire to do that integration in
> my own code.
>
> As far as sampling frequency, here's the deal:  I'm working on a
> system to estimate the power draw associated with a run (or set of
> runs) of an arbitrary program on my Linux computer.  Some of the
> program runs will be brief, but I'm not sure how brief we're talking.
> I'm no statistics expert, but I believe my power-draw estimates will
> get pretty inaccurate unless the sampling rate is markedly higher than
> the program's running time.  I *can* limit my studies to programs that
> run for a long time (so as to reduce the relative error stemming from
> a slow-sampling power meter), but that would put an unwelcome
> limitation on my research.
>
>
> On Wed, Oct 19, 2011 at 8:24 AM, Charles Lepple <clepple at gmail.com> wrote:
>> On Oct 18, 2011, at 10:18 PM, Christian Convey wrote:
>>
>>> I'd like to write a Linux app that will know, in approximate
>>> real-time, how much power is being drawn by a computer plugged into an
>>> outlet.
>>
>> Can you narrow down your definition of "approximate real-time"?
>>
>> The default poll interval of NUT drivers is 2 seconds, but usbhid-ups has
>> longer intervals for some values since retrieving values over low-speed USB
>> takes a non-trivial amount of time.
>>
>> If you are ultimately trying to integrate power over time to get energy
>> consumption, you probably want a device that does this measurement for you
>> (a watt-hour meter, basically). Then, the exact update rate doesn't matter
>> as much - if you poll less frequently, the energy per interval will simply
>> be proportionally larger. You can still divide out the time to get average
>> power, but of course, that won't show surges as effectively.
>>
>>> Is NUT well-suited to this usage?
>>>
>>> And if so, can anyone recommend relatively cheap monitoring hardware
>>> (ideally less than $200 US) that will meet my needs?
>>
>> I haven't gone shopping for an UPS in a while, but I'd think you would need
>> to spend at least USD $300-400 to get an UPS with decent current-monitoring
>> hardware. (The voltage-monitoring side usually is good enough even in
>> low-end UPSes.)
>>
>> Do you need backup power as well as monitoring capability? What about power
>> control?
>>
>> If you just want monitoring, you might consider one of the Watts Up
>> products:
>>
>>   https://www.wattsupmeters.com/secure/products.php
>>
>> (Disclaimer: I haven't personally tried any of them, and I can't vouch for
>> any of their software, either.)
>>
>> You could also look at power distribution units (PDUs) but I have a feeling
>> that the monitoring capability is also not available in the under-$200 price
>> range.
>>
>



More information about the Nut-upsuser mailing list