监视何时创建/启动Azure资源 [英] Monitor when Azure resources are created/started
问题描述
当前,我的团队的任务是分配所有非生产的VM(我们管理的和都不在我们所有的四个订购中管理的VM).我已经开发了自动化功能来标记所有1000多个正在运行的虚拟机,已经被释放.现在,我们希望能够 监视其他团队何时在我们不知情的情况下重启虚拟机(这些其他团队无法访问门户,但使用服务主体应用程序来使事情自动化).
Currently, my team is tasked with Deallocating all nonprod VMs (both ones we manage and do not manage in all 4 of our subscriptions). I have developed automation to tag all 1000+ VMs both running & already deallocated. Now, we want to be able to monitor when other teams restart a VM without our knowledge (these other teams do not have access to the portal but utilize a service principal app to automate things).
我正在寻找一个好的解决方案来监视Azure VM的创建/重新启动/启动时间.我尝试使用Azure Monitor,当您拥有100多个资源组和4个订阅时,它不是最佳解决方案.
I am looking for a good solution to monitor when Azure VMs are created/restarted/started. I tried using Azure Monitor which isn't the best solution when you have over 100+ resource groups and 4 subscriptions.
希望创建一个也不会显示太多信息的策略.
Looked at creating a policy which doesn't show much information either.
是否可以使用自动化(脚本+ Jenkins).还是那里还有其他Azure功能?
Is it possible to use Automation (script + Jenkins). Or is there any other Azure capability out there ?
推荐答案
您可以使用Azure Diagnostics/Log Analytics来实现.请参阅下面的链接-
You can achieve this using Azure Diagnostics/Log Analytics. See links below -
https://azure.microsoft. com/en-in/blog/windows-azure-virtual-machine-monitoring-with-wad-extension/
https://docs.microsoft.com/zh-CN -us/azure/log-analytics/log-analytics-quick-collect-azurevm 或者您可以使用PowerShell阅读订阅活动日志-
OR you can read subscription activity logs using PowerShell -
https://docs.microsoft.com/zh-CN /azure/monitoring-and-diagnostics/insights-powershell-samples
Let us know if this helps
这篇关于监视何时创建/启动Azure资源的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!