Skip to main content
🎤 Luca Berton is speaking at Red Hat Summit & KubeCon EU 2026!Learn more →
Back to Blog

Rook Ceph Kubernetes Storage Guide

Rook deploys Ceph distributed storage on Kubernetes for block, file, and object storage. Learn how to set up Rook-Ceph for persistent volumes, shared.

Luca BertonFebruary 4, 20261 min read

Kubernetes needs persistent storage. Cloud providers offer EBS and PersistentDisks. On-premises and bare metal clusters need something else. Rook deploys Ceph — a production-grade distributed storage system — as a Kubernetes operator.

What Rook-Ceph Provides

Storage TypeUse CaseKubernetes Object
Block (RBD)Databases, single-pod volumesPersistentVolumeClaim
Filesystem (CephFS)Shared storage, ReadWriteManyPersistentVolumeClaim
Object (RGW)S3-compatible storageObjectBucketClaim

Installation

bash
# Deploy the Rook operator
helm install rook-ceph rook-release/rook-ceph \
  --namespace rook-ceph --create-namespace

# Create a Ceph cluster
kubectl apply -f - <<EOF
apiVersion: ceph.rook.io/v1
kind: CephCluster
metadata:
  name: rook-ceph
  namespace: rook-ceph
spec:
  cephVersion:
    image: quay.io/ceph/ceph:v18.2
  dataDirHostPath: /var/lib/rook
  mon:
    count: 3
  storage:
    useAllNodes: true
    useAllDevices: true
EOF

Rook discovers available disks on each node and creates a Ceph cluster automatically.

Related Course

Master this topic with hands-on labs

Go beyond reading — build real projects in sandboxed environments with expert video guidance.

Browse Courses →

Block Storage (RBD)

For databases and single-pod workloads:

yaml
apiVersion: ceph.rook.io/v1
kind: CephBlockPool
metadata:
  name: replicapool
  namespace: rook-ceph
spec:
  replicated:
    size: 3  # 3 copies across nodes
---
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: rook-ceph-block
provisioner: rook-ceph.rbd.csi.ceph.com
parameters:
  clusterID: rook-ceph
  pool: replicapool
  csi.storage.k8s.io/fstype: ext4
reclaimPolicy: Delete
allowVolumeExpansion: true
yaml
# Use in a deployment
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: postgres-data
spec:
  storageClassName: rook-ceph-block
  accessModes: [ReadWriteOnce]
  resources:
    requests:
      storage: 50Gi

Shared Filesystem (CephFS)

For shared storage across multiple pods:

yaml
apiVersion: ceph.rook.io/v1
kind: CephFilesystem
metadata:
  name: shared-fs
  namespace: rook-ceph
spec:
  metadataPool:
    replicated:
      size: 3
  dataPools:
    - replicated:
        size: 3
  metadataServer:
    activeCount: 1
    activeStandby: true
---
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: rook-cephfs
provisioner: rook-ceph.cephfs.csi.ceph.com
parameters:
  clusterID: rook-ceph
  fsName: shared-fs
yaml
# ReadWriteMany PVC — shared across pods
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: shared-uploads
spec:
  storageClassName: rook-cephfs
  accessModes: [ReadWriteMany]
  resources:
    requests:
      storage: 100Gi

Multiple pods can read and write to the same volume simultaneously.

Stay Updated

Get weekly IT automation tips

Docker, Ansible, Terraform, MLOps — curated insights delivered to your inbox. No spam.

Subscribe Free →

Object Storage (S3)

yaml
apiVersion: ceph.rook.io/v1
kind: CephObjectStore
metadata:
  name: s3-store
  namespace: rook-ceph
spec:
  metadataPool:
    replicated:
      size: 3
  dataPool:
    replicated:
      size: 3
  gateway:
    port: 80
    instances: 2
yaml
# Request a bucket
apiVersion: objectbucket.io/v1alpha1
kind: ObjectBucketClaim
metadata:
  name: app-bucket
spec:
  generateBucketName: app-data
  storageClassName: rook-ceph-bucket

Access via S3 API using credentials from the generated secret.

Monitoring

bash
# Check cluster health
kubectl -n rook-ceph exec deploy/rook-ceph-tools -- ceph status

# Output:
  cluster:
    health: HEALTH_OK
  services:
    mon: 3 daemons
    osd: 6 osds: 6 up, 6 in
  data:
    pools:   3 pools, 96 pgs
    objects: 1.2k objects, 4.5 GiB
    usage:   15 GiB used, 585 GiB avail

When to Use Rook-Ceph

Good fit: - On-premises Kubernetes clusters needing persistent storage - Bare metal clusters without cloud storage - Workloads needing ReadWriteMany (shared) volumes - Teams wanting S3-compatible storage alongside block storage

Not needed: - Cloud clusters (use EBS, PersistentDisks) - Small clusters (<3 nodes — Ceph needs 3+ for replication) - Workloads that only need ephemeral storage

Rook-Ceph is production-grade but operationally complex. Plan for monitoring, capacity management, and occasional maintenance.

---

Ready to go deeper? Master Kubernetes storage with hands-on courses at CopyPasteLearn.

Ready to learn by doing?

Stop reading tutorials — start building. Expert video courses with hands-on labs in real sandboxed environments.

Share this article
LB
Luca Berton

Docker Captain, IT automation expert, Red Hat Summit & KubeCon speaker. Building hands-on education for DevOps engineers at CopyPasteLearn.

Related Articles

Explore topics

Browse more articles on the topics covered here.