Re: total configured swap pages exceeds maximum recommended amount

2018-03-02 Thread David Wolfskill
[Recipient list trimmed, as this response addresses a peripheral
consern -- dhw]
On Fri, Mar 02, 2018 at 12:23:34AM -0800, Jeremy Chadwick wrote:
> ...
> The reason this box has 32GB swap (4x more than existing RAM) has to do
> with planning ahead.  The system can support up to 32GB RAM, but does
> not have all the DIMM slots populated at this time.  Swap on this
> machine is a physical partition on its main disk, thus "shrinking swap"
> is not not possible without a full format/reinstall.
> .

Actually, now that you have sized the partitions. you could use "gpart
resize" to shrink the (effective) swap partition, leaving a "hole" (of
unused diske space) -- for now.

Later, you could use "gpart resize" again to reclaim (some of) the
unused space for your swap partition, should you want to do so.

Peace,
david
-- 
David H. Wolfskill  da...@catwhisker.org
Yes, the indictments don't "prove" guilt; that's what trials are for.

See http://www.catwhisker.org/~david/publickey.gpg for my public key.


signature.asc
Description: PGP signature


total configured swap pages exceeds maximum recommended amount

2018-03-02 Thread Jeremy Chadwick
I am not subscribed to -stable, so please keep me CC'd.  I am CC'ing
folks who have touched this code or dealt with it recently or in the
past.

Something has changed regarding how FreeBSD determines when to emit this
message.  I do not know if this is a regression.  The message below
comes from a stable/11 r330260 amd64 box w/ 8GB RAM and 32GB swap during
boot:

warning: total configured swap (8358563 pages) exceeds maximum recommended 
amount (8141112 pages).
warning: increase kern.maxswzone or reduce amount of swap.

In stable/9, the message could be squelched via kern.maxswzone="0" in
loader.conf.  Confirmation is here (see Dag-Erling's responses):
https://lists.freebsd.org/pipermail/freebsd-stable/2012-August/069301.html

In stable/11, this no longer appears to work (the default value is 0).

The reason this box has 32GB swap (4x more than existing RAM) has to do
with planning ahead.  The system can support up to 32GB RAM, but does
not have all the DIMM slots populated at this time.  Swap on this
machine is a physical partition on its main disk, thus "shrinking swap"
is not not possible without a full format/reinstall.

This code has been touched/tweaked semi-recently in PR 221356:
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221356

Code references:

stable/9:  
https://svnweb.freebsd.org/base/stable/9/sys/vm/swap_pager.c?annotate=284100#l2132
stable/10: 
https://svnweb.freebsd.org/base/stable/10/sys/vm/swap_pager.c?annotate=320557#l2156
stable/11: 
https://svnweb.freebsd.org/base/stable/11/sys/vm/swap_pager.c?annotate=329591#l2126

My questions: how does one squelch this warning message on such systems
running stable/11?  If it involves setting the tunable to a more useful
value, how does one reliably calculate that value?

Thank you.

-- 
| Jeremy Chadwick   j...@koitsu.org |
| UNIX Systems Administratorhttp://jdc.koitsu.org/ |
| Making life hard for others since 1977. PGP 4BD6C0CB |

___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"