PostgreSQL Ubuntu 18, PostgreSQL 10.10 2019/12

PostgreSQLのインストール
# インストール
apt install postgresql

# インストール確認
psql -V

設定ファイルディレクトリ
/etc/postgresql/10/main

実行ファイルディレクトリ
/usr/lib/postgresql/10/bin

データベースクラスタ
/var/lib/postgresql/10/main

/var/lib/postgresql/.bash_profile
export PATH=$PATH:/usr/lib/postgresql/10/bin
export PGDATA=/etc/postgresql/10/main
postgresqlユーザがPostgresのコマンドを使用できるようにする。