Before you activate vSphere with Tanzu, create storage policies for the Supervisor and namespaces. The policies represent available datastores in the vSphere environment. They control the storage placement of such objects as control plane VMs, pod ephemeral disks, container images, and persistent storage volumes. When you use VMware Tanzu™ Kubernetes Grid™ Service, the storage policies also dictate how the Tanzu Kubernetes Cluster nodes are deployed.

Assign a New Tag to the vSAN Datastore for Developer Ready Infrastructure for VMware Cloud Foundation

To assign the vSAN datastore to a storage policy based on a vSphere tag, you first create a category, create a tag to that category, and apply that tag to the vSAN datastore.

UI Procedure

  1. Log in to the VI workload domain vCenter Server at https://<vi_workload_vcenter_server_fqdn>/ui as [email protected].
  2. From the vSphere Client menu, select Tags & Custom Attributes.

  3. Create a new category to later add to your tag.

    1. On the Tags and Custom Attributes page, under the Tags tab, select Categories, and click New.

    2. In the Create category dialog box, enter a category name according to your value in the VMware Cloud Foundation Planning and Preparation Workbook, configure the following settings , and click Create.

      Setting

      Value

      Tags Per Object

      One tag

      Associable Object Types

      Datastore

  4. Create a new tag for your new category.

    1. On the Tags & Custom Attributes page, select Tags, and click New.

    2. In the Create tag dialog box, enter a tag name according to your value in the VMware Cloud Foundation Planning and Preparation Workbook, select the category that you created in the previous step, and click Create.

  5. Add the tag to the vSAN datastore.

    1. From the vSphere Client menu, select Inventory.

    2. In the storage inventory, expand your vCenter Server and your data center.

    3. Right-click the vSAN Datastore and click Tags & Custom Attributes > Assign Tag.

    4. In the Assign Tag dialog box, select the check box for the newly created tag, and click Assign.

PowerShell Procedure

  1. Start PowerShell.

  2. Replace the values in the sample code with values from your VMware Cloud Foundation Planning and Preparation Workbook and run the commands in the PowerShell console.

    $sddcManagerFqdn = "sfo-vcf01.sfo.rainpole.io"
    $sddcManagerUser = "[email protected]"
    $sddcManagerPass = "VMw@re1!"
    
    $sddcDomainName = "sfo-w01"
    
    $tagCategoryName = "vsphere-with-tanzu-category"
    $tagName = "vsphere-with-tanzu-tag"
  3. Perform the configuration by running the command in the PowerShell console.

    Set-DatastoreTag -Server $sddcManagerFqdn -User $sddcManagerUser -Pass $sddcManagerPass -Domain $sddcDomainName -TagName $tagName -TagCategoryName $tagCategoryName

Create a Storage Policy that Uses the New vSphere Tag for Developer Ready Infrastructure for VMware Cloud Foundation

After you have created the vSphere tag and applied it to the vSAN datastore, you can create a storage policy using that tag.

UI Procedure

  1. Log in to the VI workload domain vCenter Server at https://<vi_workload_vcenter_server_fqdn>/ui as [email protected].
  2. From the vSphere Client menu, select Policies and Profiles.

  3. In the navigation pane, select VM Storage Policies.

  4. On the VM Storage Policies page, click Create.

  5. On the Name and description page, configure the name and vCenter Server settings according to your values in the VMware Cloud Foundation Planning and Preparation Workbook and click Next.

  6. On the Policy structure page, select the Enable tag based placement rules check box and click Next.

  7. On the Tag based placement page, set the Usage option to Use storage tagged with, configure the Tag category and Tags settings according to your values in the VMware Cloud Foundation Planning and Preparation Workbook, and click Next.

  8. On the Storage compatibility page, click Next.

  9. On the Review and Finish page, click Finish.

PowerShell Procedure

  1. Start PowerShell.

  2. Replace the values in the sample code with values from your VMware Cloud Foundation Planning and Preparation Workbook and run the commands in the PowerShell console.

    $sddcManagerFqdn = "sfo-vcf01.sfo.rainpole.io"
    $sddcManagerUser = "[email protected]"
    $sddcManagerPass = "VMw@re1!"
    
    $sddcDomainName = "sfo-w01"
    
    $spbmPolicyName = "vsphere-with-tanzu-storage-policy"
    $tagName = "vsphere-with-tanzu-tag"
  3. Perform the configuration by running the command in the PowerShell console.

    Add-StoragePolicy -Server $sddcManagerFqdn -User $sddcManagerUser -Pass $sddcManagerPass -Domain $sddcDomainName -PolicyName $spbmPolicyName -TagName $tagName

Create a Subscribed Content Library for Developer Ready Infrastructure for VMware Cloud Foundation 4.5.2 or Earlier

For VMware Cloud Foundation 4.5.2 or earlier, before you can deploy a Tanzu Kubernetes cluster, create a Subscribed Content Library to store virtual machine images that the VMware Tanzu™ Kubernetes Grid™ Service uses to create Tanzu Kubernetes Cluster nodes.

If you are using VMware Cloud Foundation 5.0 or later, you do not perform this procedure.

UI Procedure

  1. Log in to the VI workload domain vCenter Server at https://<vi_workload_vcenter_server_fqdn>/ui as [email protected].
  2. From the vSphere Client menu, select Content Libraries.

  3. In the Content Libraries inventory, click Create.

  4. On the Name and location page, configure the settings according to your values in the VMware Cloud Foundation Planning and Preparation Workbook and click Next.

  5. On the Configure content library page, select Subscribed content library, configure the settings and click Next.

    Setting

    Value

    Subscription URL

    https://wp-content.vmware.com/v2/latest/lib.json

    Enable Authentication

    Deselected

    Download Content

    Immediately

  6. In the Kubernetes - Unable to verify authenticity dialog box, click Yes to accept the SSL certificate thumbprint.

  7. On the Apply security policy page, click Next.

  8. On the Add Storage page, select your vSAN datastore, click Next

  9. On the Ready to Complete page, review the settings and click Finish.

PowerShell Procedure

  1. Start PowerShell.

  2. Replace the values in the sample code with values from your VMware Cloud Foundation Planning and Preparation Workbook and run the commands in the PowerShell console.

    $sddcManagerFqdn = "sfo-vcf01.sfo.rainpole.io"
    $sddcManagerUser = "[email protected]"
    $sddcManagerPass = "VMw@re1!"
    
    $sddcDomainName = "sfo-w01"
    
    $contentLibraryName = "Kubernetes"
  3. Perform the configuration by running the command in the PowerShell console.

    Add-ContentLibrary -Server $sddcManagerFqdn -User $sddcManagerUser -Pass $sddcManagerPass -Domain $sddcDomainName -ContentLibraryName $contentLibraryName -SubscriptionUrl "https://wp-content.vmware.com/v2/latest/lib.json"