VOOZH about

URL: https://thenewstack.io/tutorial-configure-storage-volumes-for-kubeflow-notebook-servers/

⇱ Configure Storage Volumes for Kubeflow Notebook Servers - The New Stack


TNS
SUBSCRIBE
Join our community of software engineering leaders and aspirational developers. Always stay in-the-know by getting the most important news and exclusive content delivered fresh to your inbox to learn more about at-scale software development.
REQUIRED
It seems that you've previously unsubscribed from our newsletter in the past. Click the button below to open the re-subscribe form in a new tab. When you're done, simply close that tab and continue with this form to complete your subscription.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.
Welcome and thank you for joining The New Stack community!
Please answer a few simple questions to help us deliver the news and resources you are interested in.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Great to meet you!
Tell us a bit about your job so we can cover the topics you find most relevant.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Welcome!

We’re so glad you’re here. You can expect all the best TNS content to arrive Monday through Friday to keep you on top of the news and at the top of your game.

What’s next?

Check your inbox for a confirmation email where you can adjust your preferences and even join additional groups.

Follow TNS on your favorite social media networks.

Become a TNS follower on LinkedIn.

Check out the latest featured and trending stories while you wait for your first TNS newsletter.

PREV
1 of 2
NEXT
VOXPOP
As a JavaScript developer, what non-React tools do you use most often?
Angular
0%
Astro
0%
Svelte
0%
Vue.js
0%
Other
0%
I only use React
0%
I don't use JavaScript
0%
Thanks for your opinion! Subscribe below to get the final results, published exclusively in our TNS Update newsletter:
NEW! Try Stackie AI
From clobbered drafts to real-time sync
Apr 14th 2026 10:00am, by David Moore
TypeScript 6.0 RC arrives as a bridge to a faster future
Mar 14th 2026 9:00am, by Darryl K. Taft
Mastra empowers web devs to build AI agents in TypeScript
Jan 28th 2026 11:00am, by Loraine Lawson
2021-07-09 09:42:52
Configure Storage Volumes for Kubeflow Notebook Servers
tutorial,
Kubernetes / Storage

Configure Storage Volumes for Kubeflow Notebook Servers

This tutorial focuses on provisioning the storage backend for Jupyter Notebook Servers running in Kubeflow platform.
Jul 9th, 2021 9:42am by Janakiram MSV
👁 Featued image for: Configure Storage Volumes for Kubeflow Notebook Servers
This tutorial is the latest installment in an explanatory series on Kubeflow, Google’s popular open source machine learning platform for Kubernetes. Check back each Friday for future installments.

In the last installment of this series, we have created custom Docker images for provisioning Jupyter Notebook Servers targeting the data preparation, training, and inference stages of a machine learning project.

Before we launch the fully customized environments for data scientists and ML developers, we need to make sure that the storage is configured to facilitate collaboration among teams.

This tutorial focuses on provisioning the storage backend for Jupyter Notebook Servers running in the Kubeflow Kubernetes machine learning operations (MLops) platform.

There are two prerequisites for configuring storage for Kubeflow:

    1. A storage class that supports dynamic provisioning
    2. A storage backend with support for shared volumes

While the first prerequisite is met by most of the overlay storage choices available for Kubernetes, only a few support the second.

As discussed in the earlier parts, Kubeflow has a unique requirement of shared volumes and dedicated volumes to run MLOps pipelines. Shared volumes make it possible for multiple pods to read and write simultaneously. Dedicated volumes are traditional Kubernetes persistent volume claims (PVCs) mounted in a single pod.

This tutorial will show how Portworx and NFS provisioner can be used to configure the storage volumes. For detailed instructions on deploying and configuring Kubeflow storage, refer to the DeepOps guide for NFS and Portworx. You can use one of these storage providers as the preferred overlay storage backend for Notebook Servers.

Configure NFS-Based Shared Volumes for Kubeflow

When you install the NFS client provisioner through NVIDIA DeepOps, you get a storage class by name nfs-client which supports shared volumes.

👁 Image

Let’s create two shared PVCs for sharing the dataset and models.

apiVersion: v1
kind: PersistentVolumeClaim
metadata:
 name: datasets
 namespace: kubeflow-user-example-com
spec:
 accessModes:
 - ReadWriteMany
 storageClassName: nfs-client
 resources:
 requests:
 storage: 10Gi

This PVC will be used for performing the ETL operations and data pre-processing.

The next one that we create would be used for storing the model artifacts.

apiVersion: v1
kind: PersistentVolumeClaim
metadata:
 name: models
 namespace: kubeflow-user-example-com
spec:
 accessModes:
 - ReadWriteMany
 storageClassName: nfs-client
 resources:
 requests:
 storage: 10Gi

Configure Portworx-Based PVCs for Kubeflow

Portworx supports shared volumes through the SharedV4 storage class. Let’s start by creating the storage class.

kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
 name: shared-sc
provisioner: kubernetes.io/portworx-volume
parameters:
 repl: "2"
 allow_all_ips: "true"
 sharedv4: "true"

Now, we can define the PVCs based on the above storage class.

kind: PersistentVolumeClaim
apiVersion: v1
metadata:
 name: datasets
 namespace: kubeflow-user-example-com
 annotations:
 volume.beta.kubernetes.io/storage-class: shared-sc
spec:
 accessModes:
 - ReadWriteMany
 resources:
 requests:
 storage: 10Gi

The below YAML specification creates the PVC for storing the model artifacts:

kind: PersistentVolumeClaim
apiVersion: v1
metadata:
 name: models
 namespace: kubeflow-user-example-com
 annotations:
 volume.beta.kubernetes.io/storage-class: shared-sc
spec:
 accessModes:
 - ReadWriteMany
 resources:
 requests:
 storage: 10Gi

Use the Kubeflow 1.3 Volumes UI to Configure PVCs

If the storage class is already created, we can also configure the PVCs through the new volumes UI introduced in Kubeflow 1.3.

👁 Image

Notice how the dropdown list picks up the storage classes and gives us a choice of access modes.

Apart from the shared storage volumes, we also need a dedicated volume (RWO) that will be mounted as the home directory of the Notebook Server. When the Notebook Servers are launched, the volume dashboard shows all the bound PVCs.

👁 Image

With the custom Docker container images and storage volumes in place, we are all set to launch the Notebook Servers for data preparation, training, and inference.

In the next part of this series, we will configure the first Notebook Server that performs the ETL and data pre-processing job. Stay tuned!

TRENDING STORIES
Janakiram MSV (Jani) is a practicing architect, research analyst, and advisor to Silicon Valley startups. He focuses on the convergence of modern infrastructure powered by cloud-native technology and machine intelligence driven by generative AI. Before becoming an entrepreneur, he spent...
Read more from Janakiram MSV
SHARE THIS STORY
TRENDING STORIES
Portworx is a sponsor of The New Stack.
TNS owner Insight Partners is an investor in: Docker.
SHARE THIS STORY
TRENDING STORIES
TNS DAILY NEWSLETTER Receive a free roundup of the most recent TNS articles in your inbox each day.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.