Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MOM Service not starting upon reboot

Status
Not open for further replies.

monsterjta

IS-IT--Management
Sep 12, 2005
702
US
Hello,

NONE of my MOM agents start at boot time. If I start them manually, they are fine. Anyone have this issue?

Thanks in advance.
 
UPDATE

I haven't officially resolved why the MOM service does not start. However, I have created my own workaround until I come across a solution.

I created a script using WMI, as follows. This is quite nice, as I can check and manipulate other services with this script as well.

Code:
'''''''''''''''''''''''''''''''''''''''''''''''
'This script checks the MOM serices for all   '
'servers in the domain.  If the service  '
'is in a Stopped state, this will start the   '
'service.  Server must be listed in the array '
'''''''''''''''''''''''''''''''''''''''''''''''

Option Explicit
Dim objWMIService, objItem, objService, strServiceList
Dim colListOfServices, strServer, strService, arrServers

arrServers = Array("server1", "server2")

On Error Resume Next

For Each strServer In arrServers
	Set objWMIService = GetObject("winmgmts:" _
	& "{impersonationLevel=impersonate}!\\" & _
	strServer & "\root\cimv2")
	Set colListOfServices = objWMIService.ExecQuery _
	("Select * from Win32_Service ")
		For Each objService in colListOfServices
			If objService.name ="MOM" then
			strServiceList = strServiceList & _
			strServer & vbCr & objService.Name _
			& vbCr & objService.State
			If objService.State = "Stopped" _
			Then objService.StartService()
			End if
		Next
Next

I set this up on my MOM server as a scheduled task, which runs ever 5 minutes.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top