Date: Thu, 05 Feb 1998 17:38:26 -0800 From: Cy Schubert - ITSD Open Systems Group <cschuber@uumail.gov.bc.ca> To: "Evan Champion" <evanc@synapse.net> Cc: "Cy Schubert - ITSD Open Systems Group" <cschuber@uumail.gov.bc.ca>, freebsd-stable@FreeBSD.ORG Subject: Re: Instant trap on make installworld Message-ID: <199802060139.RAA08385@cwsys.cwsent.com> In-Reply-To: Your message of "Thu, 05 Feb 1998 16:48:09 EST." <00b501bd327f$bfe170a0$2844c00a@cello.synapse.net>
next in thread | previous in thread | raw e-mail | index | archive | help
> >There is a bug in nullfs/umapfs or VM (depending on your point of view)
> >which causes the panic you're describing when the mmap() system call is
> >used. I put together a patch (kludge) and submitted it as a PR. This
> >has caused a fair bit of discussion among various develpers and members
> >of the Core Team.
>
>
> ... and of course, as soon as make installworld resets the libpaths, mmap()
> gets involved on the nullfs...
>
> Ok, given that this bug exists, is there a way I can use links to simulate
> what I wanted to accomplish with nullfs? The basic problem is that on the
> client, the tree is mounted as /usr/src and /usr/obj, but on the server it
> is under /exports.
>
> If I try to link /usr/src to /exports/src etc. on the server, make
> installworld fails because it tries to find the objects then under
> /exports/obj/exports/src (or something similar) instead of
> /exports/obj/usr/src, where they would have been written by the client.
>
> Obviously, I can hand-link to fix the problem, but are there a set of make
> options that will allow me to build without tinkering?
>
> Evan
This patch will fix the nullfs/umapfs divide-by-zero panic.
vnode_pager.c is probably not the best place to fix this problem,
however the patch suffices until a better fix can be found.
--- src/sys/vm/vnode_pager.c.orig2 Sun Dec 7 13:11:03 1997
+++ src/sys/vm/vnode_pager.c Fri Dec 19 06:30:27 1997
@@ -231,10 +231,12 @@
blocksperpage = 0;
if (pagesperblock > 0) {
reqblock = pindex / pagesperblock;
- } else {
+ } else if (bsize > 0) {
blocksperpage = (PAGE_SIZE / bsize);
reqblock = pindex * blocksperpage;
- }
+ } else
+ return FALSE;
+
err = VOP_BMAP(vp, reqblock, (struct vnode **) 0, &bn,
after, before);
if (err)
Regards, Phone: (250)387-8437
Cy Schubert Fax: (250)387-5766
UNIX Support OV/VM: BCSC02(CSCHUBER)
ITSD BITNET: CSCHUBER@BCSC02.BITNET
Government of BC Internet: cschuber@uumail.gov.bc.ca
Cy.Schubert@gems8.gov.bc.ca
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199802060139.RAA08385>
