KS-Soft. Network Management Solutions
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister    ProfileProfile    Log inLog in 

Querying DHCP scope for number of available IP's

 
Post new topic   Reply to topic    KS-Soft Forum Index -> Library
View previous topic :: View next topic  
Author Message
Yoorix



Joined: 14 Dec 2005
Posts: 177

PostPosted: Tue Mar 04, 2008 9:38 am    Post subject: Querying DHCP scope for number of available IP's Reply with quote

I figured out how to monitor the number of available IP's on my DHCP server using HostMonitor and want to share my experience with community.

I use "SNMP Get" test method.
There are two useful counters, specified in DHCP-MIB:
noAddInUse - 1.3.6.1.4.1.311.1.3.2.1.1.2 - number of IP's in use
noAddFree - 1.3.6.1.4.1.311.1.3.2.1.1.3 - number of available IP's

These OIDS are scope-level counters, so I have to add "scope" to the end of the OID. For example, if my DHCP server manages scope "192.168.1", I should use following OID to get the number of available IP's in this particular scope: 1.3.6.1.4.1.311.1.3.2.1.1.3.192.168.1.0

Regards,
Yoorix
Back to top
View user's profile Send private message
JuergenF



Joined: 26 Jan 2003
Posts: 331
Location: Germany, North Rhine-Westphalia

PostPosted: Tue Mar 04, 2008 4:48 pm    Post subject: Reply with quote

Hi Yoorix,

that is very interesting to know !

My alternative for monitoring DHCP is this
Code:
; ------- Test #01 -------


Method      = NTLog
;--- Common properties ---
DestFolder  = DCC\DE VZs\BLN - Berlin\
Title       = DHCPServer ScopeFull Berlin
Comment     = DHCPServer ScopeFull Berlin
RelatedURL  =
ScheduleMode= Regular
Schedule    = 7 Days, 24 Hours
Interval    = 1800
Alerts      = Gen.HTML report-Retest-Alarm after 3
ReverseAlert= No
UnknownIsBad= No
WarningIsBad= Yes
UseWarning  = Yes
WarningExpr = %udv_status_bad%
UseCommonLog= Yes
PrivLogMode = Default
CommLogMode = Default
SyncCounters= No
SyncAlerts  = No
DependsOn   = list
MasterTest-Alive = Ping to blndc001 - Server Berlin
;--- Test specific properties ---
Computer    = \\blndc001
Log         = System
Source      = DHCPServer
CheckComp   = Any
CheckType   = AnyFromList
CheckID     = AnyFromList
CheckDescr  = AnyFromList
CompList    =
TypeList    = Warning
IDList      = ^M1020^M
DescrList   = ^M95 percent utilized^M95 Prozent ausgelastet^M96 percent utilized^M96 Prozent ausgelastet^M97 percent utilized^M97 Prozent ausgelastet^M98 percent utilized^M98 Prozent ausgelastet^M99 percent utilized^M99 Prozent ausgelastet^M100 percent utilized^M100 Prozent ausgelastet^M
ReportMode  = LastEvent


udv_status_bad = ("%SuggestedSimpleStatus%"=="DOWN")

It's an EventLog test. So you don't have to care, when adding new Scopes
It's working for Geman and English Systems and gives an Alert when more than 95 Percent of the IP-Adresses of a Scope are in use
(If I remember correctly 95 % is the threshold for Event-Log entries. So you can't test for 90 %)

And a problem is not to miss the Alert.
Because the test will go to BAD only for 1 testcycle. (Just when the new Event-Log entry appears)
EDIT: So sending an eMail might be a good idea
The next test will not find a new "Bad" entry in the Event-Log. Therefore the test will change back to OK.
It's described here http://www.ks-soft.net/cgi-bin/phpBB/viewtopic.php?t=4238

Best regards

Juergen


Last edited by JuergenF on Fri Mar 07, 2008 5:28 am; edited 1 time in total
Back to top
View user's profile Send private message
Yoorix



Joined: 14 Dec 2005
Posts: 177

PostPosted: Fri Mar 07, 2008 5:18 am    Post subject: Reply with quote

Hi Juergen!

Your solution looks brilliant!
I'll give it a try.

Thank you.

------------
Yoorix
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    KS-Soft Forum Index -> Library All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group

KS-Soft Forum Index