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 1j5c5B-0004pJ-Oq for pgsql-general@arkaria.postgresql.org; Sat, 22 Feb 2020 21:13: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 1j5c5A-00084A-9a for pgsql-general@arkaria.postgresql.org; Sat, 22 Feb 2020 21:13: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 1j5c59-000843-ST for pgsql-general@lists.postgresql.org; Sat, 22 Feb 2020 21:13:04 +0000 Received: from out2-smtp.messagingengine.com ([66.111.4.26]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1j5c57-0006ld-ME for pgsql-general@postgresql.org; Sat, 22 Feb 2020 21:13:02 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id E7ADE21ADD; Sat, 22 Feb 2020 16:13:00 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute6.internal (MEProxy); Sat, 22 Feb 2020 16:13:00 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= subject:to:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm2; bh=T Jwiqch7QShh86dULvICLI7ODLkE+LjjxELdMgFA+VE=; b=V1ic0/b2UXxFwrtRP +3ovN38fR61A58j16XAIg8U0yd+RRuzJrlaMhz88tYYOxBVQalAYcSkH9J22e/21 zbMimRYY1gUYyv7WfYDm5BHFXSu4TSMmZQJFwveRN5J/PZfWL3XuWU2tL0i+LP4J ouUk+9xasQct+99hbyee4NBD025a6XpzEymNJTLbA2Zr7IpwqmA3Vky7cOFWE6NP ZaNHaB631477M8xVikBYSHOD3uQqgcZVaMdPC+ymo+aBq1UqpogAak+UMuSAErVS w3P6NTRwIPEcgZZiSzimW78nN75uG/z2WfN1rlZURW5xd9Zh4nRISUcr2Lexlw3d +p6Pg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=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=TJwiqch7QShh86dULvICLI7ODLkE+LjjxELdMgFA+ VE=; b=FJegES9v/Ih+uvpykk6cNCf/LWWA8vygwBeBFfz/AQVYI1uIL3jvMEJ4L JKGB+NeFuAzySxw0XvidlCv0o2zTpSC0RnHaXj0c5CD9CRGyyTGPPkW9UArDAvHR 6s0FSp2AyPUpsDkR8XdmOVJLU0C94NaKX6tRAAnipbqGroyAbgSUmkGGa0fd0V7r BC195FZPNlK7YXYuOaqZ9f0VhTNwGb/Ge3naEJRZ/bp+LWD+Po2hEBOLNr1em/j+ WlSdjWlHcI9SEow7PZty2lxzLGQrci7tL2ykGp0g8vkY7CSx4FqyvnZ4pTbJsZ3k 0QPVis/zQ6lUQfZQYh7hpFg475Geg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrkeeigddugeejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepuffvfhfhkffffgggjggtgfesthekredttdefheenucfhrhhomheptegurhhi rghnucfmlhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtoh hmqeenucfkphepjedurddvuddvrdduvdelrdduleefnecuvehluhhsthgvrhfuihiivgep tdenucfrrghrrghmpehmrghilhhfrhhomheprggurhhirghnrdhklhgrvhgvrhesrghklh grvhgvrhdrtghomh X-ME-Proxy: Received: from [192.168.1.10] (unknown [71.212.129.193]) by mail.messagingengine.com (Postfix) with ESMTPA id 6882F3060FCB; Sat, 22 Feb 2020 16:13:00 -0500 (EST) Subject: Re: Replication: slave server has 3x size of production server? To: Edson Richter , pgsql-general References: <98f036e0-9bf2-8798-8742-9dba0601fb9a@aklaver.com> <590174e0-256a-fe72-468a-0bcf77ca0df8@aklaver.com> From: Adrian Klaver Message-ID: <46ab8dff-645a-0521-16e8-821db6fc6d9c@aklaver.com> Date: Sat, 22 Feb 2020 13:12:59 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2/22/20 11:23 AM, Edson Richter wrote: > ------------------------------------------------------------------------ > > *De:* Adrian Klaver > *Enviado:* sábado, 22 de fevereiro de 2020 16:16 > *Para:* Edson Richter ; pgsql-general > > *Assunto:* Re: Replication: slave server has 3x size of production > server? > On 2/22/20 11:03 AM, Edson Richter wrote: > >     ------------------------------------------------------------------------ > > > > > > > > > Streaming replication. Initiated via pg_basebackup. > > > > Settings on master server: > > > > # - Sending Server(s) - > > # Set these on the master and on any standby that will send replication > > data. > > max_wal_senders = 2             # max number of walsender processes > > (change requires restart) > > wal_keep_segments = 25          # in logfile segments, 16MB each; 0 disables > > #wal_sender_timeout = 60s       # in milliseconds; 0 disables > > max_replication_slots = 2       # max number of replication > > slots (change requires restart) > > #track_commit_timestamp = off   # collect timestamp of transaction > > commit (change requires restart) > > # - Master Server - > > # These settings are ignored on a standby server. > > #synchronous_standby_names = '' # standby servers that provide sync > > rep number of sync standbys and comma-separated list of > > application_name from standby(s); '*' = all > > #vacuum_defer_cleanup_age = 0   # number of xacts by which cleanup is > > delayed > > > > > > > > Settings on slave server: > > > > # - Standby Servers - > > # These settings are ignored on a master server. > > hot_standby = on                        # "on" allows queries during > > recovery (change requires restart) > > max_standby_archive_delay = -1          # max delay before canceling > > queries when reading WAL from archive; -1 allows indefinite delay > > max_standby_streaming_delay = -1        # max delay before canceling > > queries when reading streaming WAL; -1 allows indefinite delay > > wal_receiver_status_interval = 10s      # send replies at least this > > often 0 disables > > hot_standby_feedback = on               # send info from standby to > > prevent query conflicts > > wal_receiver_timeout = 0                # time that receiver waits for > > communication from master in milliseconds; 0 disables > > wal_retrieve_retry_interval = 5s        # time to wait before retrying > > to retrieve WAL after a failed attempt > > What are the settings for: > > archive_mode > archive_command > > on the standby? > > Are the files in pg_xlog on the standby mostly from well in the past? > > > Actually, standby server is sending wals to a backup (barman) server: > > archive_mode = always           # enables archiving; off, on, or always > (change requires restart) > archive_command = 'rsync -e "ssh -2 -C -p 2022" -az %p > barman@192.168.0.2:/dados/barman/dbcluster/incoming/%f' And the above is working, the files are showing up on the barman server? > > > The files are about 7 months old. Are there newer files that would indicate that the streaming is working? > > > Thanks, > > Edson > > > > > > > Regards, > > > > Edson > > > >     > > >     > > >     > Edson > >     > > > > >     -- > >     Adrian Klaver > >     adrian.klaver@aklaver.com > > > > > -- > Adrian Klaver > adrian.klaver@aklaver.com > -- Adrian Klaver adrian.klaver@aklaver.com