A process is an instance of a computer program that is being executed.

learn more… | top users | synonyms (1)

3
votes
4answers
403 views

How to get the id of a very short child process if the parent is known?

I'm looking for a way to get the PID of a short child process in Linux. The process is instant from a human perspective. I know the parent process which will spawn the child process. Is there a way ...
2
votes
2answers
95 views

How to get environmental variables of a very short process?

I have a very short process for which i want to check the environmental variables for debugging purposes. The process is instant from a human perspective. The example illustrates it better. Example ...
0
votes
2answers
313 views

what is a background process?

Here is a common definition of a background process: "A background process is a program that is running without user input. A number of background processes can be running on a multitasking operating ...
4
votes
3answers
1k views

Possible to get SMS/text message notification when process ends/is killed?

There are scripts that will send an e-mail when a server process is finished. However, I do not want to check my email every so often just to see whether a job has finished. Therefore I'd like to get ...
1
vote
1answer
92 views

Find if a process terminates in a specific amount of time

I am running a program.Inside this program i run a specific command and i use ulimit command to terminate the running of that command if it exceeds an amount of time.To be more clear i run this: ...
2
votes
1answer
221 views

pmap and memory usage

On Ubuntu 12.04, I have several apache2 processes running (the 1130 parent and the children it spawned), and as you can see, they have around 300-400 mb of virtual memory and 10 mb of resident memory: ...
2
votes
1answer
5k views

ps switches to display PID, PPID, PGID, and SID collectively

I tried ps with different kinds of switches e.g. -A, aux, ef, and so forth but I cannot seem to find the right combination of switches that will tell me the Process ID (PID), Parent Process ID (PPID), ...
1
vote
2answers
2k views

Zombie process cannot be removed or killed [duplicate]

I have a zombie process that refuses to be removed, have tried killall -9 1913 and pkill with no effect. Any help would be very much appreciated.Running Ubuntu 12.04.2 LTS. Thank you. ...
1
vote
1answer
78 views

Are zombie processes something I should be concerned about? [duplicate]

I run a server. Should I be concerned about zombie processes? Do they consume any system resources (RAM, process table entry, etc.) that I should be concerned about?
2
votes
1answer
67 views

Run a script when a process throws stderr message

I want to "wrap" a process around another to catch stderr messages when they occur. Use Case I'm using Compass and I have to have a terminal open and see if there is something wrong. My plan is to ...
1
vote
1answer
151 views

Deadlock in a crontab between cron and its child defunct processes

I'm having a strange case of deadlock, where the two processes launched by cron are defunct, but cron does not pick the return code and exit. I don't have access to the root user. myuser@myserver:~) ...
2
votes
4answers
2k views

How to kill a process which can't be killed without rebooting?

There are 5 processes which can't be killed by kill -9 $PID and executing cat /proc/$PID/cmdline will hang the current session. Maybe they're zombie processes. Executing ps -ef or htop will also hang ...
1
vote
2answers
522 views

“ps” command doesn't return to prompt

I have this linux box that I need to maintain periodically. To do that, I issue a ps command programmatically and check the running processes. But as shown in the screenshot, sometimes, the ps ...
2
votes
1answer
527 views

what is the structure of a linux process? [closed]

what is the structure of a linux process? In linux there are processes executed on a address and which use system resources. Can anyone tell me the structure of a process and which parameter ...
3
votes
1answer
197 views

init: is it a user thread or a kernel thread?

init is the first task executed after kernel is loaded, right? Then who is its owner. also I can see [swapper/0] [swapper/1] ..... [swapper/7] having pid 0 PID PPID CPU TASK ST %MEM ...
5
votes
3answers
292 views

Determining the particular processor on which a process is running

I have access to an 8-core node of a Linux cluster. When logged in to the node, I can see a list of processors using this command: more /proc/cpuinfo In my 8-core node, the processors are numbered ...
4
votes
3answers
4k views

