Sponsored Content
Full Discussion: find a process age
Top Forums UNIX for Dummies Questions & Answers find a process age Post 97994 by Perderabo on Friday 3rd of February 2006 04:47:38 PM
Old 02-03-2006
I don't understand how the process age fits into this problem. In general, no, it is hard to get the age of a process. The tools mostly display start time. So you need to do calculations. I believe that you use SunOS, though. Bear in mind that on a Sun, you can using the find command on processes by using /proc. Each process gets a subdirectory. So as root you can do:
cd /proc
find . ! -name . -prune -mtime +3 -print | xargs ls -ld
or something like that.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to find the File Age and wait for that...

Hi, I want to know my file is 1 hr 30 min old or not, If 1 hr 30 min old I will do some tasks in that file.. other wise I will wait to 1 hr 30 min and then do the tasks.. how to do it in Unix script? any idea? (3 Replies)
Discussion started by: redlotus72
3 Replies

2. Shell Programming and Scripting

how to find the chid process id from given parent process id

how to find the chid process id from given parent process id.... (the chid process doesnot have sub processes inturn) (3 Replies)
Discussion started by: guhas
3 Replies

3. HP-UX

How to find memory used by a process

Hi, Can anyone help me out in writing the shell scrip which monitors a process which is running and gives me the output of the memory being used by the process, I have the requirement of monitorig the memory usage of the process when it is running. Please help me out (3 Replies)
Discussion started by: vijayagiri
3 Replies

4. What is on Your Mind?

What is your age?

What is your age? (15 Replies)
Discussion started by: royal
15 Replies

5. Shell Programming and Scripting

Find the age of a file in Minutes

KSH: Please lt me know how to find the age of a file in minutes(Based on last modified time). ie, if the file was modified 15 Minutes ago, the output should be 15 (1 Reply)
Discussion started by: hari_anj
1 Replies

6. Shell Programming and Scripting

Find age of files...

I am trying to figure out how to look at only the following directory... /lcl/prd/data/dc003p/dump And search it for any files that have a .arc extension and are older then 24 hours. I have never done anything like this and have no idea where to start. I want to make sure it does not... (10 Replies)
Discussion started by: LRoberts
10 Replies

7. Shell Programming and Scripting

Finding the age of a unix process, killing old processes, killing zombie processes

I had issues with processes locking up. This script checks for processes and kills them if they are older than a certain time. Its uses some functions you'll need to define or remove, like slog() which I use for logging, and is_running() which checks if this script is already running so you can... (0 Replies)
Discussion started by: sukerman
0 Replies

8. Shell Programming and Scripting

Perl Find file age

Hi I can not say that i am new to perl but today i learned something new, i wanted to know age (last time file got modified) of file so i initially thought of using find -mtime command but when i googled it, i found perl solution for the same my $age = -M $ARGV ; print "$ARGV age is... (1 Reply)
Discussion started by: zedex
1 Replies

9. Programming

Find parent process (not process ID)

Hi: I have a program written in FORTRAN running on AIX platform. It is because missing of documentation and without root password, therefore we want to modify the program so that we can find out which script/program that call this FORTRAN program. I have google for few days, all of them are... (3 Replies)
Discussion started by: cstsang
3 Replies

10. UNIX for Dummies Questions & Answers

Help with "process age " script

I want a script that will identify all processes for a particular id and kill it if its running more than 5 hours. i have tried to make it but dont know how to find to retrive the process running more than 5 hours. tried below: ps -eo pid,etime,comm,user,tty | grep sas please help... (1 Reply)
Discussion started by: milan111
1 Replies
EXIWHAT(8)                                                    System Manager's Manual                                                   EXIWHAT(8)

NAME
exiwhat - Finding out what Exim processes are doing SYNOPSIS
exiwhat DESCRIPTION
On operating systems that can restart a system call after receiving a signal (most modern OS), an Exim process responds to the SIGUSR1 sig- nal by writing a line describing what it is doing to the file exim-process.info in the Exim spool directory. The exiwhat script sends the signal to all Exim processes it can find, having first emptied the file. It then waits for one second to allow the Exim processes to react before displaying the results. In order to run exiwhat successfully you have to have sufficient privilege to send the signal to the Exim processes, so it is normally run as root. Unfortunately, the ps command which exiwhat uses to find Exim processes varies in different operating systems. Not only are different options used, but the format of the output is different. For this reason, there are some system configuration options that configure exactly how exiwhat works. If it doesn't seem to be working for you, check the following compile-time options: EXIWHAT_PS_CMD the command for running "ps" EXIWHAT_PS_ARG the argument for "ps" EXIWHAT_EGREP_ARG the argument for "egrep" to select from "ps" output EXIWHAT_KILL_ARG the argument for the "kill" command An example of typical output from exiwhat is 164 daemon: -q1h, listening on port 25 10483 running queue: waiting for 0tAycK-0002ij-00 (10492) 10492 delivering 0tAycK-0002ij-00 to mail.ref.example [10.19.42.42] (editor@ref.example) 10592 handling incoming call from [192.168.243.242] 10628 accepting a local non-SMTP message The first number in the output line is the process number. The third line has been split here, in order to fit it on the page. BUGS
This manual page needs a major re-work. If somebody knows better groff than us and has more experience in writing manual pages, any patches would be greatly appreciated. SEE ALSO
exim(8), /usr/share/doc/exim4-base/ AUTHOR
This manual page was stitched together from spec.txt by Andreas Metzler <ametzler at downhill.at.eu.org>, for the Debian GNU/Linux system (but may be used by others). March 26, 2003 EXIWHAT(8)
All times are GMT -4. The time now is 12:24 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy