Multiple domain in DHCP Server and same network

Hi,
Is there a way to add more domains in a single subnet?

I want to add multiple suffixes where I ping a device like PC1 it returns PC1.dnssuffix1 and if I ping PC2 to return PC2.dnssuffix2
On the DNS I already added PC1.dnssuffix1 and PC2.dnssuffix2 and its IP, but it doesn’t respond to ping to PC2 unless I type the full domain name PC2.dnssuffix2 as expected since the configuration was made on DHCP server only with one domain, dnssuffix1.

So, any way to add multiple domains under same subnet/gateway?
Thank you.

It seems you have to construct DHCP option 119 manually.

This thread shows how to do it (success post is near the end of thread): http://forum.mikrotik.com/t/search-domain-dhcp-option-119-not-working/143324/1

There are number of DHCP code 119 encoders, this one also shows ROS config code: https://jjjordan.github.io/dhcp119/

At the end of the day it might not work for certain types of DHCP clients … the rule is that if client doesn’t request certain option, then ROS DHCP server will not provide it.

Thanks,
Will try that out and come back if I succeed.

Wow, that link was really helpful and it worked like a charm what I wanted!
Thanks! I need to read the documentation for code 119 to understand why the hex starts with 0x07 in my case.

Hi,
I have another problem. I created 2 DNS options with both code 119 and value “0x0B’homenetwork’0x00” and “0x10’otherhomenetwork’0x00”
However if I set both DHCP options as per screenshot it will only read the first one, DNS1 but not the other one. If I reverse the order it will read only DNS2 and not DNS1

Every change I do I always do on PC the following commands
ipconfig /renew
ipconfig /flushdns
ping

If I check my interface with ipconfig /all I see only these info:

Wireless LAN adapter Wi-Fi:

Connection-specific DNS Suffix . : homenetwork
Connection-specific DNS Suffix Search List :
homenetwork

On the connection-specific DNS Suffix Search List should’nt appear both Domains?

How to force the DHCP options to take it both domains?
dhcp options.png

You can only use single option of same value in DHCP config, i.i. single option 119. But you can set multiple search domains in single setting. The option calculator I linked allows to do that …

Ahhh, right!
That’s even better. Many thanks again!