Skip to content

Commit 5b568b0

Browse files
committed
Update Blog “how-to-backup-and-restore-stateful-applications-on-kubernetes-using-kasten-k10-in-hpe-greenlake-for-private-cloud-enterprise”
1 parent 8a2cd75 commit 5b568b0

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

content/blog/how-to-backup-and-restore-stateful-applications-on-kubernetes-using-kasten-k10-in-hpe-greenlake-for-private-cloud-enterprise.md

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ Before starting, make sure you meet the following requirements:
9696

9797
### Install Kasten K10
9898

99-
Kasten K10 can be deployed on K8s like any other application, and it runs in its own namespace.
99+
Kasten K10 can be deployed on K8s like any other application and it runs in its own namespace.
100100

101101
Following the [Kasten K10 installation page](https://docs.kasten.io/latest/index.html), Kasten K10 can be installed to the cluster with the following commands using helm:
102102

@@ -179,7 +179,7 @@ Click *Accept Terms* after specifying your email and company name, you will b
179179

180180
![](/img/k10-dashboard.png)
181181

182-
Kasten K10 automatically discovers all the applications and their data across namespaces in the cluster. The K10 dashboard displays a list of applications that are mapped to namespaces. It also displays a summary of the cluster’s backup data footprint, showing *0.0 B* when accessing the dashboard for the first time.
182+
Kasten K10 automatically discovers all the applications and their data across namespaces in the cluster. The K10 Dashboard displays a list of applications that are mapped to namespaces. It also displays a summary of the cluster’s backup data footprint, showing *0.0 B* when accessing the dashboard for the first time.
183183

184184
To use Kasten K10 with HPE CSI driver for K8s, you need to ensure the configured *VolumeSnapshotClass* in the cluster contains the K10 annotation ***k10.kasten.io/is-snapshot-class: "true"***. Typing the following command to add this required K10 annotation to the *VolumeSnapshotClass*:
185185

@@ -203,7 +203,7 @@ $ kubectl get volumesnapshotclass gl-sbp-frank-gl1-sstor01 -o yaml -o jsonpath='
203203

204204
### Deploy MySQL database
205205

206-
In order to show backup and restore process, an MySQL database instance from [my GitHub repo](https://github.com/GuopingJia/mysql-app) will be deployed as a sample stateful application to the cluster.
206+
In order to show backup and restore process, a MySQL database instance from [my GitHub repo](https://github.com/GuopingJia/mysql-app) will be deployed as a sample stateful application to the cluster.
207207

208208
**1. Install MySQL database**
209209

@@ -226,7 +226,7 @@ spec:
226226
storage: 1Gi
227227
```
228228

229-
This PVC file, together with other YAML manifest files in the folder *base*, will be used to install the MySQL database instance using [Kustomize](https://kustomize.io/).
229+
This PVC file, together with other YAML manifest files in the folder *'base'*, will be used to install the MySQL database instance using [Kustomize](https://kustomize.io/).
230230

231231
```shell
232232
$ tree mysql-app/base
@@ -462,7 +462,7 @@ You can also check the **Data Usage** page to see the data used by database b
462462

463463
![](/img/k10-data-backup.png)
464464

465-
In the cluster, after snapshot of the MySQL database, you can check there is a *VolumeSnapshot* *k10-csi-snap-ltxzrwxgp6r5pwkp* created from the PVC *mysql-pvc* in the namespace *mysql*, together with a *VolumeSnapshotContent* object created at cluster level. The *READYTOUSE* of the *VolumeSnapshot* should be showing as *true*:
465+
In the cluster, after snapshot of the MySQL database, you can check there is a *VolumeSnapshot* *'k10-csi-snap-ltxzrwxgp6r5pwkp'* created from the source PVC *'mysql-pvc'* in the namespace *mysql*, together with a *VolumeSnapshotContent* object created at cluster level. The *READYTOUSE* of the *VolumeSnapshot* should be showing as *true*:
466466

467467
```shell
468468
$ kubectl get volumesnapshot -n mysql
@@ -480,9 +480,9 @@ This volume snapshot can be used for MySQL database restore.
480480

481481
Before showing the database restore, I will first delete some table from MySQL database to simulate a loss of data. Then, I will perform the database recovery using the Kasten K10.
482482

483-
#### Delete table
483+
##### Delete table
484484

485-
Delete data from the table *departments* by typing the following commands:
485+
Delete data from the table '*departments'* by typing the following commands:
486486

487487
```shell
488488
$ mysql -h 127.0.0.1 -uroot -pCfeDemo@123 -P 42281 -Demployees
@@ -568,7 +568,7 @@ $ mysql -h 127.0.0.1 -uroot -pCfeDemo@123 -P 42281 -t <test_employees_sha.sql
568568
+---------+--------+
569569
```
570570

571-
#### Perform MySQL database restore
571+
##### Perform MySQL database restore
572572

573573
In order to restore the MySQL database, go to the Kasten K10 Dashboard, locate the MySQL database *'mysql'* from the application list, expand the menu of *mysql*, then click *Restore* button:
574574

@@ -653,7 +653,6 @@ This indicates the MySQL database gets recovered from its backup and MySQL da
653653

654654
### Summary
655655

656-
In this blog post, I
657-
introduced and discussed Kasten K10 and HPE CSI driver for K8s. Using the volume snapshot capability in HPE CSI driver for K8s, I demonstrated how to use Kasten K10 dashboard to backup the persistent volume of a sample MySQL database deployed in the cluster, and how to restore databasae using the created backup. Kasten K10 provides a powerful and intuitive interface that enables you to easily backup and restore the stateful applications running in the cluster. It can significantly simplify the process and enhance the robustness of data management in a K8s cluster.
656+
In this blog post, I introduced and discussed Kasten K10 and HPE CSI driver for K8s. Using the volume snapshot capability in HPE CSI driver for K8s, I demonstrated how to use Kasten K10 to backup the persistent volume of a sample MySQL database deployed in the cluster, and how to restore databasae using the created backup. Kasten K10 provides a powerful and intuitive interface that enables you to easily backup and restore the stateful applications running in the cluster. It can significantly simplify the process and enhance the robustness of data management in a K8s cluster.
658657

659658
You can keep coming back to the [HPE Developer blog](https://developer.hpe.com/blog/) to learn more about HPE GreenLake for Private Cloud Enterprise.

0 commit comments

Comments
 (0)