Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [top]

A command-line system monitor tool that produces a frequently-updated list of processes.

0
votes
1answer
12 views

top command, why such a big difference between VIRT and RES, while swap is 0?

I've read some posts that says a process's VIRT = RES + SWAP. But look at the screenshot below, the whole system's Swap is 0 (0 used). So I expect each process's VIRT at least ≈ RES. But as you can ...
0
votes
0answers
27 views

Cmd to check pids used by particular cpu's

In our environment we have applications running in servers with 0-3( total 4 cpu's). While seeing 'top' command and choosing 1 option, able to see 4 cpu's ( example: a server has 4 cpu's). In this ...
2
votes
1answer
33 views

User not listed in /etc/passwd

As far as I thought, the list of users for my system can be printed in the terminal with: sed 's/\([^:]*\).*/\1/' /etc/passwd But I have noticed that when I use top In the USER column, my user ...
1
vote
2answers
64 views

Top-like command configurable from command line

For Ubuntu Bionic, is there a tool that will, like top, show various data on processes and refresh automatically, but can be configured from the command line to specify what data (columns) to show?
3
votes
2answers
76 views

differences between `top` and `system-monitor`

I noticed a difference in CPU percentage between two utility: top and gnome-sytem-monitor (but the same happens with htop...) The screenshot shows the issue. You can see as first item both is the ...
3
votes
2answers
60 views

Output redirection is not working with top piped to grep

When I run this command in Linux: $ top -b -d 20 | grep "load average" -A 20 > top.log top.log is always empty. But when I run this command: $ top -b -d 20 | grep "load average" -A 20 | tee top....
0
votes
1answer
48 views

What is the meaning of the R/D flag in ps output?

What is the meaning of R / D from ps ax? Does it indicate a problem? 3 ? R 522:45 [ksoftirqd/0] 4380 ? Rl 1240:31 gdm-session-worker [pam/gdm-launch-environment] 5938 ? ...
0
votes
1answer
22 views

How to format automatically top output for logging?

Currently my top command output is shown as: 14861 root 20 0 0.252t 0.028t 556 S 13.3 92.8 8:45.64 I want the display of this in m. It is presently showing in t. I am getting the above ...
0
votes
0answers
43 views

CPU core is very busy and top shows 0.0 %CPU on it

This Ubuntu server is booted with CPU isolation isolcpus=0-7, so 8 cores from 16 are reserved and the only processes that use them are numbered as worker_0 - worker_7. As can be see by top's per CPU ...
0
votes
2answers
126 views

uptime + cpu load average [closed]

we have the follwing CPU details more lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 32 On-line CPU(s) list: 0-...
1
vote
0answers
136 views

multi-core CPU usage

I am using the Windows Subsystem for Linux (WSL). Recently, I've been wanting to get better insight in the CPU usage of processes, but I am getting well confused. I am on a computer with 2 cores and ...
0
votes
0answers
153 views

How to display `top` results sorted by memory usage by a process in KB/MB?

I have known about top command. When I using this command, I got only the memory usage of a process in terms of PERCENTAGE(%MEM) only. Is there any option to get the memory details in terms of Bytes(...
1
vote
2answers
70 views

How can I get CPU overall usage and individual core usage information just once?

Is there a command which can show CPU usage information (both for overall cpu and for individual cores), in a static way (i.e. just once) similar to how free shows memory usage information? When we ...
1
vote
1answer
70 views

How to analyze top command results: CPU & RAM consumption

I am working on ARM-based processor (OS version: Linux 3.4.35) and I need to analyze the processor's performance while some processes are running, by typing top command, I can see some statistics but ...
1
vote
0answers
141 views

htop / top with specifying process name filter on the command line - at program startup?

I'm on Ubuntu 18.04. I'm already aware that I can start htop, and then hit F4 for filter, then type or paste a process name search query (say, gphoto2 for looking for gvfs-gphoto2-volume-monitor....
1
vote
3answers
83 views

How to remove the summary at the beginning of the “top” command in Linux?

I used top -b -n 2 | awk '{if ($9 != 0.0) print $0,sed -n '8,20p'}'>>text.txt , then the output is : top - 16:24:42 up 3:49, 3 users, load average: 0.23, 0.29, 0.31 Threads: 503 total, 2 ...
0
votes
2answers
63 views

Filtering processes with top in FreeBSD

➥ When using top utility to view processes and their activity, how does one filter the list to a subset by name? For example when I want to see only the processes with a name containing postgres or ...
0
votes
0answers
33 views

How to list all NEW running processes? [duplicate]

How to do something like akin to "tail -f" on ps ? In other words I would like to see the list of newly created processes, as they get created. I don't think top/htop can to that. Bonus if it shows ...
1
vote
1answer
124 views

Why is top command showing users that the who command is not?

Working on a Raspberry Pi 2, running Raspbian GNU/Linux 9 (stretch). I am simply trying to understand why, when I run the top command I can see some users that I cannot see in the who command. Here ...
0
votes
1answer
40 views

How to record PID and its command every 15s?

For troubleshooting purpose, I'd like to record PID and its command every 15s and write them to a text file. The desired output: TimeStamp, PID, Command
1
vote
2answers
54 views

Exclude chrome/firefox from top command output

How can I exclude Chrome/Firefox processes from top command output? It's just too messy with them in there, and it isn't important for me to see them there.
3
votes
1answer
464 views

Top showing virtual memory usage of hundreds of gigabytes

On a new virtual machine, top shows that a process of mine consumes 100 GB of virtual memory. I've read that it's possible because of overcommit, however, it's a bit too much. I've never seen anything ...
0
votes
1answer
38 views

Why are “program images and shared libraries” “considered private to a process” but “shared (SHR) by the kernel”?

In the manpage of top, Why are "program images and shared libraries" in #3 "considered private to a process", if "they will be accounted for as shared (SHR) by the kernel"? In what "private" sense ...
0
votes
1answer
133 views

What is the difference between USED and VIRT?

In the manpage of top, What is the difference between USED and VIRT? USED is "RES" + "SWAP". Is "VIRT - USED" equal to pages that have been mapped but not used? Does "VIRT" or "USED" include the ...
1
vote
1answer
172 views

Appearance of plus (+) in top output

This is the output of my top command. Tasks: 633 total, 1 running, 380 sleeping, 0 stopped, 0 zombie %Cpu(s): 9.9 us, 1.1 sy, 0.0 ni, 65.1 id, 23.9 wa, 0.0 hi, 0.0 si, 0.0 st KiB Mem : ...
1
vote
1answer
38 views

What does the CPU consumption in top mean when a CPU is assigned to a single process?

Being on Linux I have "CPUAffinity= 0 1 3" set in system.conf. I also use "taskset -cp 2 $pid" to assign a CPU to a single process. But what does the CPU consumption for the process in top now mean? ...
2
votes
0answers
31 views

Incorrect Top? or manpage?

According to top's manpage: 16. PR -- Priority The scheduling priority of the task. If you see `rt' in this field, it means the task is running under real time scheduling priority. ...
0
votes
0answers
246 views

How to remove 'top' command's header?

I have top as above, and would like to remove header. I tried to look into its sourcecode but can't find what should be changed to remove its header, trying to modify and create a patch. Thanks in ...
1
vote
0answers
55 views

Why is the output of top command not the same as /proc?

Sometimes I see the output of top output like this But when I try to access /proc, it gives me different information, like this Why do I see different session ID from top and /proc?
11
votes
2answers
925 views

Cursor disappears when running `top -n1 | head`

When running top -n1 | head the terminal's cursor disappears. Running top -n1 brings it back. Tested in gnome-terminal and tilix in Ubuntu 16.04 and CentOS 7.5. Running top -n1 | tail doesn't have ...
2
votes
1answer
49 views

How to add pids at runtime to a top command?

I am trying to monitor a certain process with top command and have launched top with top -p <pid1> The process quits after some operations and I relaunch the process. This time the process ...
0
votes
1answer
88 views

can we View the contents of the atop log files that sent from remote machine on local machine

on remote machine we have the following atop files ls -l /var/log/atop/ total 1634632 -rw-r--r-- 1 root root 127992086 Aug 30 01:49 atop_20180829 -rw-r--r-- 1 root root 262277153 Aug 31 00:00 ...
1
vote
1answer
896 views

how auto-rotate atop logs

we can see that atop logs are created on each day and that take a lot of space ls -l /var/log/atop/ total 1634632 -rw-r--r-- 1 root root 127992086 Aug 30 01:49 atop_20180829 -rw-r--r-- 1 root root ...
2
votes
1answer
45 views

Filter top(1) display by COMMAND=abc OR COMMAND=xyz

I'm experimenting with the top(1) program, and I'm trying to figure out how to display only specified program names. For example, if I invoke a command line like $ ssh localhost sleep 15 I'd like to ...
-1
votes
1answer
535 views

How to kill a process in a top?

Unlike htop -- top is more difficult for me and I would to know how to kill any process in top ? Thank in advance my Stackoverflow friends !
1
vote
1answer
203 views

Not able to exit from interactive mode for yarn top command

I have a bash script which is on serverA. This script will ssh to serverB and runs yarn top command, pulls the metrics and put into the file(test.txt) on serverA. Below is the command which I am using:...
3
votes
4answers
1k views

Converting awk printf string to decimal

Task: stdout the load avg from top in a decimal form like (e.g 0.23) Details: I need to parse this script to Chef's inspec and check if its result is bigger/smaller than something, for example: ...
1
vote
1answer
70 views

How to deny other people to see my running details after “top” command and press key “c”

In my school, we share one server to run programs. Using top we can see the situation of the server, if press key c, we even can see the command details, somehow including my lab data information. ...
2
votes
1answer
301 views

Htop sorting CPU% column incorrectly

Sometimes when I'm trying to diagnose what process is hogging all of my laptop's resources, I notice that htop will sort the CPU% column incorrectly. Example below: The “CPU%” column is highlighted ...
0
votes
1answer
344 views

monitor multiple users with top

Is it possible to monitor processes of multiple (but not all) users in Linux top? Something of this kind: top -u user1 -u user2 Thank you for your help!
1
vote
1answer
275 views

Centos - top takes 100% cpu

I have a CentOS server where I'm running the top command, I can see that the process top utilize 100% CPU.
0
votes
0answers
95 views

Why does htop start so quickly?

I tried to read info about processes from /proc/ just like htop and top do. It seems like the value for "CPU%" in htop or top is calculated by summing up the values utime and stime in the stat file ...
-1
votes
1answer
4k views

The “free” command does not display the correct values

We have a very strange issue on one of our machine redhat 7.2. How it can be free - 0 , while used is 43 from total 47? [root@master ~]# free -g total used free ...
0
votes
1answer
154 views

Why does top's CPU breakdown (option 1) in default non-irix mode show conflicting results?

I'm running some benchmarks on various forks of bitcoind and I noticed some conflicting values when running top. In the screenshot below, there is an even spread of ~30% cpu utilization across each ...
0
votes
1answer
341 views

Is it possible to calculate CPU utilization from load average & top CPU% column

I have a file which contains 2 output of uptime load average & CPU% column like an output from top command. So, is it possible to calculate it into CPU utilization or CPU usage at a time? ...
4
votes
1answer
297 views

Linux - Extracting Tar dramatically slows down server

I have a web server (specs below) with 12 TB of storage. I am moving massive amounts of csv files packaged in TAR's to the server, then extracting on the server. The problem is that when extracting ...
2
votes
1answer
81 views

I in the process status coloumn in top and total tasks > sleeping+running tasks

I ran top in kali linux 2018.1 and was unable to figure out a few things. What does I stands for in the process status coloumn. I know about R,S,D,K,T and Z but don't have any idea about I. Also ...
2
votes
1answer
199 views

Why is ps -u command not working?

When I use the 'top' command I get 10366 mithus 25 0 11120 1044 884 R 99.9 0.0 67:14.35 gm when I start a process using nohup ./gm &. showing that a process 'gm' is running. ...
3
votes
1answer
142 views

How can I show the full process name in iotop?

I am using iotop to see which processes are reading from the disk. The process name column is small and some of the names are truncated: gvfsd-tra~ec_spaw/1 gnome-sof~n-service gnome-key~1,secrets ...
0
votes
1answer
376 views

Meaning of the swap part in the top command

Do you know in which unit the swap column is display in the top output? According with top documentation it is in KB, but please take a look in the below image. What means g or m next to the swap ...