Portál AbcLinuxu, 4. května 2025 15:41
dnsmasq
.
root@router:~# /etc/init.d/dnsmasq start root@router:~# ping www.nic.cz ping: bad address 'www.nic.cz' root@router:~# /etc/init.d/dnsmasq restart udhcpc: started, v1.28.3 udhcpc: sending discover udhcpc: no lease, failing root@router:~# ping www.nic.cz ping: bad address 'www.nic.cz'přičem výpis
ps
mi nevypíše dnsmasq. konfigurace v /etc/config/dhcp
je standardní podle openwrt dokumentace
root@router:~# cat /etc/config/dhcp config dnsmasq option localise_queries '1' option expandhosts '1' option authoritative '1' option readethers '1' option leasefile '/tmp/dhcp.leases' option resolvfile '/tmp/resolv.conf.auto' option localservice '1' option nonwildcard '0' option domain 'doma' option dnssec '1' option filterwin2k '1' option rebind_protection '0' option local 'doma' config dhcp 'lan' option interface 'lan' option start '256' option limit '150' option leasetime '12h' option dhcpv6 'server' option ra 'server' config dhcp 'wan' option interface 'wan' option ignore '1' config host option name 'xxxxx' option dns '1' option mac '70:85:c2:xxxxx' option ip '10.0.0.10' option hostid 'aa10' . . .při spuštění přímo
dnsmasq
server nastartuje a na dotazy ze sítě odpovídá (ale neodpovídá na localhostu).
Server odhcpd
funguje a dodává IPv6 adresy, ale dnsmasq
nedodává ani IPv4 do lokální sítě. Takže moje otázka je jak zjistit, co je špatně? Před aktualizací vše fungovalo.
Řešení dotazu:
nslookup www.nic.cz Server: 10.0.0.140 Address: 10.0.0.140#53 ** server can't find www.nic.cz: REFUSEDadresa 10.0.0.140 je lokální adresa routeru. Takže
dnsmasq
nefunguje mi nijak (ani DHCP ani DNS)
opkg install ncat Unknown package 'ncat'. Collected errors: * opkg_install_cmd: Cannot install package ncat.Také jsem zkusil scany na porty a DHCP port tam není. TCP
nmap 10.0.0.140 Starting Nmap 7.70 ( https://nmap.org ) at 2018-09-16 18:32 CEST Nmap scan report for 10.0.0.140 Host is up (0.00042s latency). Not shown: 997 closed ports PORT STATE SERVICE 22/tcp open ssh 53/tcp open domain 80/tcp open http Nmap done: 1 IP address (1 host up) scanned in 47.27 secondsUDP
sudo nmap -sU 10.0.0.140 Starting Nmap 7.70 ( https://nmap.org ) at 2018-09-16 19:20 CEST Nmap scan report for 10.0.0.140 Host is up (0.00036s latency). Not shown: 998 closed ports PORT STATE SERVICE 53/udp open domain 123/udp open ntp MAC Address: 30:B5:C2:xxx (Tp-link Technologies) Nmap done: 1 IP address (1 host up) scanned in 1072.71 seconds
Tiskni
Sdílej:
ISSN 1214-1267, (c) 1999-2007 Stickfish s.r.o.