X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 1D0F58BA418 for ; Wed, 16 Feb 2005 16:45:22 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 80960-02 for ; Wed, 16 Feb 2005 16:45:11 +0000 (GMT) Received: from out011.verizon.net (out011pub.verizon.net [206.46.170.135]) by svr1.postgresql.org (Postfix) with ESMTP id 926B78BA37E for ; Wed, 16 Feb 2005 16:45:09 +0000 (GMT) Received: from jfradkin ([66.15.127.235]) by out011.verizon.net (InterMail vM.5.01.06.06 201-253-122-130-106-20030910) with ESMTP id <20050216164506.VJS28171.out011.verizon.net@jfradkin>; Wed, 16 Feb 2005 10:45:06 -0600 From: "Joel Fradkin" To: "'Tom Lane'" Cc: Subject: Re: WHat foldsers in the data folder would I need to link to have my data on a different drive? Date: Wed, 16 Feb 2005 11:48:50 -0500 Message-ID: <001101c51447$653bf970$797ba8c0@jfradkin> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable In-Reply-To: <24232.1108568234@sss.pgh.pa.us> X-Authentication-Info: Submitted using SMTP AUTH at out011.verizon.net from [66.15.127.235] at Wed, 16 Feb 2005 10:45:06 -0600 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=3.171 tagged_above=0 required=5 tests=AWL, MSGID_DOLLARS X-Spam-Level: *** X-Archive-Number: 200502/142 X-Sequence-Number: 16310 Not running SELinux as it is behind a fire wall with only nated connectivity. Question is what folder or folders in /data need to be linked to = /pgdata in order to locate the data files, or if I stay with doing a initdb in = /pgdata what startup files needto be edited? Do I just use -D /pgdata then even though its in /var/lib/pgsql/data and the config in there points to = /pgdata? -----Original Message----- From: Tom Lane [mailto:tgl@sss.pgh.pa.us]=20 Sent: Wednesday, February 16, 2005 10:37 AM To: Joel Fradkin Cc: pgsql-admin@postgresql.org Subject: Re: [ADMIN] WHat foldsers in the data folder would I need to = link to have my data on a different drive?=20 "Joel Fradkin" writes: > I originally used the data_dir conf option to have my data on = /pgslq/data, > but am thinking I should do it the way I did the /wal with a link. My > thinking is then the pid would still be in /var not /pgsql, and the stratup > and shutdown would work better. I am just guessing here, not having done the experiment --- but I'm not at all sure that that will let you escape the SELinux policy restrictions. I suspect you will find that you have no choice but to alter the policy to allow the postgres daemon to access your nondefault data area. (Or turn off SELinux, but that might be an overreaction.) It might be possible to make an end-run by using a nondefault installation of Postgres --- if the postmaster executable doesn't live in /usr/bin, I *think* (but am not certain) that the SELinux targeted policy will not think it's supposed to constrain the daemon's actions. Then you are back to relying solely on filesystem permissions; but that seems like plenty to me. regards, tom lane