After selecting the bridge mode in VMware virtual machine and configuring the network, we found that Ping IP address can ping, but in Ping Baidu( www.baidu.com )If you can’t do it when you’re in bed, it’s a reminder:
So what’s the reason?
You can check whether the system is configured with DNS and enter the command cat/etc/ resolv.conf
As can be seen from the above results, the system is not configured with DNS. Here, you need to set DNS and enter the command: VI/etc/ resolv.conf
You can use Google’s public DNS service to add the following configuration to the file:
nameserver 8.8.8.8
nameserver 8.8.4.4
As shown in the figure below:
Reason: why configure DNS server
In the Internet, we communicate through IP address, and in order to facilitate users’ memory, we map IP to the corresponding domain name (e.g www.baidu.com ), So we use the command Ping Baidu( www.baidu.com )At the same time, the actual system also needs a DNS resolution process, through the domain name to find the corresponding IP, we can carry out the communication between the two hosts, and the DNS server is used to do this.
Similar Posts:
- Workaround for “could not retrieve mirrorlist” during Yum installation
- Running ntpdate reports an error: temporary failure in name resolution
- CentOS ping www.google.com Error: name or service not know
- ping: www.bing.com: Temporary failure in name resolution
- LINUX: How to Fix Ping Warning unknown host www.google.com
- ping: www.baidu.com : unknown name or service. Linux cannot access the Internet
- wget: unable to resolve host address
- linux pingreward errorName or service not known
- [Solved] Yum command error: could not retrieve mirrorlist http://mirrorlist.centos.org…
- [Solved] nginx no resolver defined to resolve..