Re: [Dnsmasq-discuss] How to let dnsmasq using multiple upstream dns servers with non-standard ports.

2015-09-30 Thread Simon Kelley
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256



On 30/09/15 02:02, Hongyi Zhao wrote:
> 2015-09-30 5:04 GMT+08:00 Simon Kelley :
>> On 27/09/15 04:44, Hongyi Zhao wrote:
>>> 2015-09-27 4:53 GMT+08:00 Simon Kelley
>>> :
 You can't put non-standard ports in a resolv-file, the format
 of those files does not include ports.
 
 It is possible to put a non-standard port in dnsmasq
 configuration files using
 
 server=server1#port1
 
 So simply make your file look like
 
 server=server1#port1 server=server2#port2 
 server=server3#port3 server=server4#port4
 
 call it /path/to/servers.dnsmasq
 
 and tell dnsmasq to read it as a dnsmasq configuration file.
 
 
 sudo dnsmasq -d -p 5353 -C /path/to/servers.dnsmasq
 --all-servers
>>> 
>>> According to the help of dnsmasq, it seems that the more
>>> appriate method should be using the following option to invoke
>>> the above configuration file:
>>> 
>>> --servers-file=   Specify path to file with 
>>> server= options
>>> 
>>> sudo dnsmasq -d -p 5353 --servers-file=/path/to/servers.dnsmasq
>>> --all-servers
>> 
>> Yes, that's a good way to do it.
>> 
>>> 
>>> In addition, I want to know another thing: how to control the
>>> shortest time with which I wait for the responding from these
>>> upstream dns servers.  I mean: when using `--all-servers'
>>> option, the dnsmasq will query all of these dns servers
>>> parallely and I want to use the most firstly query returned to
>>> me and then throttle the remail query for the spefific domain
>>> name.  Is this possiable?
>> 
>> The first answer returned will be the one used. I don't
>> understand the second part of your question, sorry. Could you
>> explain another way what you want to do?
> 
> Sorry for my poor english.
> 
> Let me describe it as follows:
> 
> Just as you have told me: the first answer returned will be the one
> used.
> 
> But, after the  the first answer returned, there still will be
> other query restults returned subsequently due to the parallelly
> query done by `all-servers' option.  So, how the dnsmasq deal with
> the remain ones?  Does it simply discard the remainly returned
> results?

Yes. That's exactly what it does.


Cheers,

Simon.

> 
> Regards
>> 
>> 
>> 
>> Cheers,
>> 
>> Simon.
>> 
>>> 
 
 
 
 That should do the trick.
 
 
 Cheers,
 
 Simon.
 
> 
 
 On 24/09/15 02:56, Hongyi Zhao wrote:
> Hi Simon,
> 
> I have server upstream dns servers with non-standard ports
> opening for querying, i.e., as follows:
> 
> server1:port1 server2:port2 server3:port3 server4:port4
> 
> I want to use the `--resolv-file=' option to invoking
> the file which stored the infomation for these servers.
> 
> Say, I named this file as resolv-file.dnsmasq, and its
> content has the following forms:
> 
> server server1#port1 server server2#port2 server
> server3#port3 server server4#port4
> 
> Then I use the following command to run the dnsmasq:
> 
> sudo dnsmasq -d -p 5353 -r /path/to/resolv-file.dnsmasq
> --all-servers
> 
> But, at this step, I get the following errors:
> 
> dnsmasq: no servers found in /path/to/resolv-file.dnsmasq,
> will retry
> 
> So, how to let dnsmasq using multiple upstream dns servers
> with non-standard ports?
> 
> Regards
> 
 
 
 ___ 
 Dnsmasq-discuss mailing list 
 Dnsmasq-discuss@lists.thekelleys.org.uk 
 http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>>>
>>>
>>>
>>
>
 
> 
> 
-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.22 (GNU/Linux)

iQIcBAEBCAAGBQJWDFCfAAoJEBXN2mrhkTWiIaAQAITMf8vjuZm979NPAbw5w/KM
JP9Qza0zZc4qI+6u0IpcpHgn5TZYK0OhWC+DNN6YlcJrbco3Yrz/7SSY7yOOHl6Y
eKTzwUwRRSQwLvSqJBWDtOyeeIA+1WcGwHV6EJ45B6cRrlcoNaOTzij/BcW5noKT
NiySwx2lV9YO/P6KUlvzNq6H/2g9tkNc5Pd1lJGJdcVlkYouWVso6b4xM8x6V7Tc
ORb78oPe+4/BlNufLPLAETVYBb4nAmlWfuSM9CpyphpG/CUT96uXsIkSG/SvNYmn
+dGfon9kOGTnLjKKsc74JA7UtGIOdiikLNzobSoBJR3CxdopvSidIzIgaWiP8Myg
zGMFTAVfpUiNWgO4QKhQgELn2NLjNn/ktNE11XYCaDky1Ufudg5MxIeuRghTUSRC
/fg9RwpUUv8w8eflYJ75DtEZz4VIansqAC6Wzu+/NkA7ShzWIKfoAEmCFFLs4qsJ
pfFvh1d0quKCwJnIMKI55uDwn7mRdW/s2J8PXS1hemJsNLGSTPLik1KdNtc83rKc
M+UnaG/+NxilfVc8UaM18tvoGA0qs36w1AY4bbS/t7KyU2HtdegpB96nM3p63ZA7
+aGbCn+m2VV8qypDQCk8jqP3RDERU5+nBRfwsvSaF5ceMrCVAgQFSn9KytXVyOum
EO9Z6+wMpNsiXWCq4Zyi
=fetp
-END PGP SIGNATURE-

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] How to let dnsmasq using multiple upstream dns servers with non-standard ports.

2015-09-29 Thread Simon Kelley
On 27/09/15 04:44, Hongyi Zhao wrote:
> 2015-09-27 4:53 GMT+08:00 Simon Kelley :
>> You can't put non-standard ports in a resolv-file, the format of those
>> files does not include ports.
>>
>> It is possible to put a non-standard port in dnsmasq configuration files
>> using
>>
>> server=server1#port1
>>
>> So simply make your file look like
>>
>> server=server1#port1
>> server=server2#port2
>> server=server3#port3
>> server=server4#port4
>>
>> call it /path/to/servers.dnsmasq
>>
>> and tell dnsmasq to read it as a dnsmasq configuration file.
>>
>>
>> sudo dnsmasq -d -p 5353 -C /path/to/servers.dnsmasq  --all-servers
> 
> According to the help of dnsmasq, it seems that the more appriate
> method should be using the following option to invoke the above
> configuration file:
> 
> --servers-file=   Specify path to file with
> server= options
> 
> sudo dnsmasq -d -p 5353 --servers-file=/path/to/servers.dnsmasq  --all-servers

Yes, that's a good way to do it.

> 
> In addition, I want to know another thing: how to control the shortest
> time with which I wait for the responding from these upstream dns
> servers.  I mean: when using `--all-servers' option, the dnsmasq will
> query all of these dns servers parallely and I want to use the most
> firstly query returned to me and then throttle the remail query for
> the spefific domain name.  Is this possiable?

The first answer returned will be the one used. I don't understand the
second part of your question, sorry. Could you explain another way what
you want to do?



Cheers,

Simon.

