Community discussions

MikroTik App
 
edys
just joined
Topic Author
Posts: 15
Joined: Mon Dec 31, 2018 12:52 pm

Local address make it public

Thu Apr 04, 2019 12:47 pm

Hello,

I have a situation like this :
- 192.168.0.1 - hap ac mikrotik router (ppoe connection )
- 192.168.0.5 - Synology NAS

On the synology nas i instaled dns server, i put my registered domain there . The problem apears when i just wana make nameservers for my site, request me and ip address. Its posible to make an local ip address dono 192.168.0.250 to take my public ip to dont change it everytime. Right now the i have 2 nat rules to dnsnat from ppoe connection to 192.168.0.5 on ports 80 and 443.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: Local address make it public

Thu Apr 04, 2019 5:06 pm

Same way as you forward ports for web server, you can forward ports for dns server. But I don't think that running own authoritative server this way is a good idea. Is it what you're trying to do, right?
 
Vacadeluna
newbie
Posts: 38
Joined: Mon Apr 01, 2019 9:15 pm

Re: Local address make it public

Thu Apr 04, 2019 5:10 pm

Are you talking about your ISPs public address changing that they assign to you?

If you are, I would purchase a domain elsewhere, and point your domain to your DNS server. BUT, I would also use a free ddns (or paid) account, and then you can use your web server to redirect to the domain you want to use. I use no-ip.com and they have a tool that constantly updates your public IP, and you can use that ddns address instead of your public IP.
 
edys
just joined
Topic Author
Posts: 15
Joined: Mon Dec 31, 2018 12:52 pm

Re: Local address make it public

Thu Apr 04, 2019 9:14 pm

Same way as you forward ports for web server, you can forward ports for dns server. But I don't think that running own authoritative server this way is a good idea. Is it what you're trying to do, right?
Thanks for reply,

I have an dns provided by my provider, but dns server on the nas allows me to put only ip address (not dns). my public ip address is dynamic, so i cannot put the public one. i just wana put on the dns server an local ip address and refresh automatically (on ddwrt i think its called dmz),because if i put my public address all the time i need to change it(if its local one no needed). i hope i was clear enough because i dono how to explain :D
 
edys
just joined
Topic Author
Posts: 15
Joined: Mon Dec 31, 2018 12:52 pm

Re: Local address make it public

Thu Apr 04, 2019 9:18 pm

Are you talking about your ISPs public address changing that they assign to you?

If you are, I would purchase a domain elsewhere, and point your domain to your DNS server. BUT, I would also use a free ddns (or paid) account, and then you can use your web server to redirect to the domain you want to use. I use no-ip.com and they have a tool that constantly updates your public IP, and you can use that ddns address instead of your public IP.
Thanks for reply
i have dns provided by my provider, i have my own domain and i just wana use it on my nas. for what i need its ok. i dont have an host for it, that s why i need that dns server on my nas. i wana put the local ip address instead put the public one (because all the time i need to change it). the no-ip i think dont provides me cname,ns,a . i just wana host it on my nas and i dono how to make the local ip address to take the public address just in local network to refresh automatically
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: Local address make it public

Thu Apr 04, 2019 9:54 pm

I'm getting confused. Can you explain what exactly are you trying to do? I mean some "big picture" explanation.

Is it possible that you don't really need external dns server at all, and you'd be satisfied with what you can do on router? Specifically something like:
/ip dns static
add address=192.168.88.10 name=www.example.net
Just a guess...
 
edys
just joined
Topic Author
Posts: 15
Joined: Mon Dec 31, 2018 12:52 pm

Re: Local address make it public

Fri Apr 05, 2019 2:00 pm

I'm getting confused. Can you explain what exactly are you trying to do? I mean some "big picture" explanation.

Is it possible that you don't really need external dns server at all, and you'd be satisfied with what you can do on router? Specifically something like:
/ip dns static
add address=192.168.88.10 name=www.example.net
Just a guess...
What settings should make on the router to have something like in the picture.
You do not have the required permissions to view the files attached to this post.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: Local address make it public

Fri Apr 05, 2019 2:33 pm

That's not what I meant. I still don't understand what's the ultimate goal of this. You want external IP address in internal DNS, but the question is what you're trying to solve with this? You left out the whole thought process between the original problem and decision that running own DNS server on NAS would be the solution. Maybe it is, maybe it isn't, it's hard to say without knowing where you're going with this.
 
edys
just joined
Topic Author
Posts: 15
Joined: Mon Dec 31, 2018 12:52 pm

Re: Local address make it public

Fri Apr 05, 2019 3:04 pm

That's not what I meant. I still don't understand what's the ultimate goal of this. You want external IP address in internal DNS, but the question is what you're trying to solve with this? You left out the whole thought process between the original problem and decision that running own DNS server on NAS would be the solution. Maybe it is, maybe it isn't, it's hard to say without knowing where you're going with this.
I just wana host my site on my Nas, and i dont know how to do it, only to make my own dns server.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: Local address make it public

Fri Apr 05, 2019 6:13 pm

In that case, the easiest solution for problem with dynamic address is to use built-in DDNS in RouterOS. Go to IP->Cloud and check "DDNS Enabled". It will give you hostname like xxxxxxxx.sn.mynetname.net, which is not exactly pretty, but it will be automatically updated to point to current public address.

If you have public domain name, you don't need to (and in this case shouldn't) run your own DNS servers. Use servers provided by domain registrar. Add new CNAME record for selected hostname (e.g. www.yourdomain.tld) and point it to xxxxxxxx.sn.mynetname.net. And anyone using www.yourdomain.tld will get your current public address.

If you want to only experiment with this using local domain, you can do the same, but it will work only for you and nobody else.