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 1hCutP-0007K6-Dy for pgsql-general@arkaria.postgresql.org; Sat, 06 Apr 2019 23:38:36 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hCutO-0002YK-55 for pgsql-general@arkaria.postgresql.org; Sat, 06 Apr 2019 23:38:34 +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 1hCutN-0002OJ-A9 for pgsql-general@lists.postgresql.org; Sat, 06 Apr 2019 23:38:33 +0000 Received: from mail-oln040092000080.outbound.protection.outlook.com ([40.92.0.80] helo=NAM01-BN3-obe.outbound.protection.outlook.com) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hCutJ-0006Gu-K6 for pgsql-general@lists.postgresql.org; Sat, 06 Apr 2019 23:38:31 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WDdtzaSmjVtd8h8PIRjIYVktCLbpfKh4sFVlDuZoDYs=; b=gTz7sE9C3zzhDslscKCsyeQrN0Azzt6fSREfl3mDKOxwgdEJNL2mYSmTp2cJ09eZa8a8adUuLGS2HQaODVuHriauTg8qlTflw931vGGukUa0Orv4cNncidy25bMdeK5d46btrKqyUnAJkB44nfjl0t32zTwJaZcr+TbriZXmqJT3fn+cPVfuA6JcKmoRnXuc4catKNnSx94S+msqL62nnHhz+XoKNPk0KYDnalgD3uMslTZN+kXU3dfwdxsAAQ9X0hTTOUPxk1JXcvE1wa4e3cdU4eTIbo6Qbf1fP2iKp5Weyor5csAkblIsAfIu4Y6Yl/XzlAl/0OkAWcgac7PI9A== Received: from BN3NAM01FT054.eop-nam01.prod.protection.outlook.com (10.152.66.54) by BN3NAM01HT109.eop-nam01.prod.protection.outlook.com (10.152.67.177) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1771.16; Sat, 6 Apr 2019 23:38:26 +0000 Received: from BYAPR01MB3701.prod.exchangelabs.com (10.152.66.56) by BN3NAM01FT054.mail.protection.outlook.com (10.152.67.208) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1771.16 via Frontend Transport; Sat, 6 Apr 2019 23:38:26 +0000 Received: from BYAPR01MB3701.prod.exchangelabs.com ([fe80::3c48:513d:60f7:6afc]) by BYAPR01MB3701.prod.exchangelabs.com ([fe80::3c48:513d:60f7:6afc%2]) with mapi id 15.20.1750.021; Sat, 6 Apr 2019 23:38:26 +0000 From: senor To: "pgsql-general@lists.postgresql.org" Subject: Re: pg_upgrade --jobs Thread-Topic: pg_upgrade --jobs Thread-Index: AQHU7KUEoYaMmqXr9EqkQgpkSWov1KYvnAIAgAAGP06AAA0ygIAAC4Y+ Date: Sat, 6 Apr 2019 23:38:26 +0000 Message-ID: References: ,<1c0469fb-1878-35ac-8468-78ce47299638@aklaver.com> ,<16144.1554588125@sss.pgh.pa.us> In-Reply-To: <16144.1554588125@sss.pgh.pa.us> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-incomingtopheadermarker: OriginalChecksum:8542B7FCB1F7CEC1F3CE1E8259376A89BBF16FB7BD4FCFD1197D8E6C94D27CD5;UpperCasedChecksum:0CC64B6AB00C16B2642691699951E4911EC6FFF4AC65087E80111F4BF770FF17;SizeAsReceived:6931;Count:44 x-ms-exchange-messagesentrepresentingtype: 1 x-tmn: [7t5v1HiBZipleAoosHoOTYsWR9sLeR1f] x-ms-publictraffictype: Email x-incomingheadercount: 44 x-eopattributedmessage: 0 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(20181119110)(201702061078)(5061506573)(5061507331)(1603103135)(2017031320274)(2017031323274)(2017031324274)(2017031322404)(1601125500)(1603101475)(1701031045);SRVR:BN3NAM01HT109; x-ms-traffictypediagnostic: BN3NAM01HT109: x-microsoft-antispam-message-info: ZG/UDkMwX0XzewwcAM7Hopr3UgqUSfzftxs78EM6y120F6v29UMiJRADl3UTZ6iq Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-CrossTenant-Network-Message-Id: 405ebbf2-cc27-48f5-33ec-08d6bae8f752 X-MS-Exchange-CrossTenant-rms-persistedconsumerorg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-CrossTenant-originalarrivaltime: 06 Apr 2019 23:38:26.3251 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3NAM01HT109 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Thanks Tom. I suppose "pg_dump can only parallelize data dumping" answers m= y original question as "expected behavior" but I would like to understand t= he reason better. My knowledge of Postgres and other DBMSs is at casual admin level with the = occasional deep dive on specific errors or analysis. I'm not averse to gett= ing into the code. Before my OP I searched for reasons that the schema-only= option would prevent pg_dump from being able to run multiple jobs and didn= 't find anything that I understood to confirm either way. Is the limitation simply the state of development to date or is there somet= hing about dumping the schemas that conflicts with paralleling? I'm willing= to do some studying if provided links to relevant articles. The --link option to pg_upgrade would be so much more useful if it weren't = still bound to serially dumping the schemas of half a million tables. As al= ready mentioned, if there is an alternate process that mimics pg_upgrade bu= t allows for paralleling, I'm open to that. Thanks all ________________________________________ From: Tom Lane Sent: Saturday, April 6, 2019 3:02 PM To: senor Cc: pgsql-general@lists.postgresql.org Subject: Re: pg_upgrade --jobs senor writes: > Since pg_upgrade is in control of how it is calling pg_dump, is there a r= eason pg_upgrade cannot use the directory output format when calling pg_dum= p? Is the schema-only operation incompatible? Well, there's no point in it. pg_dump can only parallelize data dumping, and there's none to be done in the --schema-only case that pg_upgrade uses. Also, since pg_upgrade *does* use parallelism across multiple pg_dump calls (if you've got multiple databases in the cluster), it'd be a bit problematic to have another layer of parallelism below that, if it did indeed do anything. You don't want "--jobs=3D10" to suddenly turn into 100 sessions. regards, tom lane