Windows Office Outlook software tips tricks Outlook Office Windows software tips tricks
 
 
  Home | Windows Tips | Office Tips | News | Books | Search | Contact | Feedback |


NEW! Search the group policy database
            Includes Windows Server 2003
            Windows XP, Windows XP SP 2,
             and Windows 2000


Featured Article — Windows Server

Create a script to e-mail service failure notification

Sooner or later, whether you are troubleshooting a server or just managing one, knowing when a particular service goes down can be a real lifesaver. Early notification can help you recognize when a problem has occurred and let you get to work on the problem as soon as possible to minimize disruption to users and/or customers.

The properties for a service provide for a handful of recovery options. To view these properties, open the Services console, double-click a service, and then click the Recovery tab.

Three drop-down lists on the Recovery tab enable you to specify what action Windows should take, if any, when the service fails the first, second, and subsequent times. If you want to receive an e-mail notification when the service goes down, create the following script using Notepad:

set objArgs = Wscript.Arguments

Set objEmail = CreateObject("CDO.Message")

objEmail.From = "adminaddress@yourdomain.tld"

objEmail.To = "youraddress@yourdomain.tld"

objEmail.Subject = objArgs(0) & " service is down"

objEmail.Textbody = "The service " & objArgs(0) & " has failed."

objEmail.Send

set objArgs = nothing

set objEmail = nothing

Save the script as Mail.vbs, then open the properties for the service from the Services console. In one of the three drop-down lists, choose the option Run a File. Click Browse to browse for and select the Mail.vbs script you just created. In the Command Line Parameters field, type the service name (without spaces) that you want passed to the script. Then, click OK.

Other Featured Articles

Introduction to Microsoft Electricity Organize Your Calendar with the Outlook 2003 Calendar Views Add-In
Protect confidential e-mail messages with Rights Management Use Comments in PowerPoint
What to do with all that spam  
Overview of Business Contact Manager  
Make a Common Change to Multiple Contacts  
Understanding Microsoft Client Access Licenses  
Integrating FTP with Your Web Site  

Get a Free ASP-Based Hit Counter

 


// -->

Google
 
Web www.boyce.us

 

Home | Windows Tips | Office Tips | News | Books | Search | Contact | Feedback | Newsletter