zoukankan      html  css  js  c++  java
  • executing in nfs will not generate core dump file

    最近遇到了一个奇怪的问题。

    linux系统的pc搭建nfs server,开发板作为nfs client,开发板中全程root权限操作,执行的程序放到 nfs server 中 exports 出的目录中。

    1. 开发板中已经设置了 ulimit -c unlimited

    2. 将程序copy到 开发板的 /tmp 目录下执行,可以正常生成 core 文件,提示 core dumped。

    3. 程序放到 nfs 上执行,生成空的 core 文件,不提示 core dumped。

    4. 因为在nfs server中设置了 root_squash,anonuid=1001,anongid=1001 ,所以开发板操作nfs是以uid 为1001 的用户操作的。尝试设置成 no_root_squash,发现第3步的执行可以生成core文件,提示 core dumped。

    这个网址提到了几种可能不会生成 core 文件的原因,网址:https://linux.die.net/man/5/core

    对照了一下,没有发现与我遇到的这种问题相对应的。

    上述网址中提到了一种情况,

    The process is executing a set-user-ID (set-group-ID) program that is owned by a user (group) other than the real user (group) ID of the process. (However, see the description of the prctl(2) PR_SET_DUMPABLE operation, and the description of the /proc/sys/fs/suid_dumpable file in proc(5).)

    我尝试 执行 echo 1 > /proc/sys/fs/suid_dumpable,发现无效。

    问题未找到根本原因。

  • 相关阅读:
    Linux软件安装中RPM与YUM 区别和联系(转载)
    linux文件系统
    (转载) linux基础知识
    linux学习:硬盘挂载
    IDEA版github教程(转载)
    idea配置gitee(转载)
    事与人的关系
    maven打包失败与问题反思
    计算机开机
    maven到底干了啥
  • 原文地址:https://www.cnblogs.com/vanwoos/p/6933822.html
Copyright © 2011-2022 走看看