高性能 Kubernetes 元数据存储 KubeBrain 的设计思路和落地效果-许辰主负责写和事件分发 • 从负责读 • 底层对接分布式强一致性存储 • CAS 事务写 • 快照读 实现架构图 存储层 存储层 – 分布式 KV Store ByteKV • Multi Raft Goup • 全局有序 Range 分区 • 强一致性 • 支持多 key 事务 • 支持 CAS • 支持快照读 • 高性能 存储层 - 数据格式 etcd KubeBrain • 性能优化 • 落地效果 • 未来演进 性能优化 写优化 - 1 降低锁粒度 存储引擎替换 表锁 -> 行锁,增大了写的并发 写优化 - 2 单点写 -> 多点写 multi raft range 分片,增大写并发 Brain 层无磁盘 io,只有网络 io 写优化 - 3 事务优化 精心设计 key 格式 一个 k8s 对象的索引和数据在同一分区内 跨分区分布式事务 Stream 代替分页,降低延迟 内存高效复用,避免 OOM 读优化 - 2 多分片并发读 通过并发,大大减少读时延 读优化 - 3 读写分离 follower 可以无限扩展,没有 raft 同步问题 读写之间无相互影响 读优化 - 4 Count 优化 基于周期性 Compact 统计,存在内存 降低时延,减轻存储压力 Watch 优化 - 1 写性能提升带来直接收益0 码力 | 60 页 | 8.02 MB | 1 年前3
Chaos Mesh让应用与混沌在 Kubernetes 上共舞-杨可奥使用起来更加简单 ● SideCar 共享 Network Namespace ○ 范围和权限更加可控 Chaos Mesh 使用案例 以 TiDB 为例 ● 假设 ○ TiDB 使用 Raft 一致性算法构建副本,应当拥有容错的能力 ○ 在杀掉一个节点之后,QPS 应当会下降 ○ 一段时间之后,QPS会恢复正常 ● 运行实验 ○ 使得一个节点无法工作(Pod Failure)0 码力 | 30 页 | 1.49 MB | 9 月前3
K8S安装部署开放服务/etc/docker/daemon.json { "exec-opts": ["native.cgroupdriver=systemd"], "log-driver": "json-file", "log-opts": { "max-size": "100m" }, "storage-driver": "overlay2", "storage-opts": nbiot-udp: address: ":9092/udp" providers: kubernetesCRD: "" log: filePath: "" level: error format: json accessLog: filePath: lvwq Org = iSurpass Bucket = openservice [Log] Filename = /opt/tools/iSurpass/openservice/log/openservice.log MaxSize = 1 MaxBackups = 30 MaxAge = 150 码力 | 54 页 | 1.23 MB | 1 年前3
涂小刚-基于k8s的微服务实践/data/all-log pod-path /data/all-log kafka-cluster elasticsearch-cluster logstash-cluster kafka-groupid=es topic applog logstash kafka-groupid=file file-storage mkdir -p /data/all- log/${namespaces}/${pod-name} app-log-path pod 1 worker node pod * app-log log* daemonsets filebeat 容器启动挂载宿主/data/all-log到容器/data/all-log 容器启动时创建namespace和pod-name 创建软连接到logs目录 daemonset在每一个k8s-node节点启动 挂载/data/all-log目录 实时扫描发现新目录日志0 码力 | 19 页 | 1.34 MB | 1 年前3
Kubernetes Native DevOps PracticeJob Job Job Job Pod Pod Pod Pod ElasticSearch ElasticSearch Logging Service agent to collecting log data ElasticSearch ElasticSearch Monitor/Alert Service CronJob Node Pod Node Pod Unified collecting log data ElasticSearch ElasticSearch Monitor/Alert Service DevOps Operator Cluster AutoScaler k8s API DevOps Service DevOps Service DevOps Manager Restful API realtime log history history log pull metric data ElasticSearch ElasticSearch Prometheus Push Gateway push metric data • Build task can also expose custom metric data • Ephemeral build task can push metric to gateway if0 码力 | 21 页 | 6.39 MB | 1 年前3
Kubernetes日志平台建设最佳实践-元乙Semi- structured Data SQL�NoSQL Log Service / LogShipper Mobile & Web IoT Mobile Logs Web Text & Logs Services & Languages IoT & Devices Camera �� Log Service / LogHub Real-time Data Stream DataV Log Service / Dashboard ��� Stream Processing SparkStreaming Function Compute Hadoop HIVE Big Data Analytics Batch Processing Pig PAI MaxCompute EMR Interactive Analytics DLA Log Service0 码力 | 30 页 | 53.00 MB | 1 年前3
在大规模Kubernetes集群上实现高SLO的方法ContainerCrashLoopBackOff, FailedPostStartHook, Unhealthy… Trace system Increase of SLO Data Collect Audit log Event The unhealthy node Monitoring Isolation Recover Degrade Data Analysis Failures/Machine problems automatically。 The infrastructure Log Event End User Storage Analysis Platform Trace Report Weakness The trace system Data Collect: Collect Audit log for the whole cluster. Data analysis: Analyze Auto Human experience Improve of strategy …… 1. Collect data from metrics NPD, Trace system and Log. 2. Analyze the problem of the node, such as DiskRO, critical Daemonset is not ready. 3. Processing0 码力 | 11 页 | 4.01 MB | 1 年前3
k8s操作手册 2.3/var/lib/chrony/dri� makestep 1.0 3 rtcsync keyfile /etc/chrony.keys leapsectz right/UTC logdir /var/log/chrony EOF # �medatectl set-�mezone Asia/Shanghai #设置时区 # systemctl restart chronyd # #pod容器要使用的存储卷声明 - name: alog #根据此名称去寻找对应的volume存储卷 mountPath: /var/log/nginx #容器里的挂载点 readOnly: false #非只读(即可读写) volumes: containers: - name: nginx-v1-19-5 #xxx省略其他配置项 volumeMounts: - name: alog mountPath: /var/log/nginx volumes: - name: alog nfs: server: 10.99.1.71 # nfs server ip/域名0 码力 | 126 页 | 4.33 MB | 1 年前3
QCon北京2017/企业软件互联网应用实践/基于 kubernetes 的企业级容器云logspout K8S DaemonSet stdout stderr K8S Pod LogMinion Kibana Kafka Cluster Log Parser ES Cluster log tail log tail stdout stderr Console 21 2017 Lenovo Internal. All rights reserved. Showcase0 码力 | 30 页 | 1.80 MB | 1 年前3
Go Programming Pattern in Kubernetes Philosophyimage: gcr.io/google_containers/testapp:v1 volumeMounts: - name: varlog mountPath: /var/log - name: logging-agent image: gcr.io/google_containers/fluentd:1.30 env: - name: FLUENTD_ARGS value: -c /etc/fluentd-config/fluentd.conf volumeMounts: - name: varlog mountPath: /var/log - name: config-volume mountPath: /etc/fluentd-config volumes: - name: varlog emptyDir: -c /etc/fluentd-config/fluentd.conf volumeMounts: - name: varlog mountPath: /var/log - name: config-volume mountPath: /etc/fluentd-config volumes: - name: varlog0 码力 | 29 页 | 2.12 MB | 1 年前3
共 19 条
- 1
- 2













