centos7.5安装postgresql方法

2025-04-30 09:11:38

1、添加yum源

centos7.5安装postgresql方法

2、清除之前的yum源并生成新的缓存

centos7.5安装postgresql方法

3、yum install postgresql96-server postgresql96-contrib postgresql96-devel

centos7.5安装postgresql方法

4、输入y并回车继续安装

centos7.5安装postgresql方法

5、验证是否安装成功rpm -aq| grep postgres

centos7.5安装postgresql方法

6、初始化数据库/usr/pgsql-9.6/bin/postgresql96-setup initdb

centos7.5安装postgresql方法

7、[root@vm-122-136 ~]# systemctl enable postgresql-9.6Cr髫潋啜缅eated symlink from /etc/systemd/system/multi-user.target.wants/postgresql-9.6.service to /usr/lib/systemd/system/postgresql-9.6.service.You have new mail in /var/spool/mail/root[root@vm-122-136 ~]# systemctl start postgresql-9.6

centos7.5安装postgresql方法

8、连接数据库并修改密码

centos7.5安装postgresql方法
声明:本网站引用、摘录或转载内容仅供网站访问者交流或参考,不代表本站立场,如存在版权或非法内容,请联系站长删除,联系邮箱:site.kefu@qq.com。
猜你喜欢