惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

GbyAI
GbyAI
Martin Fowler
Martin Fowler
云风的 BLOG
云风的 BLOG
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
T
The Blog of Author Tim Ferriss
大猫的无限游戏
大猫的无限游戏
A
About on SuperTechFans
小众软件
小众软件
博客园_首页
博客园 - 聂微东
罗磊的独立博客
Recent Announcements
Recent Announcements
U
Unit 42
N
Netflix TechBlog - Medium
Blog — PlanetScale
Blog — PlanetScale
阮一峰的网络日志
阮一峰的网络日志
博客园 - 叶小钗
V
V2EX
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
IT之家
IT之家
Stack Overflow Blog
Stack Overflow Blog
博客园 - Franky
D
DataBreaches.Net
Last Week in AI
Last Week in AI

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Upgrading GBase 8c: Online and Offline Strategies
Michael · 2026-05-09 · via DEV Community

Michael

To improve stability, security, and performance, database upgrades are a core operations task. GBase 8c, the China‑domestically developed database from GBASE, supports both online and offline upgrades with a grey‑release approach — business is unaffected during the process, and you can quickly rollback at the first sign of trouble.

Upgrade Modes

  • Online upgrade: No downtime. Services keep running throughout.
  • Offline upgrade: Business is suspended during the window.

You can upgrade just the HA module, just the database kernel, or both together. Small and major version upgrades follow the same steps.

Offline HA Module Upgrade

  1. Upload and extract the new package.
  2. Prepare the configuration:
   gha_ctl prepare version pkg_path install_prefix [-u 'gbase'] [-p 22] [-c gbase8c] -l dcslist [-t multiple-nodes|single-inst]

Enter fullscreen mode Exit fullscreen mode

  1. Pre‑processing:
   ./gha_ctl upgrade -t catalog V5_S3.0.3B06 -l http://10.0.7.11:2379

Enter fullscreen mode Exit fullscreen mode

Note: Replace upgrade with rollback if downgrading.

  1. Stop all nodes:
   gha_ctl stop all -l http://10.0.7.11:2379

Enter fullscreen mode Exit fullscreen mode

  1. Perform the HA upgrade:
   ./gha_ctl upgrade V5_S3.0.3B06 100.0.7.12 -t ha -l http://10.0.7.11:2379

Enter fullscreen mode Exit fullscreen mode

  1. Start all nodes:
   gha_ctl start all -l http://10.0.7.11:2379

Enter fullscreen mode Exit fullscreen mode

  1. Post‑upgrade configuration:
   gha_ctl upgrade -t catalog-post V5_S3.0.3B06 -l http://10.0.7.11:2379

Enter fullscreen mode Exit fullscreen mode

Online Upgrade

The service stays online. Nodes are upgraded one by one.

  1. Check cluster state:
   gha_ctl monitor all -l https://10.185.102.1:2379 -H -I -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

  1. Upload and extract the new package:
   tar -zxf GBase8cV5_S3.0.3B06_centos7.6_aarch64.tar.gz
   tar -zxf GBase8cV5_S3.0.3B06_CentOS_aarch64_om.tar.gz

Enter fullscreen mode Exit fullscreen mode

  1. Prepare the new version across nodes:
   gha_ctl prepare V5_S3.0.3B06 /data/mpp/gbase/gbase_pkg_b86 /data/mpp/gbase/gbase_db -l http://10.185.102.1:2379,... -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

  1. Upgrade HA:
   gha_ctl upgrade V5_S3.0.3B06 -t ha -l http://10.185.102.1:2379,... -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

  1. Upgrade each node in sequence (example for node1):

a. Switchover primary DN/GTM to standby:

   gha_ctl switchover datanode dn1 dn1_3 dn1_4 -l ... -c gbase8c-cluster01
   gha_ctl switchover gtm gtm3 gtm5 -l ... -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

b. Stop the standby instances and coordinator:

   gha_ctl stop datanode dn1 dn1_3 -l ... -c gbase8c-cluster01
   gha_ctl stop datanode dn2 dn2_4 -l ... -c gbase8c-cluster01
   gha_ctl stop gtm gtm3 -l ... -c gbase8c-cluster01
   gha_ctl stop coordinator cn3 -l ... -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

c. Upgrade the database kernel:

   ./gha_ctl upgrade V5_S3.0.3B06 10.185.103.1 -t app -l ... -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

d. Bring the instances back up:

   gha_ctl start datanode dn1 dn1_3 -l ... -c gbase8c-cluster01
   gha_ctl start datanode dn2 dn2_4 -l ... -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

Repeat the same pattern for node2, node3, and node4. After all nodes are upgraded, restore the original primary assignments:

   gha_ctl switchover datanode dn2 dn2_4 dn2_3 -l ... -c gbase8c-cluster01
   gha_ctl switchover datanode dn4 dn4_4 dn4_3 -l ... -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

  1. Validate cluster health and version:
   gha_ctl monitor all -l https://10.185.102.1:2379 -H -I -c gbase8c-cluster01

Enter fullscreen mode Exit fullscreen mode

Data Protection

No data is exported or imported during the upgrade. Take a full backup before starting:

  1. Enable WAL archiving:
   gha_ctl set gtm gtm1 -p archive_command="'scp %p 10.0.1.47:/home/gbase/backup/gtm_wal/%f'" -l http://10.0.1.44:2379/
   gha_ctl set gtm gtm1 -p archive_mode=on -l http://10.0.1.44:2379/

Enter fullscreen mode Exit fullscreen mode

  1. Run a full backup:
   gha_ctl backup all -p /home/gbase/backup -l http://10.0.7.64:2379

Enter fullscreen mode Exit fullscreen mode

The grey‑release methodology and built‑in rollback tools make GBase 8c upgrades a safe, predictable operation in any gbase database environment.