Friday, August 30, 2013

How to pimp your Surface in 50sec

It is off-topic, but you really have to see that:

http://t.co/Bz0CENQmzz

We LIKE it!

Read Full Post...

Tuesday, August 20, 2013

PowerShell module not working

Recently I wrote a PowerShell script to do some magic stuff triggered by a SCOM notification.

Because it is a SCOM 2012 I loaded the module by

Import-Module OperationsManager

and while running interactively it worked as expected. However, the script failed as soon as it has been fired from the notification channel. Since I have some logging within all my scripts writing some debugging information and the $error variable to the event log it was easy

“The specified module ‘OperationsManager’ was not loaded because no valid module file was found in any module directory.”

That occurs even if the path is registered in the $env:PSModulePath.

After checking the $env:PSModulePath I found that the setup routine did not registered the correct path to the SCOM module:

C:\Users\me\Documents\WindowsPowerShell\Modules;C:\Windows\system32\WindowsPowerShell\v1.0\Modules\;C:\Program Fi
les\Microsoft System Center 2012 R2\Operations Manager\Powershell\
;C:\Program Files\Microsoft System Center 2012 R2\Ope
rations Manager\Powershell\

However, using the absolute path to the PSM file helps:

Import-Module “C:\Program Files\System Center 2012\Operations Manager\Powershell\OperationsManager\OperationsManager.psm1”

To get the right path you can do the following:

$setupKey = Get-Item -Path "HKLM:\Software\Microsoft\Microsoft Operations Manager\3.0\Setup"

$installDirectory = $setupKey.GetValue("InstallDirectory") | Split-Path

$psmPath = $installdirectory + ‘\Powershell\OperationsManager\OperationsManager.psm1’

Import-Module $psmPath

All information is provided "as is" without any warranty! Try in lab before. Handle with care in production.

Read Full Post...

Tuesday, August 13, 2013

No agents pending after SCOM 2012 SP1 (UR3) update?

You’ve got a MG with (hopefully) more than one MS and after updating the Management Servers the agents don’t appear under Pending Management so that you can approve the upgrade?

Maybe you’ve updated the first MS and it had no agents? In that case it is pretty easy: SCOM will only check the pending flag once per MG. No second chance. No way!

However, there is an easy workaround for that: simply apply the patch again. The easiest way (when you didn’t download but applied them with WSUS/SCCM/Windows Update) is to download it from here. Don’t forget to run the MSP from an elevated prompt.

Good luck!

All information is provided "as is" without any warranty! Try in lab before. Handle with care in production.

Read Full Post...

Thursday, February 14, 2013

Network Devices discovered multiple times

In SCOM 2012 you have great network device monitoring functionalities.

I already wrote a post regarding network device discovery:

SCOM 2012 Network Discovery with primary IP

One thing I’d like to mention: in case you have some stack devices without a software loopback address configured, you’ll get the same device discovered multiple time and you’ll get duplicate IP alerts as well.

After some troubleshooting with Microsoft (thx to Mihai) there is a fix for that. Unfortunately it is not public yet but if you drop me a line I’ll give you the case ID you can refer to (to get the private fix from MS).

All information is provided "as is" without any warranty! Try in lab before. Handle with care in production.

Read Full Post...