Avahi mDNS 在队列中被阻止

Avahi mDNS 在队列中被阻止

我在arm64嵌入式设备(Ubuntu 20.04.6)上运行avahi-daemon 0.8。如果我在浏览器中直接使用 IP 访问设备,最大加载时间为 2 毫秒,但如果使用我创建的带有“.local”域的主机名,它会在阻止部分中停留很长时间,并且仅在一定时间后才会出现。这是 Windows 中 Firefox 中计时的屏幕截图 来自开发者控制台的计时

另外,我的 avahi-daemon.conf 文件:

[server]
host-name=name
domain-name=local
#browse-domains=0pointer.de, zeroconf.org
use-ipv4=yes
use-ipv6=no
#allow-interfaces=lo.IPv4, lan1.IPv4
#deny-interfaces=eth1
#check-response-ttl=no
#use-iff-running=no
#enable-dbus=yes
#disallow-other-stacks=no
allow-point-to-point=yes
#cache-entries-max=4096
#clients-max=4096
#objects-per-client-max=1024
#entries-per-entry-group-max=32
ratelimit-interval-usec=1000000
ratelimit-burst=1000

[wide-area]
enable-wide-area=no

[publish]
#disable-publishing=yes
#disable-user-service-publishing=no
#add-service-cookie=no
#publish-addresses=yes
#publish-hinfo=no
#publish-workstation=no
#publish-domain=no
#publish-dns-servers=
#publish-resolv-conf-dns-servers=yes
#publish-aaaa-on-ipv4=yes
#publish-a-on-ipv6=no

[reflector]
#enable-reflector=no
#reflect-ipv=no
#reflect-filters=_airplay._tcp.local,_raop._tcp.local

[rlimits]
#rlimit-as=
#rlimit-core=0
#rlimit-data=8388608
#rlimit-fsize=0
#rlimit-nofile=768
#rlimit-stack=8388608
#rlimit-nproc=3

我的意思是.local作为 mDNS 域。这也是/etc/nsswitch.conf上下文:

passwd:         files
group:          files
shadow:         files
gshadow:        files

hosts:          files mymachines dns myhostname
networks:       files

protocols:      db files
services:       db files
ethers:         db files
rpc:            db files

netgroup:       nis

相关内容