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 1kVV88-0008AC-EU for pgsql-general@arkaria.postgresql.org; Thu, 22 Oct 2020 07:35:24 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kVV87-0000uy-Cb for pgsql-general@arkaria.postgresql.org; Thu, 22 Oct 2020 07:35:23 +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 1kVV87-0000ui-2O for pgsql-general@lists.postgresql.org; Thu, 22 Oct 2020 07:35:23 +0000 Received: from lana.depesz.com ([88.198.49.178] helo=depesz.com) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kVV84-0008VU-E8 for pgsql-general@lists.postgresql.org; Thu, 22 Oct 2020 07:35:22 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=depesz.com; s=20170201; h=In-Reply-To:Content-Type:MIME-Version:References:Reply-To: Message-ID:Subject:Cc:To:Sender:From:Date:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=joeZFi7CjBiTmXiQI7wS4OjHD6FicXpFdPT5v0zjpZw=; b=MwXKgFd20pEIzHey5KrvxmDuNy 6+lauDqkyupikb0j6yCNeQ0nBjcLgkXp9Mnp39UaoH18uqgttSeK3WUYiHDEJpQDncdV+VGZtHwHd ZCeTa/RTAyyxdfg0Y+t99wAKlhcfdtFo+WNGMvC3slyWvC+S19C1DQb+ro/hYYsnsvO0=; Received: from lana.depesz.com ([88.198.49.178] helo=depesz.com) by depesz.com with esmtpa (Exim 4.92) (envelope-from ) id 1kVV81-00077n-F1; Thu, 22 Oct 2020 09:35:17 +0200 Date: Thu, 22 Oct 2020 09:35:17 +0200 From: hubert depesz lubaczewski Sender: depesz@depesz.com To: "W.P." Cc: pgsql-general@lists.postgresql.org Subject: Re: Hot backup in PostgreSQL Message-ID: <20201022073517.GA22554@depesz.com> Reply-To: depesz@depesz.com References: <486ad2c5-01e0-fbf7-b09d-88898b28cdb0@wp.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <486ad2c5-01e0-fbf7-b09d-88898b28cdb0@wp.pl> User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Thu, Oct 22, 2020 at 08:42:08AM +0200, W.P. wrote: > Hi there, > > how to do "hot backup" (copying files) while database running? > > Not using pg_dump. > > Is there some equivalent of Oracle (I knew v8) "ALTER DATABASE BEGIN > BACKUP", which froze writes to database files, pushing everything to redo > files? There are many ways to do it. To be able to suggest proper solution we'd need to know: 1. what is the problem with pg_dump? 2. what is the exact problem you're solving (clearly it's not only "having backup", as this is done using pg_dump without any problem). depesz