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 1jUQks-0005o8-0n for pgsql-general@arkaria.postgresql.org; Fri, 01 May 2020 08:10:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jUQkp-0001Bm-GD for pgsql-general@arkaria.postgresql.org; Fri, 01 May 2020 08:10:39 +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 1jUQkp-0001Bf-8c for pgsql-general@lists.postgresql.org; Fri, 01 May 2020 08:10:39 +0000 Received: from ms-10.1blu.de ([178.254.4.101]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jUQkj-0001Tx-7x for pgsql-general@lists.postgresql.org; Fri, 01 May 2020 08:10:38 +0000 Received: from [188.174.56.157] (helo=localhost.unixarea.de) by ms-10.1blu.de with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.86_2) (envelope-from ) id 1jUQkg-0005La-MB; Fri, 01 May 2020 10:10:30 +0200 Received: from localhost.my.domain (localhost [127.0.0.1]) by localhost.unixarea.de (8.15.2/8.14.9) with ESMTPS id 0418ATW9003346 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Fri, 1 May 2020 10:10:29 +0200 (CEST) (envelope-from guru@unixarea.de) Received: (from guru@localhost) by localhost.my.domain (8.15.2/8.14.9/Submit) id 0418ATRO003345; Fri, 1 May 2020 10:10:29 +0200 (CEST) (envelope-from guru@unixarea.de) X-Authentication-Warning: localhost.my.domain: guru set sender to guru@unixarea.de using -f Date: Fri, 1 May 2020 10:10:29 +0200 From: Matthias Apitz To: pgsql-general@lists.postgresql.org Subject: How to move a 11.4 cluster to another Linux host, but empty? Message-ID: <20200501081029.GA3261@c720-r342378> Reply-To: Matthias Apitz MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Operating-System: FreeBSD 13.0-CURRENT r342378 (amd64) X-message-flag: Mails containing HTML will not be read! Please send only plain text. User-Agent: Mutt/1.11.1 (2018-12-01) X-Con-Id: 51246 X-Con-U: 0-guru X-Originating-IP: 188.174.56.157 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Hello, I've a 11.4 cluster on a Linux host with 3 production database, all below /data/postgresql11.4/ (i.e. the cluster itself is /data/postgresql11.4/data) fully configured an running fine. I want to move it "cold" (i.e. when it is shutdown) by tar to another host, BUT without the database (due to PII and GDPR relevant data). Between the source and target host there is no network. Of course I could, after moving all the PostgreSQL software (all is below a top level directory /usr/local/sisis-pap/pgsql, compiled by me) and setup the cluster from scratch on the other host, but I wanted to have it all in one shoot by tar. Is there a way to exclude the databases from the move by tar, or by some sophisticated pg_* command? Thanks matthias -- Matthias Apitz, ✉ guru@unixarea.de, http://www.unixarea.de/ +49-176-38902045 Public GnuPG key: http://www.unixarea.de/key.pub