LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 832|回复: 3

OPENBSD中怎么KILL掉所有以NOBODY用户名运行的进程?

[复制链接]
发表于 2004-3-13 23:20:48 | 显示全部楼层 |阅读模式
不知道apache出什么问题了。想kill掉所有的nobody运行的进程
load averages:  7.48,  7.39,  7.27                                                                                         22:25:49
64 processes:  8 running, 56 idle
CPU states: 20.6% user,  0.0% nice, 79.3% system,  0.2% interrupt,  0.0% idle
Memory: Real: 225M/498M act/tot  Free: 1224K  Swap: 0K/1024M used/tot

  PID USERNAME PRI NICE  SIZE   RES STATE WAIT     TIME    CPU COMMAND
14619 nobody    62    0 9856K   10M run   -       56:37 14.16% httpd
5556 nobody    64    0 9772K   10M run   -       57:22 13.33% httpd
15446 nobody    64    0 3768K 4164K run   -       55:23 13.18% httpd
2497 nobody    64    0 1072K 1176K run   -       60:38 13.09% httpd
1645 nobody    64    0 1084K 1224K run   -       54:36 12.99% httpd
13568 nobody    64    0 3884K 4336K run   -       55:55 12.65% httpd
2287 nobody    64    0 1044K 1072K run   -       57:58 12.55% httpd
1927  10000     2    0  312K  892K sleep netio    0:05  0.00% pure-ftpd
17265 mysql      2    0   15M 5064K sleep poll     0:05  0.00% mysqld
28172 root       2    0  344K    4K idle  select   0:01  0.00% sshd
23603 root       2    0 2064K 3756K sleep select   0:01  0.00% httpd
2269 root       4    0  368K  252K sleep bpf      0:00  0.00% pflogd
9747 root       2    0 1016K  896K sleep select   0:00  0.00% nmbd
27702 www        2    0   10M    4K idle  netcon   0:00  0.00% httpd
20745 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
21326 www        2    0 8308K    4K idle  netcon   0:00  0.00% httpd
16956 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
2420 www        2    0 7036K    4K idle  netcon   0:00  0.00% httpd
25525 www        2    0 7028K    4K idle  netcon   0:00  0.00% httpd
29164 www        2    0   10M    4K idle  netcon   0:00  0.00% httpd
18069 www        2    0 7016K    4K idle  netcon   0:00  0.00% httpd
15659 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
27899 www        2    0 7024K    4K idle  netcon   0:00  0.00% httpd
30146 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
11588 www        2    0 7028K    4K idle  netcon   0:00  0.00% httpd
7754 www        2    0 7028K    4K idle  netcon   0:00  0.00% httpd
17918 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
1754 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
17924 www        2    0 7004K    4K idle  netcon   0:00  0.00% httpd
8413 www        2    0 7016K    4K idle  netcon   0:00  0.00% httpd
12702 www        2    0 7016K    4K idle  netcon   0:00  0.00% httpd
31853 www        2    0 7004K    4K idle  netcon   0:00  0.00% httpd
9784 www        2    0 7016K    4K idle  netcon   0:00  0.00% httpd
5445 www        2    0 7004K    4K idle  netcon   0:00  0.00% httpd
16235 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
22622 postgres   2    0 2444K    4K idle  select   0:00  0.00% postgres
2806 www        2    0 7004K    4K idle  netcon   0:00  0.00% httpd
20204 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
22148 www        2    0 7012K    4K idle  netcon   0:00  0.00% httpd
32302 www        2    0   10M    4K idle  netcon   0:00  0.00% httpd
30906 www        2    0 7004K    4K idle  netcon   0:00  0.00% httpd
30863 www        2    0 7004K    4K idle  netcon   0:00  0.00% httpd
19252 www        2    0 7008K    4K idle  netcon   0:00  0.00% httpd
发表于 2004-3-14 11:47:18 | 显示全部楼层

你应该去shell编程版块找个shell程序来杀。

ps -auxw | sed -n '/nobody/p' | awk {prinf $1} | killall
不知道对不对哦 !我刚开始学习shell程序。
感觉应该用更简单的方法
 楼主| 发表于 2004-3-14 20:30:10 | 显示全部楼层
没有KILLALL命令
发表于 2004-3-15 08:40:09 | 显示全部楼层

那就kill

ps -auxw | grep nobody | awk {prinf $1} | kill
尝试………………
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表