1

Everytime I startup the server it seems to completely ignore all configuration settings. My data directory is an external drive, so I use pg_ctl -D /Volumes/Data/Postgres start to start.

It only accepts localhost connections on port 5432, which I have confirmed by show listen_addresses; even though the config file has the following under connection settings:

#listen_addresses = '*' # what IP address(es) to listen on;
                    # comma-separated list of addresses;
                    # defaults to 'localhost'; use '*' for all
                    # (change requires restart)
#port = 9000                # (change requires restart)

I also checked the postgresql.auto.conf file, as apparently this overrides the config file, and its completely empty.

For the record the database has crashed a few times due to power being disconnected/connection issues...but it still works fine it seems because I can connect locally...

1 Answer 1

2

You forgot to remove the # in the beginning of the configuration file line. PostgreSQL ignores everything from # to the end of the line.

Most of the postgresql.conf entries are “commented out” in that fashion. This should serve as documentation: you can see what parameters there are and what the default value is.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.