运行 teuthology-suite 时解决 DNSError 的解决方法
注意:这仅对可以访问 Ceph 实验室的人员有用。
在使用 Ceph 集成测试使用 teuthology 时,它可能会因为以下 DNS 解析问题而失败
$ ./virtualenv/bin/teuthology-suite --base ~/software/ceph/ceph-qa-suite \ --suite upgrade/firefly-x \ --ceph wip-8475 --machine-type plana \ --email loic@dachary.org --dry-run 2014-06-27 INFO:urllib3.connectionpool:Starting new HTTP connection (1): ... requests.exceptions.ConnectionError: HTTPConnectionPool(host='gitbuilder.ceph.com', port=80): Max retries exceeded with url: /kernel-rpm-centos6-x86_64-basic/ref/testing/sha1 (Caused by : [Errno 3] name does not exist)
这可能是由 DNS 传播问题引起的,指向 ceph.com 可能会更好。如果正在运行 bind,在 /etc/bind/named.conf.local 中添加以下内容会将所有 ceph.com 相关的 DNS 查询转发到主服务器(NS1.DREAMHOST.COM 即 66.33.206.206),假设 /etc/resolv.conf 设置为首先使用本地 DNS 服务器
zone "ceph.com."{ type forward ; forward only ; forwarders { 66.33.206.206; } ; }; zone "ipmi.sepia.ceph.com" { type forward; forward only; forwarders { 10.214.128.4; 10.214.128.5; }; }; zone "front.sepia.ceph.com" { type forward; forward only; forwarders { 10.214.128.4; 10.214.128.5; }; };
front.sepia.ceph.com 区域将解析由 teuthology-lock 分配并用作目标的机器名称,例如
targets: ubuntu@saya001.front.sepia.ceph.com: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABA ... 8r6pYSxH5b