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 1lJo5K-0006dZ-Hc for pgsql-general@arkaria.postgresql.org; Wed, 10 Mar 2021 01:56:26 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lJo5J-0004Jg-8X for pgsql-general@arkaria.postgresql.org; Wed, 10 Mar 2021 01:56:25 +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 1lJo5I-0004JZ-Vc for pgsql-general@lists.postgresql.org; Wed, 10 Mar 2021 01:56:25 +0000 Received: from mail-qv1-xf2a.google.com ([2607:f8b0:4864:20::f2a]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1lJo5C-0006Cj-Nr for pgsql-general@postgresql.org; Wed, 10 Mar 2021 01:56:24 +0000 Received: by mail-qv1-xf2a.google.com with SMTP id h3so35638qvh.8 for ; Tue, 09 Mar 2021 17:56:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:content-transfer-encoding:mime-version:subject:message-id:date :to; bh=PDplSGSIXim7BLMXThMSKYs2HPYFmuo4+ANm8sdxKeA=; b=GFjlw9cXYQBCbEf/NbzCYXB1H0c9JizBEaL4dSKuZ2j3GFAJIhFg6Qmmt/mVA6O3bX nxz5HRfSw6Yn6xg8F3IjfLn/YH76arNFIDPqzDBEe8dd/90Yy6bpi2ldPkU8TKwNUrWn 1jGRjyBsy+JvYxAFmwLdqj4Rqwfy4IuMZvvTFIddwG8nKhNDUCTeKzRcMMHMzW8aNlZi uJ2gqrSiSz+EQhNddQJyZfC67+UICO3kt5GlUS9+3edBxE2QS+y7F/TdZpG9QqLsga3I dAFD/Iiqj6u8Nr5EDQV+VYDx4kHW7opN75uTrEO8UdWTLg1gv90SZPFgIyYk3yywJYVF uymg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:content-transfer-encoding:mime-version :subject:message-id:date:to; bh=PDplSGSIXim7BLMXThMSKYs2HPYFmuo4+ANm8sdxKeA=; b=iGJq/qORcWBbxPQjnmjwy6aua0grj7S7kzEnYaFO1WkmMlajXpRDF6YumRs/drRVX9 6D9/g4ukb6TYnWF2WrFsAwB0xdqzA/NgUZo2RDObarToQgAODeFTWFjADsFTWqMewMeU 7rvTbERM0Rf7GGgWRR5Svytq+OFeSS+Uif9EaMb/o0DEUtb92CeVjUj+HAlv8vUBln2M Re1frArV+gnNF7jaQRMKf6Esw7eLHEP6X5NITmhKIPk5enRNGDgcA4ZziPEDMeFrUbE2 REWfhlZwdw8U5xGAI5ZoyNtLDy4DOW5eo2njmKymBioiQ5dJ8P/wM+eY/xlZGq8hPHSg 7yUg== X-Gm-Message-State: AOAM532Sxcn720e16+b3StWC4LzCG0dtn/BQzBBPyYN2oF8fOiy6UH2s KdlXpDfO4Wn+cp1PdakuN0t5GxwCRT6wRA== X-Google-Smtp-Source: ABdhPJwFRFxEUS7A2ivWOIQ1xzzoJAy7hkhrr7qA6g6XYCSQUAyXqVGurmvBsMJmewyYzfChVaflUw== X-Received: by 2002:ad4:472d:: with SMTP id l13mr797648qvz.17.1615341377366; Tue, 09 Mar 2021 17:56:17 -0800 (PST) Received: from [10.0.1.18] (r167-60-238-95.dialup.adsl.anteldata.net.uy. [167.60.238.95]) by smtp.gmail.com with ESMTPSA id 85sm12007180qkf.58.2021.03.09.17.56.16 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 09 Mar 2021 17:56:16 -0800 (PST) From: =?utf-8?B?TWFydMOtbiBGZXJuw6FuZGV6?= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.60.0.2.21\)) Subject: Logical Replication, CPU load and Locking contention Message-Id: <184F3383-E7EC-40FB-8D9B-42E8EBC8D92C@gmail.com> Date: Tue, 9 Mar 2021 22:56:15 -0300 To: pgsql-general@postgresql.org X-Mailer: Apple Mail (2.3654.60.0.2.21) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hello, I=E2=80=99m troubleshooting a problem at my company with a pg 12 cluster = that we run. We are using Amazon DMS to replicate data from our database into S3 = buckets. DMS replicates data by using logical replication slots.=20 After introducing DMS in our environment, we have seen an increase in = CPU load of 20 points at business hours (from ~60% to ~80%). The other thing that we have identified is that AccessShareLocks = increase considerably when DMS running. Based on this information, I=E2=80=99m trying to understand if this is = something expected when running logical replication or not. We=E2=80=99ve = been running physical replication for several years and we haven=E2=80=99t= seen nothing like this. It could be the case that the issue is not = related at all with logical replication and is purely a DMS artifact.=20 Thanks before hand! Best, Mart=C3=ADn=