How can you configure network access to PostgreSQL?
There are two levels to configure network access. In postgresql.conf (listen_addresses), you can configure the bind addresses and open remote connections. In pg_hba.conf, you can tell PostgreSQL how to authenticate network connections. Depending on the IP range a request comes from, different rules can be applied.
What is a user and what is a role?
Basically, the difference between a user and a role is academic. When creating a role, the default value is NOLOGIN, which is not the case when you use CREATE USER. Otherwise, roles and users can be considered to be the same.
How can a password be changed?
This is simple. You can use ALTER USER to do the job, as shown in the following example:
test=# ALTER USER hs PASSWORD 'abc';
ALTER ROLE
Keep in mind that passwords are not necessarily stored in PostgreSQL. If...