当前位置: 首页> 游戏> 单机 > html网页设计作业源代码_报告格式范文_seo线上培训机构_谷歌seo是什么职业

html网页设计作业源代码_报告格式范文_seo线上培训机构_谷歌seo是什么职业

时间:2025/7/11 15:51:07来源:https://blog.csdn.net/szy13323042191/article/details/144892425 浏览次数:0次
html网页设计作业源代码_报告格式范文_seo线上培训机构_谷歌seo是什么职业

CentOS7离线压缩包安装PostgreSQL

1 下载压缩包

官方地址
注:本文使用的是17.2版本

2 安装依赖

yum install -y perl-ExtUtils-Embed readline-devel zlib-devel pam-devel libxml2-devel libxslt-devel openldap-devel python-devel gcc-c++ openssl-devel cmake
yum install -y libicu libicu-devel

3 解压

tar -zxvf postgresql-17.2.tar.gz
cd postgresql-17.2

4 编译postgresql源码

./configure --prefix=/opt/pgsql/postgresql172

4.1 可能出现的问题

  1. configure: error: no acceptable C compiler found in $PATH
sudo yum install gcc-c++
  1. configure: error: ICU library not found If you have ICU already installed, see config.log for details on the failure. It is possible the compiler isn’t looking in the proper directory. Use --without-icu to disable ICU support.
sudo yum install libicu-devel
  1. configure: error: bison not found
yum install bison
  1. configure: error: flex not found
yum install flex
  1. configure: error: readline library not found
yum install readline-devel
  1. configure: error: zlib library not found
yum install zlib-devel

5 源码编译安装

make
make install

6 创建用户组、用户

groupadd postgres
useradd -g postgres postgres

7 创建数据主目录

cd /opt/pgsql/postgresql172
mkdir data
chown postgres:postgres data

8 配置环境变量

cd /home/postgres/
ls -la
vi .bash_profile

在最后面添加:
export PGHOME=/opt/pgsql/postgresql172
export PGDATA=$PGHOME/data
export PATH=$PATH:$HOME/bin:$PGHOME/bin

9 应用环境变量

source .bash_profile

10 初使化数据库

su - postgres
initdb

11 配置服务

cd /opt/pgsql/postgresql172/data
vi postgresql.conf

修改:
listen_address = ‘*’
port = 5432
max_connections = 100

vi pg_hba.conf

添加一行:
# IPv4 local connections:
host all all 0.0.0.0/0 trust
host all all 127.0.0.1/32 trust

12 设置开机自启动

su root
cd /home/postgresql-17.2/contrib/start-scripts
chmod a+x linux
cp linux /etc/init.d/postgresql172
vi /etc/init.d/postgresql172

修改:
prefix = /opt/pgsql/postgresql172
PGDATA=“/opt/pgsql/postgresql172/data”

chkconfig --add postgresql172
chkconfig

13 设置防火墙

yum -y install firewalld
systemctl start firewalld
systemctl status firewalld
firewall-cmd --permanent --zone=public --add-service=postgresql
firewall-cmd --reload

14 启动数据库服务

service postgresql start
ps -ef | grep postgres
su - postgres
psql
# 修改密码
ALTER USER postgres WITH PASSWORD 'admin@123';
关键字:html网页设计作业源代码_报告格式范文_seo线上培训机构_谷歌seo是什么职业

版权声明:

本网仅为发布的内容提供存储空间,不对发表、转载的内容提供任何形式的保证。凡本网注明“来源:XXX网络”的作品,均转载自其它媒体,著作权归作者所有,商业转载请联系作者获得授权,非商业转载请注明出处。

我们尊重并感谢每一位作者,均已注明文章来源和作者。如因作品内容、版权或其它问题,请及时与我们联系,联系邮箱:809451989@qq.com,投稿邮箱:809451989@qq.com

责任编辑: