pgbouncer的安装和配置
tar -zxvf libevent-2.0.21-stable.tar.gz
cd libevent-2.0.21-stable/
mkdir /home/pg10/libevent
./configure --prefix=/home/pg10/libevent
make & make install
tar -zxvf pgbouncer-1.7.2.tar.gz
cd pgbouncer-1.7.2
./configure --prefix=/home/pg10/pgbouncer/ --with-libevent=/home/pg10/libevent
make & make install
mkdir /var/log/pgbouncer
mkdir /var/run/pgbouncer
mkdir /etc/pgbouncer
cp /opt/soft_bak/pgbouncer-1.8.1/etc/pgbouncer.ini /etc/pgbouncer
cd /etc/pgbouncer
vi pgbouncer.ini
[databases]
postgres=host=10.110.13.172 port=5432 user=postgres dbname=postgres pool_size=100
[pgbouncer]
logfile = /var/log/pgbouncer/pgbouncer.log
pidfile = /var/run/pgbouncer/pgbouncer.pid
auth_file = /etc/pgbouncer/userlist.txt
auth_type = trust
listen_addr = 10.110.13.172
listen_port = 9999
pool_mode = transaction
admin_users = postgres
vi /etc/pgbouncer/userlist.txt
"postgres" "hytera1993"
chown -R pg10:pg10 /var/log/pgbouncer
chown -R pg10:pg10 /var/run/pgbouncer
chown -R pg10:pg10 /etc/pgbouncer
chmod 755 /var/log/pgbouncer
chmod 755 /var/run/pgbouncer
chmod 755 /etc/pgbouncer
su - pg10
vi .bash_profile
export PATH=/home/pg10/pgbouncer/bin:$PATH:.
source .bash_profile
pgbouncer -d /etc/pgbouncer/pgbouncer.ini --r
1、lsof -i:端口号
2、netstat -tunlp|grep 端口号
都可以查看指定端口被哪个进程占用的情况
pgbouncer的安装和配置的更多相关文章
- linux ---pgbouncer的安装和配置
pgbouncer是一款轻量级针对postgresql的数据库连接工具,可以对客户端的连接做限制,防止恶意连接,另外也可以减少数据库的实际连接数,从而减少数据库的开销. 环境: centos 6.5 ...
- JDK安装与配置
JDK安装与配置 一.下载 JDK是ORACLE提供免费下载使用的,官网地址:https://www.oracle.com/index.html 一般选择Java SE版本即可,企业版的选择Java ...
- Node.js 教程 01 - 简介、安装及配置
系列目录: Node.js 教程 01 - 简介.安装及配置 Node.js 教程 02 - 经典的Hello World Node.js 教程 03 - 创建HTTP服务器 Node.js 教程 0 ...
- 烂泥:redis3.2.3安装与配置
本文由ilanniweb提供友情赞助,首发于烂泥行天下 想要获得更多的文章,可以关注我的微信ilanniweb 前一段时间写过一篇codis集群的文章,写那篇文章主要是因为当时的项目不支持redis自 ...
- mysql源码包手动安装、配置以及测试(亲测可行)
笔记编者:小波/qq463431476博客首页:http://www.cnblogs.com/xiaobo-Linux/ 记下这篇mysql笔记,望日后有用! redhat6采用centos yum源 ...
- 环境搭建系列-系统安装之centos 6.5安装与配置
按照国际惯例,系列目录先奉上: 系列一:系统安装之centos 6.5安装与配置 系列二:准备工作之Java环境安装 系列三:数据为先之MySQL读写集群搭建 系列四:谈分布式之RabbitMQ集群搭 ...
- ZooKeeper安装与配置
一. 单机安装.配置: 1. 下载zookeeper二进制安装包下载地址:http://apache.dataguru.cn/zookeeper/zookeeper-3.4.3/zookeeper-3 ...
- mac 下JDK 与 tomcat 的安装与配置
一.Mac下JDK的安装 1.先检测Mac是否已经安装过JDK,在终端中输入java 或者 javac 显示说明,表明已经安装过JDK,JDK版本查询终端键入java -version,终端会返回JD ...
- 烂泥:zabbix3.0安装与配置
本文由ilanniweb提供友情赞助,首发于烂泥行天下 想要获得更多的文章,可以关注我的微信ilanniweb 这个月又快过完了,最近也比较忙,没时间写文章,今天挤点时间把zabbix3.0安装与配置 ...
随机推荐
- mysql的安装与基本管理
MySQL是一个关系型数据库管理系统,由瑞典MySQL AB 公司开发,目前属于 Oracle 旗下公司.MySQL 最流行的关系型数据库管理系统,在 WEB 应用方面MySQL是最好的 RDBMS ...
- P4474 王者之剑
P4474 王者之剑 题目大意 n*m的带权网格,任意选择起点开始时刻为0秒.以下操作,每秒按顺序执行 在第i秒开始的时候,在方格(x,y)上,获得(x,y)的值 在偶数秒,周围四格的值清零 每秒可选 ...
- 【转载】帧缓冲驱动程序分析及其在BSP上的添加
原文地址:(四)帧缓冲驱动程序分析及其在BSP上的添加 作者:gfvvz 一.BSP修改及其分析 1. BSP中直接配置的四个寄存器 S3C6410数据手册的第14.5部分是显示控制器的编程模型部 ...
- Spring Boot2.0之自定义参数
自定义参数,把不同环境的配置放到配置文件中去. 不同环境,如何区分配置文件信息,自定义配置文件信息 比如在 application.properties定义个参数 name=toov5 Spring ...
- 大数据初级笔记二:Hadoop入门之Hadoop集群搭建
Hadoop集群搭建 把环境全部准备好,包括编程环境. JDK安装 版本要求: 强烈建议使用64位的JDK版本,这样的优势在于JVM的能够访问到的最大内存就不受限制,基于后期可能会学习到Spark技术 ...
- iOS开发 - 如何跳到系统设置里的各种设置界面
在iOS开发中,有时会有跳转系统设置界面的需求,例如提示用户打开蓝牙或者WIFI,提醒用户打开推送或者位置权限等.在iOS6之后,第三方应用需要跳转系统设置界面,需要在URL type中添加一个pre ...
- L93
Three Days to See(Excerpts) All of us have read thrilling stories in which the hero had only a limit ...
- listen 78
Struggling Young Readers Like Kindles Kindles, Nooks and other e-readers catch flack for threatening ...
- linux 网络编程getdomainname与gethostname函数
getdomainname与gethostname函数 1 gethostname() : 返回本地主机的标准主机名. 原型如下: #include <unistd.h> int geth ...
- Python: Neural Networks
这是用Python实现的Neural Networks, 基于Python 2.7.9, numpy, matplotlib. 代码来源于斯坦福大学的课程: http://cs231n.github. ...