Hi
I'm looking for a way to do a reverse lookup using dnspython. All of my
attempts so far have failed and I haven't been able to find any info on
the web about it. I'm running the latest version of python and the
latest version (from svn repo) of dnspython.
I've tried many many many ways of getting to work, with no success. In
my mind (and I could be wayyyy off), the following should work...
forward lookup...
>>> for a in dns.resolver.query('viclaptop2'):
... print a
...
10.1.10.158
reverse lookup...
>>> for a in dns.resolver.query('10.1.10.158'):
... print a
...
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/local/lib/python2.4/site-packages/dns/resolver.py", line
647, in query
return get_default_resolver().query(qname, rdtype, rdclass, tcp)
File "/usr/local/lib/python2.4/site-packages/dns/resolver.py", line
591, in query
raise NXDOMAIN
dns.resolver.NXDOMAIN
DNS most certainly works...
[1]+ Stopped python
bash-2.03$ /usr/sbin/nslookup viclaptop2
Server: csr-gtw-02.csr.uic.edu
Address: 10.1.10.2
Name: viclaptop2.csr.uic.edu
Address: 10.1.10.158
bash-2.03$ /usr/sbin/nslookup 10.1.10.158
Server: csr-gtw-02.csr.uic.edu
Address: 10.1.10.2
Name: viclaptop2.csr.uic.edu
Address: 10.1.10.158
Been banging my head against the wall with this for a couple days, so
any help would be much appreciated.
--
"If we hit that bullseye, the rest of the dominoes will fall like a house of cards.
Checkmate."
Zapp Brannigan
_______________________________________________
dnspython-users mailing list
[email protected]
http://woof.play-bow.org/mailman/listinfo/dnspython-users