1. You are viewing our forum as a guest. For full access please Register. WindowsBBS.com is completely free, paid for by advertisers and donations.

How to create a batch file for checking IIS service running or not

Discussion in 'Windows Server System' started by luckyhce, 2010/01/06.

  1. 2010/01/06
    luckyhce

    luckyhce Inactive Thread Starter

    Joined:
    2008/02/23
    Messages:
    9
    Likes Received:
    0
    I want a batch script to

    (a) to check if a windows service has stopped, if not then report fail status to a log file reporting as service failed to stop.

    (b) to check if a windows service has started, if not then report fail status to a log file reporting as service failed to start.

    (c) to check if a windows service is running,if not then report fail status to a log file reporting as service is not running.


    actually it is to check the IIS service in the web servers.plz help me.
     
  2. 2010/01/20
    bilbus

    bilbus Inactive

    Joined:
    2006/09/02
    Messages:
    97
    Likes Received:
    4
    If you just want to log the results thats easy. If you want to be emailed results .. you can use blat.

    You can do all of this checking with the SC command and a batch file.
     

  3. to hide this advert.

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.