Disable Preview features in Azure

Aditya Mediratta 1 Reputation point
2021-09-28T07:17:00.8+00:00

135759-azure.jpg

How to permanently disable Preview features in Azure. In-case any Preview feature has been marked registered - how to identify who registered it and when ?

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
9,014 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. SRIJIT-BOSE-MSFT 4,346 Reputation points Microsoft Employee
    2021-09-28T13:13:28.64+00:00

    @Aditya Mediratta , thank you for your question.

    There is currently no out-of-the-box feature available to:

    permanently disable Preview features in Azure

    To unregister Preview features you can follow the instructions shared here.

    You can, however, create an Azure Policy definition with Policy Rule as follows:

    {  
      "mode": "All",  
      "policyRule": {  
        "if": {  
          "field": "type",  
          "equals": "Microsoft.Features/providers/features"  
        },  
        "then": {  
          "effect": "deny"  
        }  
      },  
      "parameters": {}  
    }  
    

    This will prevent operations on any preview feature under Azure Feature Exposure Control (AFEC), available through the Microsoft.Features namespace. For more information please check the following:

    Or

    Alternatively, deny particular users or management groups the Azure RBAC permission Microsoft.Features/providers/features/register/action

    In-case any Preview feature has been marked registered - how to identify who registered it and when ?

    You can check this easily from the Azure Subscription's Activity Logs as shown below:

    1. Navigate to the Azure Subscription on the Azure Portal:
      135952-image.png
    2. Go to Activity Log from the left-hand menu. Add a filter Operation : Register Provider Feature (Microsoft.Features/providers/features/register/action). You can optionally set the appropriate Timespan filter to narrow down the logs to a specific time span. In the Event initiated by column of the output you shall find the entity that registered the feature and in the Time stamp column you will find the timestamp of the operation.
      135868-image.png
    3. You can further click on an entry upon which you shall find the JSON view of the operation, to check the resourceId field which shall give you the name of the feature and caller and claims fields for more information on the entity who initiated the operation .
      135869-image.png

    ----
    Hope this helps.

    Please "Accept as Answer" if it helped, so that it can help others in the community looking for help on similar topics.

    2 people found this answer helpful.
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.