Discussion:
[Nagios-users] detect 2 DHCP Servers on network?
Hari Sekhon
2006-07-28 16:40:20 UTC
Permalink
I was wondering what the best way of detecting a rogue dhcp server on
the network is.


I ask because some idiot at work installed vmware with it's dhcp server
which stuffed the company laptops which rely on dhcp since they got sent
to the wrong subnet.

Nagios actually drew my attention to this when troubleshooting because
it said 2 DHCP offers received.

I'm thinking about writing a shell wrapper to parse the output from the
check_dhcp plug-in and raise a warning status if it returns more than 1
dhcp offer.

Any other ideas?


Hari
Eli Stair
2006-07-28 17:01:55 UTC
Permalink
Use CPAN's Net::DHCP::Packet to quickly create a DHCPDISCOVER packet, and
IO::Socket::INET to read raw incoming data to port 68, count the number of
DHCPOFFER's you get. Set your script output to proper OK/WARN/CRIT state
and the number/names of "rogue" servers in the text.

Just a suggestion.

/eli
Post by Hari Sekhon
I was wondering what the best way of detecting a rogue dhcp server on
the network is.
I ask because some idiot at work installed vmware with it's dhcp server
which stuffed the company laptops which rely on dhcp since they got sent
to the wrong subnet.
Nagios actually drew my attention to this when troubleshooting because
it said 2 DHCP offers received.
I'm thinking about writing a shell wrapper to parse the output from the
check_dhcp plug-in and raise a warning status if it returns more than 1
dhcp offer.
Any other ideas?
Hari
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Nagios-users mailing list
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting
any issue.
::: Messages without supporting info will risk being sent to /dev/null
Continue reading on narkive:
Loading...