Skip to main content
  1. Blog/

How to Configure NFS Repository for Kasten K10

·667 words·4 mins·
Author
Marco Escobar
Data protection, Kubernetes, cybersecurity and AI. Hands-on guides from the trenches: Veeam, Kasten, VMware, Oracle, cloud, and whatever I’m breaking in the homelab this week.
Table of Contents
How to Configure NFS Repository for Kasten K10 - screenshot 1

NFS is one of the most common targets companies use to store their backups. In this guide, we will walk through configuring an NFS Location Profile for Kasten K10, following the best practices outlined in the Kasten documentation.

Documentation
#

Before anything else, we should always review the documentation for the technologies we are going to use to reach our goal. In this case we will use Kasten K10 and the NFS Subdir External Provisioner. You can find the official information here:

Requirements
#

To use NFS as a profile in Kasten K10, as the documentation indicates, we need to meet the following requirements:

  • An NFS service reachable from every node where K10 is installed
  • A shared folder exported over NFS that can be mounted on every node where K10 is installed
  • A PV that defines the NFS shared folder
  • A PVC with its corresponding StorageClassName for K10

Once these requirements are met, our NFS profile will be correctly configured to store our backups.

NFS Folder Configuration
#

As with any NFS server, you need to create a folder (or use an existing one) to store the backups, always with its corresponding access configuration, whether by authentication or by allowing access per HOST in NFS. For example, on my QNAP I have configured the following:

How to Configure NFS Repository for Kasten K10 - screenshot 2

Once this is configured, we will move on to installing and configuring the NFS Subdir External Provisioner.

Installing the NFS Subdir External Provisioner
#

Again, following the solution’s documentation, the first thing we need to do is set up the Helm repository, so we run the following command:

helm repo add nfs-subdir-external-provisioner https://kubernetes-sigs.github.io/nfs-subdir-external-provisioner/

```bash



How to Configure NFS Repository for Kasten K10 - screenshot 3
Then we install it with Helm, passing the details of the NFS server we want to use:
How to Configure NFS Repository for Kasten K10
Validate the installation with: ```bash kubectl get pods ```bash
How to Configure NFS Repository for Kasten K10 - screenshot 4
## Storage Class Configuration To meet the Kasten K10 requirements, we need a StorageClass. In fact, when installing and configuring with Helm, the StorageClass is created automatically: ```bash kubectl get sc ```yaml
How to Configure NFS Repository for Kasten K10 - screenshot 5
## Creating a Persistent Disk using NFS Now that we have everything in place, let's test creating a PVC with our new StorageClass. To do that, we run the following (adjust the size and name if necessary): ```yaml kind: PersistentVolumeClaim apiVersion: v1 metadata: name: prueba-disco-nfs spec: storageClassName: nfs-client accessModes: - ReadWriteMany resources: requests: storage: 100Gi ```bash
How to Configure NFS Repository for Kasten K10 - screenshot 6
Validate the configuration in Kubernetes and also in our NFS shared folder:
How to Configure NFS Repository for Kasten K10 - screenshot 7
How to Configure NFS Repository for Kasten K10 - screenshot 8
We will now delete this disk to prepare the one needed for Kasten K10: ```bash kubectl delete pvc prueba-disco-nfs ```bash
How to Configure NFS Repository for Kasten K10 - screenshot 9
Now we will create the disk that Kasten K10 needs in its own namespace, using the following file: ```bash kind: PersistentVolumeClaim apiVersion: v1 metadata: name: repo-nfs-respaldos namespace: kasten-io spec: storageClassName: nfs-client accessModes: - ReadWriteMany resources: requests: storage: 100Gi ```bash
How to Configure NFS Repository for Kasten K10 - screenshot 10
If we list the PVCs without specifying a namespace, we will see that none exist: ```bash kubectl get pvc ```bash
How to Configure NFS Repository for Kasten K10 - screenshot 11
Now, if we list the PVCs in the kasten-io namespace, we will see our new disk: ```bash kubectl get pvc -n kasten-io
How to Configure NFS Repository for Kasten K10 - screenshot 12

Configuring the NFS Location Profile in Kasten K10
#

Now we will open the Kasten K10 console on the cluster where we configured our NFS and enter the name of the PVC:

How to Configure NFS Repository for Kasten K10 - screenshot 13

We validate the configuration:

How to Configure NFS Repository for Kasten K10 - screenshot 14

Now we will test a backup to this new NFS profile used to store the backups.

Testing a Backup Run to NFS
#

For this, we just need to create a backup policy that uses our new profile:

How to Configure NFS Repository for Kasten K10 - screenshot 15

Then we run it and wait for it to complete:

How to Configure NFS Repository for Kasten K10 - screenshot 16

We validate the backup on our NFS:

How to Configure NFS Repository for Kasten K10 - screenshot 17

And finally, a restore test in another namespace, in this case nfspacman:

How to Configure NFS Repository for Kasten K10 - screenshot 18

In the Kasten K10 dashboard we will see:

How to Configure NFS Repository for Kasten K10 - screenshot 19

And in Kubernetes:

How to Configure NFS Repository for Kasten K10 - screenshot 20

And finally, the Pacman application working as expected:

How to Configure NFS Repository for Kasten K10 - screenshot 21
How to Configure NFS Repository for Kasten K10 - screenshot 22

Related posts#

Related