Search code examples
azureazure-devopsterraformazure-cliazure-cognitive-search

Unable to create Azure search service through terraform and AZ CLI with Standard3 High density SKU but getting the error


I am trying to create an azure search service through terraform but it is not supported through standard3 High Density SKU. Subsequently, I am trying to create it with AZ CLI but getting the error as"ERROR: Unrecognized arguments: --hosting-mode highDensity". How to resolve this error and create a search service with S3HD SKU?

I Passed the AZ CLI command to create an Azure Search Service with S3HD Sku but it failed saying hosting mode is an unsupported argument, Also terraform does not support High Density SKU.


Solution

  • I Tried to reproduce the same in my environment to create an Azure Search Service with S3HD SKU Azure CLI:

    Follow the below steps to create Azure Search Service using CLI.

    If you select Azure Search Service SKU S3HD, it will show as Standard3 High density as below.

    enter image description here

    Azure CLI Commands

    #Sing into Azure Subscription
    
    az login
    
    #Create Azure Search service with SKU S3HD
    
    az search service create --name  venkatsearch --resource-group myResourceGroup --sku Standard3 --hosting-mode highDensity
    

    Result:

    enter image description here

    az search service list --resource-group myResourceGroup
    

    Result:

    enter image description here

    Once ran the above commands Azure Search Service with S3HD SKU are created successfully as below.

    enter image description here

    Refer the Ms Doc more about Azure Search Service using CLI.