Terminating a bash shell script running in the background

I often use bash shell scripts to run simple commands for many different files. For example, suppose that I have the following bash shell script, called script.sh, that runs the program/command foo ...
2
votes
1answer
438 views

How does One Find the PID of a Process Started with startproc?

My understanding is that it's generally a good idea to create a PID file for daemon processes and that startproc is a good way to start these daemons. I know that startproc takes -i and -p arguments ...
6
votes
7answers
7k views

Bash way to check if a process is already running in the background (and skip re-execution based on that)?

Can I make a bash command line that only runs a certain command if the process is not already running (in the background)? How do I check*, if a command is already running? (so I can add the next ...
3
votes
3answers
3k views

Fix “firefox is already running” issue in Linux

I am trying to open Firefox in CentOS, but I'm getting the following message: Firefox is already running but is not responding and Firefox doesn't open. I tried this in command line: kill ...
15
votes
5answers
2k views

Can ps display only non kernel processes on Linux?

How can I ask ps to display only user processes and not kernel threads? See this question to see what I mean...
5
votes
4answers
163 views

Best practices for job/process tracking and multi-tasking

I run 10+ different commands from 10+ different directories, and I need a better process to track everything. I do a lot of debugging, and often times I need to work on multiple issues in parallel. I ...
1
vote
1answer
161 views

AIX why does ps display the process name between square brackets? [duplicate]

On AIX 7 I have a process whose name appears between square brackets in the ps output: PID TTY TIME CMD 7798784 pts/2 0:00 [myproc] 9044154 pts/2 0:00 ps 10485770 pts/2 0:00 ...
1
vote
3answers
108 views

How to know if a specific program is open

Using a command line in terminal, I want to be displayed 1 if a program (for example Firefox or Chromium) is open and 0 otherwise. Edit: By "open", I mean "is running on the current machine and has a ...
3
votes
2answers
182 views

Get PID of the application running in the active terminal emulator

My end goal is to be able to open a new terminal window (urxvt) directly in the current working directory of the program running in the window currently active. I'm currently using the shell (Bash), ...
4
votes
1answer
143 views

Raise Brightness When Maximizing Terminal

I'm looking to raise the brightness when I maximize or foreground the Terminal window which has Vim running. I would like to reset the brightness to normal when I minimize or background that process ...
2
votes
1answer
563 views

How to check if a currently running process is opened by root or user

I'm currently creating a BASH script to kill off processes. I first check if the process is running then kill it. But I would like to add a nested if to find out if that process was opened by root ...
5
votes
2answers
491 views

Turning off swapping for only one process with cgroups?

I would like to turn off swapping for only one process. Swap should work as usual for the other processes. How I can implement this with cgroups?
1
vote
2answers
602 views

How do I kill 'repo sync' using crontab given it spawns many processes?

I need to 'repo sync' the Android source overnight, as my monthly bandwidth is limited. , I start the 'repo sync' at midnight, then want to kill it at 8am. The following is the command: 2 0 * * * ...
0
votes
1answer
351 views

Identify Tasks/Process which are 7 days old in linux

How can I identify the processes running since 7 days in Linux?
1
vote
1answer
195 views

How to kill all processes that don't have specific parent process?

A parent process should always be running with N children process. I would like to run a script which will show/kill all children processes that don't have a parent process. $ ps faux | grep ...
1
vote
2answers
196 views

process memory usage

What is usually meant by the phrase process memory usage, what does this actually mean, i.e. what does this memory consist of? And what column does it correspond in ps aux output, RSS or VSZ?
4
votes
2answers
200 views

Is grandchild process also child process?

In Unix/Linux terminology, do child processes of a process include grandchild processes of the process?
4
votes
3answers
927 views

What is a process GID and what purpose does it serve?

Reading mod_wsgi's documentation I found you can choose which group to run the worker processes as. I can understand group ownership of files and how only a user who belongs to that group can achieve ...
5
votes
3answers
282 views

Dynamic file content generation: Satisfying a 'file open' by a 'process execution'

I have a read-only file, F. A program, P, that I'm not the author of, needs to read F. I want the content of F to come from another 'generator' program, G, whenever P tries to read F (taking F to ...
0
votes
2answers
1k views

`ps | grep | kill` aborts my script prematurely [duplicate]

I have a Linux computer that I remotely SSH into using plink on a Windows XP machine. I have the Plink program set to execute commands in a script using automated login: plink -ssh [domain name] -l ...
3
votes
3answers
307 views

Print process ID (PID) of a Matlab instance

To run my Matlab scripts, I've created a shell script to which I give two parameters - the path to the matlab file ($1) and to the log file ($2): nohup time matlab -some_parameters -r "run $1;exit" ...
3
votes
2answers
202 views

How to monitor the last PID assigned by the kernel?

To monitor process creation I'd like to periodically write the last PID assigned by the kernel to any process on the system (not just processes created by the PID-monitoring program) with a time stamp ...
1
vote
1answer
783 views

How to kill the (last - 1) PID with bash

I know how to kill the last process with kill $! However I would like to kill the last−1 process, i.e. not the last one, but the one before the last one. I tried kill $$(($! -1)) but ...
2
votes
4answers
240 views

Open program as root, close root session but still program is running

When I run my backup script, first I switch to root, mount a truecrypt partition and then run the script. I've noticed that after run truecrypt as root, I can exit the root session and truecrypt ...
0
votes
0answers
260 views

Tracing system call on Ubuntu 12.04

The main task I have to carry out, is to trace the system call of processes in ubuntu 12.04 LTS. Problem is, I am unable to trace them continuously, i.e. as soon as they are added to the system, they ...
5
votes
3answers
522 views

Can I pipe any two processes to each other?

In this page from The Design and Implementation of the 4.4BSD Operating System, it is said that: A major difference between pipes and sockets is that pipes require a common parent process to set ...
-1
votes
1answer
91 views

System call tracing [closed]

I am working on system call tracing for host based IDS, i need to trace a process as soon as it entered in the system (a new entry in /proc). Is there any interrupt or signal or kernel datastructure ...
2
votes
3answers
2k views

pkill can't kill processes with parent process id 1

I want to kill the following processes using pkill "run_tcp_sender.sh" or pkill -SIGKILL "run_tcp_sender.sh" root 14320 1 0 2012 ? 00:00:00 bash run_tcp_sender.sh ...
1
vote
1answer
161 views

How to trace process scheduling of certain process?

For a project at my university I am researching ways to trace, log and manipulate the process scheduling of certain processes. I would like to launch an number of applications, everyone in a single ...
1
vote
2answers
88 views

Single process accessible temporary file

I want to create a file that is only accessible to the process that created it (and potentially its children), and that disappears when the process exits, ideally never persisting the file to disk. As ...
4
votes
1answer
44 views

Suspend and edit previous single line commands

Say I want to modify the latter of some concatenated command line options, is it possible without killing the first command? Specifically I have compile and run scripts executed thusly: > compile ...
6
votes
2answers
675 views

What does it mean each process has a current directory?

I'm reading "The Unix Programming Environment", but I don't comprehend the concept current directory of process. Each process, has a current directory, and all filenames are implicitly assumed ...
7
votes
2answers
406 views

Kill user processess on logout

I have a Ubuntu server that handles remote X sessions from users. However, I don't want to allow users to run any kind of background processes - so here is my question: How do I prevent users from ...
5
votes
5answers
378 views

Is a persistent zombie process sign of a bug?

(OS: Debian variant.) Having a process with zombie-status. The PPid belonged to a gvim process. The contents of /proc/[pid]/wchan is do_exit, /comm is sh and /cmdline is empty, /status is shown ...