public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Martin Zwickel <martin.zwickel@technotrend.de>
To: Denis Vlasenko <vda@port.imtp.ilyichevsk.odessa.ua>
Cc: linux-kernel@vger.kernel.org
Subject: Re: 2.6.7-rc2-mm2 udp multicast problem (sendto hangs)
Date: Wed, 23 Jun 2004 14:00:23 +0200	[thread overview]
Message-ID: <20040623140023.4cd7aa3e@phoebee> (raw)
In-Reply-To: <200406231334.57816.vda@port.imtp.ilyichevsk.odessa.ua>

On Wed, 23 Jun 2004 13:34:57 +0300
Denis Vlasenko <vda@port.imtp.ilyichevsk.odessa.ua> bubbled:

> On Wednesday 23 June 2004 12:56, Martin Zwickel wrote:
> > if I use MSG_DONTWAIT with sendto, I get temporarily unavailable resources
> > (many!):
> >
> > sendto(sendfd): Resource temporarily unavailable
> >
> > but isn't udp supposed to not block?
> 
> Think about what will happen if you will try to spew
> udp packets continuously:
> 
> while(1)
> 	sendto(...);
> 
> They will pile up in queue and eventually it will fill up.
> Then kernel may either drop excess packets silently
> or return you EAGAIN.

Yes, but why does the kernel not send out the queue?(I don't know if the queue
is empty or full when my sendto stops)
Without MSG_DONTWAIT, sendto waits endlessly. But on what?
Normally the kernel should put the queued packets on the line and accept new
ones, or did I misunderstand this?

My program sends out many udp packets, and sometimes it just stops until the
kernel receives a network packet or I access the local network(with arp
command).

So if I run arp in an endless loop(while :; do arp; done), sendto runs smooth.

For me it smells like a bug ;)

Martin

-- 
MyExcuse:
I'd love to help you -- it's just that the Boss won't let me near the computer.

Martin Zwickel <martin.zwickel@technotrend.de>
Research & Development

TechnoTrend AG <http://www.technotrend.de>

  reply	other threads:[~2004-06-23 12:00 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-22 14:40 2.6.7-rc2-mm2 udp multicast problem (sendto hangs) Martin Zwickel
2004-06-23  9:56 ` Martin Zwickel
2004-06-23 10:34   ` Denis Vlasenko
2004-06-23 12:00     ` Martin Zwickel [this message]
2004-06-23 12:36       ` Denis Vlasenko
2004-06-23 13:42         ` Martin Zwickel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040623140023.4cd7aa3e@phoebee \
    --to=martin.zwickel@technotrend.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vda@port.imtp.ilyichevsk.odessa.ua \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox