1、怎样获得域名解析出的IP如题 谢谢了
C:\>nslookup 这里使用nslookup命令Default Server: ns2.cache.yntelAddress: 61.166.150.123> www.baidu.com Server: ns2.cache.yntelAddress: 61.166.***.*** 这里影去了 这里是当地dns服务器的IPNon-authoritative answer:Name: www.a.shifen.com Addresses: 220.181.6.18, 220.181.6.19Aliases: www.baidu.com >
麻烦采纳,谢谢!
2、如何根据域名查询ip地址
1.域名查询IP方法,点击开始选择“运行”输入cmd点击确定,打开cmd窗口
2.输入ping baidu.com(输入所要查询的域名),查询域名ip地址
3.输入nslookup 域名,同样可以查询域名ip地址。
4.查本机局域网IP方法,输入ipconfig,查询本机ip
3、如何获取目标主机的域名或IP?
知道了域名的前提下 你可以进入dos界面ping一下就知道ip了比如想要知道 wenwen.soso.com 的ip 结果如下Pinging wenwen- cdn.soso.com [58.251.60.62] with 32 bytes of data:Reply from 58.251.60.62: bytes=32 time=55ms TTL=54Reply from 58.251.60.62: bytes=32 time=57ms TTL=54Reply from 58.251.60.62: bytes=32 time=60ms TTL=54Reply from 58.251.60.62: bytes=32 time=66ms TTL=54Ping statistics for 58.251.60.62: Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),Approximate round trip times in milli-seconds: Minimum = 55ms, Maximum = 66ms, Average = 59ms
4、如何查看一个域名所对应的IP地址?
查看一个域名所对应的IP地址步骤如下:
1、点击电脑左下角开始菜单,打开“运行”选项。
2、然后输入“cmd”并打开。
3、在弹出的页面输入ping+你想要查看的域名,比如新浪网,ping www.sina.com.cn。
4、然后按键盘的回车键,此时出现的IP就是你要查看的IP,如图所示。
(4)取域名ip扩展资料
网域名称系统(DNS,Domain Name System,有时也简称为域名)是因特网的一项核心服务,它作为可以将域名和IP地址相互映射的一个分布式数据库,能够使人更方便的访问互联网,而不用去记住能够被机器直接读取的IP地址数串。
例如,www.wikipedia.org是一个域名,和IP地址208.80.152.2相对应。DNS就像是一个自动的电话号码簿,我们可以直接拨打wikipedia的名字来代替电话号码(IP地址)。我们直接调用网站的名字以后,DNS就会将便于人类使用的名字(如www.wikipedia.org)转化成便于机器识别的IP地址(如208.80.152.2)。
参考资料网络--域名
5、linux 获取域名ip的方法
^1、用ping/nslookup/dig都能解析ip
2、实例getip.sh
#!/bin/sh
name=$1
if [ -z $1 ];then
echo Usage:$0 dns
exit 1
fi
dig $name|grep ^$name|awk '{print $5}'
3、./getip.sh 一个域名
6、如何通过域名得到IP
最简单的是通过:运行 > cmd > ping 域名 > 回车执行就可以得到该域名现在解析到什么IP了;
第二种可以上http://www.ip138.com 这里查询
7、如何获取域名对应的IP地址
最简单,容易的方法
使用ping命令
例如 ping baidu.com
然后ping 回复的地址就是该网站的
8、java怎么通过域名获取ip地址
import java.net.InetAddress;
import java.net.UnknownHostException;
public class TestInetAddress {
InetAddress myIpAddress = null;
InetAddress[] myServer = null;
public static void main(String args[]) {
TestInetAddress address = new TestInetAddress();
System.out.println("Your host IP is: " + address.getLocalhostIP());
String domain = www.jb51.net;
System.out.println("The server domain name is: " + domain);
InetAddress[] array = address.getServerIP(domain);
int count=0;
for(int i=1; i<array.length; i++){
System.out.println("ip "+ i +" "+ address.getServerIP(domain)[i-1]);
count++;
}
System.out.println("IP address total: "+count);
}
/**
* 获得 localhost 的IP地址
* @return
*/
public InetAddress getLocalhostIP() {
try {
myIpAddress = InetAddress.getLocalHost();
} catch (UnknownHostException e) {
e.printStackTrace();
}
return (myIpAddress);
}
/**
* 获得某域名的IP地址
* @param domain 域名
* @return
*/
public InetAddress[] getServerIP(String domain) {
try {
myServer = InetAddress.getAllByName(domain);
} catch (UnknownHostException e) {
e.printStackTrace();
}
return (myServer);
}
}
9、如何获取一个域名的IP
ping这个域名即可得到IP。
例如 ping www.baidu.com,就能看到它的IP是14.什么什么了。
在“运行”那里执行该命令即可。