Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1uZz2G-00CCnO-4t for pgsql-hackers@arkaria.postgresql.org; Thu, 10 Jul 2025 21:42:32 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1uZz2E-00HNdK-5h for pgsql-hackers@arkaria.postgresql.org; Thu, 10 Jul 2025 21:42:30 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1uZz2D-00HNdC-Qy for pgsql-hackers@lists.postgresql.org; Thu, 10 Jul 2025 21:42:30 +0000 Received: from mail-il1-x136.google.com ([2607:f8b0:4864:20::136]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1uZz2B-006uVj-3A for pgsql-hackers@lists.postgresql.org; Thu, 10 Jul 2025 21:42:30 +0000 Received: by mail-il1-x136.google.com with SMTP id e9e14a558f8ab-3dc9e7d10bdso4765445ab.2 for ; Thu, 10 Jul 2025 14:42:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1752183745; x=1752788545; darn=lists.postgresql.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=aycwP0tNp8sRpei6eT6p3oqZgSb6HY7YsJAy9NZOXkk=; b=Dgig40LQ8QDUgMRpx5wStJqa0eiH+jRZXXBVnMxeHQEyQGK+alLDOWAb+mbigRRJLI hJb8wA63z/U6t8vxpyHRK5rLLm4mBKv0ZrXW32617HqMFAnZN/ZS1DCLtYQ3E/nbahUT SGn3ONJlizh/I60HVzrLpC64B4dyejb5BWIuAEmhtJjrO9kUwsvtYaXqdo+BKZMysBqJ 77F1IzQ4sOFu11KNUHBpH5x7EDGw7oL589fkwwaOl0BKV4bo8S6qlGuLzk+MCW2iTgv1 0hZMV3nudlKp22NXDmti0avoyhAM9KDxVSjhf3yVzKhnYhXI9pmREZSZ+DOIf7e53ogm 3RNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752183745; x=1752788545; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=aycwP0tNp8sRpei6eT6p3oqZgSb6HY7YsJAy9NZOXkk=; b=j9umT6dDFOtqVqXaELQuQDj2n9iqF7mCvCVQb9lKeNAJaPSy0//n0wJgdUk5OZ7x3s Uvu9c18CvU/BsGiljax680+AXf156ENCWrGuzndcXJNnRSavE7I3KdDKg5whpXA24Baw n2W+YsNi3aD2s/0fCN6t7i8VisQtMqcRXSs7ohhDL+U+XONNOtk+W/zAcXR4tbQEHr47 fvmI+z9PDnf1nBA+d+3gP4VbTXLTstgBbYjQLcilRSr5XINQCuqrhTSSRSZHR5VQlGJ7 u+FeQx4+ZKkbOwpLOQZl/m4njh4zpRnw+WPjzooQjJZG5ncZQBP16czBwC5OFmScpgrN CP/A== X-Forwarded-Encrypted: i=1; AJvYcCVDreth7wW1PWbll6BgcWdIitVHKtsVTL0NTX3KidF0NgyoE5I+Bf4uunGxbpZV4q98yGRoigujuJaEjQZX@lists.postgresql.org X-Gm-Message-State: AOJu0YyefY1kHCV5vHuZ5u5rPlUcv+zv5PLjlMV/S62gJzqIhxvvQori /+CfBQyR0z5ABeRpnZ8+b5fK0t58yc/dU6pv/OC2huxT5aMVLlzFBPTU X-Gm-Gg: ASbGncuhT1xJA3zKo3r5pn8Eb+N4c750jEsH54KMXcht8nD76bmGjQF2CkBODBSv+Ub gv8gqpxJFmVJcZyPySz1mgGPJu2YAYZ3TkKYmpWdBJv+YRvDHEAeQKnsvLoiOySMww1mFPU3Ez2 ug7tEEt7YM3vYFCHMLbvwph+rZCDsHw/aYVjoK9fwtsXDDmtC/FB8r8fAOPO8XRoq9LUxSXb8l6 fnk4WvOoLEqd83k/PtgK+WX1bNiVUMRM9QnAVndJF/Zzk2DxjW/jB+4D1u8eixKIRcGMHb7QPPz niE/yK9fQBleWoyMTKr7NXsvCrVLQ7tFVbHgCJZnyhqrxPZRWMT4M5BRgPPpdZGxVBM1bOKa6kX LkmqbmDM+DrOY4kRExBkh/z0zFe8bELUSBMVCFPuuxiAXasuNM4sM X-Google-Smtp-Source: AGHT+IFWXy65fijwi+ivjj9SHztW7CPIiTFlyZaT92Djpuqgk7iZeXRWoJP2/mXq/+w4x/4AeNyKVw== X-Received: by 2002:a05:6e02:2403:b0:3df:5354:a804 with SMTP id e9e14a558f8ab-3e25332a066mr17100275ab.18.1752183745494; Thu, 10 Jul 2025 14:42:25 -0700 (PDT) Received: from nathan (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id e9e14a558f8ab-3e246135327sm7646795ab.23.2025.07.10.14.42.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Jul 2025 14:42:24 -0700 (PDT) Date: Thu, 10 Jul 2025 16:42:23 -0500 From: Nathan Bossart To: Nitin Motiani Cc: Hannu Krosing , Tom Lane , PostgreSQL Hackers Subject: Re: Horribly slow pg_upgrade performance with many Large Objects Message-ID: References: <4050387.1744132029@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="wDo6IHo3pIZ/EZgg" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --wDo6IHo3pIZ/EZgg Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Jul 10, 2025 at 06:05:26PM +0530, Nitin Motiani wrote: > - * pg_largeobject_metadata, after the dump is restored. > + * pg_largeobject_metadata, after the dump is restored. In versions > + * before v12, this is done via proper large object commands. In > + * newer versions, we dump the content of pg_largeobject_metadata and > + * any associated pg_shdepend rows, which is faster to restore. > */ > > Should the comment provide further detail on why this is only being done > for v12 and above? Yes. I've fixed this in v3. -- nathan --wDo6IHo3pIZ/EZgg Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=v3-0001-pg_upgrade-Use-COPY-for-large-object-metadata.patch