kubernetes via operators rook: automating ceph for...automates deployment, bootstrapping,...
TRANSCRIPT
![Page 1: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/1.jpg)
Rook: Automating Ceph for Kubernetes via Operators
Travis NielsenRook MaintainerMay 7, 2019
![Page 2: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/2.jpg)
Platform Revolution: Kubernetes
● Kubernetes is the new platform for applications● Based on containers● https://kubernetes.io/
![Page 3: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/3.jpg)
Platform Revolution: OpenShift
● Red Hat® OpenShift® is a comprehensive enterprise-grade application platform, built for containers with Kubernetes.
● OpenShift is Red Hat’s distro of Kubernetes● https://www.openshift.com/
![Page 4: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/4.jpg)
Storage for Kubernetes
● Storage is traditionally external● Volume plugins allow storage solutions to provide storage to
your apps
![Page 5: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/5.jpg)
Traditional Storage Limitations
● Not portable: requires these services to be accessible● Deployment burden of external solutions● Vendor lock-in due to using provider managed services
![Page 6: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/6.jpg)
Storage ON Kubernetes
● Kubernetes can manage our storage solution
● Highly portable applications (including storage dependencies)
● Dedicated K8s storage cluster also possible
![Page 7: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/7.jpg)
● https://rook.io ● Storage Provider for Kubernetes● Uses Kubernetes patterns (custom types and controllers)● Automates deployment, bootstrapping, configuration,
provisioning, scaling, upgrading, migration, disaster recovery, monitoring, and resource management
● Open Source (Apache 2.0)● Hosted by the Cloud-Native Computing Foundation (CNCF)● Framework for several storage providers
○ Ceph: https://www.ceph.com
What is Rook?
![Page 8: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/8.jpg)
● Upstream○ v1.0 was just released!○ Operator Hub integration in progress
https://www.operatorhub.io/ ● Downstream
○ Integration in progress: RHHI Next and OCS 4
Rook Project
![Page 9: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/9.jpg)
Rook Architecture
![Page 10: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/10.jpg)
Ceph on Kubernetes with Rook
![Page 11: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/11.jpg)
Operator Pattern
● OpenShift strategy: Operators are the future of automation● Codifies domain expertise to deploy and manage an
application○ Automates actions a human would normally do
● Apply user’s desired state○ Observe - discover current actual state of cluster○ Analyze - determine differences from desired state○ Act - perform operations to drive actual towards desired
![Page 12: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/12.jpg)
● Custom Resource Definition (CRDs) are arbitrary types that extend the Kubernetes API○ look just like any other built-in object (e.g. Pod)○ Enabled native oc/kubectl experience
● A means for user to describe their desired state● Standard yaml files
Custom Resource Definitions (CRDs)
apiVersion: ceph.rook.io/v1kind: CephClustermetadata: name: my-clusterspec: dashboard: enabled: true network: hostNetwork: true...
![Page 13: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/13.jpg)
Rook Ceph Operator
● The Operator leverages the full power of K8S○ Services, ReplicaSets, DaemonSets, Secrets, …
● Contains all the logic to manage storage systems at scale○ Handle stateful upgrades○ Handle rebalancing the cluster○ Handle health and monitoring tasks
● Not on the data path – can be offline for minutes
![Page 14: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/14.jpg)
DEMO: Rook Walkthrough
● Start a Rook Ceph cluster on OpenShift
Node 1(Apps)
MySQL
Node 2(Apps)
Node 3(Apps)
Node 4(Storage)
MonOSD
Node 5(Storage)
MonOSD
Node 6(Storage)
MonOSD
MasterOpenShift
![Page 15: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/15.jpg)
CephCluster CRD
● Ceph CRDs are v1● Host path
○ Required for persistence of the data
● Dashboard○ Web UI to view and
manage the Ceph cluster● Network
apiVersion: ceph.rook.io/v1kind: CephClustermetadata: name: my-clusterspec: dataDirHostPath: /var/lib/rook cephVersion: image: ceph/ceph:v13.2.2-20181023 dashboard: enabled: true network: hostNetwork: true ...
![Page 16: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/16.jpg)
● https://rook.io/● Try out the Rook v1.0 release!● Contribute to Rook: https://github.com/rook/rook● Slack - https://rook-io.slack.com/● Twitter - @rook_io● Forums - https://groups.google.com/forum/#!forum/rook-dev● Community Meetings
How to get involved?
![Page 17: Kubernetes via Operators Rook: Automating Ceph for...Automates deployment, bootstrapping, configuration, provisioning, scaling, upgrading, migration, disaster recovery, monitoring,](https://reader033.vdocument.in/reader033/viewer/2022050523/5fa6e4e010063c08750a01c8/html5/thumbnails/17.jpg)