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 1gUQJe-0000yu-T8 for pgsql-general@arkaria.postgresql.org; Wed, 05 Dec 2018 06:05:47 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gUQJd-0001NM-D1 for pgsql-general@arkaria.postgresql.org; Wed, 05 Dec 2018 06:05:45 +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 1gUQJc-0001Ma-VE for pgsql-general@lists.postgresql.org; Wed, 05 Dec 2018 06:05:45 +0000 Received: from mail-vs1-xe2b.google.com ([2607:f8b0:4864:20::e2b]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gUQJZ-0003em-Vv for pgsql-general@postgresql.org; Wed, 05 Dec 2018 06:05:43 +0000 Received: by mail-vs1-xe2b.google.com with SMTP id p74so11406105vsc.0 for ; Tue, 04 Dec 2018 22:05:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=BzpjPODYaUa7hYs5GZdJUyBgedo2TIIFUKYzX+Ggfnk=; b=OzaKC/OH/RKS5N8qKkS/FKzo0La7ZARW7Q2kZuknTuuD72X5YVfLQ0q01oVPHUkFM4 poGcHMGAs5gldcagKJpBP7dFg7N3dUmiVLZLtbgEwWA4CHIPpzYWVoqtc+zHHP5ZqOlr bUmZ0FdbJfQTVr6EUlPk9uOJDb491QymhWfBNvFSUGNiGsB//tyaSx74QEtM3vOCKs8d bBTSd8Ppb17yM513SKRYiNQuAHsHyT5ztPY3WDmEyx8hsOjI69b0zpsg6UT5p3IKhfCm f3NEi/zY3nTg/aF1jRgyOmODaouilJQFAS27ZNoSQur/iZXbeNOGSASRpD/THvVhtWu5 dpNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=BzpjPODYaUa7hYs5GZdJUyBgedo2TIIFUKYzX+Ggfnk=; b=Oh0uc58frlaf2QfFaJ5dQbfJDdz5nf+em/R0VYn3OOKDWss1xFMemd2csGCc549y4j cLCUrDs9lHGIvbLJ9tAeLL7ONs7ILUNDSyZXaa9ckp8i+C3A9So/5fTZYrgS21SpFbEp 4mzBQRSmrQdKR18r0wlnd4EbBGzHEiZouT8acwFQ3JAyupUefl9UdigOiN1dnd85U9CC 1uDr4sKxDW4IFYOP1OcFv/jPBNIrQeK90guUQIE3e4F8CybzxLwAz/QpsINUFzczIMwg 8Gbj1yu/10T6KUfjh9M2d2TStL4scrPn4l0gMq/quIewMlyPacywX4CkbnMZvK9MLdNm nWzw== X-Gm-Message-State: AA+aEWaGNovNLTCn6nn4W9nyVUjeQWnjc1cZXDIUnL6tVXijPUhGJTl5 Nqq77olOSsI+vIczxOsQYJg= X-Google-Smtp-Source: AFSGD/V1ekBkst0xzDn3bJCkXXRQ6NAAiH8NWuDTUWzZ3io2W+GI4v39Z1vy4PUhiPrvqlUuRbl9qA== X-Received: by 2002:a67:3144:: with SMTP id x65mr10312457vsx.186.1543989940667; Tue, 04 Dec 2018 22:05:40 -0800 (PST) Received: from [100.81.115.144] (62.sub-174-208-20.myvzw.com. [174.208.20.62]) by smtp.gmail.com with ESMTPSA id m13sm6287335vkf.21.2018.12.04.22.05.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 04 Dec 2018 22:05:40 -0800 (PST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (1.0) Subject: Re: Moving large table between servers: logical replication or postgres_fdw From: Rob Sargent X-Mailer: iPhone Mail (16B92) In-Reply-To: Date: Tue, 4 Dec 2018 23:05:38 -0700 Cc: pgsql-general@postgresql.org Content-Transfer-Encoding: quoted-printable Message-Id: <7DD54254-62D2-4A7E-8A0A-0F57D7BC6DA1@gmail.com> References: To: "Rhys A.D. Stewart" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk > On Dec 4, 2018, at 8:14 PM, Rhys A.D. Stewart wro= te: >=20 > Greetings Folks, >=20 > I have a relatively large table (100m rows) that I want to move to a > new box with more resources. The table isn't doing anything...i.e its > not being updated or read from. Which approach would be faster to move > the data over: >=20 > a). Use pg_fdw and do "create local_table as select * from foreign_table"= . > b). setup logical replication between the two servers. >=20 > Regards, >=20 > Rhys > Peace & Love|Live Long & Prosper >=20 Can=E2=80=99t help but think an unread unwritten table goes to quietly to /d= ev/null :)=