Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1itu4W-0007RG-Tc for pgsql-hackers@arkaria.postgresql.org; Tue, 21 Jan 2020 14:00:01 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1itu4U-0002Yh-Dg for pgsql-hackers@arkaria.postgresql.org; Tue, 21 Jan 2020 13:59:58 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1itu4U-0002Ya-4W for pgsql-hackers@lists.postgresql.org; Tue, 21 Jan 2020 13:59:58 +0000 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1itu4Q-0003bG-0s for pgsql-hackers@postgresql.org; Tue, 21 Jan 2020 13:59:57 +0000 Received: by mail-wm1-x32e.google.com with SMTP id t14so3122692wmi.5 for ; Tue, 21 Jan 2020 05:59:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=UfDyTk8fWI+rswRaSx6FvcgT5Fk9bAVznyIt/Gy4+9w=; b=A3AIQNphkXm6+aszx2OoxUvqVZuGO7SNxrbEhF8hybeODWwMLBX+jZCrzBP8RBGV9e YnPRFLffaO24X4wj27yfkS/Cli2dEHLk0F1CpYYfZb+/RXHjZOr4TAGP9jHFVUshwwQj PJuBvFpIxOVWl97Dt48Jovv9HDZiazsV7G0pQGmNKYfb6lLOQMLEksWXQA1WSgSh0Tmv xJBJRfkaGx84VqnH5j+WxPQBRIsfBtFRNTkMGbFQPmLOSNHTu3QfmZjN4l68jxK41fZz 8BjUwfQFNr1iAD6s2/+nI3Rf1gLukBJ5YVVFxZZnB7DNw1kGKRYoUGMHp99UD+I19YFt WjDw== 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:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=UfDyTk8fWI+rswRaSx6FvcgT5Fk9bAVznyIt/Gy4+9w=; b=MyQ1xfnViweW+A135bIkt1xmt1Nv4c1BgUXwzHd6jNOIhHdW1124Bzye1cF/gMTyNX p+vS1ek7JXJKCGVUDUovr5+bt+4HTvbHYq+qNfV28xOvf8GndOZYCyz+P/YkH7JqSe51 Tg1FWgNAY5t6PwXV+xIlG8Rj6hbwAhn+jaT34YoEUXoymNLyWOSCwf5x9vc1eMULow+B HVQi9PfTUmoGkwanRIvJ6v4pIGNKjRYWkgMrkG6qcwWIUnN1f0bi0VDirWbD4gOj85BR LHVMiofBNHlL2EOyKRtzgqpKdxt40Qs7joplpMp+TB8ZYfptR/DX0BpXIcYtPDjcFQ0E b4OQ== X-Gm-Message-State: APjAAAWFZ+oi+Qr5Q5d8VPx5YMfgSiUblvAePcO6SkJcvclcLgRcqk8Y 4CSXut3bN7qdmE5icqFNgOV1sg== X-Google-Smtp-Source: APXvYqyAzDcHZSAbeiio3Hw/gVzYaRGo+yj2llJIpVhFb7dvDBpesr8qRaS79ukUyuN42wKqn7KB8g== X-Received: by 2002:a1c:6707:: with SMTP id b7mr4593300wmc.54.1579615193439; Tue, 21 Jan 2020 05:59:53 -0800 (PST) Received: from localhost (static-84-42-175-93.net.upcbroadband.cz. [84.42.175.93]) by smtp.gmail.com with ESMTPSA id e8sm52625474wrt.7.2020.01.21.05.59.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Jan 2020 05:59:52 -0800 (PST) Date: Tue, 21 Jan 2020 14:59:51 +0100 From: Tomas Vondra To: "tsunakawa.takay@fujitsu.com" Cc: "pgsql-hackers@postgresql.org" Subject: Re: SLRU statistics Message-ID: <20200121135951.dlmhe2tjpqktfn4b@development> References: <20200119143707.gyinppnigokesjok@development> <20200120163754.mbbkbhzaummlo47c@development> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Tue, Jan 21, 2020 at 06:24:29AM +0000, tsunakawa.takay@fujitsu.com wrote: >From: Tomas Vondra >> You're right the users can't really take advantage of this - my >> primary motivation was providing a feedback for devs, benchmarking >> etc. That might have been done with DEBUG messages or something, but >> this seems more convenient. > >Understood. I'm in favor of adding performance information even if it >doesn't make sense for users (like other DBMSs sometimes do.) One >concern is that all the PostgreSQL performance statistics have been >useful so far for tuning in some way, and this may become the first >exception. Do we describe the SLRU stats view in the manual, or hide >it only for PG devs and support staff? > Yes, the pg_stat_slru view should be described in a manual. That's missing from the patch. > >> I think it's unclear how desirable / necessary it is to allow users >> to tweak those caches. I don't think we should have a GUC for >> everything, but maybe there's some sort of heuristics to determine >> the size. The assumption is we actually find practical workloads >> where the size of these SLRUs is a performance issue. > >I understood that the new performance statistics are expected to reveal >what SLRUs need to be tunable and/or implemented with a different >mechanism like shared buffers. > Right. It's certainly meant to provide information for further tuning. I'm just saying it's targeted more at developers, at least initially. Maybe we'll end up with GUCs, maybe we'll choose other approaches for some SLRUs. I don't have an opinion on that yet. regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services