An instance of a running computer program.

learn more… | top users | synonyms (1)

83
votes
9answers
19k views

Keeping a linux process running after I logout

I'm connecting to a linux machine through SSH, because I'm trying to run a heavy bash script that makes filesystem operations, and it's expected to keep running for hours. But I cannot leave the SSH ...
48
votes
8answers
27k views

Environment variables of a running process on Unix?

This is to troubleshoot some problems related to environment variables .. On Windows, I could do this by using tool such as ProcessExplorer to select particular process and view values of each ...
36
votes
22answers
3k views

What's the biggest time saver you've implemented?

Which changes that you have implemented did have the biggest impact on saving time in you daily sysadmin workload? What are your tricks to work more efficient and get more things done or work less for ...
31
votes
5answers
4k views

How to prevent “ps” reporting its own process?

$ ps | grep django 28006 ttys004 0:01.12 /usr/bin/python bin/django celeryd --beat 51393 ttys005 0:01.45 /usr/bin/python bin/django celeryd -l INFO 51472 ttys005 0:01.29 /usr/bin/python ...
24
votes
5answers
2k views

What is svchost and why are multiple instances of it running?

There's six instances running on my desktop, and probably ten on a server I manage. What is this, and is it vital to system function?
20
votes
4answers
17k views

How to sort ps output by process start time?

Is there a way to sort ps output by process start time, so newest are either at the top or bottom ? On Linux ? On SysV5 ? On Mac ?
15
votes
6answers
13k views

If I launch a background process and then log out, will it continue to run?

Asking this after a prolonged discussion with a coworker, I'd really like a clarification here. I launch a background process, either by appending "&" to the command line or by stopping it with ...
14
votes
9answers
970 views

Documentation As-A-Manual vs. Documentation As-A-Checklist

I've had discussions in the past with other people in my department about documentation, specifically, level-of-detail and requirements. In their view, documentation is a simple checklist of Y things ...
14
votes
3answers
27k views

How do you free up a port being held open by dead process?

A colleague of mine recently ran into a problem where a process that had supposedly died was still bound to a network port, preventing other processes from binding to that port. Specifically, netstat ...
13
votes
3answers
6k views

Show full process name in top

I'm running a rails stack on ubuntu. When I ps -AF, I get a descriptive process name set by the apache module like 00:00:43 Rails: /var/www... which is really helpful in diagnosing load issues. ...
12
votes
11answers
2k views

Production deployment tools [closed]

