replication

Redis replication and client-output-buffer-limit

≯℡__Kan透↙ 提交于 2020-06-11 01:23:25
问题 I am having a problem with redis replication that I can not figure out. Master keeps hitting the client-output-buffer-limit. Master Config: # redis-cli -p 6380 config get client-output-buffer-limit 1) "client-output-buffer-limit" 2) "normal 0 0 0 slave 536870912 536870912 0 pubsub 33554432 8388608 60" Master Log: Client id=3014598 addr={{MASTER}} fd=6 name= age=217 idle=217 flags=S db=0 sub=0 psub=0 multi=-1 qbuf=0 qbuf-free=0 obl=3723 oll=4806 omem=581952061 events=rw cmd=psync scheduled to

Kubernetes部署服务

橙三吉。 提交于 2020-04-07 07:24:12
基本流程为: 做image 并且push到private registry 创建replication controller 创建service 搭建nginx代理 测试 下面详述: 1. 制作image java基础image: FROM dockerimages.yinnut.com:15043/centos:7 MAINTAINER xuelun-infra morgan.wu@yinnnut.com ADD jdk-8u60-linux-x64.tar.gz /usr/local/ ENV JAVA_HOME /usr/local/jdk1.8.0_60 ENV PATH $JAVA_HOME/bin:$PATH Friend-Service镜像: FROM dockerimages.yinnut.com:15043/yinnut-java:0.1 MAINTAINER xuelun-infra morgan.wu@yinnnut.com ADD FriendService.war / ADD jetty-runner.jar / WORKDIR / VOLUME ["/var/log"] 2. 创建Replication Controller rc.yaml文件, 创建了2个friend的pod,设置replicas为2 apiVersion: v1 kind:

repmgr实现pg流复制失效自动切换

橙三吉。 提交于 2020-04-07 07:04:28
本次测试中用到的配置及脚本见: https://github.com/lxgithub/repmgr_conf_scripts 一、系统 IP HOSTNAME PG VERSION DIR OS 192.168.100.146 node1 9.3.4 /opt/pgsql CentOS6.4_x64 192.168.100.150 node2 9.3.4 /opt/pgsql CentOS6.4_x64 # cat /etc/issue CentOS release 6.5 (Final) Kernel \r on an \m # uname -a Linux barman 2.6.32-431.11.2.el6.x86_64 #1 SMP Tue Mar 25 19:59:55 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux # cat /etc/hosts 127.0.0.1localhost.localdomainlocalhost.localdomainlocalhost4localhost4.localdomain4localhostnode1 ::1localhost.localdomainlocalhost.localdomainlocalhost6localhost6.localdomain6localhostnode1 192

Kubernetes管理基本教程

我的梦境 提交于 2020-04-06 22:00:51
本文不对Kubernetes做过多介绍,直接讲Kubernetes的各种YAML基本撰写规范。 基本概念请见: http://www.infoq.com/cn/articles/Kubernetes-system-architecture-introduction 所有的Resource的定义文档在这里都有 http://kubernetes.io/v1.0/docs/api-reference/definitions.html 例如:你要查询Pod声明里面有哪些字段,那么很有用. 不多废话。 1. 创建Container / Pod## Kubernetes的编排基本单元是Pod,故而哪怕你只有一个Container,也要创建一个Pod来容纳这个Container. apiVersion: v1 kind: Pod metadata: name: hello-world # pod资源名称,集群unique的 spec: # specification of the pod’s contents restartPolicy: Never # 运行这个容器一次,然后就结束这个pod containers: - name: hello # 只是这个container的nickname image: "ubuntu:14.04" # image 名, 默认使用Docker Hub

MongoDB as windows service and setting up replicaSet

萝らか妹 提交于 2020-03-17 04:38:04
问题 I have installed MongoDB and its set up as windows service. When I try to set up replicaSet I am getting error "Only one usage of each socket address (protocol/network address/port) is normally permitted. for socket: 0.0.0.0:27017". So, I have stopped the windows service and set up replicaSet. The replicaSet is working fine now. But, I don't see the windows service up and running. Does that means I can't set up replicaSet and MongoDB service at the same time? 回答1: You can set up replica set

heartbeat + pacemaker实现pg流复制自动切换

*爱你&永不变心* 提交于 2020-03-02 09:07:26
heartbeat + pacemaker + postgres_streaming_replication 说明: 该文档用于说明以 hearbeat +pacemaker 的方式实现 PostgreSQL 流复制自动切换。注意内容包括有关 hearbeat /pacemaker 知识总结以及整个环境的搭建过程和问题处理。 一、介绍 Heartbeat 自 3 版本开始, heartbeat 将原来项目拆分为了多个子项目(即多个独立组件),现在的组件包括: heartbeat 、 cluster-glue 、 resource-agents 。 各组件主要功能: heartbeat :属于集群的信息层,负责维护集群中所有节点的信息以及各节点之间的通信。 cluster-glue :包括 LRM (本地资源管理器)、 STONITH ,将 heartbeat 与 crm (集群资源管理器)联系起来,属于一个中间层。 resource-agents :即各种资源脚本,由 LRM 调用从而实现各个资源的启动、停止、监控等。 Heartbeat 内部组件关系图: Pacemaker Pacemaker ,即 Cluster Resource Manager ( CRM ),管理整个 HA ,客户端通过 pacemaker 管理监控整个集群。 常用的集群管理工具: ( 1 )基于命令行

Why starting a solo MongoDB instance as replica set is not recommended in production?

偶尔善良 提交于 2020-02-29 06:42:19
问题 Following the discussions in the comments at this answer, @kevinadi recommended me to open a new questions related to his comment: You can start a replica set with one node for development purposes. [...] Be advised that this is not a recommended setup for a production environment. Many people are starting a replica set for solo MongoDB instances, and having a clear answer about WHY this is not recommended is interesting for future reference. I'm hoping @kevinadi will answer it, providing

Django 1.8 Migration with Postgres BDR 9.4.1

限于喜欢 提交于 2020-02-02 04:22:53
问题 I am trying to run Django migrations on a Postgres database with BDR. python manage.py makemigrations works fine, but running python manage.py migrate results in the following error: ALTER TABLE … ALTER COLUMN TYPE … may only affect UNLOGGED or TEMPORARY tables when BDR is active; auth_permission is a regular table The offending module is django/django/contrib/auth/migrations/0002_alter_permission_name_max_length.py . I am not finding anything on how to UNLOGGED tables using Django,

Django 1.8 Migration with Postgres BDR 9.4.1

与世无争的帅哥 提交于 2020-02-02 04:21:10
问题 I am trying to run Django migrations on a Postgres database with BDR. python manage.py makemigrations works fine, but running python manage.py migrate results in the following error: ALTER TABLE … ALTER COLUMN TYPE … may only affect UNLOGGED or TEMPORARY tables when BDR is active; auth_permission is a regular table The offending module is django/django/contrib/auth/migrations/0002_alter_permission_name_max_length.py . I am not finding anything on how to UNLOGGED tables using Django,

Cassandra replication system - how it works

我是研究僧i 提交于 2020-01-22 16:18:28
问题 Does Cassandra replicate only on write procedure (with chosen consistency level)? Is there any auto-replicate option for absent nodes, if I want symmetric data in every node? If I plug in a new node to the cluster, there is no auto replication. How can I sync data from other nodes with the new one? If I want replication like multimaster (2 nodes) with slave backup (1 node) known from MySQL, what is the proper way to set up and manage that on Cassandra (3 nodes)? How about two nodes? 回答1: