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 1hiDOX-0004mf-C9 for pgsql-general@arkaria.postgresql.org; Tue, 02 Jul 2019 07:40:05 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hiDOW-0003QR-7L for pgsql-general@arkaria.postgresql.org; Tue, 02 Jul 2019 07:40:04 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hiDOV-0003Im-Mm for pgsql-general@lists.postgresql.org; Tue, 02 Jul 2019 07:40:03 +0000 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hiDOS-0007KZ-QY for pgsql-general@lists.postgresql.org; Tue, 02 Jul 2019 07:40:02 +0000 Received: by mail-wm1-x344.google.com with SMTP id c6so2103803wml.0 for ; Tue, 02 Jul 2019 00:40:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec-at.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:date:in-reply-to:references:user-agent :mime-version:content-transfer-encoding; bh=nirXLvDZeT8RhoP4yWBAKLaBCm/Tb7g4EjDuRl9ej74=; b=iK1mXXR+YC4BhjvNLZehzlEWqS+zky4RciLUdtLEjqyFZUi/J0zt/eU4oECxeYwZMV xkmLQuK0/P8atYibvyar2bv2rTcexiFvNMZzME8oselFRsGxFMb2Y7KzquHTG8qNSkTh gXATa08ZDlb0oPtAOoifUDHSAozGd/g3Kyu1x9L7qG+pMzzuJwttOiM8KvPTZPpl1eSb 7goAF6t//JQQVESmeUTeYiTZ68t3LfwFJwQw/scojKUWdnhX808Ey5kokGx3TR1Krc/N S+cqdUBmxwIjt6MJtIAG5u2i1L7AN4qocPvtPzlr+ivMWRiUFI2lEdp3P4hNqBEa/WOT 4EPQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=nirXLvDZeT8RhoP4yWBAKLaBCm/Tb7g4EjDuRl9ej74=; b=uSj2RmBvIQb4cCktlTzFa5YJcuEvxNzOAlTT/mETQ/B3Rk8nfBi/c6K1Y2e6B7qHJX xy7hrnzkjDN9E87dL7bDKUluMfL56uRKixrWLhr1WDqVA3xczPUAGXP48kqbfvBP38Im 9NT/A7gOxmcInuA/nfaTQTCW2lAdIKlmvtdIB2Ue3RsPs+DW6/xyN5sw6Eg4ep0UJIIZ Zf6sOT1iJSJKew5xDvbOiovemSbtVKvmyeWDZKJicGXmN0R8h7UmBRpmRj4hfu+A394X StMfrIAbA9Ona4hOJrdfkT5WYZvSIMemdmvjosaM3ZnV+li+Bbw6FCSyC6zUoJnPnQO9 rfWA== X-Gm-Message-State: APjAAAUHrFs+6ofSanNKr/cx+2gerBQUxOJ519KtWYP9+wqOtKHkKprh rXFwgohTF14a9k9lYFM2Gmc= X-Google-Smtp-Source: APXvYqyyQda4mmjoZmp+pccc7uMPP+tNJmwTsPaI8YaLQJqmcg0Ob4/uIMmXoaySaEQXKPcgBZKbBQ== X-Received: by 2002:a1c:480a:: with SMTP id v10mr2309288wma.120.1562053199359; Tue, 02 Jul 2019 00:39:59 -0700 (PDT) Received: from localhost.localdomain (217-149-169-10.nat.highway.telekom.at. [217.149.169.10]) by smtp.gmail.com with ESMTPSA id x8sm1880619wmc.5.2019.07.02.00.39.58 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Tue, 02 Jul 2019 00:39:58 -0700 (PDT) Message-ID: Subject: Re: Statistics tables not being updated anymore From: Laurenz Albe To: Ron , "pgsql-general@lists.postgresql.org" Date: Tue, 02 Jul 2019 09:39:58 +0200 In-Reply-To: <4939085b-d994-4d35-ce15-f14d6257e64a@gmail.com> References: <4939085b-d994-4d35-ce15-f14d6257e64a@gmail.com> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.30.5 (3.30.5-1.fc29) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Ron wrote: > v9.6.9 > > Statistics views like pg_stat_*_tables, pg_stat_*_indexes, pg_statio_*_tables and pg_statio_*_indexes > aren't being updated anymore. Specifically, all counter fields are 0, and date fields are blank. > > The first thing I checked was postgresql.conf (but it hasn't been modified since December 2018), > and track_activities is turned on. Also, I connect as user "postgres", so it's not a privileges problem. > > Where else should I look? > > track_activities | on > track_activity_query_size | 1024 > track_commit_timestamp | off > track_counts | on > track_functions | none > track_io_timing | off I have seen something like that before, and described the incident in https://www.cybertec-postgresql.com/en/stale-statistics-cause-table-bloat/ What happened there was that during system startup, PostgreSQL was started and created the statistics collector UDP socket on IPv6 localhost. Later in the boot sequence, IPv6 was disabled, so no more statistics could be collected. Since it is an UDP socket, there were no errors. Yours, Laurenz Albe -- Cybertec | https://www.cybertec-postgresql.com