Similar to building software, tools should be used to deploy production server updates (whether DB, website, router configurations, etc). The use of tools reduces certain types of human error (missed ...
12
votes
3answers
4k views

Do background processes get a SIGHUP when logging off?

This is a followup to this question. I've run some more tests; looks like it really doesn't matter if this is done at the physical console or via SSH, neither does this happen only with SCP; I also ...
11
votes
3answers
14k views

how i can identify which process is making UDP traffic on linux?

my machine is continously making udp dns traffic request. what i need to know is the PID of the process generating this traffic. The normal way in TCP connection is to use netstat/lsof and get the ...
10
votes
2answers
1k views

Linux/Debian - What does 'pee' in moreutils do?

I recently discovered the 'moreutils' package in Debian (and Ubuntu). It's a collection of convenient unix tools. One of the commands is 'pee'. The man page says: pee is like tee but for pipes. ...
10
votes
2answers
3k views

Linux - Find out the current working directory of a process?

If i have a process PID X, how can I find out what directory it was running in? I can see with ps aux | grep X the full command line that it was invoked with. However in this case it's ./script.sh, ...
9
votes
6answers
5k views

How do I log CPU usage per process?

I have a box on Linode that's going through weird behavior. Every now and then CPU and disk I/O will shoot to 100% and the server becomes unresponsive and has to be booted. I'd like to investigate ...
9
votes
3answers
14k views

How to get - number of threads per process?

This is one Ubuntu 9.10 server. Also how to see memory usage per process? Thanks
9
votes
5answers
2k views

Limiting network throughput of an already launched process ? (Linux/FreeBSD)

Is there any utility to limit the network throughput of a process after it has been launched? Simple example: you note that a user takes all your upload bandwidth using scp and you'd like to limit the ...
8
votes
5answers
24k views

Dump a linux process's memory to file

Is it possible to dump the current memory allocated for a process (by PID) to a file? Or read it somehow?
8
votes
3answers
3k views

How do I start a process in suspended state under Linux?

Practically, I need a process which behaves, as if I had pressed Ctrl+Z just after it started. Hopefully, it is possible to do such thing using a shell script. (Also, knowing the resulting PID would ...
7
votes
5answers
2k views

Pain removing a perl rootkit

So, we host a geoservice webserver thing at the office. Someone apparently broke into this box (probably via ftp or ssh), and put some kind of irc-managed rootkit thing. Now I'm trying to clean the ...
7
votes
5answers
3k views

Linux - How do I see when a process started?

How can I see when a process started, assuming I know the pid. (On Linux)
7
votes
8answers
3k views

How to detect a hidden process in linux?

We have a box we suspect has been rooted at work. The question is how do we find it? I am no system administrator, but I was brought onto the team to resolve the situation and I am curious where ...
7
votes
6answers
846 views

What is the best way to identify unknown processes on windows?

How do you typically identify processes in windows' task manager when trouble shooting a problematic system? It's easy enough to get a list of tasks via the task manager but how do you determine ...
7
votes
5answers
34k views

How to measure solaris process memory usage?

How to check how much memory a solaris process consumes? I'd like both total address space allocated and the amount that is resident in RAM. I tried summing pmap output with some awk script, but it ...
7
votes
4answers
15k views

Is there an equivalent command for 'init.d/networking restart' in OS X

From time to time, I've encountered issues with OS X clients' network connections (Wired and Wireless, Leopard/Snow Leopard) where nothing will fix the issue, until you reboot. Is there a ...
7
votes
3answers
197 views

How to safeguard a shell script against running out of control?

I've recently had an experience of writing a shell script which crashed a server (and damaged a partition) by consuming all resources. It was hooked up to a cron job, and it seems it took longer to ...
7
votes
7answers
14k views

How to kill a <defunct> process with parent 1

I am running Bacula on a RedHat box. From time to time, the storage daemon bacula-sd stops working and becomes <defunct>. [root@backup ~]# ps -ef | grep defunct | more root 4801 29261 0 ...
7
votes
1answer
101 views

App Pool doesn't respect memory limits

I am dealing with a legacy .NET app that has a memory leak. In order to try and mitigate a run away memory situation, I've set the app pool memory limits from anywhere between 500KB to 500000KB ...
6
votes
4answers
21k views

How do you kill a process tree in linux? [closed]

Sometimes, sending a SIGTERM to a process will cause it to send SIGTERM to all its child processes. However, sometimes this doesn't work. Is there a command or a utility that will allow me to kill a ...
6
votes
4answers
5k views

Are .pid files reliable for determining whether a process is running?

Many programs such as sshd create .pid files in /var/run/ that contain their process ID. Are these files reliable for determining whether a process is running? My guess is that these files are ...
6
votes
2answers
9k views

How to configure a Windows service process to run with low priority?

Is there a way to configure a Windows service process (e.g. squidNT, SQL Server, etc) to start automatically with low priority without manually changing process priority via Task Manager?
6
votes
1answer
22k views

What is a Process Handle?

What is a process handle and what can we know about a running process through the "handle count" property in a task explorer?
6
votes
1answer
5k views

Putting a process in the background without stopping it - (ctrl+z)?

If I start a process by typing it in normally at the command line, such as wget http://site.com/bigfile.zip and then decide I want to move that to the background, I know that I can use something ...
6
votes
2answers
3k views

How can I redirect an already running process's stdout/stderr?

(Running on an Ubuntu 10.04 64-bit server) Yesterday, I made the mistake of starting a process (which I didn't realize was going to take several days to run) over SSH without using screen. I've ...
5
votes
6answers
3k views

How to relaunch an executable if it dies

I'm looking for a way to monitor a process, and relaunch the executable if the process dies for whatever reason. Does Linux have a built-in tool that can do this?
5
votes
4answers
7k views

How do I automatically restart a process on server reboot/process exit?

On my Ubuntu server I use God to monitor some Ruby processes/scripts, including a Queue system. God automatically checks when one of my processes exists and restarts it. It also keeps track of memory ...
5
votes
5answers
2k views

What's the best way of setting up a cron job to check that a long-running process is still going and if not, start it?

As per the title: What's the best way of setting up a cron job to check that a long-running process is still going and if not, start it? If I start a long-running process in cron, is it going to ...
5
votes
3answers
992 views

Supervisor VS cronjob

Actually I'm using supervisor to monitor a process and restart it when it stops for some reason. The problem is that in case of a supervisor crash the process stops get monitored. So I thought to ...
5
votes
3answers
163 views

Sort Active Processes in Unix

How can i sort active processes by total process time in unix?
5
votes
1answer
658 views

Verify disown command

I issued the ^z; bg; disown sequence in order to allow me to close an ssh session in which I am running a super-important long-running process. This process writes status output to stderr, and it has ...
5
votes
2answers
559 views

Run a pool of processes in shell

I'm looking for an easy method to run N selected processes at the same time with one command. It should put all the output on my terminal and shut down all of them when I exit with ctrl+c. Is there ...
5
votes
3answers
234 views

Does your change control process score change requester and/or implementers?

Does your organisation have a change process, formalising every change, from whole new system deployments to cable patches? If so does your process score those asking for changes or/and also those ...
5
votes
3answers
457 views

Does anyone know a simple way to monitor root process spawn

I want to exec a script when a new root process spawns. (on Linux) How can I simply do that ? Thanks
5
votes
5answers
4k views

Find (and kill) old processes

Basically I need to be able scan the process tree and find processes that match a certain name and started running more than a week a go. Once I have them, I need to kill them. All the processes are ...
4
votes
5answers
2k views

Bash snippet for killing a process until it's dead?

I'm trying to write a robust bash script, and in it I create a background process. At the end of the script, I want to kill it. I have it's PID. I was thinking of somthing like this while [[ ps ef ...
4
votes
2answers
602 views

Linux: ps -awx vs. ps -awwx

Does anyone know the difference of ps -awx vs. ps -awwx? I'm tracking down some processes, and I see significantly more information when I add an additional "w". Does this work like in other cases ...
4
votes
2answers
145 views

Remove a zombie process from the process table

I've got an annoying zombie process that gets adopted by init, and it won't go away. I've read there is a way to create a dummy process, attach the zombie as a child of that new process and then kill ...
4
votes
4answers
338 views

Linux process management

I started a long running background-process (dd with /dev/urandom) in my ssh console. Later I had to disconnect. When I logged in, again (this time directly, without ssh), the process still seemed to ...
4
votes
3answers
7k views

What is “Interrupts” process and why it so loves my CPU?

I have windows XP SP3 on Intel Core Duo 2GHz. The "Interrupts" process, according to the Process Explorer, continuously take 30-40% CPU. Is it normal?