From owner-freebsd-questions Fri Aug 29 08:55:36 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id IAA10987 for questions-outgoing; Fri, 29 Aug 1997 08:55:36 -0700 (PDT) Received: from dyson.iquest.net (dyson.iquest.net [198.70.144.127]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id IAA10975 for ; Fri, 29 Aug 1997 08:55:33 -0700 (PDT) Received: (from root@localhost) by dyson.iquest.net (8.8.6/8.8.5) id KAA02114; Fri, 29 Aug 1997 10:55:28 -0500 (EST) From: "John S. Dyson" Message-Id: <199708291555.KAA02114@dyson.iquest.net> Subject: Re: Problem using 'vn' device for swap In-Reply-To: from Chris at "Aug 29, 97 10:49:35 am" To: mikk0022@maroon.tc.umn.edu (Chris) Date: Fri, 29 Aug 1997 10:55:28 -0500 (EST) Cc: toor@dyson.iquest.net, questions@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk Chris said: > > > On Fri, 29 Aug 1997, John S. Dyson wrote: > > > Aug 28 23:41:41 mercury /kernel: swap_pager_finish: I/O error, clean of page 67a000 failed > > > Aug 28 23:41:42 mercury /kernel: swap_pager: I/O error - async pageout failed; blkno 408, size 8192, error 0 > > Did you create the file with: > > > > dd if=/dev/zero of=swapfile count=xxx bs=yyy > > > > or did you just use an empty 64MB file? > > Oh, I just used an empty 64MB file. I wasn't aware there was a > difference. > EEEK!!! there is. Lemme 'splain :-). There will be no file space allocation during pageouts. This was done to eliminate layers between the vn device and the actual disk. The problem is that there are serious resource starvation issues. Imagine the case where you are out of memory... You might need to allocated buffers to allocation more disk space then. If there was only one level of recursion, there would be no problem. In the majority of the time it works, however, there are cases where the kernel stack gets fried because of overrun. So, in order to fix that problem, and for efficiency, the layers that provide the disk block allocation are bypassed. -- John dyson@freebsd.org jdyson@nc.com