Community discussions

MikroTik App
 
bes
just joined
Topic Author
Posts: 20
Joined: Fri Feb 24, 2006 10:01 pm

/ip dns static not work

Wed Mar 15, 2006 10:08 pm

Hi,not work dns static
[admin@juri] ip dns> pri
primary-dns: 212.59.0.1
secondary-dns: 195.14.170.14
allow-remote-requests: yes
cache-size: 10240KiB
cache-max-ttl: 1w
cache-used: 20KiB
And
[admin@juri] ip dns static> pri
Flags: D - dynamic
# NAME ADDRESS TTL
0 http://www.takas.lt 192.168.3.2 1d
Opening http://www.takas.lt and not works forward to 192.168.3.2
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6630
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Thu Mar 16, 2006 8:28 am

you have to be sure, that router client uses Router DNS as primary dns server configuration,

Redirect NAT rules might be added to forward DNS requests from clients directly to the router, than router DNS cache will be used despite of client PC configuration .
 
User avatar
mag
Member
Member
Posts: 378
Joined: Thu Jul 01, 2004 12:32 pm
Location: Cologne, NRW, Germany
Contact:

Thu Mar 16, 2006 8:18 pm

i am trying to use this, but to no success. maybe someone could correct me.

using this rule:
add chain=dstnat in-interface=lan dst-port=53 action=redirect to-ports=53
gets
Flags: X - disabled, I - invalid, D - dynamic 
 0   ;;; redirect DNS-requests
     chain=dstnat in-interface=lan dst-port=53 action=redirect to-ports=53 
dig gives me, for example:
dig @192.168.255.3 www.microsoft.de

; <<>> DiG 9.2.2 <<>> @192.168.255.3 www.microsoft.de
;; global options:  printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 43368
;; flags: qr rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;www.microsoft.de.              IN      A

;; ANSWER SECTION:
www.microsoft.de.       1428    IN      CNAME   microsoft.de.
microsoft.de.           1428    IN      A       207.46.130.108
microsoft.de.           1428    IN      A       207.46.250.119
which is ok, but in a web-browser i can't open any page on the internet.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6630
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Thu Mar 16, 2006 11:30 pm

Protocols have to be specified for NAT rules too, protocol=tcp and second for protocol=udp.
 
User avatar
mag
Member
Member
Posts: 378
Joined: Thu Jul 01, 2004 12:32 pm
Location: Cologne, NRW, Germany
Contact:

Fri Mar 17, 2006 9:24 am

thx. this one makes it:
add chain=dstnat in-interface=lan protocol=tcp dst-port=53 action=redirect to-ports=53 
add chain=dstnat in-interface=lan protocol=udp dst-port=53 action=redirect to-ports=53 

Who is online

Users browsing this forum: Baidu [Spider], Bing [Bot], Dsmoro and 85 guests