Re: [Dnsmasq-discuss] Slow response to DHCPDISCOVER

2012-04-24 Thread richardvo...@gmail.com
Daryl may still be correct.  Linux's bridge module also implements the
learning phase (for detection of loops) before it begins forwarding packets.

On Tue, Apr 24, 2012 at 10:38 PM, Adrian May  wrote:

> Hi Daryl,
>
> There is no switch. I'm trying to build a router and I'm plugging clients
> directly into it. It's actually a little fanless thing with 8 ethernet
> ports, 7 of which I bridge to make the private LAN, and the other of which
> dials pppoe. I installed ubuntu server 10.04, followed by the bridge, and
> then dnsmasq.
>
> In the meantime, I got another result. With IPFire, I found dhcp very
> fast, and it turned out that some of the home made cables around here can't
> connect the embedded boards to the little box I'm making the router out of.
> But they can connect any PC to my router or the 10 dollar router, and they
> can connect any PC or embedded board to the 10 dollar router, and the
> proper cables can connect anything to anything. In other words, the only
> combination that doesn't work is the home-made cable connecting the
> embedded boards to my new router. What's more, it doesn't matter whether I
> use a 100Mb or 1Gb socket on the new router. Very strange. That's all under
> IPFire, so now I'm reinstalling ubuntu to see if I get the same result.
>
> Adrian.
>
>
>
>
> On 04/24/2012 10:51 PM, Daryl Richards wrote:
>
>> Actually, the "10 dollar domestic router" fix points to the probable
>> solution. You likely have spanning tree turned on on your usual switch,
>> which will block all traffic on that port for the first 50 seconds after
>> a link state change. Either switch to rapid spanning tree, or look into
>> your switch's version of "portfast"..
>>
>> On 12-04-23 11:21 PM, Adrian May wrote:
>>
>>> Hi Simon,
>>>
>>> In the meantime I installed ClearOS, which uses dnsmasq. Now the PCs
>>> get served fast but my embedded boards are still not getting IPs. If I
>>> plug these embedded boards into my 10 dollar domestic router, they get
>>> an IP instantly. I already tried setting bootp-dynamic and
>>> dhcp-broadcast in the config. If I grep everything under /var/log for
>>> dnsmasq, there's no evidence that requests were even received from
>>> these boards. So I still suspect the networking layer.
>>>
>>> As for the boards themselves, I'm not entirely sure what they do.
>>> They've got some kind of embedded linux. One boots into yamon where I
>>> can only say "net init", the other into something of its own invention
>>> where I start udhcpc.
>>>
>>> I tried no-ping but it had no effect. I can't get my brain around your
>>> tag system. I've just been writing things like bootp-dynamic with no
>>> tags right in the main config file, or in the case of ClearOS, in the
>>> dhcp config file which is referenced from the main config file. Could
>>> it be that these settings have no effect unless I attach some tags, or
>>> put them inside a subnet declaration?
>>>
>>> Adrian.
>>>
>>>
>>>
>>> On 04/23/2012 08:01 PM, Simon Kelley wrote:
>>>
 On 23/04/12 12:02, Adrian May wrote:

> Hi all,
>
> I get the same result with dnsmasq, dhcp3-server and isc, namely, that
> the client has to send several DHCPDISCOVER packets before the server
> finally responds after about 30 seconds. This is breaking a couple of
> embedded platforms because they aren't that patient, and I have no way
> of configuring that.
>
> Why don't DHCP servers just respond to the first DHCPDISCOVER?
> Especially when I made them authoritative?#
>
 Servers allocate an address and then ping it for a few seconds just
 to be sure it's not in use. That's the main delay. In dnsmasq
 --no-ping will stop this behaviour. Also the  client is entitled to
 wait around collecting answers from more than one server before
 deciding which one to use; they rarely do this and it doesn't sound
 like yours are.

> I think I might have seen in the logs that the dhcp processes aren't
> even getting the earlier packets, even though the machine is. It's
> as if
> they get discarded by the networking layer. This is a ubuntu server
> 10.04 machine.
>

 Firewall rules can affect things, but the result is rarely
 intermittent. Is your network heavily loaded and dropping packets?


 Cheers,

 Simon.

  Any ideas?
>
> Adrian.
>
>
>
>
> __**_
> 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] Slow response to DHCPDISCOVER

2012-04-24 Thread Adrian May

Hi Daryl,

There is no switch. I'm trying to build a router and I'm plugging 
clients directly into it. It's actually a little fanless thing with 8 
ethernet ports, 7 of which I bridge to make the private LAN, and the 
other of which dials pppoe. I installed ubuntu server 10.04, followed by 
the bridge, and then dnsmasq.


