安装mariadb报错Neither host ‘skytx.yunvn.com’ nor ‘localhost’ could be looked up with ‘/usr/local/mariadb/bin/resolveip’


今天在安装mariadb的时候报错如下:

Neither host 'skytx.yunvn.com' nor 'localhost' could be looked up with
'/usr/local/mariadb/bin/resolveip'
Please configure the 'hostname' command to return a correct
hostname.
If you want to solve this at a later stage, restart this script
with the --force option

这是因为本地没有把localhost解析成127.0.0.1,只需要在hosts文件里面添加这个解析记录就好了。

QQ截图20140721134940


Whatever is worth doing is worth doing well.