Please enable Javascript for better experience...
 
vSphere 7 with K8s - Configure Persistent Storage in vSphere with Kubernetes
By Pranay Jha | Apr 23, 2020 | In Articles | Update: Apr 24, 2020 | Total Views [ 233 ]
Taged In
(0 Like)
Rate

Source of Inputs: VMware

Source of Images: VMware Tech Pubs Youtube Channel

--------------------

While checking Vmware social channel, I came through one of the video on vSphere 7 with Kubernetes and thought to share brief output through this blog. As we know that "vSphere 7 with Kubernetes" setup required huge compute resources even for inhouse nested lab as it's required VCF environment, unfortunetely I couldn't manage to get sufficient hardware to setup inhouse lab due to lockdown. Therefore I have captured the screenshot of the images from VMware videos itself and I won't forget to give credit. Thanks to VMware.

Well, In this blog, we will see the workflow to for creating and managing persistent storage in vSphere 7. Certain applications that run on Kubernetest required persistent volumes to retain their states and data and continue to exist even if pod is deleted or reconfigred. vSphere integrates with kubernetes and provide its storage resources so that kubernetes persistent volumes backed with virtual disk on datastores. There are several tasks that is being performed to achieve this task. These tasks are devided into vSphere Admin and DevOps Engineer. Step 1, 2, and 5 are the responsibility of vSphere Admin whereas Step 3 and 4 is responsibility of DevOps Engineer.

Steps

vSphere Administrator

  • Step 1 - Create Storage Policies
  • Step 2 - Assign Storage Policies to a Namespace
  • Step 5 - Monitor the persistent volumes and their backing virtual disks.

DevOps Engineer

  • Step 3 - Verify that the storage classes are available in the Kubernetes environment
    • $ Kubectl get storageclass
  • Step 4 - Use the storage classes in persistent volume claims or deployments

Follow below steps to perform these tasks.

Step 1 - By vSphere Admin

vSphere Administrator Creates Storage Policies using vSphere console.

Storage policy "Gold" has been created. You can verify it from here.

Step 2 - By vSphere Admin

vSphere Admin assign storage policy to namespace.

To assign storage policy to namespace, go to vSphere console Home Page and click on Workload Management.

Under Namespaces and select namespace.

Under Storage panel, click on Edit Storage.

Select Storage Policy that you would like to add to namespace.

You can also set Resource Limits from "Capacity and Usage" panel.

After the vSphere Admin assign the storage policy to the namespace, the matching storage class appears in the kubernetes environment. Now DevOps Engineer will verify the Storage Class which is available.

Step 3 - By DevOps Engineer

Run below command to check the Storage Class.

$kubectl get storageclass

Step 4- By DevOps Engineer

Now DevOps engineer can se the storage classess in persistent volme claims or deployments. After deployment of persistent volume claim that references the storage class, vSphere with Kubernetes creates a persistent volume object and a matching persistent volume disk.

Step 5 - By vSphere Admin

vSphere Admin now monitors the persistent volumes and their backing virtual disks. To do that, go vSphere console Home page and Click on Workload Management, Click on Namespaces that has persistent volume.

Click the Storage tab, Go to Persistent Volume Claims. Click on the name of persistent volume claims.

Now it will show container volume page.

Scroll to down and Click on Container Volumes under Cloud Native Storage. Now you can check the volumes has status and storage policy compliance.

Click on Volume name and switch to Basics tab. You can see the Storage policy is assigned to Gold and it is Compliant.


Thanks for visiting here. Share this article if you found it useful.
Like Facebook Page https://www.facebook.com/VMwareInsight/
Connect to twitter https://twitter.com/imPranayK
Subscribe my Channel https://www.youtube.com/vmwareinsight
Connect over Linkedin https://in.linkedin.com/in/impranayk
Share this on Social Media

About the Author

Pranay Jha
Pranay Jha
Founder, Contributer VMwareInsight.com
Follow me

facebook linkedin twitter G+ VMTN youtube

Thank you for visiting my profile. I am Pranay Jha, bring along a total of 11+ years of extensive experience with me in Information Technology sector for organizations from small business to large enterprises, wherein my current assignment I am associated with IBM as a Technical Solution Architect for Virtualization platform. I am vExpert x 3 (16/17/18), VCIX-DCV, VCAP5/6-DCD, VCAP5-DCA, VCP7-CMA, VCP5/6-DCV, VCA-DCV, VCA-Cloud, VSP, VCE-CIA, MCITP, MCSE, MCSA(Messaging). I am also an Independent blogger and founder of http://vmwareinsight.com and https://cloudpathshala.com. I can be reached via email at pranay1988jha@gmail.com or Direct Message via Contact Us form.

 
Please SignUp/Login to comment...

Or comment as anonymous...
* Name
* Email ID
Comment
 
Sponsors
 
 
 
 
 
Facebook Likes