From owner-freebsd-questions Tue Sep 7 9:58: 5 1999 Delivered-To: freebsd-questions@freebsd.org Received: from fw.wintelcom.net (ns1.wintelcom.net [209.1.153.20]) by hub.freebsd.org (Postfix) with ESMTP id B709114C1C for ; Tue, 7 Sep 1999 09:57:59 -0700 (PDT) (envelope-from bright@wintelcom.net) Received: from localhost (bright@localhost) by fw.wintelcom.net (8.8.8/8.8.8) with ESMTP id DAA10366; Tue, 7 Sep 1999 03:14:23 -0700 (PDT) (envelope-from bright@wintelcom.net) Date: Tue, 7 Sep 1999 10:14:23 +0000 (GMT) From: Alfred Perlstein To: Decebal Topala Cc: questions@FreeBSD.ORG Subject: don't fork bomb In-Reply-To: <199909071605.TAA02860@atlas.dnt.md> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Tue, 7 Sep 1999, Decebal Topala wrote: > Hi > > I used an script to ping all ip addresses in my ocal ip subnet. > I was very slow. In order to make this faster i put ping process in > baground. After 15 second system is dumpimg. can you please tell us the panic message? in the meantime, try adding: options NMBCLUSTERS=8192 I'll see what I can do about this on a -stable box i have. it looks like this script constitutes a nice fork bomb, you are forking 62230 processes, maybe a workaround would be to add a "wait" right after before "class_b=$((${class_b}+1))" this will limit the script to 254 pings at a time... good luck, -Alfred > > Here is the script > ################################################################# > #!/bin/sh -x > class_c=0 > class_b=0 > subnet=172.16 > count=2 > while [ ${class_b} != 255 ] > do > class_c=0 > > while [ ${class_c} != 255 ] > do > ping -c ${count} ${subnet}.${class_b}.${class_c} & > class_c=$((${class_c}+1)) > echo ${class_b}.${class_c} > done > > class_b=$((${class_b}+1)) > done > ##################################################### > And here is my kernel config file. > > ################################################################ > > > machine "i386" > cpu "I686_CPU" > ident fire > maxusers 500 > options "MAXDSIZ=(256*1024*1024)" > options "DFLDSIZ=(256*1024*1024)" > options MATH_EMULATE #Support for x87 emulation > options INET #InterNETworking > options FFS #Berkeley Fast Filesystem > options FFS_ROOT #FFS usable as root device [keep this!] > options MSDOSFS #MSDOS Filesystem > options "CD9660" #ISO 9660 Filesystem > options "CD9660_ROOT" #CD-ROM usable as root. "CD9660" req'ed > options PROCFS #Process filesystem > options "COMPAT_43" #Compatible with BSD 4.3 [KEEP THIS!] > options SCSI_DELAY=15000 #Be pessimistic about Joe SCSI device > options UCONSOLE #Allow users to grab the console > options FAILSAFE #Be conservative > options USERCONFIG #boot -c editor > options VISUAL_USERCONFIG #visual boot -c editor > config kernel root on wd0 > controller isa0 > controller pnp0 > controller eisa0 > controller pci0 > controller fdc0 at isa? port "IO_FD1" bio irq 6 drq 2 > disk fd0 at fdc0 drive 0 > disk fd1 at fdc0 drive 1 > options "CMD640" # work around CMD640 chip deficiency > controller wdc0 at isa? port "IO_WD1" bio irq 14 > disk wd0 at wdc0 drive 0 > disk wd1 at wdc0 drive 1 > controller wdc1 at isa? port "IO_WD2" bio irq 15 > disk wd2 at wdc1 drive 0 > disk wd3 at wdc1 drive 1 > options ATAPI #Enable ATAPI support for IDE bus > options ATAPI_STATIC #Don't do it as an LKM > device acd0 #IDE CD-ROM > device wfd0 #IDE Floppy (e.g. LS-120) > device mcd0 at isa? port 0x300 bio irq 10 > controller atkbdc0 at isa? port IO_KBD tty > device atkbd0 at isa? tty irq 1 > device psm0 at isa? tty irq 12 > device vga0 at isa? port ? conflicts > pseudo-device splash > device sc0 at isa? tty > device npx0 at isa? port IO_NPX irq 13 > device sio0 at isa? port "IO_COM1" flags 0x10 tty irq 4 > device sio1 at isa? port "IO_COM2" tty irq 3 > device sio2 at isa? disable port "IO_COM3" tty irq 5 > device sio3 at isa? disable port "IO_COM4" tty irq 9 > device xl0 # 3Com 3c90x (``Boomerang'', ``Cyclone'') > pseudo-device loop > pseudo-device ether > pseudo-device pty 16 > pseudo-device gzip # Exec gzipped a.out's > options KTRACE #kernel tracing > options SYSVSHM > options SYSVMSG > options SYSVSEM > pseudo-device bpfilter 4 #Berkeley packet filter > > ############################################################# > > I tried the same the same on linux and it does not trap the system. > > > Please advice any ideas how to solve this. > > > DEcebal > > > > ___________________________________________ > Get your free mail box @ http://www.mail.md > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message