Forum Discussion

Gunter Danzeisen's avatar
Gunter Danzeisen
Brass Contributor
Sep 12, 2019
Solved

Force a refresh on the Security Policy

Hello there,


Is it possible to force a refresh on the Security Policy or a single recommendation once changes have been made to correct the security alert?

 

  • No force refresh capability, the scan interval is about 30 min for policy based recommendations.

9 Replies

  • Exedexes's avatar
    Exedexes
    Copper Contributor

    Gunter Danzeisen I had the same issue and found a powershell command that forces an Azure Policy Compliance Scan.

    There are two options
    Whole Subscription:
    $job = Start-AzPolicyComplianceScan -AsJob
    $job | Wait-Job

     

    Single Resource Group:

    $ResourceGroup = '%yourresourcegroup%'
    $job = Start-AzPolicyComplianceScan -ResourceGroupName $ResourceGroup -AsJob
    $job | Wait-Job

    Hope this helps!

  • Miri_Landau's avatar
    Miri_Landau
    Brass Contributor
    No force refresh capability, the scan interval is about 30 min for policy based recommendations.
    • mkoeller's avatar
      mkoeller
      Copper Contributor

      Miri_Landau 

       

      This is definitely not true. I don't know how long it actually takes and when Defender for Cloud is willing to update its information, but it's definitely closer to 24+ hours than to anything else. It would be a great enhancement if Microsoft enabled a Refresh button on this....

      • Greg_Skoff's avatar
        Greg_Skoff
        Copper Contributor
        Yes, I've fixed one of the recommendations almost 18 hours ago and the recommendation is still showing in Azure Advisor. I'll keep watching to see when it goes away. 🙂
    • ingl0rius's avatar
      ingl0rius
      Copper Contributor

      Miri_Landau 

       

      Are you sure about this? It appears to be taking much, much longer on our dashboard; more like 12+ hours.

Resources