摘要: 每一个进程都有自己的一组资源限制,在Linux系统中我们可以通过这2个API来取得和设置资源。#include int getrlimit(int resource, struct rlimit *rlim);int setrlimit(int resource, const struct rlimit *rlim);getrlimit用来取得,setrlimit用来设置。这二个参数都需要一个要控制的资源,比如控制CPU、内存、文件描述符个数等等的控制,作为第一个参数传入,第二个参数是一个rlimit的结构体地址(指针),他的结构定义放在头文件/usr/include/bits/resourc 阅读全文
posted @ 2013-02-21 19:10 only_eVonne 阅读(618) 评论(0) 推荐(0) 编辑
摘要: My application sometimes randomly receives a SIGKILL signal, gdb wouldsay something like:Program terminated with signal SIGKILL, Killed.The program no longer exists.(gdb)And i have no clue why? When does the system send a SIGKILL? There isno 3rd application send anything to mine....There are situati 阅读全文
posted @ 2013-02-21 18:53 only_eVonne 阅读(1871) 评论(0) 推荐(0) 编辑