From owner-freebsd-current@freebsd.org Sat Aug 19 16:54:18 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7710DDD3FFA for ; Sat, 19 Aug 2017 16:54:18 +0000 (UTC) (envelope-from cy.schubert@komquats.com) Received: from smtp-out-no.shaw.ca (smtp-out-no.shaw.ca [64.59.134.13]) (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 4DAF180F8F for ; Sat, 19 Aug 2017 16:54:17 +0000 (UTC) (envelope-from cy.schubert@komquats.com) Received: from spqr.komquats.com ([96.50.22.10]) by shaw.ca with SMTP id j70jd8caWI8mCj70kd5CAJ; Sat, 19 Aug 2017 10:54:11 -0600 X-Authority-Analysis: v=2.2 cv=HahkdmM8 c=1 sm=1 tr=0 a=jvE2nwUzI0ECrNeyr98KWA==:117 a=jvE2nwUzI0ECrNeyr98KWA==:17 a=kj9zAlcOel0A:10 a=KeKAF7QvOSUA:10 a=vxP3BzG0AAAA:8 a=YxBL1-UpAAAA:8 a=6I5d2MoRAAAA:8 a=H1F7QWHVIKXboCpJM1oA:9 a=CjuIK1q_8ugA:10 a=4tHceQipB5Rc01mo_vQZ:22 a=Ia-lj3WSrqcvXOmTRaiG:22 a=IjZwj45LgO3ly-622nXo:22 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTPS id 5BCA31C72; Sat, 19 Aug 2017 09:54:09 -0700 (PDT) Received: from slippy (localhost [127.0.0.1]) by slippy.cwsent.com (8.15.2/8.15.2) with ESMTP id v7JGs8sM063853; Sat, 19 Aug 2017 09:54:09 -0700 (PDT) (envelope-from Cy.Schubert@cschubert.com) Message-Id: <201708191654.v7JGs8sM063853@slippy.cwsent.com> X-Mailer: exmh version 2.8.0 04/21/2012 with nmh-1.6 Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: tech-lists cc: freebsd-current@freebsd.org Subject: Re: swapfile query In-Reply-To: Message from tech-lists of "Sat, 19 Aug 2017 16:00:28 +0100." <77fdd002-2873-eb67-c851-0127ae3141b6@zyxst.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sat, 19 Aug 2017 09:54:08 -0700 X-CMAE-Envelope: MS4wfOQswzVI8H/9zRReiNDOnN7kOoPdohQzJYxeUfj+zo+jMCbwe76byinIm75E8ZHNqcDkfpEsSqsFJFsyejcomKCRAi3LK2xyaqj6ZZHo4V/ur2UMVt3B +a4i5xOgc5q+bYcymkcRRhDNcNIsblOQ0Dg2LJsKbQNYKzJ9uUYUg8fWCiv1HtetnLrzZeKglu97hb2MP6vH2hfuJDHgRNW4XX92oH81Xd6Ib8Eo+52D86Pm X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Aug 2017 16:54:18 -0000 In message <77fdd002-2873-eb67-c851-0127ae3141b6@zyxst.net>, tech-lists writes: > Hello list, > > (freebsd-current is r317212 on this machine) > > I have a machine with 128GB RAM. When 12-current was installed, for some > reason the swap partition was set to 4GB. I see sometimes via top and > also via daily status reports that sometimes the machine runs out of > swap. It doesn't crash the machine though. > > I know how to add more swap with a swapfile. My questions are: > > 1. should I make more than one swapfile, say 4x32GB or will it be ok > with one 128GB swapfile? It's better to spread the load across multiple spindles. > > 2. will the 4GB already there as swap play nice with a swapfile, or > multiple swapfiles? Or should I deactivate the 4GB swap partition first? Is the 4 GB on the same disk as another swapfile? > > 3. should total swap be 1x 2x or some other multiple of RAM these days? Depends. If you're running some kind of database server or OLTP application. Some vendors recommend no swap whatsoever while others recommend some. What does your application vendor recommend? > > FreeBSD and the swap partition reside on the same SSD. The swapfiles, if > created, will reside on this SSD. Then it doesn't matter if you use one or many swapfiles and deleting the 4 GB won't make a difference. Just add the desired swap as required. With 128 GB RAM you shouldn't be swapping anyway. If your system is you have more serious problems than the lack of swap. -- Cheers, Cy Schubert FreeBSD UNIX: Web: http://www.FreeBSD.org The need of the many outweighs the greed of the few.