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

推荐订阅源

WordPress大学
WordPress大学
Jina AI
Jina AI
小众软件
小众软件
GbyAI
GbyAI
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 【当耐特】
D
DataBreaches.Net
腾讯CDC
V
Visual Studio Blog
博客园 - 叶小钗
B
Blog
Apple Machine Learning Research
Apple Machine Learning Research
T
The Blog of Author Tim Ferriss
S
SegmentFault 最新的问题
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
V
V2EX
博客园 - 三生石上(FineUI控件)
云风的 BLOG
云风的 BLOG
The Cloudflare Blog
MongoDB | Blog
MongoDB | Blog
有赞技术团队
有赞技术团队
U
Unit 42
博客园 - 司徒正美
博客园 - 聂微东

OneUptime Blog

How to Monitor Azure App Services (PaaS) with OpenTelemetry Grafana Stack vs OneUptime: DIY Observability or Unified Platform? Your AI Workloads Are About to Blow Up Your Observability Bill The Great Observability Consolidation Is Here How to Write Custom Object Classes for Ceph How to Write Custom Ceph Manager Modules How to Write a ceph.conf Configuration File How to Use Rook-Ceph with OpenShift How to Use Rook-Ceph with Longhorn for Comparison How to Configure Volume Snapshot Class for RBD in Rook How to Configure VolumeReplicationClass Scheduling Intervals in Rook How to Set Up Volume Replication with Rook-Ceph How to Create Volume Group Snapshots with Rook CSI How to Visualize Ceph Network Performance in Grafana How to Enable Virtual Host-Style Bucket Access in Rook How to View Runtime Configuration via Admin Socket How to View Quota Settings and Update Stats in Ceph RGW How to View PG Scaling Recommendations with autoscale-status How to View PG Distribution via Admin Socket How to View Performance Metrics in the Ceph Dashboard How to View OSD Performance Counters in Ceph How to View Connection Status via Admin Socket How to View Ceph Cluster Summary Dashboard via CLI How to Version Control Rook-Ceph Configuration How to Version Control Ceph Infrastructure with Terraform How to Verify Kubernetes Node Requirements for Rook-Ceph Deployment How to Verify Health Before and After Rook Upgrades How to Verify Data Integrity with Deep Scrubbing How to Verify Complete Rook-Ceph Cleanup How to Verify Backup Integrity from Ceph Snapshots
How to Understand OSD Recovery Process in Ceph
Nawaz Dhandala · 2026-03-31 · via OneUptime Blog

What Is OSD Recovery?

When an OSD fails or is removed, Ceph begins recovery to restore the cluster to its target replication or erasure-coded state. Recovery involves copying missing object replicas from surviving OSDs to either the returning OSD or a new one.

Recovery is distinct from backfill:

  • Recovery - restores objects to their correct OSDs after a peer rejoins
  • Backfill - moves objects to a new OSD that was not previously a member of the PG

Recovery Lifecycle

The process follows these stages:

  1. OSD goes down - PGs become degraded
  2. Ceph waits osd_recovery_delay_start seconds (default 0)
  3. Recovery threads select PGs and begin copying objects
  4. PGs transition: degraded -> recovering -> active+clean

Check current recovery state:

ceph -s

Example output during recovery:

health: HEALTH_WARN
        Degraded data: 23/150 objects degraded (15.333%)
        recovery: 12345 kB/s, 4 keys/s, 1 objects/s

Key Recovery Metrics

Monitor recovery in detail:

ceph osd pool stats
ceph pg dump | grep -E "recovering|degraded"

Watch live recovery progress:

watch -n 2 ceph -s

Get per-OSD recovery statistics:

ceph osd perf

Recovery Parameters

Important recovery configuration keys:

ParameterDefaultDescription
osd_recovery_max_active3Max concurrent recovery ops per OSD
osd_recovery_op_priority3Priority relative to client I/O
osd_recovery_sleep0Delay between recovery ops (seconds)
osd_backfill_scan_min64Min objects per backfill scan

View current settings:

ceph config get osd osd_recovery_max_active

Rook-Ceph Recovery Configuration

In Rook, configure recovery parameters via the CephCluster spec or config overrides:

apiVersion: ceph.rook.io/v1
kind: CephCluster
metadata:
  name: rook-ceph
  namespace: rook-ceph
spec:
  cephConfig:
    osd:
      osd_recovery_max_active: "3"
      osd_recovery_op_priority: "3"
      osd_recovery_sleep: "0"

Apply at runtime using the toolbox:

kubectl -n rook-ceph exec -it deploy/rook-ceph-tools -- \
  ceph config set osd osd_recovery_max_active 3

Recovery and Data Availability

During recovery:

  • Data remains readable and writable on healthy PGs
  • Degraded PGs continue to serve normal reads and writes as long as min_size is still met
  • If the number of available replicas for a PG drops below min_size, reads and writes to that PG are blocked

Monitor minimum size compliance:

ceph osd pool get <pool-name> min_size
ceph osd pool get <pool-name> size

Summary

Ceph OSD recovery is an automated process that restores data redundancy after OSD failures. Understanding the recovery lifecycle, key parameters, and health indicators helps operators ensure recovery completes efficiently without starving client I/O. Rook exposes these settings through the CephCluster CRD for Kubernetes-native management.