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 1iQFcw-0003fA-0q for pgsql-general@arkaria.postgresql.org; Thu, 31 Oct 2019 18:56:58 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iQFcu-0000Lk-Fu for pgsql-general@arkaria.postgresql.org; Thu, 31 Oct 2019 18:56:56 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iQFcu-0000Lc-2T for pgsql-general@lists.postgresql.org; Thu, 31 Oct 2019 18:56:56 +0000 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iQFcq-0005dG-Ie for pgsql-general@lists.postgresql.org; Thu, 31 Oct 2019 18:56:55 +0000 Received: by mail-wm1-x343.google.com with SMTP id 11so7106755wmk.0 for ; Thu, 31 Oct 2019 11:56:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=BZNv6fk2zk1Yh7Fkmy6nhqHa6g1EblvanNncHSul9o8=; b=Zxoxc6lU8tcAiXQHX6dXlKzZu9sGny84JGPbpB5DGQ5976q828bIveWGSeiOAoO4+F H8354syb4NjcPhcfoeRdgjSQzoLD+HQtBwsh/OWv4XFqsbBdU8CZIm2WW9pgzgXopnyV LT0dxVU8Exc4tZMhYumcG10aV7Zts3lOQqvwd/4iLXuQlyfWZ7cjn4DyHx0K1WJwCz1X TVrS2QfjlMB7316IZjISQffqqao5M93mfTayDpUzXGYMAt29txgeA+U5JE1d4GbTwrwh PAORKGZEg9wILefV+ATXJrNlui+LoWHyvgU6lMjslB4nJpABOgLb+ZzApdT+PzTz3o7o FD9A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=BZNv6fk2zk1Yh7Fkmy6nhqHa6g1EblvanNncHSul9o8=; b=PMa+T80WGxRsu8k2g6bI1S48Krsv6M3FoQPRvqHnu5ZPskmrCvzknPADwjkFnv5+Kk JYtRO7/JuyKKzU3mgW3fdm2QCb6Bf4Aw2CT+6rljCZ3qSeuKHMYzjdvivP271z++oJhq 2OCzeAw5Vj0ph7t1ZfvDYbuETSsBVsBEHJB8YrLzZpAXHgcAlTvHGjBfDSo1cnlYb5dF bneJoQgBxulXddU8w4dVkPYV58NXBD+3zSbo2PoNQnkJ4r87tL4s6ZdO5f3l4/DOvjt4 6elruIgUFjHMwTw1lZH3codEdFiEHy8M/sampmjh394/U5e6mnJzZVbxWSDjIPqNpCAw 1kXg== X-Gm-Message-State: APjAAAWTFABsVXYiPQmwert76MKm4w1W5EE/NJY938n2zGnCMX/bz+sq NGKJCuc+uS0B3k5/B9fCYdrUMA== X-Google-Smtp-Source: APXvYqyBTf60TVvSuNviJIpG0iuoNiGVvI0LdZcdwt6R9u8JIvwGBBbF58k6g208JfehcIpsxPrdyw== X-Received: by 2002:a1c:f208:: with SMTP id s8mr6429785wmc.82.1572548210333; Thu, 31 Oct 2019 11:56:50 -0700 (PDT) Received: from localhost (static-84-42-175-93.net.upcbroadband.cz. [84.42.175.93]) by smtp.gmail.com with ESMTPSA id 1sm4760639wrr.16.2019.10.31.11.56.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 31 Oct 2019 11:56:49 -0700 (PDT) Date: Thu, 31 Oct 2019 19:56:46 +0100 From: Tomas Vondra To: Daulat Ram Cc: "pgsql-general@lists.postgresql.org" , "pgsql-performance@lists.postgresql.org" Subject: Re: Barman Message-ID: <20191031185646.g6rmxczyowdhpeyg@development> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Thu, Oct 31, 2019 at 05:29:34PM +0000, Daulat Ram wrote: >Hi All, > >We have configured postgres 11.2 in streaming replication (primary & >Standby) on docker and I am looking to initiate the Postgres backup >using barman. As I know there are few options for taking backup using >barman. > >RSYNC backup >Incremental Backups >Streaming Backup with continuous WAL streaming >Centralized and Catalogued Backups > >Which is the best option for backup using barman? So that we can keep >the database safe in case of disaster? I feel the Incremental Backups >are most useful to perform the PITR but I want to know the experts >suggestions. > You're mixing a number of topics, here. Firstly, all backups done by barman are centralized and catalogued, that's pretty much one of the main purposes of barman. When it comes to backup methods, there are two basic methods. rsync and postgres (which means pg_basebackup). This is about creating the initial base backup. Both methods then can replicate WAL by either streaming or archive_command. So first you need to decide whether to use rsync and pg_basebackup, where rsync allows advanced features like incremental backup, parallel backup and deduplication. Then you need to decide whether to use archive_command or streaming (i.e. pg_receivexlog). The "right" backup method very much depends on the size of your database, activity, and so on. By default you should probably go with the default option, described as "scenario 1" in the barman docs, i.e. pg_basebackup (backup_method = postgres) and WAL streaming. regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services