Target version: 0.9
Some tools want to use Rook to run containers, but not manage the logical Ceph resources like Pools. We should make Rook's pool management optional.
Currently in Rook 0.8, creating and destroying a Filesystem (or ObjectStore) in a Ceph cluster also creates and destroys the associated Ceph filesystem and pools.
The current design works well when the Ceph configuration is within the scope of what Rook can configure itself, and the user does not modify the Ceph configuration of pools out of band.
The current model is problematic in some cases:
In FilesystemSpec (and ObjectStoreSpec), when the metadata and data pool fields are left empty, Rook will not do any management of logical Ceph resources (Ceph pools and Ceph filesystems) for the filesystem.
The pools may be initially non-nil, and later modified to be nil. In this case, while Rook may have created the logical resources for the filesystem, it will not remove them when the Rook filesystem is removed.
If either of the metadata/data fields are non-nil, then they both must be non-nil: Rook will not partially manage the pools for a given filesystem or object store.
apiVersion: ceph.rook.io/v1
kind: Filesystem
metadata:
name: myfs
namespace: rook-ceph
spec:
metadataPool:
replicated:
size: 3
dataPools:
- erasureCoded:
dataChunks: 2
codingChunks: 1
metadataServer:
activeCount: 1
activeStandby: true
In this example, the pools are omitted. Rook will not create
any pools or a Ceph filesystem. A filesystem named myfs
should already
exist in Ceph, otherwise Rook will not start any MDS pods.
apiVersion: ceph.rook.io/v1
kind: Filesystem
metadata:
name: myfs
namespace: rook-ceph
spec:
metadataServer:
activeCount: 1
activeStandby: true
Rook Operator: add logic to skip logical resource management when pools are omitted in FilesystemSpec or ObjectStoreSpec
Migration: none required. Existing filesystems and objectstores always have pools set explicitly, so will continue to have these managed by Rook.