Re: postgresql service started but pid is not saved in /var/run/postgresql/postgresql.pid

Поиск
Список
Период
Сортировка
От Juan José Santamaría Flecha
Тема Re: postgresql service started but pid is not saved in /var/run/postgresql/postgresql.pid
Дата
Msg-id CAC+AXB1APAC2VwYJpCYWSC9v+biJA1KGiB3M1YV=jn5DuKJEDw@mail.gmail.com
обсуждение исходный текст
Ответ на postgresql service started but pid is not saved in /var/run/postgresql/postgresql.pid  (Mariel Cherkassky <mariel.cherkassky@gmail.com>)
Ответы Re: postgresql service started but pid is not saved in /var/run/postgresql/postgresql.pid  (Mariel Cherkassky <mariel.cherkassky@gmail.com>)
Список pgsql-admin

On Tue, May 14, 2019 at 11:20 AM Mariel Cherkassky <mariel.cherkassky@gmail.com> wrote:
Hey,
I'm using a machine in aws and when the machine starts all the services are starting including postgresql(v9.6 , centos).  However, when I check the service`s status I see that it is stopped but all the processes are up (ps -ef ) and the postmaster.pid file is exist with the pid of the postmaster. 

The next part of code responsible for starting postgresql in redhat(/etc/init.d/postgresql) :


This seems to be old code, you can find the example of a start/stop script for 9.6 in:

 

It seems that the sleep 2 isnt enough time to start the processes and thats why the service shows that the instance is down while it is up. Does any one faced this type of issue ? I mean, I can increase the sleep , but I dont think that it is the perfect solution in this case.


What CentOS version are you using, wouldn't it be more appropriate to use systemctl anyway?

Regards,

Juan José Santamaría Flecha

В списке pgsql-admin по дате отправления:

Предыдущее
От: Mariel Cherkassky
Дата:
Сообщение: postgresql service started but pid is not saved in /var/run/postgresql/postgresql.pid
Следующее
От: Mariel Cherkassky
Дата:
Сообщение: Re: postgresql service started but pid is not saved in /var/run/postgresql/postgresql.pid