Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sxB8H-008QOp-5g for pgsql-general@arkaria.postgresql.org; Sat, 05 Oct 2024 20:12:05 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1sxB8F-004ZWA-AA for pgsql-general@arkaria.postgresql.org; Sat, 05 Oct 2024 20:12:03 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sxB8E-004ZUD-D0 for pgsql-general@lists.postgresql.org; Sat, 05 Oct 2024 20:12:02 +0000 Received: from fhigh-a8-smtp.messagingengine.com ([103.168.172.159]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sxB8B-002glU-Ic for pgsql-general@lists.postgresql.org; Sat, 05 Oct 2024 20:12:01 +0000 Received: from phl-compute-08.internal (phl-compute-08.phl.internal [10.202.2.48]) by mailfhigh.phl.internal (Postfix) with ESMTP id C03FE11400F2; Sat, 5 Oct 2024 16:11:58 -0400 (EDT) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-08.internal (MEProxy); Sat, 05 Oct 2024 16:11:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm1; t=1728159118; x=1728245518; bh=7V6LidEN/BCrshA1fRNu2+camXA7HtqFdZUY+agE+7o=; b= C4hqIroywgMTLV+YKOcnVbpZzTX5Co1Fu1wEdquy+umWmHfPT4Pk8if338aLROUf gWLDvRumMe5aqxFoTESSgzMxOIdhkVuizvp1zap70tW25EoRC6uCblU77nOgJAP+ e73/UssguFTr5s/7yGs5YQp++0S8fCZ+gCzXwdGje7KWu0ZZYa7ghNLOUM8KQccl R02seLCN4ryTgewYQuZMb2UKVEpk1x+aZmXw40+qrgVfomVRgdByqe6ahYaDU/Sx Vy39GK6UbK1gSS1Apb+2GkNocVeDAW9TmEJ/b7AiuF2zt1tMqoDedAN/p0DJYMiV 7RsWQ3BIW4bhiEPdgstZDw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1728159118; x= 1728245518; bh=7V6LidEN/BCrshA1fRNu2+camXA7HtqFdZUY+agE+7o=; b=B 7QwAKTkiFimfx9jdbKNToOdFQbmTF/YwiABAcNLPEzenEEKk8nngfr/wnGdIwLlm wuKqg8LLtnv1Yjp89t6xyb8JKLUSciWJrb2eiicuP9Lfk3/UwRW1vF5S1eh9sPL5 QjxAe5dCvoGfyVbUX/Mno3ocmqOUvIZO9A5+NhtNjexSt4YB9RhYySbBOFyIQx7y k3i8r1ld1dAcaIOTzsz6/RN243yK5/KR5u5ZA6pFHXTdLKOu+u/YualluTrtEpQ6 ND1m7wSHu9ccbKiofbJDPqLNh0v12rLioWSxbmH+geWVwlLjnpB8cYHtdfQ/3hfm O0TXDUUVf3M6VPLwIaelA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeftddrvddvhedgudegjecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenucfjughrpefkffggfgfuvfevfhfhjggtgfesthekredttddv jeenucfhrhhomheptegurhhirghnucfmlhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvg hrsegrkhhlrghvvghrrdgtohhmqeenucggtffrrghtthgvrhhnpeefgeefieeutdfggfet gefgheekjeehteeileeigfetieekjedvieeviefgheevtdenucevlhhushhtvghrufhiii gvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegr khhlrghvvghrrdgtohhmpdhnsggprhgtphhtthhopeefpdhmohguvgepshhmthhpohhuth dprhgtphhtthhopehmiigrghhrrggsvgesugdruhhmnhdrvgguuhdprhgtphhtthhopegu rghvihgurdhgrdhjohhhnhhsthhonhesghhmrghilhdrtghomhdprhgtphhtthhopehpgh hsqhhlqdhgvghnvghrrghlsehlihhsthhsrdhpohhsthhgrhgvshhqlhdrohhrgh X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sat, 5 Oct 2024 16:11:57 -0400 (EDT) Message-ID: <8fec88b9-355f-487d-95ad-103af2229fde@aklaver.com> Date: Sat, 5 Oct 2024 13:11:56 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: grant connect to all databases To: Matt Zagrabelny Cc: "David G. Johnston" , "pgsql-generallists.postgresql.org" References: <0c089041-d4eb-4bf4-bfcb-6451224190c9@aklaver.com> Content-Language: en-US From: Adrian Klaver In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 10/5/24 11:24, Matt Zagrabelny wrote: > > > Nope. I create the role (via puppet) and then add the GRANT > pg_read_all_data TO (via puppet). > > What is \drgS? I don't believe I have that. That is available in Postgres 16+, you must running be in an instance of Postgres before that. >  'CREATE ROLE "alice" ENCRYPTED PASSWORD \'$NEWPGPASSWD\' LOGIN > NOCREATEROLE NOCREATEDB NOSUPERUSER  CONNECTION LIMIT -1' > GRANT pg_read_all_data TO alice; > >  ...but I still cannot connect: > > $ psql -d test -U alice > psql: error: connection to server on socket > "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL:  permission denied > for database "test" > DETAIL:  User does not have CONNECT privilege. Something is going on in the background. What version of Postgres? Where did you install it from or where are you running it? > > Thanks for the help! > > -m -- Adrian Klaver adrian.klaver@aklaver.com