Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Forcing different DNS Servers with different clients on LAN

    Scheduled Pinned Locked Moved DHCP and DNS
    2 Posts 2 Posters 2.6k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M Offline
      matthackett
      last edited by

      Hello,
      I have recently setup my first pfSense firewall/router, and am learning as I go along. My networking fundamentals are cursory at best.

      I've been having trouble forcing different machines on my LAN to use specific DNS servers. I initially setup pfSense using two OpenDNS servers in System>General, and everything seemed to work as normal. Then I added an OpenVPN gateway (Private Internet Access) which I have successfully routed traffic from two clients through.

      What I want to do is use the DNS servers that Private Internet Access provides for those two clients (which use the VPN gateway), while using the OpenDNS servers for everything else. I have tried adding the PIA DNS servers to System>General and changing the DNS servers to specific gateways, but whenever I do a DNSLeakTest the responses always seem to be from both sets of DNS Servers. Is this because this gateway option is for actual multi-WAN setups, and not a virtual gateway that is still using my single WAN to access the internet?

      Do I need to somehow setup firewall rules to specify certain DNS servers for specific clients' IP addresses?

      I'm using pfSense 2.2.2, with (I think) fairly default settings. I'm happy to post screenshots of any relevant settings when I'm home from work this evening.

      Any help would be greatly appreciated!

      Matt

      1 Reply Last reply Reply Quote 0
      • DerelictD Offline
        Derelict LAYER 8 Netgate
        last edited by

        Set static mappings in the DHCP server for those two MAC addresses.  You can set specific DNS servers there.

        Chattanooga, Tennessee, USA
        A comprehensive network diagram is worth 10,000 words and 15 conference calls.
        DO NOT set a source address/port in a port forward or firewall rule unless you KNOW you need it!
        Do Not Chat For Help! NO_WAN_EGRESS(TM)

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.