Showing results for 
Search instead for 
Did you mean: 
Create Post
Level 9

feature request: snmp drive space monitor for freebsd?

Is it possible to get a drive space monitor for freebsd?

I can't use a simple snmp monitor to check drive space, because there are several values to check and some math to do.

For example:

I have to first look up the storage I want to monitor in hrStorageDescr (.  I want to monitor item 11.

Then I have to look up the allocation units for this storage hrStorageAllocationUnits.11.  In this case, its 512.

Next, I have to find the value for hrStorageSize.11 (.  In this case, its 2147483647.

Last, the hrStorageUsed.11 (. is needed.  818737456.

Now, we have to do the math.

Storage size is calculated by multiplying the allocation units by the storage size value to get the number of bytes.  Then you have to divide by 1024 to get kb, divide that by 1024 to get MB, and again by 1000 to get a more readable GB value.  In this case we end up with 1000GB or 1TB.

Repeat the same method with the storage used values, and then subtract the two to get the answer.  ~600GB free.

Ideally, it would be possible for the user to plug in whatever oid was needed for each field, so it would work across almost everything.  The math should be the same everywhere.



1 Reply
Product Manager
Product Manager

This sounds like something that ipMonitor users might want to vote on. Maybe you can post this in the ipMonitor Ideas Section on Thwack.

0 Kudos