Hot answers tagged

325 votes

How to kill all tmux sessions (or at least multiple sessions) from the CLI?

You can use tmux kill-server to cleanly and gracefully kill all tmux open sessions (and server). If you are inside a tmux session you would like to keep, use tmux kill-session -a to close all other ...
dgonzalez's user avatar
  • 6,980
95 votes
Accepted

How to see detailed information about a given PID?

ps -Flww -p THE_PID will show you some information. See the ps manpage for more information about the ps command. The "STANDARD FORMAT SPECIFIERS" section explains what the different columns mean.
Florian Diesch's user avatar
80 votes
Accepted

How to fix processing with runit and git-daemon-run

I was having a similar problem after I recently upgraded to Ubuntu 16.04. I found this answer and Jonathan's purge and reinstall commands took care of it for me. Hope this helps. sudo apt-get purge ...
Gnormous's user avatar
  • 924
57 votes
Accepted

How to stop a bash while loop running in the background?

I started while true; do yad; sleep 60; done & and closed the terminal to test it, now I got the same problem. If you already closed the terminal you've started the loop in Let's get an ...
dessert's user avatar
  • 40k
56 votes

How can I kill a process with a phrase in its name?

If myName is the name of the process/executable which you want to kill, you can use: pkill myName pkill by default sends the SIGTERM signal (signal 15). If you want the SIGKILL or signal 9, use: ...
Ron's user avatar
  • 20.6k
52 votes
Accepted

Tracker process taking lot of CPU

Tracker, which is enabled by default in Ubuntu since 19.10, is a file metadata indexer. It indexes your files to allow for fast searching for content in files from Files or Gnome Documents, find ...
vanadium's user avatar
  • 87.7k
47 votes
Accepted

upowerd hogging CPU while iPhone is connected

From @JonasCz, whose comment was: Do you happen to have an iPhone plugged into your computer ? If so, you may need to select "Trust this computer" on the phone (or disconnect it), which may fix ...
j0h's user avatar
  • 14.8k
42 votes

How do I get the parent process ID of a given child process?

Using only shell variable to get parent PID : echo $PPID if you need the command from this parent pid: cat /proc/$PPID/comm if you need the full command line (with all options): cat /proc/$PPID/...
Gilles Quénot's user avatar
33 votes

Bring nohup job to foreground

nohup does not disconnect a command from terminal, it makes your script ignore SIGHUP, and redirects stdout/stderr to a file nohup.out, so that the command can continue running in the background after ...
sourav c.'s user avatar
  • 44.6k
33 votes

Process 'niceness' vs. 'priority'

Short Answer PR is the priority level. The lower the PR, the higher the priority of the process will be. PR is calculated as follows: for normal processes: PR = 20 + NI (NI is nice and ranges from -...
Agustin Barrachina's user avatar
30 votes
Accepted

How to see thread name in htop?

F2 → Display options → Show custom thread names https://stackoverflow.com/questions/4461289/change-thread-name-on-linux-htop
Murphy's user avatar
  • 1,677
27 votes

What should I do when I get 'There are stopped jobs' error?

You got the message, because system warns you about active jobs associated with your current shell. You can list these running/stopped jobs by running: jobs, Then you can do one of the following: ...
kenorb's user avatar
  • 10.3k
27 votes

How to kill all tmux sessions (or at least multiple sessions) from the CLI?

This would list and kill all the sessions: tmux list-sessions | awk 'BEGIN{FS=":"}{print $1}' | \ ifne xargs -n 1 tmux kill-session -t
Sebastian Dahlgren's user avatar
25 votes

In System monitor, what is the difference between Kill Process and End Process?

I was curious too, so I just browsed through the source code and found the below in application.cpp. There is more to this code but I think these correlate to the options, at least for System Monitor ...
Elijah Lynn's user avatar
  • 3,828
25 votes
Accepted

Process status of S+ S S< Sl

When in doubt, check the manpage. From the command man ps: PROCESS STATE CODES Here are the different values that the s, stat and state output specifiers (header "STAT" or "S") will ...
Terrance's user avatar
  • 41.5k
24 votes

How to see detailed information about a given PID?

I don't know what is your exact requirement. but this may help you. There is separate directory for every process with name as pid number in /proc . ps -ef | grep docker root 1700 1 0 ...
pl_rock's user avatar
  • 11.2k
23 votes
Accepted

How can I hibernate a running application?

You can use the killall command to send a SIGSTOP signal to all processes matching a given name to freeze them and later send SIGCONT the same way to thaw them again. First find out the process name ...
Byte Commander's user avatar
  • 107k
23 votes

Firefox: "isolate+" process CPU usage 100%

About isolate+ Assuming you are seeing this in the top command interactive screen output in the terminal, the + sign means the string is shortened to fit in the current terminal window ... Expanding/...
Raffa's user avatar
  • 31.9k
22 votes

What process of Google Chrome to kill to close window from terminal?

You can stop all of them with a single command: sudo killall chrome Then to prevent it from doinng this in the future, go into Settings, pick Advanced, and near the bottom you will find a switch ...
SDsolar's user avatar
  • 3,169
22 votes
Accepted

Easy way to get process information from a window

If you can use Terminal, try this: xprop | grep WM_CLASS and your cursor should turn into cross allowing you to click on any window to get its process name. If you just need the PID, try: xprop | ...
Abhishek Nair's user avatar
21 votes
Accepted

htop displays identical program in multiple lines

The duplicated lines are threads of a single process. You can recognize them by the different color in the command column (if you have configured that in Setup > Display options > Display threads in a ...
Melebius's user avatar
  • 11.4k
20 votes

What is a <defunct> process, and why doesn't it get killed?

expanding on Paddington's answer.. From your output we see a defunct, which means this child process has either completed its task or has been corrupted or killed. Its parent process is still running ...
Kevin's user avatar
  • 992
20 votes
Accepted

How do I tell if a command is running or waiting for user input?

There's several approaches: Try signalling end of input:Without superuser privileges it is hard to know what is going on underneath the hood. What can be done is to press Ctrl+d. Terminals and ...
Sergiy Kolodyazhnyy's user avatar
19 votes

bioset process - what is its function?

It's part of the kernel block IO: https://lwn.net/Articles/26404/ Those bioset threads specifically are part of some recovery system. https://github.com/torvalds/linux/blob/...
Colin Godsey's user avatar
19 votes

What is the difference between cat /etc/services and service --status-all?

The contents of /etc/services do not actually correspond to the services on your system. That file is actually a mapping of ports to the services that usually use them (say, port 22 by SSH). It's used ...
muru's user avatar
  • 197k
19 votes

Check memory usage of process which exits immediately

A popular framework for memory profiling is Valgrind (available from the Ubuntu main repository). In particular, you could use its massif heap profiling tool. For example, given a minimal C program: #...
steeldriver's user avatar
18 votes

How to stop mysqld process?

/etc/init.d/mysql stop service mysql stop killall -KILL mysql mysqld_safe mysqld When you see the following information, you success mysql: no process found mysqld_safe: no process found mysqld: no ...
Charlie's user avatar
  • 181
17 votes

How do I get the parent process ID of a given child process?

Using pstree by command name Using pstree you can search by the child process name and get the Process ID (PID) along with the parents, grandparents and any children of the child process: $ pstree -hp ...
WinEunuuchs2Unix's user avatar
17 votes

Can't disable redshift

You can now use redshift -x to reset everything: -x Reset mode (remove adjustment from screen).
exhume-to-consume's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible