PostgreSQL的 synchronous_standby_names 参数学习
磨砺技术珠矶,践行数据之道,追求卓越价值
回到上一级页面: PostgreSQL集群方案相关索引页 回到顶级页面:PostgreSQL索引页[作者 高健@博客园 luckyjackgao@gmail.com]
客户的streaming replication的参数是这样的:synchronous_standby_names=‘’
官方文档是这样说的:
synchronous_standby_names (string)
Specifies a comma-separated list of standby names that can support synchronous replication, as described in Section 25.2.7. At any one time there will be at most one active synchronous standby; transactions waiting for commit will be allowed to proceed after this standby server confirms receipt of their data. The synchronous standby will be the first standby named in this list that is both currently connected and streaming data in real-time (as shown by a state of streaming in the pg_stat_replication view). Other standby servers appearing later in this list represent potential synchronous standbys. If the current synchronous standby disconnects for whatever reason, it will be replaced immediately with the next-highest-priority standby. Specifying more than one standby name can allow very high availability. The name of a standby server for this purpose is the application_name setting of the standby, as set in the primary_conninfo of the standby's walreceiver. There is no mechanism to enforce uniqueness. In case of duplicates one of the matching standbys will be chosen to be the synchronous standby, though exactly which one is indeterminate. The special entry * matches any application_name, including the default application name of walreceiver. If no synchronous standby names are specified here, then synchronous replication is not enabled and transaction commits will not wait for replication. This is the default configuration. Even when synchronous replication is enabled, individual transactions can be configured not to wait for replication by setting the synchronous_commit parameter to local or off. This parameter can only be set in the postgresql.conf file or on the server command line.
这里,我最关注的是缺省形态,就是此值为空的情况,此时在master和slave之间,是非同步方式。这时master的运行比较高效,不必等待slave复制完毕才进行下一步动作。
[作者 高健@博客园 luckyjackgao@gmail.com]
回到上一级页面: PostgreSQL集群方案相关索引页 回到顶级页面:PostgreSQL索引页磨砺技术珠矶,践行数据之道,追求卓越价值
PostgreSQL的 synchronous_standby_names 参数学习的更多相关文章
- [转]Python3之max key参数学习记录
Python3之max key参数学习记录 转自https://www.cnblogs.com/zhangwei22/p/9892422.html 今天用Python写脚本,想要实现这样的功能:对于给 ...
- PostgreSQL参数学习:deadlock_timeout
磨砺技术珠矶,践行数据之道,追求卓越价值回到上一级页面:PostgreSQL基础知识与基本操作索引页 回到顶级页面:PostgreSQL索引页[作者 高健@博客园 luckyjackgao@g ...
- PostgreSQL参数学习:max_wal_senders
磨砺技术珠矶,践行数据之道,追求卓越价值回到上一级页面:PostgreSQL基础知识与基本操作索引页 回到顶级页面:PostgreSQL索引页[作者 高健@博客园 luckyjackgao@g ...
- PostgreSQL参数学习:random_page_cost
磨砺技术珠矶,践行数据之道,追求卓越价值回到上一级页面:PostgreSQL基础知识与基本操作索引页 回到顶级页面:PostgreSQL索引页[作者 高健@博客园 luckyjackgao@g ...
- PostgreSQL参数学习:wal_keep_segments
http://www.postgresql.org/docs/9.3/static/runtime-config-replication.html 参考官方文档: wal_keep_segments ...
- PostgreSQL参数学习:vacuum_defer_clean_age
官方文档: http://www.postgresql.org/docs/9.3/static/runtime-config-replication.html 为了防止slave端读取数据时,因为读到 ...
- postgresql修炼之道学习笔记(1)
好好学习吧. 本笔记 仅作为摘要记录 前两章,主要是数据库对比和安装等. 对比,就比多说了,总是和别人比较,会显得自己身价低,呵呵. 安装也有很多文章,不多说. 第二章提到了一些简单的配置, 其在 d ...
- PostgreSQL EXPLAIN执行计划学习--多表连接几种Join方式比较
转了一部分.稍后再修改. 三种多表Join的算法: 一. NESTED LOOP: 对于被连接的数据子集较小的情况,嵌套循环连接是个较好的选择.在嵌套循环中,内表被外表驱动,外表返回的每一行都要在内表 ...
- PostgreSQL流复制参数max_wal_senders详解
转自:http://my.oschina.net/Kenyon/blog/152234PostgreSQL 9.2.4 主机:192.25.10.76 从机:192.25.10.71 做postgre ...
随机推荐
- angularjs中factory, service和provider
在Angular里面,services作为单例对象在需要到的时候被创建,只有在应用生命周期结束的时候(关闭浏览器)才会被清除.而controllers在不需要的时候就会被销毁了(因为service的底 ...
- UIView 中 hidden、alpha、clear color 与 opaque 的区别
透明度与图层混合相关,影响到图片绘制的效率. hidden 此属性为 BOOL 值,用来表示 UIView 是否隐藏.关于隐藏大家都知道就是让 UIView 不显示而已,但是需要注意的是: 当前 UI ...
- BZOJ1042:[HAOI2008]硬币购物(DP,容斥)
Description 硬币购物一共有4种硬币.面值分别为c1,c2,c3,c4.某人去商店买东西,去了tot次.每次带di枚ci硬币,买si的价值的东西.请问每次有多少种付款方法. Input 第一 ...
- BZOJ1468:Tree(点分治)
Description 给你一棵TREE,以及这棵树上边的距离.问有多少对点它们两者间的距离小于等于K Input N(n<=40000) 接下来n-1行边描述管道,按照题目中写的输入 接下来是 ...
- 【[IOI2005]Riv 河流】
趁魏佬去英语演讲了,赶快%%%%%%%%%%%%%%魏佬 基本上是照着魏佬的代码写的 这其实还是一个树上背包 我们用\(dp[i][j][k]\)表示在以\(i\)为根的子树里,我们修建\(k\)个伐 ...
- 【[NOI2005]瑰丽华尔兹】
非常无脑和码农的单调队列优化\(dp\) 我们发现一个时间段内移动的情况是一样的,而时间段的数目又非常少,所以可以直接按照时间段来进行\(dp\) 由于每一次\(dp\)的移动距离都是小于等于某一个固 ...
- burpsuit常用功能
1.生成GET数据包:复制url -> 打开burp -> repeater -> 右键paste url as request 2.生成POST数据包:生成一个GET数据包 -&g ...
- 【bbs】logout.php
字体大小通过js设定,并结合@media,可实现自适应. 图片自适应窗口 实现流水灯手机端不滚动,script嵌套 多余文字省略号显示 http://www.cnblogs.com/yujihang ...
- 【vue】饿了么项目-页面骨架开发
1.页面骨架开发 1.1组件拆分 手机浏览器是把页面放在一个虚拟的“窗口”(viewport)中,通常这个虚拟的“窗口”(viewport)比屏幕宽,这样就不用把每个网页挤到很小的窗口中(这样会破坏没 ...
- [Python 网络编程] TCP、简单socket模拟ssh (一)
OSI七层模型(Open System Interconnection,开放式系统互联) 应用层 网络进程访问应用层: 为应用程序进程(例如:电子邮件.文件传输和终端仿真)提供网络服务: 提供用户身份 ...