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 1n9jLf-0005fs-Kz for pgsql-hackers@arkaria.postgresql.org; Tue, 18 Jan 2022 07:56:11 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1n9jLd-0001xc-HJ for pgsql-hackers@arkaria.postgresql.org; Tue, 18 Jan 2022 07:56:09 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n9jLd-0001xS-6G for pgsql-hackers@lists.postgresql.org; Tue, 18 Jan 2022 07:56:09 +0000 Received: from mail-pl1-x634.google.com ([2607:f8b0:4864:20::634]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1n9jLY-0003ta-6j for pgsql-hackers@lists.postgresql.org; Tue, 18 Jan 2022 07:56:08 +0000 Received: by mail-pl1-x634.google.com with SMTP id a7so20882926plh.1 for ; Mon, 17 Jan 2022 23:56:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=SxtHDZv8a+ERV2trBY6LgKqYjlIcHFva582D6qD+68c=; b=Y3VPhGdEMRw0V82F82GvoR3qUD1T10m0TlDAiRA/302wU4G06mwFo9XdOGziEBdr8d n/fkc8WNYyBnDghmH5teyJ6iSAdcBO5s2Nmz7D6f/S0XYYCxcbT88aIn6/zyzX8i1wsD MkkPkUn1FohJJm0OnsFcv0zPE/OxsyzEr9N1ctl07cbG5AyltEOS2krID6H5p884AMjc zPuUqmMtzWJj5KQOAn41tm5tAwr8NjsCrpCRjxDTjfJZeBcwSOpfyqOHKrFnxyaA1fEd QReNKyUy64jXUyjX88MnRSS4PDz8J7DQ624Qu8nMvFijZF/0CO/RuHhE9+/RtSex8U+u BKYQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=SxtHDZv8a+ERV2trBY6LgKqYjlIcHFva582D6qD+68c=; b=rgBQC21QQp8HlGn1UBYTUK/q925Z0CCJ/kD43kqJ5b9bTfY1l+t/aBNTFnAogNfmqc QDemi9M9M/vX+XlJ3fcD/c0CRfdOcmjvjnSR/+WhH3gfbCrAnTqkj8goKsu1bm9mv4nj Vni9vUwNzJDZiLxEFW3mQ+iHvB3PmGFeLbhSPz2wSuLmh8ai7Wcodu4zQpxRjphsep+n k0qjiuHwqSJ7nFqlnI70r4AwWGBjUXIbKFBHkiwCYHa6JtCcDuAhXOXr5D6mw5loMOch gOmKAkANBtzb1Q6SGWL9Kjt9/on71OABuzSojgK9c0kftRojIo3DeSiSwWcQLyWIPY2V daXg== X-Gm-Message-State: AOAM532sBW6YyfA/yH8uy3VyHPMcWIjoU4qmclVPgMU5PoasrPC48V4F N0HvLZATYsRHkvz4zTQK2fg= X-Google-Smtp-Source: ABdhPJyxjRPr3Ram1IwBgTtVQd4YyVcpdkp6/C0XvsKCM2hHHbj3oQILXbmrzdFZP3/NdAEmfRRLjg== X-Received: by 2002:a17:90b:4c11:: with SMTP id na17mr34037930pjb.206.1642492561861; Mon, 17 Jan 2022 23:56:01 -0800 (PST) Received: from jrouhaud (1-171-184-213.dynamic-ip.hinet.net. [1.171.184.213]) by smtp.gmail.com with ESMTPSA id nn1sm1773001pjb.16.2022.01.17.23.56.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Jan 2022 23:56:01 -0800 (PST) Date: Tue, 18 Jan 2022 15:55:58 +0800 From: Julien Rouhaud To: Bharath Rupireddy Cc: Peter Eisentraut , PostgreSQL Hackers Subject: Re: Is there any documentation on how to correctly create extensions in HA(primary-standby) setup? Message-ID: <20220118075558.nytdwy6b2c7tkvzw@jrouhaud> References: <270122d3-7591-666e-44db-7894e8539c45@enterprisedb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, On Thu, Dec 09, 2021 at 08:19:06AM +0530, Bharath Rupireddy wrote: > > Thanks. Attaching v1 patch specifying the notes there. Please review. I think that the common terminology is "module", not "extension". That's especially important here as this information is also relevant for modules that may come with an SQL level extension. This should be made clear in that new documentation, same for the CREATE EXTENSION part that may not be relevant. It also seems that this documentation is only aimed for physical replication. It should also be explicitly stated as it might not be obvious for the intended readers. + [...] set it either via ALTER SYSTEM + command or postgresql.conf file on both primary and + standys, reload the postgresql.conf file and restart + the servers. Isn't the reload a terrible advice? By definition changing shared_preload_libraries isn't compatible with a simple reload and will emit some error. + [...] Create the extension on the primary, there is no need to + create it on the standbys as the CREATE EXTENSION + command is replicated. The "no need" here is quite ambiguous, as it seems to indicate that trying to create the extension on the standby will work but is unnecessary.