pstree – display a tree of processes

pstree -npu -n Sort processes with the same ancestor by PID instead of by name. (Numeric sort.)
-p Show PIDs. PIDs are shown as decimal numbers in parentheses after each process name.
-p implicitly disables compaction.
-u Show uid transitions. Whenever the uid of a process differs from the uid of its parent, the
new uid is shown in parentheses after the process name.
pstree -npuh -h Highlight the current process and its ancestors. This is a no-op if the terminal doesn’t support
highlighting or if neither the current process nor any of its ancestors are in the subtree being
pstree -npuH 2476 -H Like -h, but highlight the specified process instead.
Unlike with -h, pstree fails when using -H if highlighting is not available.
# ---------------------------------------------------------
# ---    : The basic syntax is as follows:
# OR
pstree pid
# OR
pstree user
# OR
pstree [options] pid|user
# ---------------------------------------------------------