In the meantime, I got another result. With IPFire, I found dhcp very 
fast, and it turned out that some of the home made cables around here 
can't connect the embedded boards to the little box I'm making the 
router out of. But they can connect any PC to my router or the 10 dollar 
router, and they can connect any PC or embedded board to the 10 dollar 
router, and the proper cables can connect anything to anything. In other 
words, the only combination that doesn't work is the home-made cable 
connecting the embedded boards to my new router. What's more, it doesn't 
matter whether I use a 100Mb or 1Gb socket on the new router. Very 
strange. That's all under IPFire, so now I'm reinstalling ubuntu to see 
if I get the same result.


Adrian.



On 04/24/2012 10:51 PM, Daryl Richards wrote:

Actually, the "10 dollar domestic router" fix points to the probable
solution. You likely have spanning tree turned on on your usual switch,
which will block all traffic on that port for the first 50 seconds after
a link state change. Either switch to rapid spanning tree, or look into
your switch's version of "portfast"..

On 12-04-23 11:21 PM, Adrian May wrote:

Hi Simon,

In the meantime I installed ClearOS, which uses dnsmasq. Now the PCs
get served fast but my embedded boards are still not getting IPs. If I
plug these embedded boards into my 10 dollar domestic router, they get
an IP instantly. I already tried setting bootp-dynamic and
dhcp-broadcast in the config. If I grep everything under /var/log for
dnsmasq, there's no evidence that requests were even received from
these boards. So I still suspect the networking layer.

As for the boards themselves, I'm not entirely sure what they do.
They've got some kind of embedded linux. One boots into yamon where I
can only say "net init", the other into something of its own invention
where I start udhcpc.

I tried no-ping but it had no effect. I can't get my brain around your
tag system. I've just been writing things like bootp-dynamic with no
tags right in the main config file, or in the case of ClearOS, in the
dhcp config file which is referenced from the main config file. Could
it be that these settings have no effect unless I attach some tags, or
put them inside a subnet declaration?

Adrian.



On 04/23/2012 08:01 PM, Simon Kelley wrote:

On 23/04/12 12:02, Adrian May wrote:

Hi all,

I get the same result with dnsmasq, dhcp3-server and isc, namely, that
the client has to send several DHCPDISCOVER packets before the server
finally responds after about 30 seconds. This is breaking a couple of
embedded platforms because they aren't that patient, and I have no way
of configuring that.

Why don't DHCP servers just respond to the first DHCPDISCOVER?
Especially when I made them authoritative?#

Servers allocate an address and then ping it for a few seconds just
to be sure it's not in use. That's the main delay. In dnsmasq
--no-ping will stop this behaviour. Also the  client is entitled to
wait around collecting answers from more than one server before
deciding which one to use; they rarely do this and it doesn't sound
like yours are.

I think I might have seen in the logs that the dhcp processes aren't
even getting the earlier packets, even though the machine is. It's
as if
they get discarded by the networking layer. This is a ubuntu server
10.04 machine.


Firewall rules can affect things, but the result is rarely
intermittent. Is your network heavily loaded and dropping packets?


Cheers,

Simon.


Any ideas?

Adrian.




___
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


___
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] DNS in DNsmasq

