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 1gzpOz-00014G-BY for pgsql-general@arkaria.postgresql.org; Fri, 01 Mar 2019 21:09: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 1gzpOy-0002gR-0U for pgsql-general@arkaria.postgresql.org; Fri, 01 Mar 2019 21:09: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 1gzpOx-0002fe-6M for pgsql-general@lists.postgresql.org; Fri, 01 Mar 2019 21:09:03 +0000 Received: from resqmta-ch2-12v.sys.comcast.net ([2001:558:fe21:29:69:252:207:44]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gzpOq-0003rr-2W for pgsql-general@lists.postgresql.org; Fri, 01 Mar 2019 21:09:01 +0000 Received: from resomta-ch2-11v.sys.comcast.net ([69.252.207.107]) by resqmta-ch2-12v.sys.comcast.net with ESMTP id zhq0guFO8pFrSzpOngDrx1; Fri, 01 Mar 2019 21:08:53 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20161114; t=1551474533; bh=Dqm43jpLWSx6uvkjFUCAdxOUC4XZTK5r7LRtim0sues=; h=Received:Received:Received:From:To:Subject:Date:Message-ID: MIME-Version:Content-Type; b=YZ3Sby7UdNpr9eTKhzL8XsEcU45rDp40jK+wS9dLzafJ/uo3g4yS0Cy1MyZh/1u6L xollsWhTNcFTutysNaegEFyG5vSmM5jx72oK6zkwQJRFPPS7Q9MIEnoxsNJCTb+41W UpzAkxw6KigkUFhmmlPpuoD0EeDvQGt5aW0dFPiiCnL/L4F9vScU7ebK2ePElQ65w5 yDxUBjhAB/sVbVbIegxbC3YdRHmZZgJTRMw6kRk07d0rpafNMa5JGZvWaH1hKk1YqM 8VnQRvI91fLMiZk91/cFeHrlt6y+NF4jQROlTLwgiIi2P229hMeaalpU7pQYOuw1Vg ePj5HvynLf80A== Received: from jsievers.comcast.net ([12.30.159.20]) by resomta-ch2-11v.sys.comcast.net with ESMTPA id zpOXg9lc76FMCzpOXg0WoR; Fri, 01 Mar 2019 21:08:48 +0000 X-Xfinity-VAAS: gggruggvucftvghtrhhoucdtuddrgedutddrvdehgddugeeiucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuvehomhgtrghsthdqtfgvshhipdfqfgfvpdfpqffurfetoffkrfenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvufhfffgjkfgfgggtsehttdertddtredtnecuhfhrohhmpeflvghrrhihucfuihgvvhgvrhhsuceoghhsihgvvhgvrhhsudelsegtohhmtggrshhtrdhnvghtqeenucfkphepuddvrdeftddrudehledrvddtnecurfgrrhgrmhephhgvlhhopehjshhivghvvghrshdrtghomhgtrghsthdrnhgvthdpihhnvghtpeduvddrfedtrdduheelrddvtddpmhgrihhlfhhrohhmpehgshhivghvvghrshduleestghomhgtrghsthdrnhgvthdprhgtphhtthhopeifrdhkvghvihhnrdifihhlkhhinhhsohhnsehgmhgrihhlrdgtohhmpdhrtghpthhtohepphhgshhqlhdqghgvnhgvrhgrlheslhhishhtshdrphhoshhtghhrvghsqhhlrdhorhhgpdhrtghpthhtohepkhhtmhesrhhitggvrdgvughunecuvehluhhsthgvrhfuihiivgeptd X-Xfinity-VMeta: sc=-100;st=legit Received: from jsievers.enova.com (localhost [127.0.0.1]) by jsievers.comcast.net (Postfix) with ESMTP id C7E57260056; Fri, 1 Mar 2019 15:08:36 -0600 (CST) From: Jerry Sievers To: Kenneth Marshall Cc: Kevin Wilkinson , pgsql-general@lists.postgresql.org Subject: Re: Methods to quickly spin up copies of an existing databases References: <20190301200017.GM15586@aart.rice.edu> Date: Fri, 01 Mar 2019 15:08:36 -0600 In-Reply-To: <20190301200017.GM15586@aart.rice.edu> (Kenneth Marshall's message of "Fri, 1 Mar 2019 14:00:17 -0600") Message-ID: <87imx2l2uj.fsf@jsievers.enova.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Kenneth Marshall writes: > On Fri, Mar 01, 2019 at 11:57:30AM -0800, Kevin Wilkinson wrote: > >> if you are able/willing to use ZFS (rather than ext4, xfs, ...) to >> store your database, then it might work for you. ZFS is >> copy-on-write so it can very quickly clone a database. >> >> kevin > > Hi Arjun > > Redhat 7 does have LVM snapshots that does something similar. Kevin is > correct, COW is the secret. Going a bit further... Any sort of storage backend that can support *atomic* snapshots across *all* volumes (in case multiple tablespaces ar involved), can be used to permit $instantaneous cloning where instantaneous relates to the actual snapshot time and crash recovery. Inability to make *atomic* snaps but perhaps seperate snaps very quickly, combined with PITR can result in clones of high-churn systems sized in TBs (as in our use case) to be provisioned in about 1 minute. Nothing but the most trivial system can be cloned rapidly and perhaps any number of times in succession without employment of thin-provisioning, copy-on-write (as mentioned already), etc. Virtual copy is more and more compelling as physical size, or more precisely, *physical* copy time grow. HTH > > Regards, > Ken > > -- Jerry Sievers Postgres DBA/Development Consulting e: postgres.consulting@comcast.net