Certbot - DNS 问题:NXDOMAIN 为 xxx 查找 A - 检查此 DNS 记录是否存在 [英] Certbot - DNS problem: NXDOMAIN looking up A for xxx - check that a DNS records exists for this

查看:70
本文介绍了Certbot - DNS 问题:NXDOMAIN 为 xxx 查找 A - 检查此 DNS 记录是否存在的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以我尝试运行以下

sudo certbot certonly --nginx --dry-run -d subdomain.domain.com -d www.subdomain.domain.com

这给了我一个 DNS 问题,但是,它在运行时有效

That gave me a DNS problem, however, it worked when running

sudo certbot certonly --nginx --dry-run -d subdomain.domain.com

我的 DNS 记录中是否遗漏了什么?

Am I missing something in my DNS records?

我已经成功运行

sudo certbot certonly --nginx --dry-run -d domain.com -d www.domain.com

如果我使用子域,是否需要为www"部分创建特定的 DNS 记录?

Do I need to make a specific DNS record for the ´´www´´ part if I use subdomains?

编辑运行dig subdomain.domain.com"的结果

Edit Result of running ´´dig subdomain.domain.com´´

; <<>> DiG 9.11.5-P4-5.1ubuntu2.1-Ubuntu <<>> subdomain.domain.co.uk
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 45932
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 65494
;; QUESTION SECTION:
;subdomain.domain.co.uk.           IN      A

;; ANSWER SECTION:
subdomain.domain.co.uk.    1800    IN      A       xxx.yyy.aa.dd

;; Query time: 88 msec
;; SERVER: 127.0.0.53#53(127.0.0.53)
;; WHEN: Fri Feb 07 11:24:26 UTC 2020
;; MSG SIZE  rcvd: 64

回答

使用主机www.subdomain"创建一个 A 类条目,您就很好

Create an type A entry with the host ´´www.subdomain´´ and you're good

推荐答案

从问题中添加正确答案:

Adding proper answer from the question:

使用主机www.subdomain"创建一个 A 类条目,您就可以了

Create an type A entry with the host "www.subdomain" and you're good

根据我的经验,我想再等 5 分钟到一个小时,让记录生效,让 certbot 能够看到它.

I'd add to wait anywhere between 5 minutes to an hour for the record to take effect and for certbot to be able to see it, from my experience.

这篇关于Certbot - DNS 问题:NXDOMAIN 为 xxx 查找 A - 检查此 DNS 记录是否存在的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