From owner-freebsd-questions@freebsd.org Sun Sep 9 12:40:13 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 C1CAE10940D5 for ; Sun, 9 Sep 2018 12:40:13 +0000 (UTC) (envelope-from phascolarctos@protonmail.ch) Received: from mail1.protonmail.ch (mail1.protonmail.ch [185.70.40.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.protonmail.ch", Issuer "QuoVadis Global SSL ICA G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5C42171BE7 for ; Sun, 9 Sep 2018 12:40:12 +0000 (UTC) (envelope-from phascolarctos@protonmail.ch) Date: Sun, 09 Sep 2018 12:40:03 +0000 To: FreeBSD Questions From: Lorenzo Salvadore Reply-To: Lorenzo Salvadore Subject: Re: swap config Message-ID: In-Reply-To: References: <10538979.gLySxXtyIk@chameleon.friedrich.org> Feedback-ID: X6az_D2smWSR8MT5MHqXnWF0upxehDyHia7Id1cbayHNBUkRu3CIeusDsZHiivIIjmaKB1_OofpALrRUYjNz3w==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.1 required=7.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.protonmail.ch 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: Sun, 09 Sep 2018 12:40:13 -0000 > 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 recommend= ed > 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 ma= tter > 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? The swap space you reserve depends of course on what you do with your compu= ter, however 64GB, whatever your use is and whatever the formula you used to determine this is, seems huge to me. Keep in mind that 1. as you say, you already have 16GB of RAM and you are not swapping, henc= e you are waisting 64GB of HD; 2. swap is slow: if you ever happen to need that much swap space, then you= would better have a very fast computer to still use it! I.e. a very fast disk= access (cpu speed is secondary), and I doubt normal computers are able to reach suc= h high speeds. I would suggest you turn off swap completely, without recreating any swap p= artition. In alternative, you could use a zfs filesystem, which would allow you to si= ze your swap space dynamically as you need it and you could still set maxium a= nd minimum swap space if you wanted. Lorenzo Salvadore.