Perl 查询域名对应的 IP 地址

清华大佬耗费三个月吐血整理的几百G的资源,免费分享!....>>>

use Socket;

$site_name = 'www.oschina.net';

$address = inet_ntoa(inet_aton($site_name));

print "The DNS address of www.oschina.net is $address";