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

learn more… | top users | synonyms (1)

15
votes
5answers
37k views

How to stop a background process?

I have started a wget on remote machine in background using &. Suddenly it stops downloading. I want to stop its process, then start it again. How can I stop it? I haven't close its shell window. ...
9
votes
1answer
263 views

How can I track executables created by my user on Linux?

Using Linux, I would like to track the executables that are executed in my name, including the whole command line (in practice, every exec*() done as my own user). A program I do not control is ...
2
votes
2answers
188 views

Why do I see more processes in KVM than in OpenVZ?

I've got a 512mb Centos 6 VPS running on KVM. Now another VPS from a org. I manage is running on OVZ. When I type top on the KVM one, I get a whole list of all sort off processes. But when I do this ...
0
votes
3answers
306 views

Owner of init and xterm

I don't understand what is owner of process. Owner of bash is me. Then who is owner of init and xterm? I searched on google but I can't find.
1
vote
4answers
2k views

Why teamviewer starts again after being killed

My main desktop has Mint 14 and I approached it via SSH from another computer, because I didn't have a screen on the Mint one. Then I tried to start teamviewer just I order to launch its desktop ...
1
vote
2answers
270 views

How do I draw a process tree from my shell to the kernel?

I can't understand this problem For each process in the tree, indicate the name of the process, the process's ID number, and the name of the owner of the process.
12
votes
3answers
436 views

How do I wait on a program started in another shell

I have a program that does a large a amount of work (takes about 4-5 hours) that gets started by cron when all the data it works with becomes available. Sometimes, when I am waiting for it to finish, ...
2
votes
1answer
698 views

How to get start time for a defunct process on AIX?

When I run the following commands on AIX: 22:root@SERVER:/root # ps -ef | head -1 UID PID PPID C STIME TTY TIME CMD 22:root@SERVER:/root # ps -ef | grep defunct | head -1 ...
5
votes
2answers
713 views

Obtaining PID of command earlier in Pipeline

I'm writing a bash script to use inotifywait to monitor a directory and kick off actions when changes are detected. Something like: inotifywait -m ... | while read f; do something; done Since ...
1
vote
1answer
86 views

Limiting processes by memory under Linux

We must launch several hungry processes on a Linux system. These processes often need several Go (~5Go) of memory to run (total memory: 16Go RAM + 2Go swap). At first, when the system was running ...
6
votes
2answers
156 views

Why are there so few “running” processes?

On all of BSD/Linux/MacOS and Solaris, I made an observation - no matter how busy the system is, top always reports very few (usually 1-2) running processes. According to my limited understanding, a ...
4
votes
3answers
1k views

Why do top and ps show different PIDs for the same processes?

When I run top -H, I see that my multiple mysql threads all have the same PID. However, in ps -eLf I see each one has a different PID: ps -eLf UID PID PPID LWP C NLWP STIME TTY ...
6
votes
2answers
460 views

How can I allow a user to prioritize a process to negative niceness?

I want a user to run a specific process on the system with a negative nice value. I can't simply fork the process to background as this specific program is a minecraft server and I rely on the command ...
2
votes
1answer
182 views

Which system calls could create a new process?

When executing ps command in my Linux system i see some user processes twice (different PID...). I wonder if they are new processes or threads of the same process. I know some functions in standard C ...
5
votes
3answers
735 views

Using `kill -s 0 $pid` vs `[[ -e /proc/$pid ]]` to detect if PID is running

One of the idioms often used to check if process is running is to use kill -s 0 $pid. My question is, does it have any upsides over using [[ -e /proc/$pid ]] construct? The script I'm writing is ...
5
votes
2answers
911 views

Get the PID of file creation

I am writing a bash script that creates 5 files with the extension ".P" and write a line of "something" into them. "P" represents a number and it's the PID of the process that creates the file. How ...
2
votes
1answer
887 views

Difference between process in background and daemon [duplicate]

