以
docker run --hostname=quickstart.cloudera --privileged=true -t -i -d --name quickstart0 -v /scratch/quickstart.cloudera/data:/data --publish-all=true -p 8888:8888 -p 7180:7180 cloudera/quickstart /usr/bin/docker-quickstart
我可以 ping 通 8.8.8.8,没问题,但是:
[root@quickstart /]# ping www.google.com
ping: unknown host www.google.com
解析配置文件
# This file is managed by man:systemd-resolved(8). Do not edit.
#
# This is a dynamic resolv.conf file for connecting local clients directly to
# all known uplink DNS servers. This file lists all configured search domains.
#
# Third party programs must not access this file directly, but only through the
# symlink at /etc/resolv.conf. To manage man:resolv.conf(5) in a different way,
# replace this symlink by a static file or a different symlink.
#
# See man:systemd-resolved.service(8) for details about the supported modes of
# operation for /etc/resolv.conf.
nameserver 75.75.75.75
nameserver 75.75.76.76
# Too many DNS servers configured, the following entries may be ignored.
search XXXXX.comcast.net
- 尝试替换 8.8.8.8 / 8.8.4.4 但没有成功
- ping 容器外的工作正常
Client: Docker Engine - Community
Version: 19.03.8
API version: 1.39 (downgraded from 1.40)
Go version: go1.12.17
Git commit: afacb8b
Built: Wed Mar 11 01:27:04 2020
OS/Arch: linux/amd64
Experimental: false
Server: Docker Engine - Community
Engine:
Version: 18.09.1
API version: 1.39 (minimum version 1.12)
Go version: go1.10.6
Git commit: 4c52b90
Built: Wed Jan 9 19:06:30 2019
OS/Arch: linux/amd64
Experimental: false
答案1
根据这除了以下之外,现在没有其他优雅的解决方案:
sudo systemctl disable firewalld