Tagged: Service

MaintMode on a single class

Didnt know that this would work…

In a project that I’m working on the customer wanted me to create a Management Pack for a couple of services, the only problem was that they wanted to restart the services during the night.
My first solution was to create a group with the computer in it and run a PowerShell script to set the computer in to maintenance mode.

Then I tested to put my own class in that group and use the same script on the class instead.

Worked like a charm 🙂

The script: systemcenterforum.org/maintenance-mode-scheduled-task-for-ops-mgr-2007/

Maintenance Mode

MOM-Script: ServiceMonitor

Ett script som kontrollerar om en service har hängt sig under uppstart/nersängning.


  • ServiceName = wuauserv (Service att övervaka)
  • RecheckSeconds = 20 (Sekunder mellan kontroller)
  • RecheckCount = 3 (Antal kontroller att göra)
  • DebugMode = False (Skapa event oavsett status? Vid felsökning)

Script: ServiceMonitor.vbs