pileofrogs has asked for the wisdom of the Perl Monks concerning the following question:
I'm making a system that scans my servers and reports all sorts of lovely details about their health.
I've got a simple function that can test if a TCP port is open or not to help me determine if my web server or SSH server is running. I'd like something similar for my UDP based services (NTP, DHCP, DNS resolver etc...).
I looked in the Perl Cookbook, and they have a recipe for a simple UDP client. Apparently, you need to send a datagram to the server and hope it sends you one back.
Is there a generic initial UDP datagram that will illicit a response that I can test for? I'm worried that differences in DNS,DHCP,NTP and whatever else will make it so there is no generic initial connection and no reliably uniform response.
A better question might be, what's the best way to test if a server is listening for UDP packets on a given port?
-Thanks!
-pileofrogs
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: UDP port scan?
by Fletch (Bishop) on Jan 18, 2006 at 01:00 UTC | |
by pileofrogs (Priest) on Jan 18, 2006 at 01:34 UTC | |
|
Re: UDP port scan?
by tirwhan (Abbot) on Jan 18, 2006 at 07:13 UTC | |
|
Re: UDP port scan?
by zombie_fred (Scribe) on Jan 18, 2006 at 07:07 UTC |