Rook Storage for Kubernetes

From WilliamsNet Wiki
Revision as of 00:34, 5 July 2020 by DrEdWilliams (talk | contribs) (Created page with "== Background == == Installation Process == === Rook Operator === # set up all the namespace, roles, bindings, and support definition (ewilliam@aslan)/workspace/outside-rep...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Background

Installation Process

Rook Operator

  1. set up all the namespace, roles, bindings, and support definition

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>kubectl create -f common.yaml

  1. create the rook operator

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>kubectl create -f operator.yaml


Using Existing Ceph Cluster

  1. create the separate namespace where the ceph cluster definition will live

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>kubectl create -f common-external.yaml

  1. create secrets based on information extracted from ceph cluster

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>bash ./import-external-cluster.sh

  1. note that the above script adds too many secrets -- the operator tries to create them and errors out since they can't be changed.
  2. We need to either edit the script to not create the excess secrets or delete the ones that aren't needed
  3. see which secrets are in the namespace for the external cluster

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>kubectl get secret -n rook-ceph-external

  1. these are the ones that need to be deleted (at least for now)

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>kubectl -n rook-ceph-external delete secret \

   rook-csi-cephfs-node rook-csi-cephfs-provisioner rook-csi-rbd-node rook-csi-rbd-provisioner
  1. create the cluster definition

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>kubectl create -f cluster-external-management.yaml

  1. create the ceph pool and storage class definition for RBD images

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes/ceph>kubectl create -f storageclass-block.yaml

Creating an internal Ceph Cluster

Testing

  1. deploy the test application
  2. each deployment requests its own Persistent Volume
  3. the wordpress service is a LoadBalancer, so it will allocate an IP address that should give direct access to the wordpress instance

(ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes>kubectl create -f mysql.yaml (ewilliam@aslan)/workspace/outside-repos/rook/cluster/examples/kubernetes>kubectl create -f wordpress.yaml