Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Jul 2002 03:17:33 -0700
From:      Terry Lambert <tlambert2@mindspring.com>
To:        Matthew Dillon <dillon@apollo.backplane.com>
Cc:        David Schultz <dschultz@uclink.Berkeley.EDU>, Sean Kelly <smkelly@zombie.org>, hackers@FreeBSD.ORG
Subject:   Re: swapoff?
Message-ID:  <3D2FFE3D.83E0CCF9@mindspring.com>
References:  <20020713040247.GA82181@edgemaster.zombie.org> <20020713052337.GA662@HAL9000.wox.org> <20020713053236.GA884@HAL9000.wox.org> <200207130652.g6D6qI93076722@apollo.backplane.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Matthew Dillon wrote:
>         * Flag the swap device being removed and then scan all OBJT_SWAP
>           VM Objects looking for swap blocks associated with the device,
>           and force a page-in of those blocks.  The getpages code for the
>           swap backing store would detect the flag and not clear the swap
>           bitmap bits as it pages-in the data.
> 
>           (Forcing a pagein may force pages to cycle back out to another
>           swap device, so special treatment of the paged-in pages (like
>           immediately placing it in the VM page cache instead of the
>           active or inactive queues) is necessary to reduce load effects
>           on the system.

Uh... so you set the bit that tells you it's allocated to prevent
it being allocated?

When I swap something in and the bit is set, how do I know that it's
in, except that it's not allocated?

In other words, I do what you say... how do I know when the device
has been drained out, vs. being in use?

I think you have to disable swapping to the device some other way,
and then return fromt he "swapoff" only when the bitmap is all zero.

-- Terry

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3D2FFE3D.83E0CCF9>