From: erik quanstrom <quanstro@quanstro.net>
To: 9fans@9fans.net
Subject: Re: [9fans] multiple pings cause panic
Date: Sun, 18 Apr 2010 17:19:47 -0400 [thread overview]
Message-ID: <a624d8792715868e31fc28a87db0b8e5@kw.quanstro.net> (raw)
In-Reply-To: <m2pb85d21141004181354j318dc1eew2df01d305dbcb397@mail.gmail.com>
> On Sun, Apr 18, 2010 at 11:32 PM, erik quanstrom <quanstro@quanstro.net> wrote:
> >> term% for (i in `{seq 1 254}) {ip/ping -n 1 192.168.1.1&}
> >
> > i think you mean
> >
> > for(i in `{seq 1 254}){ip/ping -n1 192.168.1.$i}
>
> Sorry, I meant
>
> for(i in `{seq 1 254}){ip/ping -n1 192.168.1.$i&}
>
> I added the & as I didn't want to wait for one to timeout/succeed
> before trying the next one.
i removed the & on purpose. if you don't want to write
your own version of ping, doing them one-at-a-time
makes the most sense.
if you want to get super fancy, you could
batch=10
j=()
for(i in `{seq 1 254}){
if(! ~ $#j $batch){
j=($i $j)
ping -i1 192.168.0.$i&
}
if not{
j=()
wait
}
}
if(! ~ $#j 0)
wait
what are you *really* trying to do? if you want to find servers
on the local segment, sending udp packets to them will fill arp
tables. no timeout required.
> I was expecting that a panic was a bug and I shouldn't be able to cause one.
>
> I'm running a standalone system here but if I wasn't could I bring
> down the server like this or only my terminal?
sure. that's why i said i think it can be debated if this is the
right response. but it is definately intentional. the problem is
that for some servers, running out of (say) tcp conversations
will make the server useless and a panic/reboot will set things
right, if we assume that the condition was temporary.
- erik
next prev parent reply other threads:[~2010-04-18 21:19 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-18 19:36 James Chapman
2010-04-18 20:32 ` erik quanstrom
2010-04-18 20:54 ` James Chapman
2010-04-18 21:19 ` erik quanstrom [this message]
2010-04-18 20:39 ` geoff
2010-04-18 23:52 ` erik quanstrom
2010-04-19 0:23 ` cinap_lenrek
2010-04-19 0:27 ` erik quanstrom
2010-04-19 1:19 ` cinap_lenrek
2010-04-19 1:27 ` andrey mirtchovski
2010-04-19 2:53 ` erik quanstrom
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=a624d8792715868e31fc28a87db0b8e5@kw.quanstro.net \
--to=quanstro@quanstro.net \
--cc=9fans@9fans.net \
/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;
as well as URLs for NNTP newsgroup(s).