Skip to content

Commit

Permalink
docs: update
Browse files Browse the repository at this point in the history
  • Loading branch information
hhk7734 committed Feb 22, 2025
1 parent 5965f73 commit cd6e0e6
Show file tree
Hide file tree
Showing 2 changed files with 78 additions and 6 deletions.
76 changes: 74 additions & 2 deletions docs/mlops/storage/ceph/central-storage-cluster.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,87 @@ keywords:
- storage cluster
---

:::warning
## Provider Storage Cluster

:::info[Reference]

- [Rook / External Cluster / Export config from the Ceph provider cluster](https://rook.io/docs/rook/latest/CRDs/Cluster/external-cluster/provider-export/)
- [Rook GitHub / example toolbox.yaml](https://github.com/rook/rook/blob/master/deploy/examples/toolbox.yaml)
- [Rook GitHub / example create-external-cluster-resources.py](https://github.com/rook/rook/blob/master/deploy/examples/external/create-external-cluster-resources.py)

Provider Storage Cluster의 경우 일반적으로 [cephadm](https://docs.ceph.com/en/latest/cephadm/)으로 구축된다고 안내되어 있습니다.

:::

다른 클러스터가 중앙 스토리지 클러스터의 Ceph daemon에 접근할 수 있어야합니다. 이를 위한 일반적인 설정은 Ceph daemon이 host 네트워크를 사용하는 것입니다.

```yaml
apiVersion: ceph.rook.io/v1
kind: CephCluster
spec:
network:
hostNetwork: true
provider: host
# ...
```

필요한 CephFilesystem, CephBlockPool, CephObjectStore 등을 생성합니다.

```shell
toolbox=$(kubectl get pod -l app=rook-ceph-tools -n rook-ceph -o jsonpath='{.items[*].metadata.name}')
kubectl -n rook-ceph cp create-external-cluster-resources.py $toolbox:/etc/ceph
```

```shell
python3 create-external-cluster-resources.py \
--namespace rook-ceph \
--rbd-data-pool-name <poolName> \
--cephfs-filesystem-name <filesystemName> \
--rgw-endpoint <ip>:<port> \
--format bash
```

## Consumer Cluster

:::info[Reference]

- [Rook / External Cluster / Import Ceph configuration to the Rook consumer cluster](https://rook.io/docs/rook/latest/CRDs/Cluster/external-cluster/consumer-import/)
- [Rook GitHub / example import-external-cluster.sh](https://github.com/rook/rook/blob/master/deploy/examples/external/import-external-cluster.sh)

:::

```yaml
apiVersion: ceph.rook.io/v1
kind: CephCluster
metadata:
name: rook-ceph-external
namespace: rook-ceph
spec:
external:
enable: true
crashCollector:
disable: true
healthCheck:
daemonHealth:
mon:
disabled: false
interval: 45s
# optionally, the ceph-mgr IP address can be passed to gather metric from the prometheus exporter
# monitoring:
# enabled: true
# externalMgrEndpoints:
# - ip: ip
# externalMgrPrometheusPort: 9283
```

Provider Storage Cluster에서 `create-external-cluster-resources.py`를 실행해서 얻은 환경 변수를 설정합니다.

```shell
export KUBECONFIG=~/.kube/config
export KUBECONTEXT=""
```

`import-external-cluster.sh` 파일에서 StorageClass 이름과 관련된 값을 수정하고 아래 명령어를 실행합니다.

```shell
. import-external-cluster.sh
```
8 changes: 4 additions & 4 deletions docs/mlops/storage/ceph/rook-ceph.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ helm repo update rook-release \
```

```shell
helm pull rook-release/rook-ceph --version v1.15.6
helm pull rook-release/rook-ceph --version v1.15.8
```

```shell
helm show values rook-release/rook-ceph --version v1.15.6 > rook-ceph-v1.15.6.yaml
helm show values rook-release/rook-ceph --version v1.15.8 > rook-ceph-v1.15.8.yaml
```

```yaml title="rook-ceph-values.yaml"
Expand All @@ -66,14 +66,14 @@ enforceHostNetwork: false
```
```shell
helm template rook-ceph rook-ceph-v1.15.6.tgz \
helm template rook-ceph rook-ceph-v1.15.8.tgz \
-n rook-ceph \
-f rook-ceph-values.yaml \
> rook-ceph.yaml
```

```shell
helm upgrade rook-ceph rook-ceph-v1.15.6.tgz \
helm upgrade rook-ceph rook-ceph-v1.15.8.tgz \
--install \
--history-max 5 \
-n rook-ceph \
Expand Down

0 comments on commit cd6e0e6

Please sign in to comment.