4

I have PostgreSQL version 9.5 installed at my machine (Windows 7 Enterprise x64 bit version). I have several databases in schema 'public'. I would like to use/access one of these databases from another machine (Windows 7) using LAN connectivity (so that this database may act as a shared database between two machines). I was wondering whether is it possible to do through "listen_addresses" option in postgresql.conf dialogue window? If not, is there any alternative way to do this?

2

Yes, two things that need to happen:

  1. Your database must be listening on a port and ip to external connections. For this you need to modify postgresql.conf, you may choose to use the new-ish method of ALTER SYSTEM to do that.
  2. Your database must be properly configured to authenticate someone coming in externally. To do this you must add a host or preferably hostssl entry in pg_hba.conf for that ip/port.
2

Read the article Configuring PostgreSQL to Accept Connections From Computers on Your Network where it is explained with screen shots.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.