From owner-freebsd-questions@freebsd.org Mon Sep 10 09:02:38 2018 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A031B108914C for ; Mon, 10 Sep 2018 09:02:38 +0000 (UTC) (envelope-from mueller6722@twc.com) Received: from dnvrco-cmomta03.email.rr.com (dnvrco-outbound-snat.email.rr.com [107.14.73.229]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id F0EF2771A5 for ; Mon, 10 Sep 2018 09:02:37 +0000 (UTC) (envelope-from mueller6722@twc.com) Received: from localhost ([96.28.161.151]) by cmsmtp with ESMTP id zI5UfXd47Ax0yzI5WfngmY; Mon, 10 Sep 2018 09:02:31 +0000 Date: Mon, 10 Sep 2018 09:02:08 +0000 From: "Thomas Mueller" To: freebsd-questions@freebsd.org Subject: Re: swap config References: <10538979.gLySxXtyIk@chameleon.friedrich.org> <20180910005743.3bf5df59@gumby.homeunix.com> X-CMAE-Envelope: MS4wfCB8xDtavZnUgodc594arz3jLtimE+lUgQtoNbf/fyeRCkYjuLBGiuFAayKBW311n6tBo0x9K8424hv2VxhhvX0/HTdQdy/MkKTpqZSttIy3ypvmj2za Pvnmwg9k6yNDU8wlH4LK4kx1HAz3n+S4hLjyfxB7ahvDIOzymagmcs4SZVKVO8z/a3bmoPHtIgtN3Q== X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Sep 2018 09:02:38 -0000 On Sun, 09 Sep 2018 12:40:03 +0000 Lorenzo Salvadore via freebsd-questions wrote: > > My system has 16GB of memory, so I multiplied that by 4 to get 64GB. > > I created a swap partition of 64GB. > > When I boot, I get: > > warning: total configured swap (16777216 pages) exceeds maximum > > recommended amount (986928 pages). > > warning: increase kern.maxswzone or reduce amount of swap. > > I tried adding kern.maxswzone to /boot/loader.conf but it complains > > no matter what value I set. > > What should I do? I'm not actually swapping, since I have so much > > memory, so I could turn swap off and re-create the swap partition. > > Correct? RW via freebsd-questions responded: > IIRC there is a hard limit of 4XRAM, and there is an area of the > partition reserved for metadata. I don't recall how the arithmetic is > done, but it may be necessary to make kern.maxswzone a bit smaller than > the number of 4kB pages in 64GB , and/or make the actual partition a bit > smaller than the size implied by kern.maxswzone. Are you sure? What about an old system with 256 or 512 MB RAM that would need swap > 4 * RAM? 64 GB seems like overkill for 16 GB RAM. Tom