What is technically the difference of a process that started in foreground and was manually put into background and a daemon? Do they have different properties?
3
votes
1answer
90 views

What is the rtsbpp-polling process doing?

In Ubuntu 12.04 LTS when I run the top command I see a process called rtsbpp-polling. Googling it gives only just a few hits to the Gentoo Linux forum that does not seem to be relevant (they don't ...
21
votes
3answers
1k views

If computers start counting at 0, why does the init process have a pid of 1?

Not much to put here in the body, the question is self explanatory.
1
vote
0answers
93 views

How to send a running process to jail?

"Go directly to jail; do not pass go, do not collect $200" — Monopoly Is there any way to make a running process's all future file access behave as if it has always been in a chroot environment?
1
vote
1answer
240 views

Grep Wvdial output while it is running

I want to grep the output from wvdial while wvdial is running. Actually I want to fire a task when the modem is connected. I want to do this in the following way: grep string "IP address", if it is ...
1
vote
2answers
60 views

What information about a process is retrievable after it is terminated? [duplicate]

After a process has been terminated, is it possible to retrieve any information about it, such as when it started and finished, &c. Is it possible to enable logging of this information?
75
votes
4answers
1k views

Can I somehow add a “&& prog2” to an already running prog1?

Most shells provide functions like && and ; to chain the execution of commands in certain ways. But what if a command is already running, can I still somehow add another command to be executed ...
1
vote
2answers
253 views

Is it possible to control xterm (or specifically a process that xterm has started) from another process?

If I start a process with xterm like this (where omxplayer is the process xterm is starting): xterm -fullscreen -fg black -bg black -e omxplayer -o hdmi -r %f Is it possible for me to write to ...
2
votes
2answers
482 views

AIX open() : file descriptor is zero (!?)

A daemon process, on detecting the presence of a text file in a particular directory then launches an executable file which opens the aforementioned text file in order to read and then transmit its ...
1
vote
1answer
386 views

How do I print the process name next to the process ID number in a file?

I'm redirecting results for something into a file and I also need to find the process name and ID number and redirect it to the file as well. I'm guessing the process name is the command in which I'm ...
1
vote
1answer
3k views

Modify 'Soft Limit' of 'Max processes'

I tried ulimit -u 2000 and ulimit -Su 2000 to modify the 'Max processes', and started up my program, but failed. I found file '/proc/pid/limit' is still: Max processes 1024 ...
2
votes
1answer
319 views

accessing stdin/stdout of a process started in another tty

I logged in to my linux physically(say tty1) and started a process that watches stdin for commands and has some stdout-put. How can I access/use this process from a SSH session?
5
votes
2answers
3k views

How to identify a process which has no pid?

I have a process which listen to 2 ports : 45136/tcp and 37208/udp (actually I assume it is the same process). But netstat doesn't return any pid : netstat -antlp | grep 45136 tcp 0 0 ...
2
votes
2answers
129 views

Detecting kernel thread on pre-3.0 kernels

Looking at the proc man page (http://man7.org/linux/man-pages/man5/proc.5.html) it is possible to detect which processes are kernel threads in /proc/<pid>/stat by looking at the flags value ...
2
votes
2answers
444 views

lsof - debug the output information

I was going through the questions of this site. In this particular question, I see the command lsof being used to list the files that are open for a particular user. I ran the below command in my ...
3
votes
1answer
450 views

Bind9 — How to find which programs are making which dns lookups?

Using bind9 on a laptop shows lots of nonsense domains when network connectivity is down: Oct 18 19:56:18 lap3 named[1536]: error (network unreachable) resolving './NS/IN': 128.63.2.53#53 Oct 18 ...
5
votes
2answers
289 views

Processes in Linux

As I understand it, process descriptors are stored in a doubly linked list data structure. But a fork can create multiple children for the same process, so that makes me think that there is a tree ...
5
votes
2answers
282 views

Is there a way to really prioritize processes or make Linux respect their priorities?

I know there are process priorities like in other operating systems, going from -20 (most prio) to 19 (less prio) but Linux seems to ignore them. Right now I was building the kernel in the background ...
2
votes
2answers
378 views

How to make processes not die after its parent dies?

I've been messing with forkbombs and noticed that if I just fork() processes repeatedly, killing the initial process will bring down the whole tree. This is not the case for forkbombs written in BASH ...
1
vote
3answers
6k views

process id and killing process - ps commmand

Please see the output of below ps command: abc@smaug:~/Desktop$ ps ax | grep firefox 2213 ? Sl 2:01 /usr/lib/firefox/firefox 2644 pts/0 S+ 0:00 grep --color=auto firefox Please ...
22
votes
3answers
6k views

Find out current working directory of a running process?

What command(s) can one use to find out the current working directory (CWD) of a running process? These would be commands you could use externally from the process.
2
votes
2answers
183 views

How does a process handle the situation when it finds no memory to use?

What happens when a particular process finds that there is no memory to use? Will that process kill/restart another process to proceed their task ? Or what the process (that requires more memory) ...
1
vote
1answer
85 views

devilspie detect if application was started with a flag

How can I set devilspie to detect if an application was started with the flag --hello-world from terminal? For example window_name detects the window title. How can transform in devilspie the ...
1
vote
3answers
109 views

ssh targetHost &; fg - does not work, but why?

I was trying the following combination in order to get the pid of the ssh session (running in the background displays the pid) and than fg to get back to the ssh session and introduce the password: ...
1
vote
2answers
164 views

KDE becomes slow

I experience problems with KDE 4.11.1 on Arch Linux. It suddenly becomes laggy and unresponsive and just as suddenly returns to the normal state after some time. Normal CPU load (KSysGuard): ...
2
votes
1answer
1k views

child process does not inherit the pending signals from the parent after a fork system call, why?

Could anybody please tell me the reason to why pending signals are not inherited by the child process? On the other hand, the child process inherits the signal handlers and signal mask from the ...
5
votes
1answer
209 views

How to monitor top applications using CPU (and IO if possible) in a graph?

I need to find what and when these applications used so much CPU (and IO if possible too). This should be in a graphic timeline like we see in GNOME System Monitor CPU History. I also want to compare ...
1
vote
4answers
3k views

monitoring file changes + process access to files

I would like to see what's happening in my app server folders, which files are changed by process x or which *.war files has been changed (replaced/created) in last x minutes. I am software developer ...
7
votes
3answers
3k views

Use & (ampersand) in single line bash loop

I have been using this command successfully, which changes a variable in a config file then executes a Python script within a loop: for((i=114;i<=255;i+=1)); do echo $i > numbers.txt;python ...
9
votes
3answers
2k views

What's the difference between pkill and killall?

I know that pkill has more filtering rules than killall. My question is, what is the difference between: pkill [signal] name and killall [signal] name I've read that killall is more effective ...
3
votes
1answer
97 views

How can I recover suspended processes after restarting X?

I had several instances of Firefox running, which I suspended. I think I used 'the GUI' (KDE's System Activity), which I think is the same as kill -19. Normally this works fine - I can resume the ...
0
votes
2answers
165 views

UNIX- Identify which processes are running more that 6hours

I need to know which processes are running more than 6 hours in UNIX. How can I find those out?
5
votes
1answer
7k views

bash: Run command in background and capture pid [duplicate]

Am writing a bash 4.1 script... Would like run another script (or internal function) in the background... And capture the pid of that background job in a variable in the foreground script... If the ...
1
vote
2answers
1k views

How can I automatically kill the process with the highest CPU load?

Sometimes programs will lock up in the background and cause high CPU usage. Is there any way I can programmatically ascertain which process is causing the highest CPU load at the moment and kill it?