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 1kgE82-0007RB-Bw for pgsql-general@arkaria.postgresql.org; Fri, 20 Nov 2020 21:39:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kgE81-0002Ve-1U for pgsql-general@arkaria.postgresql.org; Fri, 20 Nov 2020 21:39:37 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kgE80-0002TL-PX for pgsql-general@lists.postgresql.org; Fri, 20 Nov 2020 21:39:36 +0000 Received: from wout2-smtp.messagingengine.com ([64.147.123.25]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kgE7x-0001IO-Df for pgsql-general@lists.postgresql.org; Fri, 20 Nov 2020 21:39:35 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id B0599F5A; Fri, 20 Nov 2020 16:39:30 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Fri, 20 Nov 2020 16:39:30 -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=fm1; bh=x x9ebZRz8zgPjwBb4RswzdRU9boNm/zptH9ENeJwrBc=; b=DB/sucjBF/0neH30u Z5HHxTaLPkj5dHnRjKaGjHRLX8IrsH7GwFA0rrWF5cWmQmcy0BEPxluVgcb4pkNH HZPdzOyQ67NA8LHuUyq1w47gotVlEiz+JISu8ubXjadxKPVqPazSENqO10NqRy5H J34nCvaIIENkQfHZoKzSq+5nvMkIoBr5t0rFQKcRLZdWhku+EH7GJqSghi/w/axY WpIYTDhWXruM9VSpR0Bu8po4YIG2nFOyk7VUQKmsVvSj/ud6ce+8kvHBuaQjlefS 8N1wy48jU6Wf11nQOJYgTtL0HIkpUflJvP0T9XJ+gaZJ+IXstOtDdnuK27fpty8+ 2xF6A== 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=fm1; bh=xx9ebZRz8zgPjwBb4RswzdRU9boNm/zptH9ENeJwr Bc=; b=bwrC9luVBwhV3Rc56AFENPyB4ImKztx/dxnawQkjkTOZDgQR318Lo64dO zBwOEn+gyJhZm5YtjCAFQ7qmsgiOhPQxUyerLenO1hdKikPbr7TPitbe9zFBe16w It5A07hU84sGOchDgAnI51kFIYQV9ECUQpvmODNWFPc+4Vm9BX1DpI9tFYfVVjzk 2KoFewTHfsmx+addtQIxM5nJ5e12HS76avs23VZSGQC/CfalALLBT6ONrVrruyUY qSAH83Cis8gaDWi7k6ARMIlalDO/jdKIv0V5iI9LByRW2FEJG+AELXUwAPU+lI7r aQlgNN13ZLEdiH0YCu0YNEmulSdfA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrudegtddgudehtdcutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecunecujfgurhepuffvfhfhkffffgggjggtgfesth ejredttdefjeenucfhrhhomheptegurhhirghnucfmlhgrvhgvrhcuoegrughrihgrnhdr khhlrghvvghrsegrkhhlrghvvghrrdgtohhmqeenucggtffrrghtthgvrhhnpeetjedvte ffjeeuvdelieeffeehuedthffgvdfhhffhkedvudevgedvjedufefgveenucfkphepjeeh rddujedvrdduledrudefleenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmh grihhlfhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtohhm X-ME-Proxy: Received: from [192.168.1.4] (75-172-19-139.tukw.qwest.net [75.172.19.139]) by mail.messagingengine.com (Postfix) with ESMTPA id AB1B43064AB2; Fri, 20 Nov 2020 16:39:29 -0500 (EST) Subject: Re: pg_dump - how to force to show timestamps in client log To: Ron , pgsql-general@lists.postgresql.org References: <7919898d-f5c5-44f0-5af3-41808ba71dfc@gmail.com> From: Adrian Klaver Message-ID: <96a0c112-0ecd-ebe1-fba3-604ab25276bd@aklaver.com> Date: Fri, 20 Nov 2020 13:39:28 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.5.0 MIME-Version: 1.0 In-Reply-To: <7919898d-f5c5-44f0-5af3-41808ba71dfc@gmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 11/20/20 1:00 PM, Ron wrote: > On 11/20/20 2:56 PM, Adrian Klaver wrote: >> On 11/20/20 10:01 AM, Durumdara wrote: >>> Hello! >>> >>> We need to log the pg_dump's state. >>> What objects are in copy, and what are the starting and ending times. >>> >>> But when I try to redirect the output, the result doesn't have >>> timestamps. >>> >>> PG 11, on Windows. >>> >>> As I see the -v option isn't enough to see the starting times. >>> >>> For example: >>> >>> 2020-11-19 12:00:01.084 Dump table content table1 >>> 2020-11-19 12:03:12.932 Dump table content table2 >>> ... >>> etc. >> >> >> If you are redirecting to a file it have the creation time that you >> can use. Internally times don't really matter for the objects as the >> dump is based on a snapshot. Said snapshot is based on visible >> transactions not time. So for practical purposes they all occur at the >> same 'time'. > > It makes all the difference when monitoring the progress of a backup. > With -v you will get running list of objects dumped, just not the time. The time is only of value relative to the following. Progress will only be measurable by determining what is left to run and the time for each object. Not sure that is feasible as you would have to pre-run the dump to get information about the number of objects and an estimate of the data quantity involved and the effect of each on the other. I could see that estimate getting worse the bigger the data set(and hence the more you cared) got. Because at some point the load on the machine would affect the output speed of the dump. -- Adrian Klaver adrian.klaver@aklaver.com