WebDec 12, 2024 · After i connect as user to userdb and try get hba_file psql -h postgresql-96.local -p 5432 -U user -d userdb Password for user user: psql (9.6.6) Type "help" for help. userdb=> SHOW hba_file; ERROR: must be superuser to examine "hba_file" userdb=> userdb=> select setting from pg_settings where name='hba_file'; setting --------- (0 rows) WebSHOWhba_file; hba_file /etc/postgresql/10/main/pg_hba.conf (1 row) Once you have the location of the pg_hba.conffile, open it in your text editor to view the configuration and make changes: vim/etc/postgresql/10/main/pg_hba.conf By default, the file contains the current configuration as well as a number of helpful comments.
pg_hba do not work according to the settings - Stack …
WebJan 12, 2024 · Find your hba_file by entering the following in psql: SHOW hba_file; This should return something like:/usr/local/var/postgres/pg_hba.conf. You can modify this any … WebJul 4, 2024 · SHOW hba_file; # you should have an output like this : postgres=# SHOW hba_file; hba_file --------------------------------- /var/lib/pgsql/data/pg_hba.conf (1 row) For me its actually located in /var/lib/pgsql/data/pg_hba.conf, but maybe it can be different for you. Once you have the file path, quit the psql shell with \q. sunova koers
How to Migrate PostgreSQL Databases - DigitalOcean
WebRun psqlwith -U(for user name) followed by the name of the database, postgresin this example: # Log into Postgres as the user named postgres$ psql -U postgres. Opening a … WebSHOW hba_file; This command must be run on a superuser session, so for shell scripting you might write something like: psql -t -P format=unaligned -c 'show hba_file'; and set the … Stack Exchange Network. Stack Exchange network consists of 181 Q&A … WebSep 17, 2024 · It depends on how you installed it. Did you use source tar-gz file or did you use apt utility. If you download tar-gzipped file and installed it. The pg_hba.conf file does not exist yet unless you initialize your data directory. The INSTALL/Readme file has that info. You will find pg_hba.conf file in whatever you selected as your data directory. sunova nz