Questions tagged [ps]
ps is a Unix operating system command and the like used to display the running processes.
142
questions
0
votes
0
answers
15
views
Differences between STOPPED in top command and STOPPED in ps
I have a running script in a docker container. After a while, I found that the processes seemed to be in stuck when I used ps -ef command, since the TIME field for those processes were stuck in a ...
0
votes
0
answers
19
views
On Linux (Fedora), I want to track a PARTICULAR process' I/O to find out if it's hung or is making progress
So... I'm busy trying to clean up two decades of backups an have a particular job that's trying to get a sha1sum on two possibly duplicate files and it appears to be hung... the operative word being &...
4
votes
3
answers
922
views
How to check if a command is running currently? [duplicate]
I want to check if a command is running with the following if clause, but it's always true, whether command actually is running or not:
if [ $"(ps aux | grep curl)" ]; then echo is; else ...
1
vote
1
answer
59
views
Is it possible to get `ps` to render thread names in wide mode?
I am using the following version of PS inside a container:
bash-4.2$ ps --version
ps from procps-ng 3.3.15
The command ps -eL shows the thread names, but they are truncated:
3972 12684 ? 00:...
0
votes
0
answers
36
views
List process details
How can I list process details for a specific process?
I know about commands like ps -ef but they all truncate the details to fit into fixed column widths. For example, in one listing I can see that ...
0
votes
2
answers
1k
views
How can I correctly retrieve the PID of a process related to Java using ps aux? and how can I put the headr containing the output column name?
I am not a system administrator (I am a software developer) and I have the following doubt.
Performing this command I can see the list of the first 10 process running on my system (correct me if I am ...
0
votes
2
answers
548
views
How to kill a process on ubuntu that won't die?
I am trying to kill this process that seems to be stuck in a loop:
> ps auxww | grep -E '^USER|bash'
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
ubuntu 61505 99.7 ...
0
votes
1
answer
450
views
How to decrease the length of the output of "ps -ef" command? It is showing full output with unlimited length
When running ps -ef command on our new solaris server the command outputs the full arguments of the processes including passwords and usernames. It seems the length of characters it is showing is ...
0
votes
1
answer
668
views
linux ps command to list number of running processes in super user root
I am looking for. a command that I can list the number of running processes by superuser root and pipe it to wc -l
i already did ps -ef | grep ^$USER wc -l however that only shows for the current user
2
votes
1
answer
161
views
99 % CPU taken up by “ps”
I have an EC2 t2.micro (Linux AMI) instance. Since a few days I noticed that RAM is being 99% used by "ps" .
When that happens :
$ free -m
total used free ...
1
vote
1
answer
405
views
Need to match running processes in egrep
I need to find all running processes whose owner is neither root nor Student. I know how to not get running processes whose owner is neither root nor Student by type
ps aux | egrep '^[^(root)|(Student)...
0
votes
1
answer
28
views
Why is value of CMD for PID 1 different depending on the flags passed to ps?
ps -ef | grep -E 'PID|init' and ps -p 1 report different strings for the CMD column of ps output. Why is one systemd and the other /sbin/init? I would have expected to just see /sbin/init. I'm running ...
0
votes
1
answer
89
views
Discrepancies between "ps -f" and "ps"
We are running Red hat Enterprise 7.7 (Maipo) and for a specific oracle process I'm getting two different values under "CMD" column. See below examples:
ps -p [process_id]
109401 ? 00:09:57 ...
0
votes
1
answer
62
views
POSIX ps commands' output format ends with =
What does it mean by an equal sign that ps command ends with for its output format?
ps -o gpid= 1111
0
votes
1
answer
46
views
Linux: How to indetify what consumes 35G of system memory
currently the processes of one of usr systems are consuming 6,5G RSS:
root@system:~# ps aux | awk 'BEGIN {sum=0} {sum +=$6} END {print sum/1024, "MB"}'
6575.42 MB
root@system:~#
If I run free -m it'...
0
votes
1
answer
68
views
List all processes I can kill, so I can kill them
I need to figure out all the processes I can kill as my user (without privileges), so I can kill them. how do I do that? I just wanna kill everything I can.
3
votes
1
answer
10k
views
Why do I often receieve `no such process` in response to a process I want to kill?
me@me:~$ ps aux | grep -i firefox
me 15413 0.0 0.0 14428 1036 pts/1 S+ 05:46 0:00 grep --color=auto -i firefox
me@me:~$ kill 15413
bash: kill: (15413) - No such process
Why might this ...
2
votes
1
answer
729
views
How to get process command line arguments in execsnoop
I need to log the process start events with the command line arguments.
There's ps au which prints the command line for the processes which are currently running.
There's execsnoop which prints the ...
0
votes
2
answers
1k
views
Output of the "ps w" command
I am using customized OpenWRT, in which no option works for the ps command except w.
When I enter ps w, it’s showing all the running processes, but if I type, for example, ps w | grep kkkk it’s ...
0
votes
1
answer
789
views
Parse pstree output to list parent and child PIDs of a given process name
I am running two instances of a program called SMU, hence there will be two separate processes with the same name SMU. And each SMU process will create one (can be more than 1) child process, hence ...
0
votes
3
answers
202
views
is it possible to number the output of a command in ubuntu
I'm in a Linux class and one of my assignment questions is to find out the total number of processes running on the server.
I have used the ps -aux command to list all the processes but I was ...
0
votes
1
answer
392
views
Process management in TempleOS: listing and killing processes?
TempleOS has different processes, according to docs/Glossary.DD.Z,
There is no distinction between task, process or thread. The Fs segment reg is kept pointing to the current task's CTask. There ...
0
votes
1
answer
116
views
VPS: CPU seams to be under heavy load while no process produces such load?
I recently set up a really cheap VPS mainly for backup purposes but I also wanted it to do some small, minor tasks. But because I was too interested I wanted to take a look at CPU and Memory usage, ...
5
votes
2
answers
6k
views
what is the SI value in powershell ps?
I am trying to find process execution information with powershell ps.
There is an attribute 'SI' whose values are usually like 0, 2, 10, etc.
Specifically, I typed in the following to powershell:
...
1
vote
2
answers
2k
views
What does `args` in Linux command `ps ao args` means exactly?
In the man page of ps, I found that -a means:
Select all processes except both session leaders (see getsid(2)) and
processes not associated with a terminal.
and -o means
User-defined format. ...
1
vote
2
answers
249
views
Portable way to find all PIDs by cmdline
I want to find the PID of all processes which were run by a cmdline call which contains a certain string my_exec.
For instance, with macOS or Ubuntu, open a terminal and run /bin/bash, and then in ...
0
votes
1
answer
2k
views
How to tell if a process is running in the host or in a docker container
I have a lot of gitlab processes, but gitlab is not installed in the host:
» ps -ef | grep -c gitlab
61
Those processes, at first sight, look like normal processes:
» ps -ef | grep gitlab | head
...
3
votes
1
answer
793
views
Linux command to output each new process PID
Is there a linux command that will watch for new processes?
My goal in this is I want to see when a new gulp command is called, get the command line executed with something like ps, then filter it ...
4
votes
3
answers
3k
views
Full command text with ps on cygwin?
Is there a way to get the full output from ps on Cygwin?
For instance, none of the following gives me the full wget shell line, just /usr/bin/wget:
$ ps -ef | grep wget
Administ 9844 7780 pty1 ...
0
votes
0
answers
891
views
Get cpuid for a particular process thread using ps
How do I get the ps command to output just the cpuid if I know the pid and tid?
I can use ps -e -mo pid,tid,psr | grep Thread_Id to display the current cpu the thread is running on, but is there a ...
1
vote
1
answer
1k
views
A process is opening a tty but "ps t tty" cannot see it
See following example:
[STEP 101] # tty
/dev/pts/3
[STEP 102] # ssh -f -n -N -D :7070 127.0.0.1
[STEP 103] # pgrep -lf 7070
33109 ssh
[STEP 104] # ls -l /proc/33109/fd/
total 0
lrwx------ 1 root root ...
4
votes
1
answer
4k
views
The nohup process isn't listed using `ps`
nohup can help user keeping process running after log-out.
But while I log out & in again, the process python is gone.
Before log out
Log in again
We can find the python process ...
0
votes
0
answers
92
views
How can I find the PID for software where the name of the software is different from the executable?
I run "Videos" software from the Dash in Ubuntu. After some minutes the software freezes.
I've tried searching for the PID of the software to kill it, but I can't find any result with these commands:
...
4
votes
3
answers
60
views
Locating a process in a linux vm (it's complicated)
I have a virtualbox vm to which I can connect through a browser using localhost:8080. The network of the vm is NAT with port forwarding of localhost:8080 to vm:8080.
However, logging into the console ...
0
votes
1
answer
669
views
How to kill second gedit?
I executed this command:
for run in {1..3}
do
gedit &
done
How can i kill second gedit?
Because result of this command:
ps -eo cmd,pid | grep gedit
is:
gedit ...
1
vote
3
answers
112
views
Grep by all filenames in a directory
I want to get the process status for all services running in a given directory. Right now I can check one by one ps -ef | grep ServiceName. But is there a way to ls the directory and ps every service? ...
3
votes
2
answers
432
views
Diffrent output of "ps -a" on Ubuntu and Fedora
I have noticed that the ps -a command produces different output when I run it on ubuntu "16.04" and Fedora 23. According the man page of both distribution the -a option should do :
-a Select all ...
-3
votes
2
answers
246
views
I need help building a regex for a grep to show only the path to running versions of java
I need help building a grep from ps -ef to return only java paths.
Say we have the following runnning process:
bash> ps -ef | grep java
user pid# 1 1 00:00 ? 00:04:00 /path/to/java/...
5
votes
1
answer
4k
views
What's the equivalent of top -H -p <pid> on OS X?
I need to monitor the CPU usage of threads created by a given process.
In *nix one can use top -H -p <pid>, but that not available in OS X.
An equivalent of ps -eLo pid,ppid,lwp,nlwp,osz,rss,...
1
vote
0
answers
903
views
Many cron -f processes on unresponsive server
My Debian server had again become unresponsive and needed to be restartet (SSH login impossible, no longer transmitted log data to another server's MySQL Database, no new FTP connections possible, but ...
0
votes
0
answers
412
views
Is it possible to disable many of the default/built-in services from Mac OS X?
Looking to remove some builtin services from Mac OS X to make it into a more platable pentesting platform.
For example, services like iTunes, Airplay, etc…
I ran a ps on the command line and I see ...
6
votes
4
answers
15k
views
Can’t get Nginx to work on port 80. Works fine on any other port
I’ve just setup Homebrew’s Nginx on Mac OS X 10.11 (El Capitan).
If I set my Ngnix config like this:
listen 127.0.0.1:8080;
listen 127.0.0.1:81;
listen 127.0.0.1:75;
It’ll work. ...
3
votes
2
answers
3k
views
List linux processes having windows
How can I list linux processes (like ps aux) but only those having X11 windows?
I guess there must be some simple connection (like always in linux) between the processes and the X server. Is it ...
0
votes
0
answers
555
views
Is it ok to kill the sh zombie process?
sh process is zombie but
i have doubts killing it in case it will affect the parent crond(31720), since it's in an enterprise server.
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME ...
11
votes
1
answer
23k
views
How to get stdout of a "lost" session
I don't well what's the name of the situation, I think yesterday I closed a session with a background ipython process, but I am still able to connect to it (the process is running a web server and I ...
3
votes
2
answers
463
views
DD command running for over 17 hours on external 1.5TB drive
I used dd with nohup to erase a 1.5TB disk and now I can't get feedback from the progress.. Since it's been more than 17 hours I am worried...
I ran the command with the disk unmounted.
The disk is ...
0
votes
0
answers
51
views
Listing specific software on group of remote machine
psinfo -s \10.101.4.204 > out.txt
above command displays all software installed on 10.101.4.204
I need to find only specific software installed on remote machine
2
votes
2
answers
4k
views
What is the difference between the processes listed by `ps` and `ps -A`?
What is the difference between the processes listed by ps and ps -A ?
0
votes
1
answer
1k
views
Output of the ps command and understanding the flags
Ubuntu 12.04 LTS using bash.
I tried running the ps command from a Java program using the Runtime and got some unexpected output.
Upon closer inspection I realized that it was the output of:
ps --...
1
vote
1
answer
5k
views
what does CPU% means in `ps auxf` for processes with parent/child relationship?
When I use ps auxf to display process information with ASCII art process hierarchy. Processes with parent/child relation is listed as below.
USER PID %CPU %MEM VSZ RSS TTY STAT START ...