<!DOCTYPE html>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p>Great thank you !</p>
    <p>
      <blockquote type="cite">➜  ~ dig -t aaaa powerdns.com @127.0.0.1
        -p 5300 +nocookie +http-plain=/dns-query <br>
        <br>
        ; <<>> DiG 9.20.15-1~deb13u1-Debian <<>>
        -t aaaa powerdns.com @127.0.0.1 -p 5300 +nocookie
        +http-plain=/dns-query<br>
        ;; global options: +cmd<br>
        ;; Got answer:<br>
        ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id:
        17379<br>
        ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1,
        ADDITIONAL: 1<br>
        <br>
        ;; OPT PSEUDOSECTION:<br>
        ; EDNS: version: 0, flags:; udp: 1232<br>
        ;; QUESTION SECTION:<br>
        ;powerdns.com.            IN    AAAA<br>
        <br>
        ;; AUTHORITY SECTION:<br>
        powerdns.com.        3600    IN    SOA   
        pdns-public-ns1.powerdns.com. peter\.van\.dijk.powerdns.com.
        2025111301 10800 3600 604800 3600<br>
        <br>
        ;; Query time: 168 msec<br>
        ;; SERVER: 127.0.0.1#5300(127.0.0.1) (HTTP)<br>
        ;; WHEN: Mon Nov 17 19:09:52 CET 2025<br>
        ;; MSG SIZE  rcvd: 108<br>
      </blockquote>
    </p>
    <p><br>
    </p>
    <p>Now that I test requests via apache reverse proxy I get errors
      like this one :</p>
    <p>
      <blockquote type="cite">[proxy_<a class="moz-txt-link-freetext" href="http:error">http:error</a>] [pid 542507:tid 542557]
        (70014)End of file found: [remote 192.168.0.254:40452] AH01102:
        error reading status line from remote server 127.0.0.1:5300</blockquote>
      <br>
    </p>
    <p>I know it's perhaps more related to Apache than dnsdist but I ask
      anyway : is it possible to use Apache to proxy requests to dnsdist
      ?</p>
    <pre class="moz-signature" cols="72">
</pre>
    <div class="moz-cite-prefix">Le 17/11/2025 à 18:11, Aman Grewal a
      écrit :<br>
    </div>
    <blockquote type="cite"
cite="mid:CANkERQppO6PcJ+SZWbo6YAjSzba_iGc7KbdO4EJ0saqOxXN9_A@mail.gmail.com">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div dir="ltr">You have to tell dig to use DoH<br>
        <br>
        `+https=/dns-query` for https<br>
        `+http-plain=/dns-query` for http</div>
      <br>
      <div class="gmail_quote gmail_quote_container">
        <div dir="ltr" class="gmail_attr">On Mon, Nov 17, 2025 at
          11:51 AM ROGER VIncent via Pdns-users <<a
            href="mailto:pdns-users@mailman.powerdns.com"
            moz-do-not-send="true" class="moz-txt-link-freetext">pdns-users@mailman.powerdns.com</a>>
          wrote:<br>
        </div>
        <blockquote class="gmail_quote"
style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
          <div>
            <p>Hi,</p>
            <p>I intend to access dnsdist via DoH with an apache reverse
              proxy, but first I can't get dnsdist respond to queries :</p>
            <p> </p>
            <blockquote type="cite">➜  ~ dig -t aaaa <a
                href="http://powerdns.com" target="_blank"
                moz-do-not-send="true">powerdns.com</a> @<a
                href="http://127.0.0.1" target="_blank"
                moz-do-not-send="true">127.0.0.1</a> -p 5300 +short
              +nocookie<br>
              ;; communications error to 127.0.0.1#5300: connection
              refused<br>
              ;; communications error to 127.0.0.1#5300: connection
              refused<br>
              ;; communications error to 127.0.0.1#5300: connection
              refused<br>
              <br>
              ; <<>> DiG 9.20.15-1~deb13u1-Debian
              <<>> -t aaaa <a href="http://powerdns.com"
                target="_blank" moz-do-not-send="true">powerdns.com</a>
              @<a href="http://127.0.0.1" target="_blank"
                moz-do-not-send="true">127.0.0.1</a> -p 5300 +short
              +nocookie<br>
              ;; global options: +cmd<br>
              ;; no servers could be reached</blockquote>
            Here is my dnsdist.conf :
            <p> </p>
            <blockquote type="cite">-- disable security status polling
              via DNS<br>
              setSecurityPollSuffix("")<br>
              <br>
              setACL("<a href="http://127.0.0.1/8" target="_blank"
                moz-do-not-send="true">127.0.0.1/8</a>")<br>
              <br>
              -- Define upstream DNS server (Pi-hole)<br>
              newServer({address="<a href="http://192.168.0.26:53"
                target="_blank" moz-do-not-send="true">192.168.0.26:53</a>",
              name="Pi2-hole", checkInterval=60, mustResolve=true})<br>
              newServer({address="<a href="http://192.168.0.24:53"
                target="_blank" moz-do-not-send="true">192.168.0.24:53</a>",
              name="Pi1-hole", checkInterval=60, mustResolve=true})<br>
              <br>
              -- Set the load balancing policy<br>
              setServerPolicy(roundrobin)<br>
              <br>
              -- Create local DOH server listener in DNS over HTTP mode,
              otherwise the information coming from nginx won't be
              processed well<br>
              addDOHLocal("<a href="http://127.0.0.1:5300"
                target="_blank" moz-do-not-send="true">127.0.0.1:5300</a>",
              nil, nil, "/dns-query", {reusePort=true,
              trustForwardedForHeader=false, keepIncomingHeaders=true})<br>
            </blockquote>
            dnsdist is listening port 5300 though :
            <p> </p>
            <blockquote type="cite">➜  ~ sudo netstat -tapn | grep 5300 
                                              <br>
              tcp        0      0 <a href="http://127.0.0.1:5300"
                target="_blank" moz-do-not-send="true">127.0.0.1:5300</a> 
                      0.0.0.0:*               LISTEN      508356/dnsdist</blockquote>
            What is my mistake here ?
            <p><br>
            </p>
            <pre cols="72">-- 
ROGER Vincent</pre>
          </div>
          _______________________________________________<br>
          Pdns-users mailing list<br>
          <a href="mailto:Pdns-users@mailman.powerdns.com"
            target="_blank" moz-do-not-send="true"
            class="moz-txt-link-freetext">Pdns-users@mailman.powerdns.com</a><br>
          <a
href="https://mailman.powerdns.com/mailman/listinfo/pdns-users"
            rel="noreferrer" target="_blank" moz-do-not-send="true"
            class="moz-txt-link-freetext">https://mailman.powerdns.com/mailman/listinfo/pdns-users</a><br>
        </blockquote>
      </div>
    </blockquote>
  </body>
</html>