- From: Liam Kirsher <
>
- To:
- Subject: [chef] postgresql -- config file change fails to trigger restart
- Date: Tue, 28 Jan 2014 15:40:45 -0800
- Openpgp: id=7011F7B7; url=http://liam.numenet.com/pgp/
Hi --
I'm using the postgresql cookbook here:
https://github.com/hw-cookbooks/postgresql
with Chef-solo, on VirtualBox, using Vagrant.
(I'm also using a repmgr cookbook for replication, but I don't think
that's the issue.)
In my own cookbook's attributes/default.rb file I'm including
default[:postgresql][:config][:listen_addresses] = '*'
The chef run fails when repmgr tries to connect to the database and fails.
>
---- Begin output of /usr/bin/repmgr -f /etc/repmgr/repmgr.conf master
>
register ----
>
STDOUT:
>
STDERR: Connection to database failed: could not connect to server:
>
Connection refused
>
Is the server running on host "10.0.2.15" and accepting
>
TCP/IP connections on port 5432?
>
---- End output of /usr/bin/repmgr -f /etc/repmgr/repmgr.conf master
>
register ----
>
Ran /usr/bin/repmgr -f /etc/repmgr/repmgr.conf master register returned 6
The postgresql server is indeed running. However, it is not listening
on 10.0.2.15. (That's the local interface set up by VirtualBox.)
If I restart (not reload) postgresql then it does what I expect and
listens on 10.0.2.15.
My expectation is that adding the :listen_address = '*' attribute should
trigger a restart.
The Usage documentation states "On server systems, the postgres server
is restarted when a configuration file changes."
Am I doing something wrong, or how can I work around this issue? Is
there some way to force a restart?
Thanks for your help!
Liam
--
Liam Kirsher
PGP:
http://liam.numenet.com/pgp/
- [chef] postgresql -- config file change fails to trigger restart, Liam Kirsher, 01/28/2014
Archive powered by MHonArc 2.6.16.