1

Temat: Relayd dns

Witam
Skonfigurowałem drugi router jako relayd. Komputery podłączone do niego kablem mają internet. Wszystko działa tak jak trzeba za wyjątkiem jednej rzeczy. Po zalogowaniu się do drugiego routera przez ssh pingi działają tylko na adres ip. Rozumiem że problem jest z dns-em. Pytanie - gdzie ustawić dns? Po wprowadzeniu dns-a (np. 8.8.8.8) do interfejsu LAN sytuacja się nie zmienia.
Proszę o radę.

2

Odp: Relayd dns

Jeżeli wifi dostaje adres po dhcp to na nim (wwan) a nie lanie.

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

3 (edytowany przez khain 2016-12-13 22:13:18)

Odp: Relayd dns

Mam taki sam problem i nie udało mi się go rozwiązać. Gdy włączę daemona dnsmasq to router nie dostaje odpowiedzi z serwera DNS, którym jest drugi router a plik /etc/resolv.conf ma wpis:

nameserver 127.0.0.1

Gdy go wyłączę to jest ok, a wpis w /etc/resolv.conf zmienia się na prawidłowy:

# Interface wwan
nameserver 192.168.12.100
uci show network
network.wwan=interface
network.wwan.proto='static'
network.wwan.ipaddr='192.168.12.200'
network.wwan.netmask='255.255.255.0'
network.wwan.gateway='192.168.12.100'
network.wwan.dns='192.168.12.100'
network.stabridge=interface
network.stabridge.proto='relay'
network.stabridge.network='lan wwan'
network.stabridge.ipaddr='192.168.12.200'
network.stabridge.dns='192.168.12.100'
network.wan=interface
network.wan.ifname='eth0.2'
network.wan.proto='dhcp'
network.wan6=interface
network.wan6.ifname='eth0.2'
network.wan6.proto='dhcpv6'
network.@switch[0]=switch
network.@switch[0].name='switch0'
network.@switch[0].reset='1'
network.@switch[0].enable_vlan='1'
network.@switch_vlan[0]=switch_vlan
network.@switch_vlan[0].device='switch0'
network.@switch_vlan[0].vlan='1'
network.@switch_vlan[0].ports='0t 2 3 4 5'
network.@switch_vlan[1]=switch_vlan
network.@switch_vlan[1].device='switch0'
network.@switch_vlan[1].vlan='2'
network.@switch_vlan[1].ports='0t 1'

uci show dhcp
dhcp.@dnsmasq[0]=dnsmasq
dhcp.@dnsmasq[0].domainneeded='1'
dhcp.@dnsmasq[0].boguspriv='1'
dhcp.@dnsmasq[0].filterwin2k='0'
dhcp.@dnsmasq[0].localise_queries='1'
dhcp.@dnsmasq[0].rebind_protection='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].nonegcache='0'
dhcp.@dnsmasq[0].authoritative='1'
dhcp.@dnsmasq[0].readethers='1'
dhcp.@dnsmasq[0].leasefile='/tmp/dhcp.leases'
dhcp.@dnsmasq[0].resolvfile='/tmp/resolv.conf.auto'
dhcp.@dnsmasq[0].localservice='0'
dhcp.@dnsmasq[0].rebind_domain='free.aero2.net.pl'
dhcp.@dnsmasq[0].server='192.168.12.100'
dhcp.lan=dhcp
dhcp.lan.interface='lan'
dhcp.lan.dhcpv6='server'
dhcp.lan.ra='server'
dhcp.lan.ignore='1'
dhcp.lan.ra_management='1'
dhcp.wan=dhcp
dhcp.wan.interface='wan'
dhcp.wan.ignore='1'
dhcp.odhcpd=odhcpd
dhcp.odhcpd.maindhcp='0'
dhcp.odhcpd.leasefile='/tmp/hosts/odhcpd'
dhcp.odhcpd.leasetrigger='/usr/sbin/odhcpd-update'
TP-Link TL-WDR3600 v1.5 -  OpenWrt Chaos Calmer 15.05.1 with Luci +Microsoft LifeCam VX-3000
RaspberryPi 2 - OMV Stone Burner 2.0.15 +Creative SB Play +Medion OR24V +DVB-T Media-Tech MT4163  +MP00202AC +3xDS18B20 +HIH-4000-002 +MPXHZ6115A +Samsung SPF-85H +D-Link DUB-H7

4

Odp: Relayd dns

W /tmp/resolv.conf.auto to jest, dnsmasq robi za cache serwer i takim przypadku /etc/resolv.conf wskazuje na 127.0.0.1 właśnie.

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

5

Odp: Relayd dns

A może tu jest problem:

khain napisał/a:
dhcp.@dnsmasq[0].local='/lan/'
dhcp.@dnsmasq[0].server='192.168.12.100'

Strona https://wiki.openwrt.org/doc/uci/dhcp odsyła do man dnsmasq.
Nie mam jak tego sprawdzić w tej chwili ale

S, --local, --server=[/[<domain>]/[domain/]][<ipaddr>[#<port>][@<source-ip>|<interface>[#<port>]]
    Specify IP address of upstream servers directly. Setting this flag does not suppress reading of /etc/resolv.conf, use -R to do that. If one or more optional domains are given, that server is used only for those domains and they are queried only using the specified server. This is intended for private nameservers: if you have a nameserver on your network which deals with names of the form xxx.internal.thekelleys.org.uk at 192.168.1.1 then giving the flag -S /internal.thekelleys.org.uk/192.168.1.1 will send all queries for internal machines to that nameserver, everything else will go to the servers in /etc/resolv.conf. DNSSEC validation is turned off for such private nameservers, UNLESS a --trust-anchor is specified for the domain in question. An empty domain specification, // has the special meaning of "unqualified names only" ie names without any dots in them. A non-standard port may be specified as part of the IP address using a # character. More than one -S flag is allowed, with repeated domain or ipaddr parts as required.

GUI jest przereklamowane

ASUS WL-500gP v2, TP-Link TL-MR3420 v2, TP-Link TL-WR1043ND v3, TP-Link TL-WDR4300 v1, D-Link DWR-921 C3,
Netgear R6220