Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 971903
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T03:02:18+00:00 2026-05-16T03:02:18+00:00

I’d like to request some help in creating a Batch file to run on

  • 0

I’d like to request some help in creating a Batch file to run on a windows server which will monitor processes which sometimes get “stuck” and linger after they should be killed.

Specifcally, I can see the “age” of a process in the Elapsed Time column of the PsList command
http://technet.microsoft.com/en-us/sysinternals/bb896682.aspx

Name                Pid Pri Thd  Hnd   Priv        CPU Time    Elapsed Time
FMSCore            4908   8 146  892 750720     0:01:46.221     4:02:15.907
FMSCore            4780   8 144  943 853060     0:00:42.510     4:02:15.348
FMSCore            3532   8 146  878 553784     0:01:30.262     2:04:56.969
FMSCore            5384   8 147  753  45484     0:00:03.198     0:05:11.267
FMSCore            9548   8 133  608  17408     0:00:00.592     0:00:34.298

The next step, is I only want to kill processes which are older than 4 hours. So I believe we will need to parse the results of my PsList command, extract the last column, parse for hours, and if we find that it’s “old enough” we parse out it’s PID and kill it.

If we were talking about bash or some other scripting language I think I could figure it out, but for a batch script, I don’t know.

recommendations?

(note: I’d be willing to run an autoit script or something else, if needed)

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T03:02:18+00:00Added an answer on May 16, 2026 at 3:02 am

    So I actually figured this one out myself – had to use AutoIt and an extra filter to look at the command line arguments for each process, and then looking at each process’s elapsed time, and then killing the old ones.

    Here’s the full post:

    http://zeroasterisk.com/2010/07/23/adobe-connect-fmscore-process-killer/

    We’ve setup Connect to expire the FMSCore processes after 2 hours, but if someone is still connected to a recording, it will keep the old zombie FMSCore process until that person disconnects.

    It often happens that doesn’t work – and there’s seemingly no garbage collection in place to clean up old FMSCore.

    So we created a simple AutoIt script which can be compiled to an EXE which works, but it has some dependancies…

    The following dependencies / commands must all be in place:

    • c:\Windows\system32\pv.exe
    • c:\Windows\system32\pslist.exe
    • c:\Windows\system32\pskill.exe

    How it works

    • the script uses pv.exe to find all FMS Core processes which have a command line argument that includes “flvplayerapp” (which is only for recorded courses)
    • for each of the returned process ids
    • it uses pslist to list details which include the age of the process
    • it uses a regex match find the “hours it’s been running”
    • if longer than 5 hours (a configurable parameter) it uses pskill to kill the process.

    So we set this up on an hourly scheduled task and it handles garbage collection for us.

    http://zeroasterisk.com/blog/wp-content/uploads/2010/07/fmscore-killer-source.au3_.txt

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to run a str_replace or preg_replace which looks for certain words
For some reason, after submitting a string like this Jack’s Spindle from a text
I have just tried to save a simple *.rtf file with some websites and
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I am trying to render a haml file in a javascript response like so:
I would like my Web page http://www.gmarks.org/math_in_e-mail.txt on my Apache 2.2.14 server to display
I have some data like this: 1 2 3 4 5 9 2 6
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
I would like to count the length of a string with PHP. The string
I used javascript for loading a picture on my website depending on which small

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.