COMMAND LINE KUNG FU

Lệnh xem các tiến trình đang chạy trên Linux

868
author Bùi Tấn Việt - 2022-07-11 11:33:52 (GMT+7)

Lệnh ps giúp bạn xem các tiến trình (proccess) đang chạy trên Linux

bash (root)
ps -aufx
Kết quả
USER         PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root           1  0.0  0.0 191356  4340 ?        Ss   Apr20  39:37 /usr/lib/systemd/systemd --switched-root --system --deserialize 22
root           2  0.0  0.0      0     0 ?        S    Apr20   0:03 [kthreadd]
root           3  0.0  0.0      0     0 ?        S    Apr20   5:05  \_ [ksoftirqd/0]
root           5  0.0  0.0      0     0 ?        S<   Apr20   0:00  \_ [kworker/0:0H]
root           7  0.0  0.0      0     0 ?        S    Apr20   0:30  \_ [migration/0]
root           8  0.0  0.0      0     0 ?        S    Apr20   0:00  \_ [rcu_bh]
root           9  0.0  0.0      0     0 ?        S    Apr20  66:35  \_ [rcu_sched]
root          10  0.0  0.0      0     0 ?        S<   Apr20   0:00  \_ [lru-add-drain]
root          11  0.0  0.0      0     0 ?        S    Apr20   0:55  \_ [watchdog/0]
root        1018  0.0  0.0 110204   860 tty1     Ss+  Apr20   0:00 /sbin/agetty --noclear tty1 linux
root        1020  0.0  0.0 110204   868 ttyS0    Ss+  Apr20   0:00 /sbin/agetty --keep-baud 115200,38400,9600 ttyS0 vt220
root        1024  0.0  0.0  46036  2512 ?        Ss   Apr20   0:00 unit: main v1.26.1 [/usr/sbin/unitd --log /var/log/unit/unit.log --pid /var/run/unit/unit.pid --no-daemon]
nginx_u+    1158  0.0  0.0  46036  1160 ?        S    Apr20   0:00  \_ unit: controller
nginx_u+    1159  0.0  0.0 343956  2284 ?        Sl   Apr20   0:00  \_ unit: router
root        1031  0.0  0.0  53112  2688 ?        Ss   Apr20   0:16 /usr/sbin/dovecot -F
dovecot     1182  0.0  0.0  10436  1328 ?        S    Apr20   0:04  \_ dovecot/anvil [37 connections]
dovecot   561866  0.0  0.0  46620  3508 ?        S    Jun02   0:00  \_ dovecot/managesieve-login
root      561868  0.0  0.0  50032  3936 ?        S    Jun02   0:00  \_ dovecot/lmtp -L
root      561870  0.0  0.0  10436  1536 ?        S    Jun02   0:02  \_ dovecot/log
root      561922  0.0  0.0  50032  3940 ?        S    Jun02   0:00  \_ dovecot/lmtp -L
dovecot   561923  0.0  0.0  46620  3508 ?        S    Jun02   0:00  \_ dovecot/managesieve-login
dovecot   561924  0.0  0.0  46620  3508 ?        S    Jun02   0:00  \_ dovecot/managesieve-login
dovecot   561925  0.0  0.0  46620  3512 ?        S    Jun02   0:00  \_ dovecot/managesieve-login
root      561929  0.0  0.0  27284  3372 ?        S    Jun02   0:01  \_ dovecot/auth [0 wait, 0 passdb, 0 userdb]
dovecot   455303  0.0  0.0  46604  3512 ?        S    Jul10   0:00  \_ dovecot/pop3-login
dovecot   796129  0.0  0.0  46612  3516 ?        S    08:46   0:00  \_ dovecot/imap-login
mail        1035  0.0  0.0  65948  6524 ?        Ss   Apr20   0:35 /usr/sbin/exim -bd -q1h
root        1091  0.0  0.0 157060  2312 ?        Ss   Apr20   0:02 /usr/sbin/pure-ftpd /etc/pure-ftpd.conf
root        1374  0.0  0.0 108068   632 ?        Ss   Apr20   0:01 rhnsd
root        2058  0.0  0.0 126420  1668 ?        Ss   Apr20   2:16 /usr/sbin/crond -n
named       2358  0.0  1.9 459456 160268 ?       Ssl  Apr20   2:58 /usr/sbin/named -u named -c /etc/named.conf
polkitd  3888652  0.0  0.1 612488  8452 ?        Ssl  May31   4:03 /usr/lib/polkit-1/polkitd --no-debug
mysql     331330  0.2  3.0 2708860 245736 ?      Sl   Jun01 128:10 /usr/sbin/mysqld --daemonize --pid-file=/var/run/mysqld/mysqld.pid
root      331995  0.1  0.1 683836 10368 ?        Ssl  Jun01  58:10 /usr/sbin/db_governor
root     1086771  0.0  0.2 228088 19796 ?        Ss   Jun04   5:52 /usr/sbin/httpd -DFOREGROUND
apache    692573  0.0  0.2 342488 17984 ?        Sl   00:11   0:20  \_ /usr/sbin/httpd -DFOREGROUND
apache    696588  0.0  0.2 346580 22072 ?        Sl   00:35   0:20  \_ /usr/sbin/httpd -DFOREGROUND
root     2250118  0.0  0.2 1591468 17720 ?       Ssl  Jun09  12:13 /usr/local/directadmin/directadmin server
nobody   2250135  0.0  0.0 955536  6820 ?        Sl   Jun09   0:14  \_ /usr/local/directadmin/directadmin
root     2250394  0.0  0.0  23856   620 ?        Ss   Jun09   1:58 /usr/local/directadmin/da-popb4smtp
root     2044322  0.0  0.0  10656   128 ?        S    Jun29   0:00 /usr/sbin/proxyexec -q -d -s /var/lib/proxyexec/cagefs.sock/socket /bin/cagefs.server
root      417383  0.0  0.0 108624  2720 ?        Ss   Jul09   0:00 nginx: master process /usr/local/webserver/123nginx/sbin/nginx
nobody    417384  0.0  0.5 151884 46884 ?        S    Jul09   0:02  \_ nginx: worker process
nobody    417385  0.0  0.5 152348 46924 ?        S    Jul09   0:01  \_ nginx: worker process
root      690380  0.1  0.3 172996 25032 ?        Ss   00:00   1:22 lfd - sleeping
root      738128  0.0  0.0 661920  5796 ?        Ssl  03:37   0:06 /usr/sbin/rsyslogd -n

Bạn có làm được theo hướng dẫn này không?

Lệnh liên quan

Object Storage

Chuẩn S3, không giới hạn băng thông

Object Storage
Thông tin tác giả
Bùi Tấn Việt

Co-Founder & CEO at 123HOST

Bình luận

Tính năng đang được phát triển

Đang tải bình luận