smartdns
smartdns copied to clipboard
使用加密的dns链接,一直报错。
问题现象
简要描述问题出现的现象
上游服务器设置成加密的链接后例如:(dns.pub/dns-query、dns.google/dns-query ),则会一直报错查询不到。然后看luci界面一直在无限启动-未启动-启动-未启动一两分钟后就挂掉了。。。下面是报错信息,附件也会贴上日志文件和配置文件
[2022-04-21 11:02:06,995][ERROR][ dns_client.c:2857] Send query to upstream server failed, total server number 0 [2022-04-21 11:02:06,995][ERROR][ dns_client.c:2857] Send query to upstream server failed, total server number 0 [2022-04-21 11:02:06,995][ERROR][ dns_server.c:2774] send dns request failed. [2022-04-21 11:02:06,995][ERROR][ dns_server.c:2851] do query time1.cloud.tencent.com failed. [2022-04-21 11:02:06,995][ERROR][ dns_server.c:3450] dns server process failed. [2022-04-21 11:02:06,996][ERROR][ dns_client.c:2857] Send query to upstream server failed, total server number 0 [2022-04-21 11:02:06,996][ERROR][ dns_server.c:2774] send dns request failed. [2022-04-21 11:02:06,996][ERROR][ dns_server.c:2851] do query time1.cloud.tencent.com failed. [2022-04-21 11:02:06,996][ERROR][ dns_server.c:3450] dns server process failed. [2022-04-21 11:02:07,004][ERROR][ dns_client.c:2857] Send query to upstream server failed, total server number 0 [2022-04-21 11:02:07,004][ERROR][ dns_client.c:2857] Send query to upstream server failed, total server number 0 [2022-04-21 11:02:07,004][ERROR][ dns_server.c:2774] send dns request failed. [2022-04-21 11:02:07,004][ERROR][ dns_server.c:2851] do query time1.cloud.tencent.com failed. [2022-04-21 11:02:07,004][ERROR][ dns_server.c:3450] dns server process failed. [2022-04-21 11:02:07,004][ERROR][ dns_client.c:2857] Send query to upstream server failed, total server number 0 [2022-04-21 11:02:07,005][ERROR][ dns_client.c:2857] Send query to upstream server failed, total server number 0 [2022-04-21 11:02:07,005][ERROR][ dns_server.c:2774] send dns request failed. [2022-04-21 11:02:07,005][ERROR][ dns_server.c:2851] do query time1.cloud.tencent.com failed. [2022-04-21 11:02:07,005][ERROR][ dns_server.c:3450] dns server process failed. [2022-04-21 11:02:07,010][ERROR][ dns_client.c:2857] Send query to upstream server failed, total serve
配置文件 smartdns.txt
日志文件 smartdns.log
运行环境
- 固件型号
斐讯N1 盒子
AArch64 Processor : Cortex-A53 * 4 OpenWrt R22.3.13 / LuCI Master (git-22.068.45502-a50e601) Linux version 5.4.184-flippy-70+o (root@gtking-pro) (gcc version 11.2.0 (Ubuntu 11.2.0-7ubuntu2)) #394 SMP PREEMPT Sat Mar 12 03:09:55 CST 2022
安装最新版本的smartdns.1.2022.04.05-2046.aarch64-openwrt-all 时候有报错
Multiple packages (libgcc1 and libgcc1) providing same name marked HOLD or PREFE R. Using latest. Multiple packages (libgcc1 and libgcc1) providing same name marked HOLD or PREFE R. Using latest. Multiple packages (libpthread and libpthread) providing same name marked HOLD or PREFER. Using latest. Installing smartdns (1.2022.04.05-2046) to root... Multiple packages (libpthread and libpthread) providing same name marked HOLD or PREFER. Using latest. Configuring smartdns. Collected errors:
- resolve_conffiles: Existing conffile /etc/config/smartdns is different from t he conffile in the new package. The new conffile will be placed at /etc/config/s martdns-opkg.
- resolve_conffiles: Existing conffile /etc/smartdns/custom.conf is different f rom the conffile in the new package. The new conffile will be placed at /etc/sma rtdns/custom.conf-opkg.
更新到最新版本后安装正常
| 软件包名称 | 版本 |
|---|---|
| libgcc1 | 11.2.0-4 |
| -- | -- |
| libpthread | 1.2.3-4 |
重现步骤
-
上游DNS配置。
-
访问的域名。
信息收集
- 将/var/log/smrtdns.log日志作为附件上传。
- 如进程异常,请将coredump功能开启,上传coredump信息文件。
在自定义界面,开启设置->自定义设置->生成coredump配置,重现问题后提交coredump文件 coredump文件在/tmp目录下
看日志是smartdns无法链接到上游服务器。
你检查下网络是否通。
安装最新版本的smartdns.1.2022.04.05-2046.aarch64-openwrt-all 时候有报错
这里是说之前的版本没有卸载,配置文件存在,保留了以前的配置。没有报错。
上游服务器设置成加密的链接后例如:(dns.pub/dns-query、dns.google/dns-query ),则会一直报错查询不到。
猜测是查询循环了。smartdns需要先将dns.pub dns.google解析出ip才能连接。或者请在配置文件中直接指定使用ip连接上游
看日志是无法链接到智能服务器。
你检查下网络是否通。
网络是正常的
安装最新版本的smartdns.1.2022.04.05-2046.aarch64-openwrt-all 时候有报错这里是说之前的版本没有卸载,配置文件存在,保留了以前的配置。没有报错。
上游服务器设置成加密的链接后例如:(dns.pub/dns-query、dns.google/dns-query ),则会一直报错查询不到。猜测是人才循环。smartdns需要先将dns.pub dns.google解析出ip连接查询。或者请在配置中直接指定使用ip连接文件绕了过去
是的,上游服务器使用指定的IP格式是没有问题的,那么说的话smartdns不能使用加密的https之类的链接格式指定上游服务器是吧
那么说的话smartdns不能使用加密的https之类的链接格式指定上游服务器是吧
可以,但你需要确保smartdns自身知道dns.pub之类的上游域名对应的是哪个ip。参考#887
我也遇到了相同的错误,自己解决了。原因就是你的dns分组有cn和us,所有的上游dns全都分到了2个组里面,但是default组里面一个上游dns都没有,才会报total server number 0的错误,只需要添加一个没有指定group的dns就不会报错了。
我发现好像所有分组的dns请求都会发一份到default组,要不然也不会有这个报错,是一个bug么?
更新: https://github.com/pymumu/smartdns/issues/836 找到了上面的issue,还是open状态,根源就在于上面的issue,不光是缓存走了default组,其实正常的请求也有一份走了default组,cn组和us组其实是正常运行的。
最新版本验证,有问题reopen issue