Visit Our UNIX and Linux User Community


Current Process Running.


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Current Process Running.
# 1  
Old 01-17-2008
Question Current Process Running.

Hi all,
When I issued command ps -ef|grep Vinay in a UNIX machine,
I got the following

Vinay 22491 1 255 Jun 18 ? 294248:53 -sh
Vinay 26628 1 255 Jun 18 ? 294237:33 -sh

Could you tell me what all process is running ? Please explain each of the fields.

Thanks in advance
Coolbhai
coolbhai
# 2  
Old 01-17-2008
It would really help if you had stated WHAT UNIX you are using. Always post your OS and version.

Code:
User    Probably process ID(PID)  Parent PID   ?       Date   Terminal   ?   and command
Vinay           22491                   1       255  Jun 18    ?          294248:53 -sh

# 3  
Old 01-17-2008
Here are the details:
HP-UX B.11.11 U 9000/800 4126747535 unlimited-user license
and the shell is Bourne shell

What is '255','?' and '-sh' ,what is the process mentioned by -sh ?

in Vinay 22491 1 255 Jun 18 ? 294248:53 -sh

Thanks in advance
coolbhai
# 4  
Old 01-17-2008
When you grep those two lines out of the ps output, you discard the rest of the output. The first line is a header line that would label the fields. You should use:
ps -fu Vinay
which is much faster than doing ps -ef and then grepping a few lines. You should also do a "man ps" which would describe the fields being displayed.

The processes you list are in deep trouble and should be killed. 294248:53 is the cumulative execution time in minutes and seconds. That is an absurdly high value. 255 is the processor utilization which is used for scheduling. 255 is the max value so these processes are basicly in an infinite loop doing nothing except computation. -sh is a login shell but a login shell should have a tty assigned. This one has ? for tty which means it has become a daemon and has no tty. Each such process will fully utilize a cpu so if the box has 4 cpu's, 2 of them will have no idle time. If the system has less than 3 cpus, the system will have no idle time. The 255 does guarantee that these processes will have the lowest priority possible, so you can still get stuff done, but you still should kill these processes because they are simply wasting resources.
# 5  
Old 01-17-2008
Thanks Mate..I am satisfied with your answer. Its what I needed and I am going to kill the process.
coolbhai
 

Previous Thread | Next Thread
Test Your Knowledge in Computers #675
Difficulty: Easy
Wi-Fi is generally less vulnerable to hacker attacks than wired networks.
True or False?

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Command to get exact tomcat process I am running ignoring other java process

Team, I have multiple batchjobs running in VM, if I do ps -ef |grep java or tomcat I am getting multiple process list. How do I get my exact tomcat process running and that is unique? via shell script? (4 Replies)
Discussion started by: Ghanshyam Ratho
4 Replies

2. BSD

Process remians in Running state causing other similar process to sleep and results to system hang

Hi Experts, I am facing one problem here which is one process always stuck in running state which causes the other similar process to sleep state . This causes my system in hanged state. On doing cat /proc/<pid>wchan showing the "__init_begin" in the output. Can you please help me here... (0 Replies)
Discussion started by: naveeng
0 Replies

3. Shell Programming and Scripting

List Process running under current user

Hi, i need to list the processes running only under current logged in user. EX: $ whoami oraaqw $ ps -ef | grep tnslsnr oraaqw 11403300 19267592 0 09:14:47 pts/3 0:00 grep tnslsnr oraaqw 15794208 1 0 Jan 14 - 11:59... (6 Replies)
Discussion started by: aravindadla
6 Replies

4. Shell Programming and Scripting

Command to know all the Current running process and how to kill

All, 1.What is the unix comand used for all current running process (Including All current running processes Parent ->child->subchild process) 2.If child and subchild processes are running then what is the unix command to kill parent and its all child subchild processes in UNIX. Kindly... (7 Replies)
Discussion started by: skp
7 Replies

5. Shell Programming and Scripting

Display current directory for a running process for script

I'm trying to create a ksh script to do the following: 1) Ask the user what process they want to search for. 2) Have the script read the input as a variable and use it to search for the process. 3) Display the current time & date, the working directory of the process, and finally display the... (6 Replies)
Discussion started by: seekryts15
6 Replies

6. UNIX for Dummies Questions & Answers

Running different process from current process?

I have been having some trouble trying to get some code working, so I was wondering...what system calls are required to execute a different program from an already running process? (1 Reply)
Discussion started by: Midwest Product
1 Replies

7. Shell Programming and Scripting

script to monitor process running on server and posting a mail if any process is dead

Hello all, I would be happy if any one could help me with a shell script that would determine all the processes running on a Unix server and post a mail if any of the process is not running or aborted. Thanks in advance Regards, pradeep kulkarni. :mad: (13 Replies)
Discussion started by: pradeepmacha
13 Replies

8. Shell Programming and Scripting

current running process in shell

hi what is the shell programming code to know the number of processes currently running on the machine & information about those processes. Another one is the configuration and usage of the UNIX file system? requesting all for help. thanks (1 Reply)
Discussion started by: moco
1 Replies

9. Programming

to find current running process

Hi All, The scenario is like this: There is a process say "A" which create a child process say "B" if some condition is true and process "A" terminates. "B" invokes some C program say "C" using 'execl' function. The job of program "C" is to keep polling the server until the server will be up.... (2 Replies)
Discussion started by: ranjkuma692
2 Replies

10. UNIX for Advanced & Expert Users

how to make a current running process ignore SIGHUP signal?

I ask this question since sometimes i run a time-consuming ftp in foreground and forget to use nohup ftp.sh & to put this work background and can still running after i log off. Assume this ftp task have run 1 hour, and still 1 hour time to end, i don't want to abort the ftp, first, i use ctrl+Z... (3 Replies)
Discussion started by: stevensxiao
3 Replies

Featured Tech Videos