FATAL: could not access private key file “/etc/ssl/private/ssl-cert-snakeoil.key”: Permission denied

前端 未结 6 2734
长情又很酷
长情又很酷 2021-02-20 02:37

I believe I ended up mixing up permissions at /etc/ssl directories tree as the last modification was made on 18th November and a day after I could not get my PostgreSQL to work.

6条回答
  •  被撕碎了的回忆
    2021-02-20 03:13

    I was suffering from this issue when attempting to start Postgresql on a remote docker instance. I eventually tracked down the crazy solution here. Basically you have to recreate the directories, chown on it's own doesn't work:

    mkdir /etc/ssl/private-copy; mv /etc/ssl/private/* /etc/ssl/private-copy/; rm -r /etc/ssl/private; mv /etc/ssl/private-copy /etc/ssl/private; chmod -R 0700 /etc/ssl/private; chown -R postgres /etc/ssl/private
    

提交回复
热议问题