加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

现有PostgreSQL 集群/热备方案

发布时间:2020-12-13 17:46:07 所属栏目:百科 来源:网络整理
导读:本文地址:http://www.jb51.cc/article/p-bpqnxxqv-db.html 集群解决的负载能力的问题,要求就是能增加服务器(群)的吞吐量和响应速度。 热备解决的是服务连续性(高可用性)的问题。 不是所有的模块都需要集群,也不是所有服务都需要热备。 下面是现有的基于pos

本文地址:http://www.52php.cn/article/p-bpqnxxqv-db.html


集群解决的负载能力的问题,要求就是能增加服务器(群)的吞吐量和响应速度。

热备解决的是服务连续性(高可用性)的问题。

不是所有的模块都需要集群,也不是所有服务都需要热备。

下面是现有的基于postgreSQL的集群/热备方案列表。


1,pgpool

一个中间件,介于PostgreSQL Server和PostgresSQL database client之间。

具有一下特性:
* Connection Pooling(连接池管理),* Replication(备份),* Load Balance(负载均衡),* Limiting Exceeding Connection(连接数限制)
* Parallel Query(并发查询)

BSD licensed,不支持windows.

一个异步的主从复制系统,基于PostgreSQL,不能用于热备。

2,Slony

Slony 是一种异步的主从(master-slave)数据库复制方案,支持一主多从结构,支持cascading。
该解决方案适用于备份(非热备)。 PostgreSQL 9.0提供异步的复制方案,streaming replication

BSD licensed,

3,GridSQL

GridSQL是一个基于java的 shared nothing集群系统, 包含加速查询的负载均衡机制,Designed for Parallel Querying,基于key hash.
无心跳检测和灾备功能。

GPL licensed.

4,plproxy

一个数据库分页系统,实现基于一种pl语言设计。
对于数据操作需要使用其pl语言,pl类似于SQL.
支持水平分片,支持基于查询的负载均衡。

5,PGCluster

PGCluster是一个多主数据库同步复制工具,基于shared-nothing架构。

可以用于热备。
BSD licensed.

PGCluster的主要特性是防止数据丢失,同时也提供读操作负载均衡,但是实际应用中实施不多。

PGCluster intended features:

HA

  • DB Service does not stop during fail over,auto recovery,dynamic add and upgrade server etc.
  • No Single point of failure.
  • Auto adjust data transfer speed based on network bandwidth.
  • Load balance server and monitoring server are including.
Synchronous multi﹎aster configuration
  • Any update to any master is visible from other masters immediately.
  • No change in transaction handling.
  • Value of now() and random() are replicated.

6,PostgreSQL 9 streaming replication

Streaming replication 是PostgreSQL 9.0里面引入的数据库复制机制,异步的。不提供集群机制。不能用于热备。

7,PgBouncer

解决方案实施

解决方案对比

参考:

http://topic.csdn.net/u/20090416/21/8629c72a-857a-487b-ae1b-3db31cfd850b.html,这里提到了 pgpool,GridSQL和plproxy三种集群方案。
http://www.52php.cn/article/p-guurkvph-bga.html,PostgreSQL 数据库扩展的三种方式,有部署方案,slony-l,pgcluster。
http://www.toplee.com/blog/71.html,大型高并发高负载网站的系统架构。
http://en.wikipedia.org/wiki/Shared_nothing_architecture,Shared nothing architecture

http://www.cnblogs.com/shuaixf/archive/2011/11/22/2259067.html,pgpool-II介绍。
http://www.pgpool.net/mediawiki/index.php/Main_Page,pgpool-II wiki.
http://pgpool.projects.postgresql.org/FAQ.html,FAQ of Pgpool-II.

http://slony.info/,slony.

http://www.slideshare.net/jim_mlodgenski/scaling-postgresql-with-gridsql, scaling-postgresql-with-gridsql

http://scanningpages.wordpress.com/2010/10/09/9-0-streaming-replication-vs-slony/,9.0 Streaming Replication vs Slony.
http://wiki.postgresql.org/wiki/PgCluster,PgCluster

http://plproxy.projects.postgresql.org/faq/faq.html,plproxy FAQ.

http://baike.baidu.com/view/132705.htm,双机热备。
http://baike.baidu.com/view/2072704.htm,双机热备系统.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读