Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What do the curly braces around a process in pstree mean?

Tags:

unix

pstree

The man page does explain what the bracket-braces means (it refers to threads), but I'm wondering what just the braces means.

From this here I can see that auditd and node are like this.

❯ pstree
init─┬─agetty
     ├─atd
     ├─auditd───{auditd}
     ├─crond
     ├─dbus-daemon
     ├─dhclient
     ├─6*[mingetty]
     ├─ntpd
     ├─rsyslogd───3*[{rsyslogd}]
     ├─2*[sendmail]
     ├─sshd─┬─sshd───sshd───zsh───tmux
     │      └─sshd───sshd───zsh───man───sh───sh───less
     ├─tmux─┬─2*[zsh]
     │      ├─zsh───node───{node}
     │      └─zsh───pstree
     └─udevd───2*[udevd]

My current best guess is that it means they are blocked on input.

like image 739
Steven Lu Avatar asked Apr 04 '13 04:04

Steven Lu


1 Answers

n*[{name}] means group of the n threads. If there is only one thread, pstree use {name}

{auditd} <=> 1*[{auditd}]

For group of threads, pstree use n*[{name}]:

├─rsyslogd───3*[{rsyslogd}]

equipvalent to:

├─rsyslogd─┬─{rsyslogd}
           ├─{rsyslogd}
           └─{rsyslogd}

use command "pstree -a" to see the different.

like image 85
damphat Avatar answered Oct 16 '22 10:10

damphat