设为首页 加入收藏

TOP

PostgreSQL数据库安装部署(四)
2019-06-02 00:12:12 】 浏览:266
Tags:PostgreSQL 数据库 安装 部署
u run initdb.


Success. You can now start the database server using:


    pg_ctl -D /usr/local/pgsql-10.5/data -l logfile start


[postgres@web1 ~]$


***在此就已经部署成功了,现在要做的就是修改下配置文件,优化下***


  17、前往文件安装所在地,修改pg_hba.conf配置文件


[postgres@web1 data]$ cp pg_hba.conf pg_hba.conf.`date +%F`
[postgres@web1 data]$ vim pg_hba.conf
#######################################
# TYPE  DATABASE        USER            ADDRESS                METHOD


# "local" is for Unix domain socket connections only
local  all            all                                    trust
# IPv4 local connections:
#host    all            all            127.0.0.1/32            trust
host    all            all            0.0.0.0/0              md5    #所有ip都可以通过密码连接
# IPv6 local connections:
host    all            all            ::1/128                trust
# Allow replication connections from localhost, by a user with the
# replication privilege.
local  replication    all                                    trust
host    replication    all            127.0.0.1/32            trust
######################################


  18、前往文件安装所在地,修改postgresql.conf配置文件


[postgres@web1 data]$ cd /usr/local/pgsql/data/
[postgres@web1 data]$ cp postgresql.conf postgresql.conf.`date +%F`
[postgres@web1 data]$ vim postgresql.conf
#########################################
# - Connection Settings -


listen_addresses = '*'  #为了方便,监听所有# what IP address(es) to listen on;
                                        # comma-separated list of addresses;
                                        # defaults to 'localhost'; use '*' for all
                                        # (change requires restart)
#port = 5432                            # (change requires restart)
max_connections = 100                  # (change requires restart)
#superuser_reserved_connections = 3    # (change requires restart)
#unix_socket_directories = '/tmp'      # comma-separated list of directories
                                        # (change requires restart)
#unix_socket_group = ''                # (change requires restart)
#unix_socket_permissions = 0777 

首页 上一页 1 2 3 4 5 下一页 尾页 4/5/5
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
上一篇MySQL中使用group_concat遇到的问.. 下一篇MySQL中group by 与 order by 一..

最新文章

热门文章

Hot 文章

Python

C 语言

C++基础

大数据基础

linux编程基础

C/C++面试题目