paopaodns不工作 nslookup google or baidu直接超时。
xuezbot opened this issue · comments
ports:
- "53:53/udp"
- "53:53/tcp"
- "5304:5304/ucp"
- "5304:5304/tcp"
- "7889:7889/tcp"
再就是示例里面先进的ucp协议。
抱歉是我粘贴错误了,这里应该是udp。关于DNS不工作你可以提供更多信息吗?比如启动日志。
如果可以的话,更推荐macvlan运行,macvlan不用映射端口,因为之前大家用macvlan的比较多所以没留意到这里粘贴错了。。。
或者你可以在容器内执行debug.sh
,贴出日志,或者在这里提出issue https://github.com/kkkgo/PaoPaoDNS/issues
抱歉是我粘贴错误了,这里应该是udp。关于DNS不工作你可以提供更多信息吗?比如启动日志。
搞了半天一时间忘了日志这东西。
=====PaoPaoDNS docker start=====
images build time : 2023-05-28 15:17:55 UTC
New version install ! Try clean...
sh: error setting limit: Operation not permitted
ulimit:524288
total used free shared buff/cache available
Mem: 7779 4230 993 236 2556 3008
Swap: 0 0 0
total used free shared buff/cache available
Mem: 7.6G 4.1G 991.2M 235.9M 2.5G 2.9G
Swap: 0 0 0
MEMSIZE:3001
====ENV TEST====
MEM:220m 450m 500000 750mb
prefPC:68
CORES:4
POWCORES:4
ulimit :524288
FDLIM :4096
TZ:Asia/Shanghai
UPDATE:weekly
DNS_SERVERNAME:PaoPaoDNS
SERVER_IP:10.0.1.6
ETHIP:172.19.0.3
DNSPORT:53
SOCKS5:"10.0.1.1:1084"
CNAUTO:yes
IPV6:yes
CNFALL:yes
CUSTOM_FORWARD:"10.0.1.8:53"
AUTO_FORWARD:yes
AUTO_FORWARD_CHECK:yes
CN_TRACKER:yes
USE_HOSTS:no
HTTP_FILE:yes
SAFEMODE:
====ENV TEST====
2023-05-29T16:12:49.975+0800 INFO working directory changed {"path": "/tmp"}
Error: fail to load config, failed to read config: While parsing config: yaml: line 52: did not find expected key
2023-05-29T16:12:49.976+0800 FATAL fail to load config, failed to read config: While parsing config: yaml: line 52: did not find expected key
bind: No such file or directory
PID USER TIME COMMAND
Setting up watches.
Watches established.
1 root 0:00 {init.sh} /bin/sh /usr/sbin/init.sh
19 root 0:00 crond
96 root 0:00 dnscrypt-proxy -config /data/dnscrypt-resolvers/dnscrypt.toml
102 root 0:00 unbound -c /tmp/unbound_raw.conf -p
111 root 0:00 {data_update.sh} /bin/sh /usr/sbin/data_update.sh
114 root 0:00 {watch_list.sh} /bin/sh /usr/sbin/watch_list.sh
115 root 0:00 {watch_list.sh} /bin/sh /usr/sbin/watch_list.sh
116 root 0:00 ps
117 nobody 0:00 mini_httpd -d /data -p 7889 -r
118 root 0:00 unbound -c /tmp/unbound_forward.conf -p
122 root 0:00 inotifywait -e modify /etc/unbound/named.cache
123 root 0:00 {watch_list.sh} /bin/sh /usr/sbin/watch_list.sh
124 root 0:00 unbound -c /tmp/unbound_raw.conf -p
Setting up watches.
Watches established.
125:C 29 May 2023 16:12:50.044 # systemd supervision requested or auto-detected, but Redis is compiled without libsystemd support!
125:C 29 May 2023 16:12:50.069 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
125:C 29 May 2023 16:12:50.070 # Redis version=7.0.11, bits=64, commit=00000000, modified=0, pid=125, just started
125:C 29 May 2023 16:12:50.070 # Configuration loaded
125:M 29 May 2023 16:12:50.076 # Server initialized
125:M 29 May 2023 16:12:50.077 # WARNING Memory overcommit must be enabled! Without it, a background save or replication may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
看起来是你的/data/mosdns.yaml
有问题,你是否对这个文件进行过修改?
没有,52行是 #customforward-seted upstreams: 这个注释,整体如下
log:
file: ""
level: error
plugins:
#usehosts-yes - tag: "usehosts"
#usehosts-yes type: "hosts"
#usehosts-yes args:
#usehosts-yes#serverip-enable entries:
#usehosts-yes#serverip-enable - "paopao.dns {SERVER_IP}"
#usehosts-yes#usehosts-enable files:
#usehosts-yes#usehosts-enable - "/tmp/hosts.txt"
-
tag: "force_cn_list"
type: "domain_set"
args:
files:
- "/data/force_cn_list.txt"
#cntracker-yes - "/tmp/cn_tracker_list.txt" -
tag: "force_nocn_list"
type: "domain_set"
args:
files:
- "/data/force_nocn_list.txt"
#customforward-seted - tag: "force_forward_list"
#customforward-seted type: "domain_set"
#customforward-seted args:
#customforward-seted files:
#customforward-seted - "/data/force_forward_list.txt"
#cnfall - tag: cn_test
#cnfall type: forward
#cnfall args:
#cnfall concurrent: 3
#cnfall upstreams:
#cnfall - addr: "udp://127.0.0.1:5301"
#cnfall - addr: "udp://223.5.5.5"
#cnfall - addr: "udp://119.29.29.29"
- tag: local_unbound
type: forward
args:
upstreams:
- addr: "udp://127.0.0.1:5301"
#customforward-seted - tag: force_forward
#customforward-seted type: forward
#customforward-seted args:
#customforward-seted upstreams:
#customforward-seted - addr: "udp://{CUSTOM_FORWARD}"
-
tag: forward_unbound
type: forward
args:
concurrent: 2
upstreams:
- addr: "udp://127.0.0.1:5304"
#nosocks - addr: "udp://127.0.0.1:5302"
#socksok - addr: "udp://127.0.0.1:5303" -
tag: cnip
type: mmdb
args:
file: "/data/Country-only-cn-private.mmdb" -
tag: main_sequence
type: sequence
args:
#usehosts-yes - exec: $usehosts
- matches: qtype 65
exec: reject 0
- matches:
#ipv6ok - qname $force_nocn_list
- qtype 28
exec: reject 0
- matches:
- "!qtype 1 2 5 28 15 16 33 6 99"
exec: $local_unbound
- matches: has_wanted_ans
exec: accept
#customforward-seted - matches: qname $force_forward_list
#customforward-seted exec: $force_forward
#customforward-seted - matches: qname $force_forward_list
#customforward-seted exec: accept
- matches: qname $force_nocn_list
exec: $forward_unbound
- matches: qname $force_nocn_list
exec: accept
- matches: qname $force_cn_list
exec: $local_unbound
- matches: qname $force_cn_list
exec: accept
#cnfall - exec: cache 1024
#cnfall - matches: has_wanted_ans
#cnfall exec: accept
#nofall - exec: $local_unbound
#cnfall - exec: $cn_test
- matches:
- "!qtype 1 28"
- has_wanted_ans
exec: accept
- matches: resp_ip_mmdb $cnip CN
exec: accept
- exec: drop_resp
#ipv6ok - exec: prefer_ipv4
#autoforward-yes#autoforward-check - exec: $forward_unbound
#autoforward-yes#autoforward-check - matches: resp_ip_mmdb $cnip PRIVATE
#autoforward-yes#autoforward-check exec: accept
#autoforward-yes#autoforward-check - matches: has_wanted_ans
#autoforward-yes#autoforward-check exec: $force_forward
#autoforward-yes#autoforward-check - matches: has_wanted_ans
#autoforward-yes#autoforward-check exec: accept
#autoforward-yes#autoforward-nocheck - exec: $force_forward
#autoforward-yes#autoforward-nocheck - matches: has_wanted_ans
#autoforward-yes#autoforward-nocheck exec: accept
#autoforward-no - exec: $forward_unbound
#autoforward-no - matches: has_wanted_ans
#autoforward-no exec: accept
- exec: reject 0 -
tag: udp_server
type: udp_server
args:
entry: main_sequence
listen: :53 -
tag: "tcp_server"
type: "tcp_server"
args:
entry: main_sequence
listen: :53
idle_timeout: 5
一旦我在docker-compose里面把如下参数加上就不能正常使用了
- CN_TRACKER=yes
- USE_HOSTS=no
- SERVER_IP=10.0.1.6
- CUSTOM_FORWARD="10.0.1.8:53"
- AUTO_FORWARD=yes
- AUTO_FORWARD_CHECK=yes
- HTTP_FILE=yes
谢谢你的反馈,很有可能是容器启动脚本的问题,我先排查一下,尽快修复。
你试试把- CUSTOM_FORWARD="10.0.1.8:53"改成- CUSTOM_FORWARD=10.0.1.8:53 看看。
存在一个引号处理的问题,下个版本修复。
谢谢,正常了,tg的IP是指向这个paopao网关吗?
是的,tg的是走IP直连,你把tg的IP段(网上可以搜到)静态路由到ppgw即可。
最新版本镜像已修复。