LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
12
返回列表 发新帖
楼主: pengiums

几个使我困惑的问题,请大虾们赐教!

[复制链接]
发表于 2006-7-20 15:27:30 | 显示全部楼层
Post by yongjian
pkill - look up or signal processes based on name and other attributes. supporting pattern match for process name.


刚看了帖子还想说:
kill `pgrep mplayer`

看了一下帮助,pkill就可以搞定了,又学了一招:2cool
回复 支持 反对

使用道具 举报

发表于 2006-7-20 15:29:28 | 显示全部楼层
Post by yongjian
pkill - look up or signal processes based on name and other attributes. supporting pattern match for process name.


刚看了帖子还想说:
kill `pgrep mplayer`

看了一下帮助,pkill就可以搞定了,又学了一招:2cool
回复 支持 反对

使用道具 举报

发表于 2006-7-20 15:48:36 | 显示全部楼层
  1. [0 root@huan /var/www/vbb]# man skill
  2. Reformatting skill(1), please wait...
  3. [0 root@huan /var/www/vbb]# sleep 20 &
  4. [1] 9040
  5. [0 root@huan /var/www/vbb]# skill -c sleep
  6. [1]+  Terminated              sleep 20
  7. [0 root@huan /var/www/vbb]#         
复制代码
回复 支持 反对

使用道具 举报

发表于 2006-7-20 15:52:39 | 显示全部楼层
  1. [0 root@huan /tmp/work]# ll
  2. total 3524
  3. -rw-r--r-- 1 root root 3601135 2006-07-20 15:46 我要我的滋味.mp3
  4. [0 root@huan /tmp/work]# split -b1000000 我要我的滋味.mp3
  5. [0 root@huan /tmp/work]# ls -a
  6. .  ..  xaa  xab  xac  xad  我要我的滋味.mp3
  7. [0 root@huan /tmp/work]# cat xa* >  我要我的滋味.mp3.2
  8. [0 root@huan /tmp/work]# ll 我要我的滋味.mp3.2
  9. -rw-r--r-- 1 root root 3601135 2006-07-20 15:47 我要我的滋味.mp3.2
  10. [0 root@huan /tmp/work]# ll 我要我的滋味.mp3
  11. -rw-r--r-- 1 root root 3601135 2006-07-20 15:46 我要我的滋味.mp3
  12. [0 root@huan /tmp/work]# diff  我要我的滋味.mp3*
  13. [0 root@huan /tmp/work]#                                                         
复制代码
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-7-20 21:15:37 | 显示全部楼层
看了大家的帖子,想着应该是cat时不小心把原文件也cat上了,刚好是两倍^_^.......
等会试试
一不小心就耽误了大家的时间,抱歉抱歉。。
哈哈,又学一招---pkill
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-7-22 14:53:32 | 显示全部楼层
今天突然又找到一个以名称杀进程的方法:pidof
如:kill `pidof mplayer`
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

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