2 Formatting terminal output appropriately.
source | link

Try #ps -aef --forest

oot 114032 1170 0 Apr05 ? 00:00:00 _ sshd: root@pts/4 root 114039 114032 0 Apr05 pts/4 00:00:00 | _ -bash root 56225 114039 0 13:47 pts/4 00:00:16 | _ top root 114034 1170 0 Apr05 ? 00:00:00 _ sshd: root@notty root 114036 114034 0 Apr05 ? 00:00:00 | _ /usr/libexec/openssh/sftp-server root 103102 1170 0 Apr06 ? 00:00:03 _ sshd: root@pts/0 root 103155 103102 0 Apr06 pts/0 00:00:00 | _ -bash root 106798 103155 0 Apr06 pts/0 00:00:00 | _ su - postgres postgres 106799 106798 0 Apr06 pts/0 00:00:00 | _ -bash postgres 60959 106799 0 14:39 pts/0 00:00:00 | _ ps -aef --forest postgres 60960 106799 0 14:39 pts/0 00:00:00 | _ more

# ps -aef --forest
root     114032   1170  0 Apr05 ?        00:00:00  \_ sshd: root@pts/4
root     114039 114032  0 Apr05 pts/4    00:00:00  |   \_ -bash
root      56225 114039  0 13:47 pts/4    00:00:16  |       \_ top
root     114034   1170  0 Apr05 ?        00:00:00  \_ sshd: root@notty
root     114036 114034  0 Apr05 ?        00:00:00  |   \_ /usr/libexec/openssh/sftp-server
root     103102   1170  0 Apr06 ?        00:00:03  \_ sshd: root@pts/0
root     103155 103102  0 Apr06 pts/0    00:00:00  |   \_ -bash
root     106798 103155  0 Apr06 pts/0    00:00:00  |       \_ su - postgres
postgres 106799 106798  0 Apr06 pts/0    00:00:00  |           \_ -bash
postgres  60959 106799  0 14:39 pts/0    00:00:00  |               \_ ps -aef --forest
postgres  60960 106799  0 14:39 pts/0    00:00:00  |               \_ more

Try #ps -aef --forest

oot 114032 1170 0 Apr05 ? 00:00:00 _ sshd: root@pts/4 root 114039 114032 0 Apr05 pts/4 00:00:00 | _ -bash root 56225 114039 0 13:47 pts/4 00:00:16 | _ top root 114034 1170 0 Apr05 ? 00:00:00 _ sshd: root@notty root 114036 114034 0 Apr05 ? 00:00:00 | _ /usr/libexec/openssh/sftp-server root 103102 1170 0 Apr06 ? 00:00:03 _ sshd: root@pts/0 root 103155 103102 0 Apr06 pts/0 00:00:00 | _ -bash root 106798 103155 0 Apr06 pts/0 00:00:00 | _ su - postgres postgres 106799 106798 0 Apr06 pts/0 00:00:00 | _ -bash postgres 60959 106799 0 14:39 pts/0 00:00:00 | _ ps -aef --forest postgres 60960 106799 0 14:39 pts/0 00:00:00 | _ more

Try

# ps -aef --forest
root     114032   1170  0 Apr05 ?        00:00:00  \_ sshd: root@pts/4
root     114039 114032  0 Apr05 pts/4    00:00:00  |   \_ -bash
root      56225 114039  0 13:47 pts/4    00:00:16  |       \_ top
root     114034   1170  0 Apr05 ?        00:00:00  \_ sshd: root@notty
root     114036 114034  0 Apr05 ?        00:00:00  |   \_ /usr/libexec/openssh/sftp-server
root     103102   1170  0 Apr06 ?        00:00:03  \_ sshd: root@pts/0
root     103155 103102  0 Apr06 pts/0    00:00:00  |   \_ -bash
root     106798 103155  0 Apr06 pts/0    00:00:00  |       \_ su - postgres
postgres 106799 106798  0 Apr06 pts/0    00:00:00  |           \_ -bash
postgres  60959 106799  0 14:39 pts/0    00:00:00  |               \_ ps -aef --forest
postgres  60960 106799  0 14:39 pts/0    00:00:00  |               \_ more
1
source | link

Try #ps -aef --forest

oot 114032 1170 0 Apr05 ? 00:00:00 _ sshd: root@pts/4 root 114039 114032 0 Apr05 pts/4 00:00:00 | _ -bash root 56225 114039 0 13:47 pts/4 00:00:16 | _ top root 114034 1170 0 Apr05 ? 00:00:00 _ sshd: root@notty root 114036 114034 0 Apr05 ? 00:00:00 | _ /usr/libexec/openssh/sftp-server root 103102 1170 0 Apr06 ? 00:00:03 _ sshd: root@pts/0 root 103155 103102 0 Apr06 pts/0 00:00:00 | _ -bash root 106798 103155 0 Apr06 pts/0 00:00:00 | _ su - postgres postgres 106799 106798 0 Apr06 pts/0 00:00:00 | _ -bash postgres 60959 106799 0 14:39 pts/0 00:00:00 | _ ps -aef --forest postgres 60960 106799 0 14:39 pts/0 00:00:00 | _ more