Deploying OpenEBS on DigitalOcean can directly be done from the console. DigitalOcean provides the feature to create a cluster with OpenEBS deployed on it already. To get started, follow the below-mentioned steps:
Login to your DigitalOcean account.
Creation of cluster
Once you log in, you arrive at the dashboard, click on Marketplace under DISCOVER located on the left sidebar.
Next, scroll down to find OpenEBS, clicking on it you will be redirected to a page where you will find details about OpenEBS and Create OpenEBS button in the right side.
Next, you need to provide the necessary details such as Data Center region, cluster capacity, cluster name etc. (It is advisable to provision 3 nodes with 4vCPUs and 8 GB memory to ensure that the resources are sufficient at all times. )
Connecting your cluster
Creation, resizing and deletion can be carried out from UI but to perform administrative tasks you require command-line tools from your local machine or a remote management server. The detailed steps to install the management tools and connect the cluster to your local machine can be found under the Overview section.
To verify execute the following command,
$ kubectl get ns
NAME STATUS AGE
default Active 13m
openebs Active 13m
The output must contain openebs ns in Active state.
$ kubectl get pods -n openebs
NAME READY STATUS RESTARTS AGE
openebs-admission-server-5c4d545647-r4vgr 1/1 Running 0 13m
openebs-apiserver-56f77c9965-xft68 1/1 Running 2 13m
openebs-localpv-provisioner-64c67b5b89-czv8b 1/1 Running 0 13m
openebs-ndm-5f6nt 1/1 Running 0 13m
openebs-ndm-74njq 1/1 Running 0 13m
openebs-ndm-operator-7bc769dcff-b45bc 1/1 Running 1 13m
openebs-ndm-spttv 1/1 Running 0 13m
openebs-provisioner-755f465f9d-fr67l 1/1 Running 0 13m
openebs-snapshot-operator-7988fc8646-zpd98 2/2 Running 0 13m
All the pods must be in running state.
To attach BlockDevices to the created nodes click on Volumes on the left sidebar and then click on Add Volume button.
Next, select the volume size ( provision at least 30 GB), select the node(droplet) to which it gets attached and provide a name, then click on Create Volume button. Repeat these steps for each node (droplet).
For cStor, choose Manually Mount and Format under Choose Configuration Options.
For Jiva, choose Automatically Format and Mount under Choose Configuration Options.
After the BlockDevices get attached for all the nodes you can see an output similar to the below image.
Provisioning OpenEBS volumes
Next, you have to provision OpenEBS volumes (cStor or Jiva or LocalPV). Going through the following links can help you decide as to which will be best suited for your scenario.
Click here to know about cStor.
Click here to know about Jiva.
Click here to know about LocalPV.
Provisioning an application.
Now, things are all set to deploy an application and get started.
You can refer to the below sample articles for provisioning an application.
1. Sample application for cStor.
2. Sample application for Jiva.
3. Sample application for Local PV.
Backing up Application
It is extremely important to have a data backup and restore mechanism so that the service continues flawlessly in every situation.
Monitoring of stateful applications and OpenEBS volumes
Once the entire thing is set up, volumes are provisioned, the application is deployed it is necessary to monitor these components continuously. Director provides easy and efficient monitoring. To know about how to monitor, different monitoring views click here.
OpenEBS volumes can be deployed on various other Kubernetes Platforms as well, to know about it Click Here.