Solve the Problem of Temporary failure in name resolution when CentOS uses wget
The following error occurs when you use wget to download a file when installing Redis in CentOS:
Wget http://download.redis.io/releases/redis-3.0.7.tar.gz
Failed: Temporary failure in name resolution
Literally, it means that an error occurred while parsing the URL. I guess there may be a problem with the network configuration of the machine and checked the eth0 configuration, if an external IP address is successfully pinged, but an external url is pinged, the host is unknow, And the DNS settings are incorrect.
Then edit/etc/resolv. conf.
Two lines of DNS configuration are added. For specific values, you can view the network DNS used in the city.
Nameserver XXX. XXX
Nameserver XXX. XXX
Run service network restart to restart the network service, and then run wget.