Posted to tcl by patthoyts at Wed Nov 05 11:40:00 GMT 2008view raw
- (Release) 1 % wm with .
- (Release) 2 % package require dns
- 1.3.2
- (Release) 3 % dns::configure
- -loglevel warn -nameserver 172.16.5.103 -port 53 -protocol udp -search {} -timeout 30000
- (Release) 4 % proc Result {tok} {if {[dns::status $tok] eq "ok"} { puts "ok [dns::result $tok]"} else {puts "error: [dns::error $tok]" } ; dns::cleanup $tok}
- (Release) 5 % dns::resolve www.google.com -command Result
- ::dns::1
- ok {name www.google.com type CNAME class IN ttl 15659 rdlength 8 rdata www.l.google.com} {name www.l.google.com type A class IN ttl 300 rdlength 4 rdata 66.102.9.104} {name www.l.google.com type A class IN ttl 300 rdlength 4 rdata 66.102.9.147} {name www.l.google.com type A class IN ttl 300 rdlength 4 rdata 66.102.9.99}
- (Release) 6 %