[2973] in linux-net channel archive
An amusing test
daemon@ATHENA.MIT.EDU (Paul Gortmaker)
Thu May 23 09:06:52 1996
From: Paul Gortmaker <gpg109@rsphy6.anu.edu.au>
To: linux-net@vger.rutgers.edu
Date: Wed, 22 May 1996 20:46:49 +1000 (EST)
Here is an interesting little test to run on current kernels. Run it as
a normal user and watch the amusement. It works best if you are on an
ether subnet that is mostly vacant. You have to enter your own network
value (without the trailing zero) below where it says "NET="
Paul.
--------- cut here ----------8<---------- cut here -----------
#!/bin/bash
#
# Enter first three parts of your IP num. below (e.g. for 192.168.3.5)
#
NET=192.168.3
HOSTNUM=254
while [ $HOSTNUM != 0 ]
do
ping -s $[$RANDOM % 1490] -c1 $NET.$HOSTNUM > /dev/null 2>&1 &
HOSTNUM=$[$HOSTNUM - 1]
true; true # waste a few more ticks
kill $! > /dev/null 2>&1
done