当前位置:操作系统 > Unix/Linux >>

让aolserver3.x生成core

1. 修改其代码nsd/nsmain.c,在ns_fork()前添加:

  Ns_Log(Warning, "---------------weiqiong added for core file----------------");

  if (prctl(PR_SET_DUMPABLE, 1, 0, 0, 0) < 0)

  {

  Ns_Fatal("nsmain: prctl(PR_SET_DUMPABLE) failed: '%s'",strerror(errno));

  }

  2. 将/etc/inittab文件中的启动行改为:

  wm:23:respawn:/bin/sh -c "ulimit -c unlimited;/usr/local/aol/bin/nsd -it /usr/local/aol/sample-config.tcl -u xmail -g xmail"本文来自:http://www.xiaoyaxiao.com/1268.html
发表您的高见!
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,