目前是光猫桥接软路由播号, 试过以下方案:
1
neroxps 2023-06-21 09:29:38 +08:00
openwrt 是用 dnsmasq 代理的,所以本机 nslookup 就是 127.你得看 dnsmasq 的上游 dns ,命令行是 uci show dhcp
|
2
Jobin0528 OP @neroxps #1
``` root@OpenWrt:~# uci show dhcp dhcp.@dnsmasq[0]=dnsmasq dhcp.@dnsmasq[0].localise_queries='1' dhcp.@dnsmasq[0].rebind_localhost='1' dhcp.@dnsmasq[0].local='/lan/' dhcp.@dnsmasq[0].domain='lan' dhcp.@dnsmasq[0].expandhosts='1' dhcp.@dnsmasq[0].authoritative='1' dhcp.@dnsmasq[0].readethers='1' dhcp.@dnsmasq[0].leasefile='/tmp/dhcp.leases' dhcp.@dnsmasq[0].localservice='1' dhcp.@dnsmasq[0].resolvfile='/tmp/resolv.conf.d/resolv.conf.auto' dhcp.@dnsmasq[0].rebind_protection='1' dhcp.@dnsmasq[0].domainneeded='1' dhcp.lan=dhcp dhcp.lan.interface='lan' dhcp.lan.start='100' dhcp.lan.limit='150' dhcp.lan.leasetime='12h' dhcp.lan.dynamicdhcp='0' dhcp.lan.ignore='1' dhcp.wan=dhcp dhcp.wan.interface='wan' dhcp.wan.start='100' dhcp.wan.leasetime='12h' dhcp.wan.limit='150' dhcp.wan.dynamicdhcp='0' dhcp.wan.ignore='1' dhcp.odhcpd=odhcpd dhcp.odhcpd.maindhcp='0' dhcp.odhcpd.leasefile='/tmp/hosts/odhcpd' dhcp.odhcpd.leasetrigger='/usr/sbin/odhcpd-update' dhcp.odhcpd.loglevel='4' dhcp.@domain[0]=domain dhcp.@domain[0].name='openwrt.local' dhcp.@domain[0].ip='10.110.0.1' ``` |
3
titanium98118 2023-06-21 09:40:24 +08:00
@Jobin0528 #2 resolvfile='/tmp/resolv.conf.d/resolv.conf.auto'
|
4
Jobin0528 OP |
5
wonderblank 2023-06-27 17:55:42 +08:00
```
root@main:~# ifstatus wan | jq -r '."dns-server"[]' 58.240.57.33 221.6.4.66 ``` |