Author: Luke

Parse log files with PowerShell

Parse log files with PowerShell

If you have to find information in unstructured log files, PowerShell offers a variety of cmdlets that can help you parse text files to extract the information you need. In my last article, I showed you how to search the Windows Event Log with Get-Event. That's where you usually spot most of the pertinent messages. … Continue reading Parse log files with PowerShell

How to convert MAML to Text

How to convert MAML to Text

MAML is an XML-based markup language developed by the Microsoft User Assistance Platform team to provide user assistance. Among others, it is used in SCOM to format Knowledge articles. Here is how to convert a MAML string to standard readable text. Note: When you copy/paste code from a web site, quotes and backticks are often … Continue reading How to convert MAML to Text

How to write a one-liner progress bar

How to write a one-liner progress bar

Powershell has an easy to use and built-in cmdlet named Write-Progres. However, displaying the PercentComplete parameter seems sometimes cumbersome. Fortunately, most of the time, you need a progress bar when you are inside a foreach loop. This makes it easy to handle because the object you enumerate has a Count and an IndexOf properties. Basic … Continue reading How to write a one-liner progress bar

SCOM: Agent installation failed because Access is denied (80070005)

Sometimes, when you try to remotely install a SCOM agent you get an access denied message. Usual cause Most of the time you can address this issue by either granting administrator's rights to the Management Server Action Account or to provide alternate credential with administrator's rights. A tricky case It also happens that having the … Continue reading SCOM: Agent installation failed because Access is denied (80070005)