reliable whois in python

E

eliss

Hi everyone,

I'm trying to write a python script to whois a few domains twice a day
so I get notified when they become available. I did it 2 ways, but
neither way is very reliable, so I'm asking here.

1) I tried just calling "whois %s" using popen, but I found that once
every few weeks, I get errors like:
connect: No route to host OR
fgets: Connection reset by peer
I don't think it's a connectivity issue because looking up the other
domains that day works, and just one domain will give an error. So
it's probably more like a networking issue? I don't know...

2) I tried using sockets to connect to the whois port of
whois.internic.net and then read the info, which works a little better
than 1). However, sometimes this is not reliable too and I get errors.

Does anyone have any ideas how I can do this better?

Thanks,

eliss
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,821
Latest member
AleidaSchi

Latest Threads

Top