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 1s1wS7-00GCCR-4s for pgsql-general@arkaria.postgresql.org; Tue, 30 Apr 2024 23:00:00 +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 1s1wS3-009ArL-FS for pgsql-general@arkaria.postgresql.org; Tue, 30 Apr 2024 22:59:56 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s1wS2-009ArC-92 for pgsql-general@lists.postgresql.org; Tue, 30 Apr 2024 22:59:56 +0000 Received: from mail-mw2nam12olkn20801.outbound.protection.outlook.com ([2a01:111:f403:2805::801] helo=NAM12-MW2-obe.outbound.protection.outlook.com) by makus.postgresql.org with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s1wRz-000qEv-Uc for pgsql-general@lists.postgresql.org; Tue, 30 Apr 2024 22:59:53 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Cx4xEeA7UE8UBruVCbsTxHix10Y8IQkYIfY0qDYPbSFiWO3YdjfqIN76odsMQmIc4GkZEri1vPZ3qba2xJO9IBHNH+gSiSMMB+arQ1nxFPeXJquga/34Pe7+B1nEbJkTlGP5HMoqksOj0O4nUIg/mif8fL6hCI9JXYvbAs6UldXMF/BUpUlFoTKkxyM1jbsInrBLXasKYM1h5GswFvfCebtVylnCOiPM5dPRGlQUfJ93xuhQfLmeN14oEVGyOau4qgss8sS0RYDc6fxKRMC/TlXX+veh6AzbfVeOVRxQOHp3USp/BMD3DsUGALfoFS4Mketw52wHV6GsyXOfmU6VFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=efhePQNnQkyIWz+ZY4Ygy5vzd44rSGk3xwbQ5m5Wuqk=; b=V5yUPSsSarCcm1dqn8oFjCYgOXHhUDb+0jSOYy/vzTvZaAKydtwRmSFP6q0xIenfJ0/DFUahohI9jJn9WfhFtJNLSYlJia+TpRuo1qlAjdmIPpw4YU0MqO4PeDRTGDhmcYXs72zl7+MPPtnK0UzF1swAHvG+AaI7xhSnm+f71TRvMytOgmIbgHheOEndLQ0w85qgy3L9a6DTZ3fR/SSYKWdZXvfY+orVk81lbEMjXdeBbzGH0nsinrbR/Qg2marb+4Gv1KVvOTfmRhVBe9pzEf+JgGxKy+da8jtvnsz9KcCxyYVp31bWRFro+M7eQ7ijAcORaX1FAYGcirLmOLnzDA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none 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=efhePQNnQkyIWz+ZY4Ygy5vzd44rSGk3xwbQ5m5Wuqk=; b=EHGEWrZA8QMnB1oKD6KxwIxBK4PAV21KkZOjQcFeaezNxuSyo7DxTCoups6QJF8strmSKzwxs6qGkvT112BO6/HxlhvGvbFDLrQsB2D9+eYf7vmNikEdzONZ6gXWukLZ3PNCk8w2tNGMqDt2MbHmhjSsb4LjCd2VYyNj70nwtB2xJxjUEX6UF8+V9CKc/ePSMGyN+LxiCI1mIyT7ORp+qGXObccz1g+f+nQNjQ9dtDSAz5Qkqp755e2Is64ADu3/hGUzTAElzWoVv0PeTU/FwWFwgqqzlGKgAIZ7zZnWfmccHonJ72SY1kpP6WEoDxOXV4nYFp5GMA4pYxVJpkJDtA== Received: from SN4P221MB0683.NAMP221.PROD.OUTLOOK.COM (2603:10b6:806:1ea::15) by SJ0P221MB1027.NAMP221.PROD.OUTLOOK.COM (2603:10b6:a03:44b::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7519.34; Tue, 30 Apr 2024 22:59:48 +0000 Received: from SN4P221MB0683.NAMP221.PROD.OUTLOOK.COM ([fe80::e561:9786:6b9d:e461]) by SN4P221MB0683.NAMP221.PROD.OUTLOOK.COM ([fe80::e561:9786:6b9d:e461%7]) with mapi id 15.20.7519.031; Tue, 30 Apr 2024 22:59:48 +0000 Content-Type: multipart/alternative; boundary="------------CDd5TZ0RTNugZ0PSyu0sBQk4" Message-ID: Date: Tue, 30 Apr 2024 15:59:47 -0700 User-Agent: Mozilla Thunderbird Content-Language: en-US To: "pgsql-general@lists.postgresql.org" From: Senor Cervesa Subject: Linked directory or explicit reference X-TMN: [hfFAKdFoA3U1ONnOashF60v72V2J6M8pnIxKk64mPBqWWuIFblZAyuVYGFosnRkd6uRFDVxu6Kg=] X-ClientProxiedBy: BY3PR05CA0016.namprd05.prod.outlook.com (2603:10b6:a03:254::21) To SN4P221MB0683.NAMP221.PROD.OUTLOOK.COM (2603:10b6:806:1ea::15) X-Microsoft-Original-Message-ID: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SN4P221MB0683:EE_|SJ0P221MB1027:EE_ X-MS-Office365-Filtering-Correlation-Id: 32a331cd-870a-44c3-6338-08dc69693c2f X-Microsoft-Antispam: BCL:0;ARA:14566002|461199019|3412199016|440099019|3430499023; X-Microsoft-Antispam-Message-Info: SqIXEKlS7uVlgj6rqNhZxzfyQtX6Q7s6K66oLuArabuZjp2kzRBdxnfgnhogOT6NHzIafKbGlJt7bfW2B1G7r0T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TythbGQzOE0yZE9SdU81WVdhWGtQTURSODNEc0IycnRBdWdvaUJOVGFw?= =?utf-8?B?bG1oa1ZudlY4RGl4Wnk0RnNIWDM4eVJaaFRlbFM4UmNoaEtkZnlOQ2V6WGtG?= =?utf-8?B?WGprU2pBTlNQSWRIeTd0QTZqNUM4REZ5dlFoSDJDYXZzcXRpS2lQRkNaMUpG?= =?utf-8?B?c1lYNjkvdDJuemlOVXpZaVhvbmpBaXBsdVA1MW54ZnloMXdLVE5iMXlQVlZY?= =?utf-8?B?dFBkOTcvYUw2MGVkcDhYK3FrMFBWUk9EWWhTSEgvYks0Z2JNTFJRY3ZJR2hq?= =?utf-8?B?dm9rVTlVdE5aVlhrZmZaL3ZHZGRsSlJjOEw2NG9Mb1phZ3BWSzNBSTlqVy8v?= =?utf-8?B?SS9vdUd4L0h4alFwVk0vbFM0SzZaZVhUVTJ0WkcvMmdXS0RFQzAxbnBoem0w?= =?utf-8?Q?jaReHKOH4D6MaU23GCTkarMyPq5Z30jFFgMxLji?= X-OriginatorOrg: sct-15-20-4755-11-msonline-outlook-f5d03.templateTenant X-MS-Exchange-CrossTenant-Network-Message-Id: 32a331cd-870a-44c3-6338-08dc69693c2f X-MS-Exchange-CrossTenant-AuthSource: SN4P221MB0683.NAMP221.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Apr 2024 22:59:48.4013 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0P221MB1027 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --------------CDd5TZ0RTNugZ0PSyu0sBQk4 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Hi All; When doing an initial install of PostgreSQL on RHEL 7 or 8 derived OS via rpm, what are pros, cons and recommendations of these 2 procedures for utilizing a second disk? Secondary SSD or RAID mounted at /disk2. Option #1 1. install the rpm which creates basic user and home 2. Create symlink /var/lib/pgsql/15/data --> /disk2/data 3. initdb with no special options Or Option #2 1. install the rpm which creates basic user and home 2. initdb with --pgdata=/disk2/data Probably using included 'postgresql-12-setup' script I also link /var/lib/pgsql/data  --> ../15/data so automation can reference postgresql.conf without knowing version (legacy stuff). The install is automated with a bash script which handles several options including whether there is a second disk for DB. Scripting the install with or without the second disk is straight forward but I'm concerned with either scenario causing unforeseen differences. I don't think there's a benefit to using tablespace here but I have no experience with it. The systemd service is configured with a dependency on the disk mount so I don't think there are different risks for starting postgres with missing data directory. I've run postgres in both scenarios and not had any issues. I'm interested in comments from others on their experience using these or other options. Thanks, Senor --------------CDd5TZ0RTNugZ0PSyu0sBQk4 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit

Hi All;

When doing an initial install of PostgreSQL on RHEL 7 or 8 derived OS via rpm, what are pros, cons and recommendations of these 2 procedures for utilizing a second disk?

Secondary SSD or RAID mounted at /disk2.

Option #1

  1. install the rpm which creates basic user and home
  2. Create symlink /var/lib/pgsql/15/data --> /disk2/data
  3. initdb with no special options

Or Option #2

  1. install the rpm which creates basic user and home
  2. initdb with --pgdata=/disk2/data
    Probably using included 'postgresql-12-setup' script

I also link /var/lib/pgsql/data  --> ../15/data so automation can reference postgresql.conf without knowing version (legacy stuff).

The install is automated with a bash script which handles several options including whether there is a second disk for DB. Scripting the install with or without the second disk is straight forward but I'm concerned with either scenario causing unforeseen differences.

I don't think there's a benefit to using tablespace here but I have no experience with it. The systemd service is configured with a dependency on the disk mount so I don't think there are different risks for starting postgres with missing data directory.

I've run postgres in both scenarios and not had any issues. I'm interested in comments from others on their experience using these or other options.

Thanks,

Senor

--------------CDd5TZ0RTNugZ0PSyu0sBQk4--