sudo systemctl status postgresql
sudo -u postgres psql
CREATE ROLE myusername LOGIN CREATEDB;
\q
psql -U myusername
CREATE DATABASE mydbname;
psql -d mydbname

.bashrcで

systemctl enable postgresql