Setup PostgreSQL in Fedora

Опубликовано: 06 Май 2026
на канале: Chair Shíín
48
1

Install Fedora Server
• sudo dnf install postgresql-server postgresql-contrib
• sudo postgresql-setup --initdb
• sudo systemctl start postgresql
• sudo systemctl enable postgresql
• systemctl status postgresql

Local login
• sudo -iu postgres
• psql

INSIDE the DB
CREATE DATABASE db_name; # creat database
CREATE USER postgres WITH PASSWORD 'your_password'; # creat default user name postgres and password
GRANT ALL PRIVILEGES ON DATABASE db_name TO postgres; # provide privileges
ALTER USER postgres WITH PASSWORD 'your_password'; # change password

Connect via VSCode Extension: