From owner-freebsd-questions@freebsd.org Mon Jan 21 16:03:11 2019 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 022C114ADD4D for ; Mon, 21 Jan 2019 16:03:11 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: from mail-wr1-x433.google.com (mail-wr1-x433.google.com [IPv6:2a00:1450:4864:20::433]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E287B8FAC1 for ; Mon, 21 Jan 2019 16:03:08 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: by mail-wr1-x433.google.com with SMTP id t27so23997273wra.6 for ; Mon, 21 Jan 2019 08:03:08 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=NkglY3DJgJdCmFvzrWBfh+cWKVjFLL305bo0fglf3XE=; b=Xd4yFttqzRXzd2h792JnMB6SueOOdZ1gYZ8zJ01rRx9dRFr0r7oEe2PSjH+dOl4X0J 8/+yFNrxWox5pXTwU/tVzFXVszT+Y3p0ymtUrMiq2Wo1wq7hB4hQBm7/eM7Z3uiPT0wD 64Jtg2BdxTvHO76QJi5hPxXbvV5fq0+jdFyISHzPOKsUYsZnLSfP/Nhy6CpSSes7Vo1N 08A8CZSTLc6ZPLivd9gxpKdmblrdkuV1vSItfhePU/mnn6hvnGIhdXyOmjPex+MGuxI2 eJAUS0EXwADPEfZ6TwC7TpFskfpbYXTtBQ6tDTOmfPCqtUQp8cXVX1bjBCt+AW0Dx8Kv 5rrQ== X-Gm-Message-State: AJcUuke/Fu6NNGBTwoqCca9tnLyzpPegyLuqaO7kTtywD4/K4rbmjgJ6 vJYf1k32WLYPbM1URnlrg/Erj6lU5mg= X-Google-Smtp-Source: ALg8bN4g1HE3nBVhFsuCo7G4akxtau98NfnIeeK9MvsHV3G1o69V2kcBJWaP62WkVT+7NZf2YRFvYw== X-Received: by 2002:adf:9ec8:: with SMTP id b8mr30031664wrf.164.1548086586796; Mon, 21 Jan 2019 08:03:06 -0800 (PST) Received: from gumby.homeunix.com ([90.211.170.244]) by smtp.gmail.com with ESMTPSA id l20sm198866805wrb.93.2019.01.21.08.03.05 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 21 Jan 2019 08:03:06 -0800 (PST) Date: Mon, 21 Jan 2019 16:03:02 +0000 From: RW To: freebsd-questions@freebsd.org Subject: Re: The mysterious kern.maxswzone Message-ID: <20190121160302.0a5e2805@gumby.homeunix.com> In-Reply-To: <50f1f8d5-7db6-4abb-6beb-c82f17396304@netfence.it> References: <20190116022046.GA45024@admin.sibptus.ru> <50f1f8d5-7db6-4abb-6beb-c82f17396304@netfence.it> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; amd64-portbld-freebsd11.2) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: E287B8FAC1 X-Spamd-Bar: ------ X-Spamd-Result: default: False [-6.71 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[googlemail.com]; TO_DN_NONE(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[googlemail.com:+]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DMARC_POLICY_ALLOW(-0.50)[googlemail.com,quarantine]; NEURAL_HAM_SHORT(-0.98)[-0.978,0]; RECEIVED_SPAMHAUS_PBL(0.00)[244.170.211.90.zen.spamhaus.org : 127.0.0.10]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[googlemail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; DWL_DNSWL_NONE(0.00)[googlemail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; R_DKIM_ALLOW(-0.20)[googlemail.com:s=20161025]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; IP_SCORE(-2.72)[ip: (-9.53), ipnet: 2a00:1450::/32(-2.15), asn: 15169(-1.86), country: US(-0.08)]; RCVD_IN_DNSWL_NONE(0.00)[3.3.4.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2019 16:03:11 -0000 On Mon, 21 Jan 2019 08:56:05 +0100 Andrea Venturoli wrote: > On 1/16/19 3:20 AM, Victor Sudakov wrote: > > > > > warning: total configured swap (131072 pages) exceeds maximum > > recommended amount (113792 pages). warning: increase kern.maxswzone > > or reduce amount of swap. > > Many of my systems show this warning: in general it's harmless and > you can ignore it. Do you know, for sure, that there isn't a risk of a panic if you run out of zone space before you run out of swap. > > # sysctl kern.maxswzone > > kern.maxswzone: 36175872 > > This is strange: on all my boxes (all 11.2/amd64) kern.maxswzone=0. > If you did not set this manually (where, I don't know), perhaps this > is an i386 vs amd64 thing. That rings a bell. In i386 kern.maxswzone defaults to that fixed value of 36175872. In other architectures it defaults to zero, which means use a computed amount based on RAM size. In amd64 you can't increase the zone size because that computed default is also the limit. In this case, with i386, 36175872 is below the limit, so you can increase it. The value is in bytes, so it isn't huge. Try setting it to a few percent above 36175872 * 131072 / 113792 something like 42500000 It should be set in loader.conf, not via sysctl.