creating a scheduled task to restart an existing service  in SERVICES.MSC

Posted on 2012-08-27
Last Modified: 2012-09-02

  I have a service called "workflow" in services.msc (on Windows 2008 Std) that becomes ineffective from time to time, so I end up restarting it once a week on average when the user calls me.
 Can I create a DOS command script, store in .BAT file and have it run once a day so that I don't have to open SERVICES.MSC and re-start every time the user calls me with the problem.

Path to Executable:
C:\Program Files\Software Systems, Inc\DirectoryName\Workflow.exe
Logon as "Local System Account"

Question by:sglee
    1 Comment
    LVL 13

    Accepted Solution

    net stop workflow
    net start workflow

    Open in new window


    taskkill /F /IM workflow.exe
    C:\Program Files\Software Systems, Inc\DirectoryName\Workflow.exe

    Open in new window

    Top one will use the services.msc snap in to stop/start cleanly

    Bottom one will forcefully kill the process and start it again.

    Featured Post

    Promote certifications in your email signature

    Has your company recently won an award or achieved a certification? They'll no doubt want to show it off. Email signature images used to promote certifications & awards can instantly establish credibility with a recipient and provide you with numerous benefits.

    Join & Write a Comment

    Scenario:  You do full backups to a internal hard drive in either product (SBS or Server 2008).  All goes well for a very long time.  One day, backups begin to fail with a message that the disk is full.  Your disk contains many, many more backups th…
    You may have already been in the need to update a whole folder stucture using a script. Robocopy does it well and even provides a list of non-updated files in a log (if asked to). Generally those files that were locked by a user or a process by the …
    This tutorial will walk an individual through configuring a drive on a Windows Server 2008 to perform shadow copies in order to quickly recover deleted files and folders. Click on Start and then select Computer to view the available drives on the se…
    This tutorial will walk an individual through the steps necessary to install and configure the Windows Server Backup Utility. Directly connect an external storage device such as a USB drive, or CD\DVD burner: If the device is a USB drive, ensure i…

    755 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now