Talk:PostgreSQL - ArchWiki - Arch Linux
https://wiki.archlinux.org/title/Talk:PostgreSQLAnd psql can be run as psql -U postgres from own user account if one wants history. -- Amish ( talk) 00:53, 24 November 2017 (UTC) Currently there is no point in changing permissions for /var/lib/postgres/ indeed, since only the subfolder data is used. This is because the default upstream configuration is to have this { {ic|data} folder where ...
PostgreSQL - ArchWiki
wiki.archlinux.org › title › PostgreSQLNote: Commands that should be run as the postgres user are prefixed by [postgres]$ in this article. You can switch to the PostgreSQL user by executing the following command: If you have sudo and are in sudoers: $ sudo -iu postgres. Otherwise using su: $ su # su -l postgres. See sudo (8) or su (1) for their usage.
PostgreSQL - ArchWiki
https://wiki.archlinux.org/title/PostgreSQLFamiliarize with PostgreSQL Access the database shell. Become the postgres user. Start the primary database shell, psql, where you can do all your creation of databases/tables, deletion, set permissions, and run raw SQL commands.Use the -d option to connect to the database you created (without specifying a database, psql will try to access a database that matches your …