2012-04-24 Thread Ed W
Incidently, before you setup your own recursive server, the big problem 
I measure is that without a load of traffic, your latencies are just 
terrible because nothing is in cache... I tested a recursive cache on my 
rack and it wasn't great, so I looked into the datacenter provided one 
and had the same kinds of latency issues (first query slow, second is 
great, but I'm always doing "first queries"...)


Basically if you are the first person in the last 60 seconds to lookup 
www.yahoo.com then it's going around the world and will take some time.  
If you have a busy enough cache then someone is paying the penalty for 
you quite regularly and your responses look good.  I suspect you need 
really quite a LOT of traffic before your recursive server gets decently 
warm... So my thought would be to use a big upstream that you trust, 
unless you are "ISP sized"


Regards

Ed W

On 24/04/2012 00:12, richardvo...@gmail.com wrote:
No.  You must configure dnsmasq with an upstream nameserver which will 
perform the recursive query.


dnsmasq is a server for your local zone (with DHCP integration, 
similar to dynamic dns) and a cache.  It is not a recursive nameserver.


On Mon, Apr 23, 2012 at 9:23 AM, dnsmasq dnsmasq 
mailto:dnsmasq2...@gmail.com>> wrote:


Hello,

Did Dnsmasq support recursive/itérative queries or both?



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


Re: [Dnsmasq-discuss] Slow response to DHCPDISCOVER

2012-04-24 Thread Daryl Richards
Actually, the "10 dollar domestic router" fix points to the probable
solution. You likely have spanning tree turned on on your usual switch,
which will block all traffic on that port for the first 50 seconds after
a link state change. Either switch to rapid spanning tree, or look into
your switch's version of "portfast"..

On 12-04-23 11:21 PM, Adrian May wrote:
> Hi Simon,
>
> In the meantime I installed ClearOS, which uses dnsmasq. Now the PCs
> get served fast but my embedded boards are still not getting IPs. If I
> plug these embedded boards into my 10 dollar domestic router, they get
> an IP instantly. I already tried setting bootp-dynamic and
> dhcp-broadcast in the config. If I grep everything under /var/log for
> dnsmasq, there's no evidence that requests were even received from
> these boards. So I still suspect the networking layer.
>
> As for the boards themselves, I'm not entirely sure what they do.
> They've got some kind of embedded linux. One boots into yamon where I
> can only say "net init", the other into something of its own invention
> where I start udhcpc.
>
> I tried no-ping but it had no effect. I can't get my brain around your
> tag system. I've just been writing things like bootp-dynamic with no
> tags right in the main config file, or in the case of ClearOS, in the
> dhcp config file which is referenced from the main config file. Could
> it be that these settings have no effect unless I attach some tags, or
> put them inside a subnet declaration?
>
> Adrian.
>
>
>
> On 04/23/2012 08:01 PM, Simon Kelley wrote:
>> On 23/04/12 12:02, Adrian May wrote:
>>>
>>> Hi all,
>>>
>>> I get the same result with dnsmasq, dhcp3-server and isc, namely, that
>>> the client has to send several DHCPDISCOVER packets before the server
>>> finally responds after about 30 seconds. This is breaking a couple of
>>> embedded platforms because they aren't that patient, and I have no way
>>> of configuring that.
>>>
>>> Why don't DHCP servers just respond to the first DHCPDISCOVER?
>>> Especially when I made them authoritative?#
>>
>> Servers allocate an address and then ping it for a few seconds just
>> to be sure it's not in use. That's the main delay. In dnsmasq
>> --no-ping will stop this behaviour. Also the  client is entitled to
>> wait around collecting answers from more than one server before
>> deciding which one to use; they rarely do this and it doesn't sound
>> like yours are.
>>>
>>> I think I might have seen in the logs that the dhcp processes aren't
>>> even getting the earlier packets, even though the machine is. It's
>>> as if
>>> they get discarded by the networking layer. This is a ubuntu server
>>> 10.04 machine.
>>
>>
>> Firewall rules can affect things, but the result is rarely
>> intermittent. Is your network heavily loaded and dropping packets?
>>
>>
>> Cheers,
>>
>> Simon.
>>
>>>
>>> Any ideas?
>>>
>>> Adrian.
>>>
>>>
>>>
>>>
>>> ___
>>> 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
>
>
> ___
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss@lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss

-- 
Daryl Richards
Isle Technical Services Inc.


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


Re: [Dnsmasq-discuss] Slow response to DHCPDISCOVER

2012-04-24 Thread Simon Kelley

On 24/04/12 04:21, Adrian May wrote:

Hi Simon,

In the meantime I installed ClearOS, which uses dnsmasq. Now the PCs get
served fast but my embedded boards are still not getting IPs. If I plug
these embedded boards into my 10 dollar domestic router, they get an IP
instantly. I already tried setting bootp-dynamic and dhcp-broadcast in
the config. If I grep everything under /var/log for dnsmasq, there's no
evidence that requests were even received from these boards. So I still
suspect the networking layer.

As for the boards themselves, I'm not entirely sure what they do.
They've got some kind of embedded linux. One boots into yamon where I
can only say "net init", the other into something of its own invention
where I start udhcpc.

I tried no-ping but it had no effect. I can't get my brain around your
tag system. I've just been writing things like bootp-dynamic with no
tags right in the main config file, or in the case of ClearOS, in the
dhcp config file which is referenced from the main config file. Could it
be that these settings have no effect unless I attach some tags, or put
them inside a subnet declaration?



No tags -> applies everywhere, so that's not the problem.

Do you have some combination of --interface, --listen-address and 
--dhcp-except that's telling dnsmasq not to do DHCP on the network these 
things are plugged into? Can you plug a laptop or something into the 
same port and get a DHCP lease?


If you can narrow it down to just these embedded boards, then we'll have 
to start looking at packet dumps.



Cheers,

Simon.


Adrian.



On 04/23/2012 08:01 PM, Simon Kelley wrote:

On 23/04/12 12:02, Adrian May wrote:


Hi all,

I get the same result with dnsmasq, dhcp3-server and isc, namely, that
the client has to send several DHCPDISCOVER packets before the server
finally responds after about 30 seconds. This is breaking a couple of
embedded platforms because they aren't that patient, and I have no way
of configuring that.

Why don't DHCP servers just respond to the first DHCPDISCOVER?
Especially when I made them authoritative?#


Servers allocate an address and then ping it for a few seconds just to
be sure it's not in use. That's the main delay. In dnsmasq --no-ping
will stop this behaviour. Also the client is entitled to wait around
collecting answers from more than one server before deciding which one
to use; they rarely do this and it doesn't sound like yours are.


I think I might have seen in the logs that the dhcp processes aren't
even getting the earlier packets, even though the machine is. It's as if
they get discarded by the networking layer. This is a ubuntu server
10.04 machine.



Firewall rules can affect things, but the result is rarely
intermittent. Is your network heavily loaded and dropping packets?


Cheers,

Simon.



Any ideas?

Adrian.




___
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



___
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