From jroberson@chesapeake.net Sat Mar 29 10:19:11 2003 Date: Fri, 28 Mar 2003 19:47:14 -0500 (EST) From: Jeff Roberson To: Kirk McKusick Cc: Robert Watson , jeff@FreeBSD.org Subject: Re: panic: softdep_disk_io_initiation: read Please try the attached patch. This will fix it. This happens if we try to do a second read ahead attempt and there is only one contiguous block on disk. Ooops. :-/ Cheers, Jeff Index: vfs_cluster.c =================================================================== RCS file: /home/ncvs/src/sys/kern/vfs_cluster.c,v retrieving revision 1.135 diff -u -r1.135 vfs_cluster.c --- vfs_cluster.c 18 Mar 2003 08:45:23 -0000 1.135 +++ vfs_cluster.c 29 Mar 2003 00:20:51 -0000 @@ -266,10 +266,14 @@ lblkno += (rbp->b_bufsize / size); } else { rbp = getblk(vp, lblkno, size, 0, 0, 0); + lblkno += 1; + if (rbp->b_flags & B_DELWRI) { + bqrelese(rbp); + continue; + } rbp->b_flags |= B_ASYNC | B_RAM; rbp->b_iocmd = BIO_READ; rbp->b_blkno = blkno; - lblkno += 1; } if (rbp->b_flags & B_CACHE) { rbp->b_flags &= ~B_ASYNC; On Fri, 28 Mar 2003, Kirk McKusick wrote: > We have traced this back to a point in the read-clustering code > where it is changing a dirty BIO_WRITE buffer to be a BIO_READ > buffer. I am guessing that it is being a bit too aggressive about > trying to aggregate buffers together for reading and is accidentally > picking up one that has not yet been written. Anyway, Jeff is now > hard on the trail to track it down and I am hopeful that he will > soon have a fix :-) > > ~Kirk > > =-=-=-=-=-= > > Date: Fri, 28 Mar 2003 15:19:23 -0500 (EST) > From: Robert Watson > To: kirk@mckusick.com, jeff@FreeBSD.org > Subject: Re: panic: softdep_disk_io_initiation: read > In-Reply-To: > X-ASK-Info: Whitelist match > > Just had an identical "second panic" of the same sort. It appears to be > happening in the following scenario: > > sproing.gw.tislabs.com: > sproing:/data/p4/rwatson/trustedbsd/misc/kugidfw> !make > make > c++ -Wall -I/usr/local/include -I/usr/X11R6/include -g -c kruleedit.cc > g++ -o kugidfw main.o kugidfw.o kruleedit.o -L/usr/local/lib -lkdeui > -lkdecore -L/usr/X11R6/lib -lqt-mt -pthread -lugidfw > sproing:/data/p4/rwatson/trustedbsd/misc/kugidfw> ./k > > > cboss.gw.tislabs.com: > > > This is the exactly the same scenario -- the moment I did a tab completion > using tcsh on sproing.gw.tislabs.com. I'm going to try it one more time > without changing any settings, and then Jeff has asked me to try setting > vfs.read_max=0, so I'll try it again with that. > > Robert N M Watson FreeBSD Core Team, TrustedBSD Projects > robert@fledge.watson.org Network Associates Laboratories >