root@user:/home/user# netstat -lnp | grep tcp
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 665/mysqld
tcp 0 0 0.0.0.0:2222 0.0.0.0:* LISTEN 817/sshd
tcp6 0 0 :::2222 :::* LISTEN 817/sshd
root@user:/home/user# ps -cafew
UID PID PPID CLS PRI STIME TTY TIME CMD
root 1 0 TS 19 Jul23 ? 00:00:01 /sbin/init
root 2 0 TS 19 Jul23 ? 00:00:00 [kthreadd]
root 3 2 TS 19 Jul23 ? 00:00:00 [ksoftirqd/0]
root 5 2 TS 19 Jul23 ? 00:00:00 [kworker/u:0]
root 6 2 FF 139 Jul23 ? 00:00:00 [migration/0]
root 7 2 TS 39 Jul23 ? 00:00:00 [cpuset]
root 8 2 TS 39 Jul23 ? 00:00:00 [khelper]
root 9 2 TS 39 Jul23 ? 00:00:00 [netns]
root 10 2 TS 19 Jul23 ? 00:00:00 [sync_supers]
root 11 2 TS 19 Jul23 ? 00:00:00 [bdi-default]
root 12 2 TS 39 Jul23 ? 00:00:00 [kintegrityd]
root 13 2 TS 39 Jul23 ? 00:00:00 [kblockd]
root 14 2 TS 39 Jul23 ? 00:00:00 [kacpid]
root 15 2 TS 39 Jul23 ? 00:00:00 [kacpi_notify]
root 16 2 TS 39 Jul23 ? 00:00:00 [kacpi_hotplug]
root 17 2 TS 39 Jul23 ? 00:00:00 [ata_sff]
root 18 2 TS 19 Jul23 ? 00:00:00 [khubd]
root 19 2 TS 39 Jul23 ? 00:00:00 [md]
root 21 2 TS 19 Jul23 ? 00:00:47 [kworker/0:1]
root 22 2 TS 19 Jul23 ? 00:00:00 [khungtaskd]
root 23 2 TS 19 Jul23 ? 00:00:00 [kswapd0]
root 24 2 TS 14 Jul23 ? 00:00:00 [ksmd]
root 25 2 TS 19 Jul23 ? 00:00:00 [fsnotify_mark]
root 26 2 TS 39 Jul23 ? 00:00:00 [aio]
root 27 2 TS 19 Jul23 ? 00:00:00 [ecryptfs-kthrea]
root 28 2 TS 39 Jul23 ? 00:00:00 [crypto]
root 32 2 TS 39 Jul23 ? 00:00:00 [kthrotld]
root 34 2 TS 19 Jul23 ? 00:00:00 [scsi_eh_0]
root 35 2 TS 19 Jul23 ? 00:00:00 [scsi_eh_1]
root 36 2 TS 19 Jul23 ? 00:00:00 [kworker/u:3]
root 38 2 TS 39 Jul23 ? 00:00:00 [kmpathd]
root 39 2 TS 39 Jul23 ? 00:00:00 [kmpath_handlerd]
root 40 2 TS 39 Jul23 ? 00:00:00 [kondemand]
root 41 2 TS 39 Jul23 ? 00:00:00 [kconservative]
root 219 2 TS 19 Jul23 ? 00:02:18 [jbd2/sda1-8]
root 220 2 TS 39 Jul23 ? 00:00:00 [ext4-dio-unwrit]
root 268 1 TS 19 Jul23 ? 00:00:00 upstart-udev-bridge --daemon
root 277 1 TS 23 Jul23 ? 00:00:00 udevd --daemon
syslog 364 1 TS 19 Jul23 ? 00:00:45 rsyslogd -c4
root 368 277 TS 21 Jul23 ? 00:00:00 udevd --daemon
root 369 277 TS 21 Jul23 ? 00:00:00 udevd --daemon
root 571 1 TS 19 Jul23 ? 00:00:00 upstart-socket-bridge --daemon
root 609 1 TS 19 Jul23 tty4 00:00:00 /sbin/getty -8 38400 tty4
root 612 1 TS 19 Jul23 tty5 00:00:00 /sbin/getty -8 38400 tty5
root 619 1 TS 19 Jul23 tty2 00:00:00 /sbin/getty -8 38400 tty2
root 623 1 TS 19 Jul23 tty3 00:00:00 /sbin/getty -8 38400 tty3
root 630 1 TS 19 Jul23 tty6 00:00:00 /sbin/getty -8 38400 tty6
root 641 1 TS 19 Jul23 ? 00:00:00 cron
daemon 642 1 TS 19 Jul23 ? 00:00:00 atd
mysql 665 1 TS 19 Jul23 ? 00:53:24 /usr/sbin/mysqld
root 728 1 TS 19 Jul23 tty1 00:00:00 /sbin/getty -8 38400 tty1
root 764 1 TS 19 Jul23 ? 00:00:00 dhclient3 -e IF_METRIC=100 -pf /var/run/dhclient.eth0.pid -lf /var/lib/dhcp3/dh
root 817 1 TS 19 Jul23 ? 00:00:00 /usr/sbin/sshd -D
root 839 2 TS 19 Jul23 ? 00:00:01 [flush-8:0]
root 841 2 TS 39 Jul23 ? 00:00:00 [kdmflush]
root 867 2 TS 39 Jul23 ? 00:00:00 [kcryptd_io]
root 868 2 TS 39 Jul23 ? 00:00:00 [kcryptd]
root 878 2 TS 19 Jul23 ? 00:00:40 [kworker/0:2]
root 2187 817 TS 19 11:20 ? 00:00:00 sshd: user [priv]
user 2206 2187 TS 19 11:21 ? 00:00:00 sshd: user@pts/0
user 2207 2206 TS 19 11:21 pts/0 00:00:01 -bash
root 2307 2207 TS 19 11:21 pts/0 00:00:00 su
root 2308 2307 TS 19 11:21 pts/0 00:00:00 bash
root 2361 2308 TS 19 11:26 pts/0 00:00:00 ps -cafew