Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-74573

Machine creation fails on ASH when using AzureManaged boot diagnostics without proper validation

    • None
    • False
    • Hide

      None

      Show
      None
    • None
    • Moderate
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Description of problem:

      Before the fix https://github.com/openshift/machine-api-provider-azure/pull/182 
      When creating a Machine/MachineSet on Azure Stack Hub with diagnostics.boot.storageAccountType: AzureManaged, the Machine creation succeed, but in fact, it doesn't take affect.
      
      After the fix https://github.com/openshift/machine-api-provider-azure/pull/182  When creating a Machine/MachineSet on Azure Stack Hub with diagnostics.boot.storageAccountType: AzureManaged, the Machine creation fails with a 400 error from Azure API, but there is no validation at the Machine API level to prevent this invalid configuration.

      Version-Release number of selected component (if applicable):

      4.22

      How reproducible:

      Always 

      Steps to Reproduce:

          1. On an Azure Stack Hub cluster, create a MachineSet with the following configuration:
      
                diagnostics:
                  boot:
                    storageAccountType: AzureManaged
      
          2. Check machine status
          3.
          

      Actual results:

      Machine create failed with error:
              RESPONSE 400: 400 Bad Request
              ERROR CODE: InvalidParameter
              --------------------------------------------------------------------------------
              {
                "error": {
                  "code": "InvalidParameter",
                  "message": "Required parameter 'bootDiagnostics.storageAccountUri' is missing (null).",
                  "target": "bootDiagnostics.storageAccountUri"
                }
              }

      Expected results:

      Azure Stack Hub does not support Azure-managed boot diagnostics storage.
      So Machine/MachineSet creation should fail with validation error like "Error: Invalid Machine configuration: AzureManaged boot diagnostics is not supported on Azure Stack Hub"

      Additional info:

          

              gpei@redhat.com Gaoyun Pei
              rhn-support-zhsun Zhaohua Sun
              None
              None
              Huali Liu Huali Liu
              None
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated: