admin管理员组文章数量:1334663
I have logged into the PostgreSQL db with psql and want to see the location of config file.
But when I execute SHOW config_file, nothing shows up!
[postgres@bddb06 ~]$ psql -U postgres -d postgres
psql (15.8)
Type "help" for help.
postgres=#
postgres=# select datname from pg_database;
datname
-----------
postgres
template1
template0
(3 rows)
postgres=# select current_database();
current_database
------------------
postgres
(1 row)
postgres=#
postgres=# select version();
version
-----------------------------------------------------------------------------------------------------------------
PostgreSQL 15.8 on x86_64-redhat-linux-gnu, compiled by gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-22.0.1), 64-bit
(1 row)
postgres=# SHOW CONFIG_FILE
postgres-# SHOW 'CONFIG_FILE'
postgres-# SHOW 'config_file'
postgres-#
Can anyone help?
I have logged into the PostgreSQL db with psql and want to see the location of config file.
But when I execute SHOW config_file, nothing shows up!
[postgres@bddb06 ~]$ psql -U postgres -d postgres
psql (15.8)
Type "help" for help.
postgres=#
postgres=# select datname from pg_database;
datname
-----------
postgres
template1
template0
(3 rows)
postgres=# select current_database();
current_database
------------------
postgres
(1 row)
postgres=#
postgres=# select version();
version
-----------------------------------------------------------------------------------------------------------------
PostgreSQL 15.8 on x86_64-redhat-linux-gnu, compiled by gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-22.0.1), 64-bit
(1 row)
postgres=# SHOW CONFIG_FILE
postgres-# SHOW 'CONFIG_FILE'
postgres-# SHOW 'config_file'
postgres-#
Can anyone help?
Share Improve this question asked Nov 20, 2024 at 7:22 sahossainisahossaini 4761 gold badge5 silver badges11 bronze badges 1- 1 SHOW commands generally need to end with a semicolon, not just a newline. – jjanes Commented Nov 20, 2024 at 20:57
1 Answer
Reset to default -1Steps to Check:
Ensure you have Super User Privileges
Try another query:
SELECT sourcefile FROM pg_file_settings WHERE name = 'config_file';
If those two steps are failed, then you can check it manually:
The postgresql.conf
file is typically found in the data directory
specified during the PostgreSQL installation.
Ref - https://www.postgresql./docs/current/runtime-config-file-locations.html
本文标签: Why is there no rows for 39SHOW configfile39 in PostgreSQL databaseStack Overflow
版权声明:本文标题:Why is there no rows for 'SHOW config_file' in PostgreSQL database? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1742374720a2462931.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论