> 
>>
>>
>>
>> That should do the trick.
>>
>>
>> Cheers,
>>
>> Simon.
>>
>>>
>>
>> On 24/09/15 02:56, Hongyi Zhao wrote:
>>> Hi Simon,
>>>
>>> I have server upstream dns servers with non-standard ports opening for
>>> querying, i.e., as follows:
>>>
>>> server1:port1
>>> server2:port2
>>> server3:port3
>>> server4:port4
>>>
>>> I want to use the `--resolv-file=' option to invoking the file
>>> which stored the infomation for these servers.
>>>
>>> Say, I named this file as resolv-file.dnsmasq, and its content has the
>>> following forms:
>>>
>>> server server1#port1
>>> server server2#port2
>>> server server3#port3
>>> server server4#port4
>>>
>>> Then I use the following command to run the dnsmasq:
>>>
>>> sudo dnsmasq -d -p 5353 -r /path/to/resolv-file.dnsmasq  --all-servers
>>>
>>> But, at this step, I get the following errors:
>>>
>>> dnsmasq: no servers found in /path/to/resolv-file.dnsmasq, will retry
>>>
>>> So, how to let dnsmasq using multiple upstream dns servers with
>>> non-standard ports?
>>>
>>> Regards
>>>
>>
>>
>> ___
>> Dnsmasq-discuss mailing list
>> Dnsmasq-discuss@lists.thekelleys.org.uk
>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
> 
> 
> 


___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] How to let dnsmasq using multiple upstream dns servers with non-standard ports.

2015-09-29 Thread Hongyi Zhao
2015-09-30 5:04 GMT+08:00 Simon Kelley :
> On 27/09/15 04:44, Hongyi Zhao wrote:
>> 2015-09-27 4:53 GMT+08:00 Simon Kelley :
>>> You can't put non-standard ports in a resolv-file, the format of those
>>> files does not include ports.
>>>
>>> It is possible to put a non-standard port in dnsmasq configuration files
>>> using
>>>
>>> server=server1#port1
>>>
>>> So simply make your file look like
>>>
>>> server=server1#port1
>>> server=server2#port2
>>> server=server3#port3
>>> server=server4#port4
>>>
>>> call it /path/to/servers.dnsmasq
>>>
>>> and tell dnsmasq to read it as a dnsmasq configuration file.
>>>
>>>
>>> sudo dnsmasq -d -p 5353 -C /path/to/servers.dnsmasq  --all-servers
>>
>> According to the help of dnsmasq, it seems that the more appriate
>> method should be using the following option to invoke the above
>> configuration file:
>>
>> --servers-file=   Specify path to file with
>> server= options
>>
>> sudo dnsmasq -d -p 5353 --servers-file=/path/to/servers.dnsmasq  
>> --all-servers
>
> Yes, that's a good way to do it.
>
>>
>> In addition, I want to know another thing: how to control the shortest
>> time with which I wait for the responding from these upstream dns
>> servers.  I mean: when using `--all-servers' option, the dnsmasq will
>> query all of these dns servers parallely and I want to use the most
>> firstly query returned to me and then throttle the remail query for
>> the spefific domain name.  Is this possiable?
>
> The first answer returned will be the one used. I don't understand the
> second part of your question, sorry. Could you explain another way what
> you want to do?

Sorry for my poor english.

Let me describe it as follows:

Just as you have told me: the first answer returned will be the one used.

But, after the  the first answer returned, there still will be other
query restults returned subsequently due to the parallelly query done
by `all-servers' option.  So, how the dnsmasq deal with the remain
ones?  Does it simply discard the remainly returned results?

Regards
>
>
>
> Cheers,
>
> Simon.
>
>>
>>>
>>>
>>>
>>> That should do the trick.
>>>
>>>
>>> Cheers,
>>>
>>> Simon.
>>>

>>>
>>> On 24/09/15 02:56, Hongyi Zhao wrote:
 Hi Simon,

 I have server upstream dns servers with non-standard ports opening for
 querying, i.e., as follows:

 server1:port1
 server2:port2
 server3:port3
 server4:port4

 I want to use the `--resolv-file=' option to invoking the file
 which stored the infomation for these servers.

 Say, I named this file as resolv-file.dnsmasq, and its content has the
 following forms:

 server server1#port1
 server server2#port2
 server server3#port3
 server server4#port4

 Then I use the following command to run the dnsmasq:

 sudo dnsmasq -d -p 5353 -r /path/to/resolv-file.dnsmasq  --all-servers

 But, at this step, I get the following errors:

 dnsmasq: no servers found in /path/to/resolv-file.dnsmasq, will retry

 So, how to let dnsmasq using multiple upstream dns servers with
 non-standard ports?

 Regards

>>>
>>>
>>> ___
>>> Dnsmasq-discuss mailing list
>>> Dnsmasq-discuss@lists.thekelleys.org.uk
>>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>>
>>
>>
>



-- 
Hongyi Zhao 
Xinjiang Technical Institute of Physics and Chemistry
Chinese Academy of Sciences
GnuPG DSA: 0xD108493

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] How to let dnsmasq using multiple upstream dns servers with non-standard ports.

