Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2011

    Unanswered: Tocfind the user count for a running application

    Hi All,
    I am working on project in which I need to do some shell scripting .But I got stuck with a problem.
    My Project has some online and batch server on which many Jvm are running.
    and in one jvm one application is running which is being used by certain users
    so I want to know about how we can calculate the total user count for the application running in all jvm using unix scripting .

    Please respond to my mail on
    Thanks and Regards

  2. #2
    Join Date
    Sep 2009
    Provided Answers: 1
    Start with fuser.
    fuser filename
    will list all the process id's that have filename open.
    Then use "ps" to examine each of the processes to qualify them.
    add the following lines at the beginning and end of the application script
    echo START $LOGNAME `tty` $$ `date` >>application_usage.log
    echo THEND $LOGNAME `tty` $$ `date` >>application_usage.log
    Then analyze the log file.
    Last edited by kitaman; 09-13-11 at 10:40. Reason: typo

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts