[root@localhost work]# ps -au
Warning: bad syntax, perhaps a bogus '-'? See /usr/share/doc/procps-3.2.7/FAQ
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 2926 0.0 0.0 1628 440 tty1 Ss+ 18:09 0:00 /sbin/mingetty
root 2937 0.0 0.0 1628 436 tty2 Ss+ 18:09 0:00 /sbin/mingetty
root 2938 0.0 0.0 1624 432 tty3 Ss+ 18:09 0:00 /sbin/mingetty
root 2939 0.0 0.0 1624 436 tty4 Ss+ 18:09 0:00 /sbin/mingetty
root 2940 0.0 0.0 1624 436 tty5 Ss+ 18:09 0:00 /sbin/mingetty
root 2969 0.0 0.0 1624 432 tty6 Ss+ 18:09 0:00 /sbin/mingetty
root 3027 1.4 5.5 35088 28728 tty7 Ss+ 18:09 1:14 /usr/bin/Xorg :
root 3896 0.0 0.2 4860 1468 pts/2 Ss 18:10 0:00 bash
root 30198 0.1 4.3 81556 22324 pts/2 S 19:30 0:00 gedit 1.c
root 30199 0.0 0.0 3916 488 pts/2 T 19:30 0:00 cat e
root 30288 0.0 0.1 4464 936 pts/2 R+ 19:32 0:00 ps -au
[root@localhost work]# kill 30199
[root@localhost work]# ps -au
Warning: bad syntax, perhaps a bogus '-'? See /usr/share/doc/procps-3.2.7/FAQ
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 2926 0.0 0.0 1628 440 tty1 Ss+ 18:09 0:00 /sbin/mingetty
root 2937 0.0 0.0 1628 436 tty2 Ss+ 18:09 0:00 /sbin/mingetty
root 2938 0.0 0.0 1624 432 tty3 Ss+ 18:09 0:00 /sbin/mingetty
root 2939 0.0 0.0 1624 436 tty4 Ss+ 18:09 0:00 /sbin/mingetty
root 2940 0.0 0.0 1624 436 tty5 Ss+ 18:09 0:00 /sbin/mingetty
root 2969 0.0 0.0 1624 432 tty6 Ss+ 18:09 0:00 /sbin/mingetty
root 3027 1.4 5.5 35088 28728 tty7 Ss+ 18:09 1:14 /usr/bin/Xorg :
root 3896 0.0 0.2 4860 1468 pts/2 Ss 18:10 0:00 bash
root 30198 0.1 4.3 81556 22324 pts/2 S 19:30 0:00 gedit 1.c
root 30199 0.0 0.0 3916 488 pts/2 T 19:30 0:00 cat e
root 30302 0.0 0.1 4460 932 pts/2 R+ 19:33 0:00 ps -au
[root@localhost work]#
|
kill -9 30199
|
kill -SIGKILL 30199
kill -KILL 30199
kill -9 30199
如果是这样还不行的话,有可能是程序调用内核的某部分不能释放资源,而停留。
|
楼上正解!
|
或者:
kill -SIGKILL 30199
kill -KILL 30199
|
kill -9强制杀死
|
强制杀死