Azure Automation Runbook: Test-OMSAlertRemediation

Couple of weeks ago, I published a post titled OMS Alerting Walkthrough. I mentioned in the post that I have written a test runbook called Test-OMSAlertRemediation that extracts information from the OMS alert JSON input sends to you via email. Once you have created this rnbook in your Azure Automation account, you can use it as the remediation runbook for any OMS alerts. Source code:

Requirements This runbooks uses the SendEmail module for sending emails. You can install it to your automation account directly from PowerShell gallery(https://www.powershellgallery.com/packages/SendEmail/), or download the source code from GitHub(https://github.com/tyconsulting/SendEmail_PowerShellModule). Once the module is deployed

OMS Alerting Walkthrough

Introduction Earlier today, the OMS product team has announced the OMS Alerting feature has entered Public Preview. This is indeed an exciting news and it is another good example that Microsoft is working very hard to close the gaps between OMS and the existing On-Prem monitoring solution – System Center Operations Manager. Alex Frankel from the OMS product team has already given a brief introduction on this feature from the announcement blog post. In this post, I will demonstrate how I used this feature to alert and auto-remediate an issue detected in my lab environment. Background Few months ago, I

Azure Automation Runbook: New-FakeVirus

Often when you are playing with security related products, you would need to create dummy/fake viruses on your computers. The most common way to do this is to create a EICAR test file (https://en.wikipedia.org/wiki/EICAR_test_file). I have used this method in the past when testing the Microsoft Forefront Endpoint Protection management pack in OpsMgr. Today I needed to use it again when I was preparing a demo for the OMS Malware Assessment. I thought, why not make an Azure Automation runbook that automatically create the EICAR test file for me on remote computers, so I can trigger it manually or schedule

Start A Child Runbook From Azure Automation Hybrid Worker on the Same Hybrid Worker Group

Today I was writing a PowerShell runbook (let’s call it Runbook A) that’s designed to run on on-prem hybrid workers. At the end of Runbook A, I needed to kick off another runbook (let’s call it Runbook B) that must run on the same Hybrid Worker group. Because I don’t want to hardcode the Hybrid Worker group name in the script (or using an Automation variable), I wrote a very simple function that returns the Hybrid Worker configuration (including the Hybrid Worker group name) from registry if runs on a Hybrid Worker. To use it, simply place the function shown

New Activity-Level Tracing Options for Azure Automation Graphical Runbooks

Nowadays, OMS / Azure Automation is full of surprises. almost every time I visit the OMS and Azure Automation portals, I’d notice new features being made available. Today, I just noticed a new setting for graphical runbooks called Activity-level tracing: You can now configure additional verbose tracing for graphical runbooks. Please note in order to leverage this new capability, you must also turn on verbose logging for the particular graphical runbook. Verbose Logging without Activity-level tracing: Detailed Activity-level Tracing Enabled: As you can see, once turned on, you can see a lot more verbose logging activities (starts with ‘GraphTrace”) for

Our Azure Automation Session Recording at Microsoft Ignite Australia

Last week, I had an opportunity teamed up with the legendary CDM MVP Pete Zerger (@pzerger) and delivered a session on Azure Automation at Microsoft Ignite Australia in Gold Coast, Queensland. Our session was the first session right after the opening keynote, so while some other sessions are still waiting to be uploaded to Channel 9 at the moment, our session has already been published. You can watch the recording here: https://channel9.msdn.com/Events/Ignite/Australia-2015/ARC311 I have also published all the sample runbooks and other information on Github: https://github.com/tyconsulting/AUIgnite2015

Azure Automation Webhooks Now Support Hybrid Workers

My friend and fellow CDM MVP Pete Zerger just pinged me and told me he just spotted that Azure Automation webhooks now support targeting Hybrid Workers. The webhook configuration used to look like this: (Source image from David O’Brien’s blog: http://www.david-obrien.net/2015/05/azure-automation-webhooks/) Currently, the webhook configuration looks like this: Few days ago when Pete and I delivered the Azure Automation session at Microsoft Ignite Australia, in one of our demos, we used Webhook to kick off a process to create AD user accounts on On-Prem Active Directory using Hybrid Workers. Because Webhook did not support Hybrid Workers back then, we had

Automating OpsMgr Part 19: Creating Any Types of Generic Rules

Introduction This is the 19th instalment of the Automating OpsMgr series. Previously on this series: Automating OpsMgr Part 1: Introducing OpsMgrExtended PowerShell / SMA Module Automating OpsMgr Part 2: SMA Runbook for Creating ConfigMgr Log Collection Rules Automating OpsMgr Part 3: New Management Pack Runbook via SMA and Azure Automation Automating OpsMgr Part 4:Creating New Empty Groups Automating OpsMgr Part 5: Adding Computers to Computer Groups Automating OpsMgr Part 6: Adding Monitoring Objects to Instance Groups Automating OpsMgr Part 7: Updated OpsMgrExtended Module Automating OpsMgr Part 8: Adding Management Pack References Automating OpsMgr Part 9: Updating Group Discoveries Automating OpsMgr

Updating Connection Fields in SMA and Azure Automation Modules

Recently when I was working with Stanislav Zhelyazkov on the OMSSearch module, Stan discovered an issue where the module connection type does not get updated when you import an updated version of the module in Azure Automation if the fields have been modified in the module. I have also seen this issue with SMA, so it is not only specific to Azure Automation. Stan has also raised this issue in the User Voice: http://feedback.azure.com/forums/246290-azure-automation/suggestions/8791036-connection-fields-for-modules-are-not-updated As you can see from the feedback from Joe Levy and Beth Cooper, it is a known issue with SMA and Azure Automation. Joe has also

OMSSearch Module Sample Runbook: Invoke-OMSSavedSearch

Over the last few days, I’ve been playing with the OMSSearch PowerShell / SMA / Azure Automation Module my friend and fellow SCCDM MVP Stanislav Zhelyazkov has created. I am now part of this project on Github and have become the 3rd contributor (after Stan and Stefan Stranger). The module was updated yesterday (version 5.1.1) with some of my updates. Today, I have written a sample runbook: Invoke-OMSSavedSearch. As the name suggests, it performs a user defined saved search. Note: due to the limitation of the OMS Search API, we can only retrieve the user defined saved searches. Therefore you

%d bloggers like this: