Quote:
Originally Posted by Tom@Duna
We a software which is licensed according to active users, so if we have 30 licenses then 30 people can use the software at the same time. I am trying to determine if a user is doing anything, or if he has just logged in and left the machine that way, so I can kill these kind of processes.
How can you determine if the user is doing anything or not?
|
You can't, unless that particular piece of software spawns off other processes that you can check for. If someone logs in and fires up that package, it'll just show up as a process, whether they're doing something with it or not.
One way you could determine something, is to look at how much CPU time that process is eating from one interval to the next. If it hasn't changed, you can kill it, but that's not a sure-fire way to go. What if someone is sitting there, thinking about something for a bit? Goes to the restroom and gets sidetracked? Would kinda suck to come back and have lost your work.