2015-09-26 Thread Simon Kelley
You can't put non-standard ports in a resolv-file, the format of those
files does not include ports.

It is possible to put a non-standard port in dnsmasq configuration files
using

server=server1#port1

So simply make your file look like

server=server1#port1
server=server2#port2
server=server3#port3
server=server4#port4

call it /path/to/servers.dnsmasq

and tell dnsmasq to read it as a dnsmasq configuration file.


sudo dnsmasq -d -p 5353 -C /path/to/servers.dnsmasq  --all-servers



That should do the trick.


Cheers,

Simon.

>

On 24/09/15 02:56, Hongyi Zhao wrote:
> Hi Simon,
> 
> I have server upstream dns servers with non-standard ports opening for
> querying, i.e., as follows:
> 
> server1:port1
> server2:port2
> server3:port3
> server4:port4
> 
> I want to use the `--resolv-file=' option to invoking the file
> which stored the infomation for these servers.
> 
> Say, I named this file as resolv-file.dnsmasq, and its content has the
> following forms:
> 
> server server1#port1
> server server2#port2
> server server3#port3
> server server4#port4
> 
> Then I use the following command to run the dnsmasq:
> 
> sudo dnsmasq -d -p 5353 -r /path/to/resolv-file.dnsmasq  --all-servers
> 
> But, at this step, I get the following errors:
> 
> dnsmasq: no servers found in /path/to/resolv-file.dnsmasq, will retry
> 
> So, how to let dnsmasq using multiple upstream dns servers with
> non-standard ports?
> 
> Regards
> 


___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] How to let dnsmasq using multiple upstream dns servers with non-standard ports.

2015-09-26 Thread Hongyi Zhao
2015-09-27 4:53 GMT+08:00 Simon Kelley :
> You can't put non-standard ports in a resolv-file, the format of those
> files does not include ports.
>
> It is possible to put a non-standard port in dnsmasq configuration files
> using
>
> server=server1#port1
>
> So simply make your file look like
>
> server=server1#port1
> server=server2#port2
> server=server3#port3
> server=server4#port4
>
> call it /path/to/servers.dnsmasq
>
> and tell dnsmasq to read it as a dnsmasq configuration file.
>
>
> sudo dnsmasq -d -p 5353 -C /path/to/servers.dnsmasq  --all-servers

According to the help of dnsmasq, it seems that the more appriate
method should be using the following option to invoke the above
configuration file:

--servers-file=   Specify path to file with
server= options

sudo dnsmasq -d -p 5353 --servers-file=/path/to/servers.dnsmasq  --all-servers

In addition, I want to know another thing: how to control the shortest
time with which I wait for the responding from these upstream dns
servers.  I mean: when using `--all-servers' option, the dnsmasq will
query all of these dns servers parallely and I want to use the most
firstly query returned to me and then throttle the remail query for
the spefific domain name.  Is this possiable?

>
>
>
> That should do the trick.
>
>
> Cheers,
>
> Simon.
>
>>
>
> On 24/09/15 02:56, Hongyi Zhao wrote:
>> Hi Simon,
>>
>> I have server upstream dns servers with non-standard ports opening for
>> querying, i.e., as follows:
>>
>> server1:port1
>> server2:port2
>> server3:port3
>> server4:port4
>>
>> I want to use the `--resolv-file=' option to invoking the file
>> which stored the infomation for these servers.
>>
>> Say, I named this file as resolv-file.dnsmasq, and its content has the
>> following forms:
>>
>> server server1#port1
>> server server2#port2
>> server server3#port3
>> server server4#port4
>>
>> Then I use the following command to run the dnsmasq:
>>
>> sudo dnsmasq -d -p 5353 -r /path/to/resolv-file.dnsmasq  --all-servers
>>
>> But, at this step, I get the following errors:
>>
>> dnsmasq: no servers found in /path/to/resolv-file.dnsmasq, will retry
>>
>> So, how to let dnsmasq using multiple upstream dns servers with
>> non-standard ports?
>>
>> Regards
>>
>
>
> ___
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss@lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss



-- 
Hongyi Zhao 
Xinjiang Technical Institute of Physics and Chemistry
Chinese Academy of Sciences
GnuPG DSA: 0xD108493

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss