Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lP5Gw-0007HO-9t for pgsql-general@arkaria.postgresql.org; Wed, 24 Mar 2021 15:18:14 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lP5Gv-0001Yl-8Q for pgsql-general@arkaria.postgresql.org; Wed, 24 Mar 2021 15:18:13 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lP5Gt-0001LN-KY for pgsql-general@lists.postgresql.org; Wed, 24 Mar 2021 15:18:13 +0000 Received: from out5-smtp.messagingengine.com ([66.111.4.29]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lP5Gq-0006dl-Os for pgsql-general@lists.postgresql.org; Wed, 24 Mar 2021 15:18:10 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 9016A5C0107; Wed, 24 Mar 2021 11:18:07 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Wed, 24 Mar 2021 11:18:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= subject:to:cc:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm2; bh=2 +oXMn+V1rpXPOSm4QRDNgtyXRgjP5V4Bt6JSxIXsuI=; b=UrrD+nbQAeD6VxRnF iEP6EIQ1wtlYHaDklnqLIgf0iCHhsug6wiLVIoIPJ9Giq/XHWsli8VK38GcIk+EF N15tV/rjLh90r9BCIzjpty1SCjeOggaXfgIumKt5WGUb0rokzsr8rtZ5Yftq9208 x197VgrDJ1CmEKoRoln6d/xCVYckgtOQHQw43+JUsraCEeD7XbXaD7pzZO+rVjHy QtILOhBe6vtc5lGJJwoGyg4Qvn+WD4X295muWw1cxWr9Rbuc22O5T3XlItYKA87s 8rGG+CahzTgN8NfwyaR92924ybz4HwDwaVtlQKrXjVG4+pnig0Mf0HQtMZ+ANtlH m+a9Q== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=2+oXMn+V1rpXPOSm4QRDNgtyXRgjP5V4Bt6JSxIXs uI=; b=GCPczuSrbS3k4xmbKPrE9tQSzdWPEupdmSad4+RFj2yJLuh2Z+TTYcqIx u53NcxU57JA/qUbtTP0VVuTQTiOqPrlOVM257XtZdGeiNgKHR/caIxbM6H4eznZf g/RiaKz1beZtglqsJh7COSRWCmqiyWeagvlKJhcsiyPC2CUxXkNAIDASJ5AEHqnR CVjQLVgWRAb7nKWj+99/0TfZPixJRBc/lqvVTUBqzgniJeHCebqnvfO5VmfUXGDC W/fHydv4cADqtJ252KM53ah1VS/RbZUQ3fMstx1VRu53+TIvjxzRig6ZFTThM3WP PmhbI0MIgI2twtEIH1OlPDYwk8QDg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrudegkedgjeduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefuvfhfhffkffgfgggjtgfgsehtke ertddtfeejnecuhfhrohhmpeetughrihgrnhcumfhlrghvvghruceorggurhhirghnrdhk lhgrvhgvrhesrghklhgrvhgvrhdrtghomheqnecuggftrfgrthhtvghrnhepveevfeevfe eugeffkeekhfegieeufffgteeujedvgffhueejjefhkeejleegtdegnecukfhppeeljedr uddufedrvddujedrvdejnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrg hilhhfrhhomheprggurhhirghnrdhklhgrvhgvrhesrghklhgrvhgvrhdrtghomh X-ME-Proxy: Received: from [192.168.1.4] (97-113-217-27.tukw.qwest.net [97.113.217.27]) by mail.messagingengine.com (Postfix) with ESMTPA id ED4BF240356; Wed, 24 Mar 2021 11:18:05 -0400 (EDT) Subject: Re: No enough privileges for autovacuum worker To: =?UTF-8?B?0JDQvdC00YDQtdC5INCh0YvRh9GR0LI=?= Cc: pgsql-general@lists.postgresql.org References: <1224144510.20210323142019@cifrasoft.com> <18310311052.20210323200728@cifrasoft.com> <1723387856.20210323201857@cifrasoft.com> <56104bce-d461-1fa2-8c8d-96dd4a13ba92@aklaver.com> <913296991.20210323204551@cifrasoft.com> <3510602133.20210324121638@cifrasoft.com> From: Adrian Klaver Message-ID: <87e40ae6-efa8-f930-55e1-cceab4d1d63a@aklaver.com> Date: Wed, 24 Mar 2021 08:18:04 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <3510602133.20210324121638@cifrasoft.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 3/24/21 1:16 AM, Андрей Сычёв wrote: > I finally figured out how to tackle the problem: > > 1. When I manually execute ANALYZE on the table the error remains: > > [34938]-[192.168.67.81]-[DBeaver 7.3.2 - SQLEditor ]-[client backend]-[42501]-[postgres@fpdb] CONTEXT: SQL function "trigrams_vector" during inlining > [34938]-[192.168.67.81]-[DBeaver 7.3.2 - SQLEditor ]-[client backend]-[42501]-[postgres@fpdb] STATEMENT: ANALYZE fpbackup.fp_vpn_data_2021w12 > [31203]-[]-[]-[autovacuum worker]-[42501]-[@] ERROR: permission denied for schema dict at character 34 > [31203]-[]-[]-[autovacuum worker]-[42501]-[@] QUERY: > _to_string(dict.trigrams_array($1), ' ')::tsvector; > > This happens despite I run this query as superuser. But the hint from you > allows me to manually reproduce error. > > 2. As I wrote before the owner of the table > fpbackup.fp_vpn_data_2021w12 is "fpbkwriter" > so I run the following query: > > GRANT USAGE > ON SCHEMA > dict > TO fpbkwriter; > > and after that the problem has been solved. Hmm. I wonder why the error did not occur when the index was created or used? > > 3. The following queries do not affect the problem: > > GRANT EXECUTE > ON ALL FUNCTIONS IN SCHEMA > dict > TO fpbkwriter; > > REVOKE EXECUTE > ON ALL FUNCTIONS IN SCHEMA > dict > FROM fpbkwriter; > > -- > > Adrian, thank you very much for support. > > Your hints were very useful. > -- Adrian Klaver adrian.klaver@aklaver.com