linux fedora35安装、登录postgresql-14数据库命令整理
生活随笔
收集整理的這篇文章主要介紹了
linux fedora35安装、登录postgresql-14数据库命令整理
小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.
安裝命令
sudo dnf install -y https://download.postgresql.org/pub/repos/yum/reporpms/F-35-x86_64/pgdg-fedora-repo-latest.noarch.rpmsudo dnf install -y postgresql14-serversudo /usr/pgsql-14/bin/postgresql-14-setup initdbsudo vim sudo systemctl enable postgresql-14sudo systemctl start postgresql-14連接
su - postgrespsql -U postgresalter role postgres with password "123456"配置
修改監(jiān)聽地址
sudo vim /var/lib/pgsql/14/data/postgresql.conf #listen_addresses='localhost' #將上面這行改成如下 listen_addresses='*'設(shè)置所有網(wǎng)段IP可以訪問
sudo vim /var/lib/pgsql/14/data/postgresql.conf # IPv4 remote address connections: host all all 0.0.0.0/0 trust官網(wǎng)鏈接:https://www.postgresql.org/download/linux/redhat/
總結(jié)
以上是生活随笔為你收集整理的linux fedora35安装、登录postgresql-14数据库命令整理的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: PostgreSQL新手入门教程
- 下一篇: manjaro linux换源