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 1innoF-0003Gk-9H for pgsql-general@arkaria.postgresql.org; Sat, 04 Jan 2020 18:05:59 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1innoD-0007XE-Qu for pgsql-general@arkaria.postgresql.org; Sat, 04 Jan 2020 18:05:57 +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 1innoD-0007W5-Da for pgsql-general@lists.postgresql.org; Sat, 04 Jan 2020 18:05:57 +0000 Received: from mail.appl-ecosys.com ([50.126.108.78]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1innoA-0002Be-R5 for pgsql-general@lists.postgresql.org; Sat, 04 Jan 2020 18:05:56 +0000 Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by mail.appl-ecosys.com (Postfix) with ESMTP id 8D722262F37 for ; Sat, 4 Jan 2020 10:05:53 -0800 (PST) Date: Sat, 4 Jan 2020 10:05:53 -0800 (PST) From: Rich Shepard To: pgsql-general Subject: Re: Changing default ../data/ directory In-Reply-To: Message-ID: References: User-Agent: Alpine 2.20 (LNX 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Sat, 4 Jan 2020, Jeff Janes wrote: > PGDATA should work fine if you always start the server directly. But if > you sudo or su to another user, they likely won't inherit your environment > variables. And if you use some kind of start-up script, they will likely > override it. How do you start and stop PostgreSQL? Jeff, Slackware's /etc/rc.d/rc.postgresql start command. I can modify that script to change the data directory path. Thanks, Rich