Difference between revisions of "Listen addresses"

From wikieduonline
Jump to navigation Jump to search
 
(11 intermediate revisions by 4 users not shown)
Line 1: Line 1:
listen_addresses = 'localhost' (Use * for listening on all addresses, review also pg_hba.conf configuration)
+
{{lc}}
 +
<code>grep listen_addresses /etc/postgresql/*/main/[[postgresql.conf]]</code>
  
 +
<code>listen_addresses = 'localhost' (Use * for listening on all addresses, review also pg_hba.conf configuration)</code>
  
 +
<code>#listen_addresses = 'localhost' # what IP address(es) to listen on;</code>
 +
 +
== Example modification using [[sed (editor)|sed]] ==
 +
<code>[[sed (editor)|sed]] s/"#listen_addresses = 'localhost'"/"listen_addresses = '*'"/ /etc/postgresql/*/main/postgresql.conf</code>
 +
 +
== Related ==
 +
* <code>[[systemctl restart postgresql@14-main]]</code>
 +
listen_addresses 0.0.0.0
  
 
== See also ==
 
== See also ==
 
* {{postgresql.conf}}
 
* {{postgresql.conf}}
 
* {{PostgreSQL config files}}
 
* {{PostgreSQL config files}}
 +
 +
[[Category:Postgress]]

Latest revision as of 14:34, 2 February 2023

grep listen_addresses /etc/postgresql/*/main/postgresql.conf

listen_addresses = 'localhost' (Use * for listening on all addresses, review also pg_hba.conf configuration)

#listen_addresses = 'localhost' # what IP address(es) to listen on;

Example modification using sed[edit]

sed s/"#listen_addresses = 'localhost'"/"listen_addresses = '*'"/ /etc/postgresql/*/main/postgresql.conf

Related[edit]

listen_addresses 0.0.0.0

See also[edit]

Advertising: