Re: [ADMIN] start/restart PostgreSQL service with SSL enabled - Mailing list pgsql-admin

From Ponnam, Bhavani
Subject Re: [ADMIN] start/restart PostgreSQL service with SSL enabled
Date
Msg-id DM5PR01MB2731C942883BB83C91AC278C83700@DM5PR01MB2731.prod.exchangelabs.com
Whole thread Raw
In response to [ADMIN] start/restart PostgreSQL service with SSL enabled  ("Ponnam, Bhavani" <Bhavani.Ponnam@Stryker.com>)
List pgsql-admin

Hi,

      I currently have PostgreSQL 9.5 installed on a Windows 10 machine. I have enabled SSL and configured key & crt files with pass phrase. I know that I have to enter the PEM pass phrase everytime I try to restart. So I tried using pg_ctl to start Postgres, but I have few issues:

  1. Since I installed Postgres as Windows service, running pg_ctl does not start my service. I see postgresql exe instances running in Task manager but my windows service never gets updated to Running.
  2. After running the following command:

pg_ctl -D "c:\Program Files\PostgreSQL\9.5\data" restart -w

I was able to enter the PEM pass phrase since I got a prompt and was able to connect. But when my application is trying to establish the connection with Postgresql, the application is waiting since there are prompts on the command windows where I executed the pg_ctl command to enter the PEM pass phrase. I think this makes the application totally unusable.

  1. Per our security requirements, we cannot remove the PEM pass phrase, so how do I control the PostgreSQL service – start & restart with the pass phrase and without user interaction.

 

Please advise on how to achieve what I am doing or share any alternatives that someone already has for this situation.

 

Thank you

pgsql-admin by date:

Previous
From: "Ponnam, Bhavani"
Date:
Subject: [ADMIN] start/restart PostgreSQL service with SSL enabled
Next
From: ghiureai
Date:
Subject: [ADMIN] PG 10 streaming replication with repmgr basic cfg Q