Community discussions

MikroTik App
 
iantull
just joined
Topic Author
Posts: 5
Joined: Wed Mar 01, 2023 12:32 am

Allowing 2 IP addresses to point to a different DNS

Wed Mar 01, 2023 12:44 am

I'm new to Mikrotik and would like some help.
I have 2 internal IP's allocated from my pool that have been made static, I now want those 2 IP addresses to point to a different internal DNS rather than the external DNS entry, is this possible ?

To expand on my problem and what I'm trying to achieve, I have some IOT devices that have hardcoded fqdn entries in them, when they connect, rather than be directed to the external fqdn server, I need them to be directed to an internal server, so any internal device that is looking for this particular url, will be directed to an internal ip address.
 
Sob
Forum Guru
Forum Guru
Posts: 9119
Joined: Mon Apr 20, 2009 9:11 pm

Re: Allowing 2 IP addresses to point to a different DNS

Sun Mar 05, 2023 5:01 am

You can do something like this:
/ip dhcp-server network
add address=192.168.88.0/24 dns-server=192.168.88.1 gateway=192.168.88.1
add address=192.168.88.100/32 dns-server=192.168.123.45 gateway=192.168.88.1 netmask=24
First is defaults for subnet and second is different config for single device (192.168.88.100 for which you have static lease).
 
User avatar
baragoon
Member Candidate
Member Candidate
Posts: 298
Joined: Thu Jan 05, 2017 10:38 am
Location: Kyiv, UA
Contact:

Re: Allowing 2 IP addresses to point to a different DNS

Sun Mar 05, 2023 8:40 am

Use dhcp-option for specific address with specific dns server in the static lease.

Who is online

Users browsing this forum: Google [Bot], menyarito, mkx, tesme33 and 38 guests