Can't edit pg_hba.conf; and, How do I restart postmaster?
От | Daniel Lerch |
---|---|
Тема | Can't edit pg_hba.conf; and, How do I restart postmaster? |
Дата | |
Msg-id | 417FE17D.2020904@mountainmeasurement.com обсуждение исходный текст |
Ответы |
Re: Can't edit pg_hba.conf; and, How do I restart postmaster?
|
Список | pgsql-novice |
Hi folks, I successfully edited pg_hba.conf a few weeks ago (which means I don't remember where the file I edited was, now). Today I'm needing to re-edit it as the addresses of our computers have changed. But the two pg_hba.conf files I now find: /etc/postgresql/pg_hba.conf /usr/lib/postgresql/share/pg_hba.conf.sample are both read-only; AND when I tried to copy /etc/postgresql/pg_hba.conf (which I'd edited before), it wouldn't let me, and said 'cannot create regular file: Permission denied'. So I'm at a loss - how do I edit pg_hba.conf now? Our user accounts haven't changed, and I'm not logging in any differently than before. Plus, which is the right pg_hba.conf file, and where should it be? Also, once I get that set up, I need to know how to restart the postmaster (whatever that is). I tried running pg_ctl from within its own directory, even, but it didn't like it as a command. And I couldn't locate any comman named "service" or "sighup" or "SIGHUP" (per his instructions below). So, what do I do? (BTW- Thanks for everyone's assistance so far - this forum has been enormously helpful. And please do continue making your explanations as simple as possible. I don't know any Linux commands other than 'whereis' and 'ls', I can barely edit files with 'vi'. My new Linux and PostgreSQL books are helping a little, but not much.) Thanks! -d Tom Lane wrote: > Most likely PGDATA is /var/lib/pgsql/data ... to make sure, look at the > init script (probably /etc/init.d/postgresql). Or you could try > ps auxww | grep postmaster > and see whether the data directory was specified with a -D switch on the > postmaster's command line. > > Don't forget you need to SIGHUP or restart the postmaster after editing > its configuration files. ("pg_ctl reload" or "service postgresql > reload" usually work for sending SIGHUP conveniently.) > > regards, tom lane
В списке pgsql-novice по дате отправления: