pg_hba.conf edit

Started by Uros Gruberabout 25 years ago4 messagesgeneral
Jump to latest
#1Uros Gruber
uros@sir-mag.com

Hi!

I want to know how to edit this file. Because is only for reading. Is
there any program to edit this. For now i chmod it to 600
end edit with my editor.

Any comments.

--
Uro�

#2Brett W. McCoy
bmccoy@chapelperilous.net
In reply to: Uros Gruber (#1)
Re: pg_hba.conf edit

On Wed, 17 Jan 2001, Uro Gruber wrote:

I want to know how to edit this file. Because is only for reading. Is
there any program to edit this. For now i chmod it to 600
end edit with my editor.

That's the way you are supposed to do it! Just make sure you make it
read-only after you are done.

-- Brett
http://www.chapelperilous.net/~bmccoy/
---------------------------------------------------------------------------
While most peoples' opinions change, the conviction of their
correctness never does.

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Brett W. McCoy (#2)
Re: pg_hba.conf edit

"Brett W. McCoy" <bmccoy@chapelperilous.net> writes:

On Wed, 17 Jan 2001, Uro Gruber wrote:

I want to know how to edit this file. Because is only for reading. Is
there any program to edit this. For now i chmod it to 600
end edit with my editor.

That's the way you are supposed to do it!

Check. Nothing fancy, just whip out your text editor...

Just make sure you make it
read-only after you are done.

You don't even have to do that. The file lives in a directory that
is supposed to be mode 700, ie, no access to anyone but the postgres
user; so it doesn't much matter what the protections are on pg_hba.conf
itself.

regards, tom lane

#4Brett W. McCoy
bmccoy@chapelperilous.net
In reply to: Tom Lane (#3)
Re: pg_hba.conf edit

On Tue, 16 Jan 2001, Tom Lane wrote:

Just make sure you make it
read-only after you are done.

You don't even have to do that. The file lives in a directory that
is supposed to be mode 700, ie, no access to anyone but the postgres
user; so it doesn't much matter what the protections are on pg_hba.conf
itself.

I do it anyway, just cuz I need to protect me from my own stupidity
sometimes. ;-)

-- Brett
http://www.chapelperilous.net/~bmccoy/
---------------------------------------------------------------------------
Violence in reality is quite different from theory.
-- Spock, "The Cloud Minders", stardate 5818.4