Re: [lockup] 2.6.17-rc3: netfilter/sctp: lockup in sctp_new(), do_basic_checks()

From: Ingo Molnar
Date: Tue May 02 2006 - 09:40:16 EST



* Ingo Molnar <mingo@xxxxxxx> wrote:

> > running an "isic" stresstest on and against a testbox [which, amongst
> > other things, generates random incoming and outgoing packets] on
> > 2.6.17-rc3 (and 2.6.17-rc3-mm1) over gigabit results in a reproducible
> > lockup, after 5-10 minutes of runtime:

btw., just in case someone would like to build ISIC on a modern distro,
the minimal fixes are below. The commandline i'm typically using for
testing is:

isic -s firstbox.com -d secondbox.com -m 50000 >/dev/null 2>/dev/null

seems useful.

Ingo

--- icmpsic.c 2006-04-26 16:14:32.000000000 +0200
+++ icmpsic.c.orig 2006-04-26 16:14:33.000000000 +0200
@@ -265,7 +265,7 @@ main(int argc, char **argv)

payload = (short int *)((u_char *) icmp + 4);
for(cx = 0; cx <= (payload_s >> 1); cx+=1)
- payload[cx] = rand() & 0xffff;
+ (u_short) payload[cx] = rand() & 0xffff;


if ( rand() <= (RAND_MAX * ICMPCksm) )
--- isic.c 2006-04-26 16:14:32.000000000 +0200
+++ isic.c.orig 2006-04-26 16:14:33.000000000 +0200
@@ -229,8 +229,8 @@ main(int argc, char **argv)

payload = (short int *)(buf + IP_H);
for(cx = 0; cx <= (payload_s >> 1); cx+=1)
- payload[cx] = rand() & 0xffff;
- payload[payload_s] = rand() & 0xffff;
+ (u_int16_t) payload[cx] = rand() & 0xffff;
+ (u_int16_t) payload[payload_s] = rand() & 0xffff;

if ( printout ) {
printf("%s ->",
--- tcpsic.c 2006-04-26 16:14:32.000000000 +0200
+++ tcpsic.c.orig 2006-04-26 16:14:32.000000000 +0200
@@ -317,7 +317,7 @@ main(int argc, char **argv)

payload = (short int *)((u_char *) tcp + 20);
for(cx = 0; cx <= (payload_s >> 1); cx+=1)
- payload[cx] = rand() & 0xffff;
+ (u_int16_t) payload[cx] = rand() & 0xffff;

if ( rand() <= (RAND_MAX * TCPCksm) )
libnet_do_checksum(l, (u_int8_t *)buf, IPPROTO_TCP, (tcp->th_off << 2)
--- udpsic.c 2006-04-26 16:14:32.000000000 +0200
+++ udpsic.c.orig 2006-04-26 16:14:32.000000000 +0200
@@ -292,7 +292,7 @@ main(int argc, char **argv)

payload = (short int *)((u_char *) udp + UDP_H);
for(cx = 0; cx <= (payload_s >> 1); cx+=1)
- payload[cx] = rand() & 0xffff;
+ (u_int16_t) payload[cx] = rand() & 0xffff;

if ( printout ) {
printf("%s,%i ->",
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/