<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>数据库 on 黄文卓 | DevOps Engineer</title><link>https://socake.github.io/categories/%E6%95%B0%E6%8D%AE%E5%BA%93/</link><description>Recent content in 数据库 on 黄文卓 | DevOps Engineer</description><generator>Hugo -- gohugo.io</generator><language>zh-CN</language><managingEditor>17691281867@163.com (Wenzhuo Huang)</managingEditor><webMaster>17691281867@163.com (Wenzhuo Huang)</webMaster><copyright>© 2026 Wenzhuo Huang</copyright><lastBuildDate>Sun, 12 Apr 2026 14:00:00 +0800</lastBuildDate><atom:link href="https://socake.github.io/categories/%E6%95%B0%E6%8D%AE%E5%BA%93/index.xml" rel="self" type="application/rss+xml"/><item><title>MySQL 高可用实战：MGR + ProxySQL + Orchestrator 完整部署</title><link>https://socake.github.io/posts/mysql-ha-mgr-proxysql/</link><pubDate>Sun, 12 Apr 2026 14:00:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/mysql-ha-mgr-proxysql/</guid><description>详细讲解 MySQL 8.0 MGR 单主模式完整搭建过程、脑裂与 GTID 不一致处理方法、ProxySQL 读写分离配置和健康检查脚本、Orchestrator 自动故障转移与 ProxySQL 联动，以及 mysqld_exporter 监控集成。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/mysql-ha-mgr-proxysql/featured.jpg"/></item><item><title>PostgreSQL 高可用实战：Patroni + HAProxy + etcd 完整部署指南</title><link>https://socake.github.io/posts/postgresql-ha-patroni/</link><pubDate>Sun, 12 Apr 2026 10:00:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/postgresql-ha-patroni/</guid><description>详解 Patroni 自动故障转移机制，手把手完成 etcd 三节点集群搭建、Patroni 完整配置（含 pg_hba.conf 托管）、HAProxy 读写分离配置，以及 kill primary 故障切换演练全过程。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/postgresql-ha-patroni/featured.jpg"/></item><item><title>数据库运维实践：MySQL 高可用与 PostgreSQL 调优经验</title><link>https://socake.github.io/posts/database-ops-practice/</link><pubDate>Tue, 08 Apr 2025 13:37:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/database-ops-practice/</guid><description>数据库运维不复杂，但细节多、出问题代价大。本文整理了 MySQL 主从复制、慢查询分析、PostgreSQL 连接池这几个高频话题的实战经验，以及一些日常运维 SQL 备忘。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/database-ops-practice/featured.jpg"/></item><item><title>MongoDB 运维入门：部署、备份与生产性能调优</title><link>https://socake.github.io/posts/mongodb-ops-practice/</link><pubDate>Mon, 31 Mar 2025 11:41:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/mongodb-ops-practice/</guid><description>MongoDB 运维从选型到调优：何时选 MongoDB、Replica Set 三节点部署、索引设计、mongodump 备份，以及 wiredTiger、连接池、大文档等生产踩坑。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/mongodb-ops-practice/featured.jpg"/></item><item><title>PostgreSQL 运维实战：配置调优、连接池、慢查询与高可用</title><link>https://socake.github.io/posts/postgresql-ops-practice/</link><pubDate>Tue, 18 Mar 2025 10:15:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/postgresql-ops-practice/</guid><description>系统梳理 PostgreSQL 运维核心技能：从 shared_buffers、WAL 参数调优，到 PgBouncer 事务模式配置；从 pg_stat_statements 慢查询分析到 PITR 时间点恢复；以及主从流复制、膨胀表清理和 Prometheus 监控指标的完整实践。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/postgresql-ops-practice/featured.jpg"/></item><item><title>Doris 与 StarRocks：一次严肃的生产选型笔记</title><link>https://socake.github.io/posts/columnar-warehouse-doris-starrocks/</link><pubDate>Wed, 22 Jan 2025 15:30:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/columnar-warehouse-doris-starrocks/</guid><description>Doris 和 StarRocks 同源、相似、又各有偏好。选哪个不是&amp;quot;谁更好&amp;quot;的问题，而是&amp;quot;谁更适合我们的场景&amp;quot;的问题。这篇文章是我在两套 OLAP 集群（一套 Doris、一套 StarRocks）上运维一年多后写的深度对比，希望能帮你跳过几个月的调研和踩坑。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/columnar-warehouse-doris-starrocks/featured.jpg"/></item><item><title>数据库变更管理：从 gh-ost 到 Flyway 的完整工程化路径</title><link>https://socake.github.io/posts/database-change-management/</link><pubDate>Wed, 08 Jan 2025 10:00:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/database-change-management/</guid><description>很多团队把&amp;quot;数据库变更管理&amp;quot;当成几条 SQL + 一个工单，实际上这是工程化程度最低的一块地方。一边是开发随手写 ALTER 把线上锁住，一边是 DBA 手动盯着进度条祈祷不出事。这篇文章把我总结的 DB 变更管理最佳实践分成工具、流程、组织三个层面讲，每一层都有可以直接落地的方案。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/database-change-management/featured.jpg"/></item><item><title>Vitess 实战：把 MySQL 水平扩展到 PB 级的路</title><link>https://socake.github.io/posts/vitess-mysql-sharding/</link><pubDate>Tue, 24 Dec 2024 14:00:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/vitess-mysql-sharding/</guid><description>当 MySQL 单库扛不住、又不想切 TiDB 或 PG 的时候，Vitess 就成了最后一个选项。它保留了 MySQL 兼容性，用 vtgate 做分片代理，用 VReplication 做在线 resharding。听起来很美，但 Vitess 的学习曲线陡得惊人。这篇文章是我调研 Vitess 几个月、在 staging 跑通一个 4 shard 集群后的全面笔记。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/vitess-mysql-sharding/featured.jpg"/></item><item><title>MongoDB 分片集群实战：从 shard key 设计到 chunk 均衡的全链路</title><link>https://socake.github.io/posts/mongodb-sharding-practice/</link><pubDate>Wed, 20 Nov 2024 15:00:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/mongodb-sharding-practice/</guid><description>很多团队把 MongoDB 分片当成&amp;quot;设个 shard key 就完事&amp;quot;，结果上线半年后发现 80% 数据在一个 shard 上、balancer 每天搬几十 GB 却怎么都追不上、某个 collection 出现 jumbo chunk 无法分裂。这篇文章把我在几套 MongoDB 分片集群上的经验整理出来，希望能让你在分片之前少走一些弯路。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/mongodb-sharding-practice/featured.jpg"/></item><item><title>Redis Cluster 扩缩容与数据迁移实战：从 SETSLOT 到 Atomic Slot Migration</title><link>https://socake.github.io/posts/redis-cluster-migration/</link><pubDate>Fri, 08 Nov 2024 10:30:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/redis-cluster-migration/</guid><description>很多团队把 Redis Cluster 当成&amp;quot;开箱即用&amp;quot;的分布式 Redis，直到要做扩缩容或数据迁移时才发现：SETSLOT 协议里有十几种状态，迁移过程中客户端重定向要么不生效要么风暴，migrate 卡住没法断，big key 直接把迁移拖垮。这篇文章把我在几套千亿级 Cluster 上做过的扩缩容、迁移、救火全过一遍。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/redis-cluster-migration/featured.jpg"/></item><item><title>Redis 运维实践：持久化配置、集群模式与生产监控</title><link>https://socake.github.io/posts/redis-ops-practice/</link><pubDate>Wed, 06 Nov 2024 10:20:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/redis-ops-practice/</guid><description>Redis 运维看起来简单，但真到了生产出了问题才知道水有多深。本文整理了持久化、集群、监控、故障处理等核心运维主题。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/redis-ops-practice/featured.jpg"/></item><item><title>MySQL 备份与恢复实战：从 mysqldump 到 XtraBackup 的完整方案</title><link>https://socake.github.io/posts/mysql-backup-restore/</link><pubDate>Fri, 01 Nov 2024 11:33:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/mysql-backup-restore/</guid><description>从 mysqldump 到 XtraBackup，从全量备份到基于 binlog 的时间点恢复，这篇文章覆盖了 MySQL 备份恢复的完整知识体系，包括生产环境的踩坑和自动化验证方案。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/mysql-backup-restore/featured.jpg"/></item><item><title>PostgreSQL 膨胀治理：把 autovacuum 调到你真正需要的样子</title><link>https://socake.github.io/posts/postgresql-vacuum-bloat-tuning/</link><pubDate>Tue, 29 Oct 2024 09:30:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/postgresql-vacuum-bloat-tuning/</guid><description>大部分 PostgreSQL DBA 对 autovacuum 的理解停留在&amp;quot;它会自己跑&amp;quot;，但一旦膨胀起来才发现：默认参数对现代硬件完全不够用，几十个 autovacuum_* 参数各管一摊，出了问题根本不知道从哪儿看。这篇文章把我在几套 PG 集群上治理膨胀的经验整理出来，从 MVCC 原理讲到参数调优、从监控到应急处置。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/postgresql-vacuum-bloat-tuning/featured.jpg"/></item><item><title>MySQL 深度调优：从 Buffer Pool 到锁等待的生产手册</title><link>https://socake.github.io/posts/mysql-performance-tuning-deep-dive/</link><pubDate>Fri, 18 Oct 2024 14:30:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/mysql-performance-tuning-deep-dive/</guid><description>你有没有过这种体验：按网上教程把 innodb_buffer_pool_size 调到 75%、关了 query cache、打开了 innodb_file_per_table，然后告诉自己&amp;quot;MySQL 调优就这样了&amp;quot;？真正的调优是一个持续观察、假设、验证、回滚的过程。这篇文章把我在过去几年维护的十几套 MySQL 实例上积累的调参经验整理出来，每一条都能追到具体指标和业务效果。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/mysql-performance-tuning-deep-dive/featured.jpg"/></item><item><title>TiDB 生产环境实战：从 Placement Rules 到 TiKV 调优的全链路经验</title><link>https://socake.github.io/posts/tidb-production-practice/</link><pubDate>Sat, 05 Oct 2024 10:00:00 +0800</pubDate><author>17691281867@163.com (Wenzhuo Huang)</author><guid>https://socake.github.io/posts/tidb-production-practice/</guid><description>把 TiDB 当成&amp;quot;分布式 MySQL&amp;quot;跑起来并不难，真正难的是让 TiKV 在高并发写入下不抖动、让 PD 调度不误伤业务、让跨机房副本在 RPO=0 的前提下活下去。本文把过去两年我在几套 TiDB 集群上踩过的坑、调过的参数和定过的 SOP 都摊开来讲，不是教程，而是一份能直接照抄的作战手册。</description><media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://socake.github.io/posts/tidb-production-practice/featured.jpg"/></item></channel></rss>