Using OMS and Runbooks to update VMs when they’re down

The aim of this post is to enable a powershell Azure Automation runbook to be fired when a VM is deallocated (Stopped from the Azure management fabric), that will perform given tasks. This is useful if you have non-urgent infrastructural changes that need to be done, but you want it done with the least amount…


Make practical use of NSG Flow Logs for troubleshooting

So, you’ve found the new Azure Network Watcher features. Cool, now I can start getting some real information about what’s going on in my Azure Network. The NSG flow logs section of the Network Watcher blade, in the Azure Portal, lets you specify a Storage Account for each NSG (Network Security Group) to output detailed…


Get Azure PaaS Endpoint IPs

I’ve had a few situations where people are trying to find out the public IP Addresses for their own resources in Azure to use for Network Security Groups or User Defined Routes. Unfortunately there is nothing generic out there that can return this information for every Resource Type, so specific code needs to be developed…


Log results from Azure Automation Runbooks directly to OMS

An easy way to keep track of Azure Automation runbook operations is to create log entries to OMS during execution. There is a Rest API service as part of OMS that let’s you post log entries directly into your OMS Workspace, allowing for easy searching and alerting of anything you’re runbooks do.  There are…


Transition Azure Automation schedules from one Runbook to another

So you’ve spent a great deal of time setting up all the schedules for an Azure Automation Runbook but now you have a new version that you want to test against all the parameters for the schedules of the existing released version. You’ve already created and published the new Runbook but what a pain if…


Export Available Azure VM Sizes for all locations

I wanted to share a quick post with a script I seem to use all the time to get a spreadsheet with all the available VM sizes available for use in each region Grab it from here –> Download script


Using Azure Automation and SharePoint Online lists to schedule VM start-up and shutdown

To make the most efficient use of Public cloud you need to ensure your servers are only running when they need to be. Using SharePoint online as the source of virtual machine start-up and shutdown schedules is an option that allows for an easy, consolidated view of all your VMs and their schedules plus allows…


Extract Azure ARM resource counts and quota information

This script can be used to export all providers and resource type counts to a csv file along with the ARM VM quota information for each active Azure location. Please update the file path variable to the required location depending on your system set-up. An out-gridview will be displayed to allow the selection of particular…


Setting it up: SharePoint Online Lists with Azure Automation

To integrate SharePoint Online with Azure Automation (and Powershell scripts), I’ve used a fantastic module written by Tao Yang, SharepointSDK. The details can be found here. This post will deal with setting things up ready to use. Install the module for Powershell by using the command  Install-Module SharepointSDK. Next, navigate to the Azure Portal and we’ll add the module to…


Assign Multiple Azure AD users to multiple roles in multiple subscriptions using Powershell

This is an interactive Azure Powershell script that allows you to add multiple users to multiple roles across multiple subscriptions. Uses the Powershell GridView to allow you to multi-select users, roles and subscriptions. Search Azure AD using display name search strings or email addresses to create a list of users to grant rights to. Select…