Talking to PostgreSQL with telnet

Started by Campano, Troyover 23 years ago1 messagesgeneral
Jump to latest
#1Campano, Troy
Troy.Campano@LibertyMutual.com

I want to write a program that scans a bunch of nodes on port 5432 to see if
PostgreSQL lives there.
Is there a command I can issue from telnet that will return if it is
PostgreSQL and not another server without supplying and credentials?

For example if I telnet to a node called 'bob' on port 21 I could get:

220 bob FTP server (SunOS 5.8) ready.

And then I'd now it's a FTP server. Anything to find out if it's a
PostgreSQL server?
When I use this same method on a PostgreSQL server running on port 5432, I
get a blank console that is awaiting for a command.

thank you!

Troy Campano