Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id B871B2E004D for ; Sun, 30 Dec 2007 01:40:46 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 77410-01 for ; Sun, 30 Dec 2007 01:40:42 -0400 (AST) Received: from weatherbeeta.com.au (unknown [218.214.212.154]) by postgresql.org (Postfix) with ESMTP id 1BB202E003B for ; Sun, 30 Dec 2007 01:40:41 -0400 (AST) Received: (qmail 28608 invoked from network); 30 Dec 2007 05:40:39 -0000 X-NetworkBox-HamSign: 0101;OUT;wbeetaau1;93413eebda4d6201271e615253bfff59; Received: from mail.weatherbeeta.com.au (10.20.0.2) by network-box.weatherbeeta.com.au with SMTP; 30 Dec 2007 05:40:39 -0000 Received: (qmail 27314 invoked by uid 1166); 30 Dec 2007 16:40:37 +1100 Received: from 124.168.82.163 by mail.weatherbeeta.com.au (envelope-from , uid 1165) with qmail-scanner-1.25-st-qms (clamdscan: 0.88.6/2315. perlscan: 1.25-st-qms. Clear:RC:0(124.168.82.163):. Processed in 0.198249 secs); 30 Dec 2007 05:40:37 -0000 X-Antivirus-mail.weatherbeeta.com.au-Mail-From: phillip.smith@weatherbeeta.com.au via mail.weatherbeeta.com.au X-Antivirus-mail.weatherbeeta.com.au: 1.25-st-qms (Clear:RC:0(124.168.82.163):. Processed in 0.198249 secs Process 27305) Received: from 124-168-82-163.dyn.iinet.net.au (HELO ?192.168.1.253?) (phillip.smith@weatherbeeta.com.au@124.168.82.163) by mail.weatherbeeta.com.au with SMTP; 30 Dec 2007 16:40:36 +1100 Subject: Re: separating PG binaries into a ro mounted partition From: Phillip Smith Reply-To: phillip.smith@weatherbeeta.com.au To: Albretch Mueller Cc: pgsql-admin@postgresql.org In-Reply-To: <9ef66fac0712291840k5174fd7bp3558c0944eecd64a@mail.gmail.com> References: <9ef66fac0712291840k5174fd7bp3558c0944eecd64a@mail.gmail.com> Content-Type: multipart/alternative; boundary="=-lUOaFOCNqRU53UZBKpKa" Organization: Weatherbeeta P/L Date: Sun, 30 Dec 2007 16:41:57 +1100 Message-Id: <1198993317.5591.19.camel@cassandra-desktop> Mime-Version: 1.0 X-Mailer: Evolution 2.10.1 X-Scanned-By-wbeetaau1: Virus scan performed by network-box X-Scanned-By-wbeetaau1: Scanner file id is wbeetaau1-1198993239.565-28601-000 X-Scanned-By-wbeetaau1: No known viruses found in message (received+scanned in 0.02/0.04 secs) X-Scanned-By-wbeetaau1: Spam-Check-Result: No, hits=0 required=7 tests= autolearn=no version=2.0 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.258 tagged_above=0 required=5 tests=BAYES_50=0.001, HTML_MESSAGE=0.001, RDNS_NONE=0.1, SUBJECT_FUZZY_TION=0.156 X-Spam-Level: X-Archive-Number: 200712/243 X-Sequence-Number: 27760 --=-lUOaFOCNqRU53UZBKpKa Content-Type: text/plain Content-Transfer-Encoding: 7bit What are you trying to acheive by making the binaries read-only? All the config files reside in the data directory so there shoudl be a problem making /usr/local/postgres/bin (or whatever you choose to install the binaries) to be a read-only mounted partition. The other option (which is far easier) would be to set the binaries immutable. As root, run this: chattr +i /use/local/postgres/bin/* That way only root can remove the immutable flag so they can be changed - if it's a security issue behind your desire to do this then it doesn't matter that root can do that versus your suggestion as root would be able to just remount the partition rw: mount -o remount,rw /usr/local/postgres If you can advise why you want them to be read-only then we can make better suggestions. Cheers, ~p THINK BEFORE YOU PRINT - Save paper if you don't really need to print this *******************Confidentiality and Privilege Notice******************* The material contained in this message is privileged and confidential to the addressee. If you are not the addressee indicated in this message or responsible for delivery of the message to such person, you may not copy or deliver this message to anyone, and you should destroy it and kindly notify the sender by reply email. Information in this message that does not relate to the official business of Weatherbeeta must be treated as neither given nor endorsed by Weatherbeeta. Weatherbeeta, its employees, contractors or associates shall not be liable for direct, indirect or consequential loss arising from transmission of this message or any attachments e-mail. --=-lUOaFOCNqRU53UZBKpKa Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit What are you trying to acheive by making the binaries read-only?

All the config files reside in the data directory so there shoudl be a problem making /usr/local/postgres/bin (or whatever you choose to install the binaries) to be a read-only mounted partition. The other option (which is far easier) would be to set the binaries immutable. As root, run this:
    chattr +i /use/local/postgres/bin/*

That way only root can remove the immutable flag so they can be changed - if it's a security issue behind your desire to do this then it doesn't matter that root can do that versus your suggestion as root would be able to just remount the partition rw:
    mount -o remount,rw /usr/local/postgres

If you can advise why you want them to be read-only then we can make better suggestions.

Cheers,
~p

THINK BEFORE YOU PRINT - Save paper if you don't really need to print this e-mail.

*******************Confidentiality and Privilege Notice*******************

The material contained in this message is privileged and confidential to the addressee. If you are not the addressee indicated in this message or responsible for delivery of the message to such person, you may not copy or deliver this message to anyone, and you should destroy it and kindly notify the sender by reply email.

Information in this message that does not relate to the official business of Weatherbeeta must be treated as neither given nor endorsed by Weatherbeeta. Weatherbeeta, its employees, contractors or associates shall not be liable for direct, indirect or consequential loss arising from transmission of this message or any attachments
--=-lUOaFOCNqRU53UZBKpKa--