24小时热门版块排行榜    

查看: 2066  |  回复: 1

qh203

铜虫 (小有名气)

[求助] root和普通用户下并行计算问题

在root用户下,用openmpi并行计算cpi 这个算例,6个节点,每个节点8个cpu。输出正常,如下

[root@node1 examples]# mpirun -np 40 -machinefile test ./cpi
Process 3 on node2
Process 38 on node6
Process 18 on node4
Process 32 on node6
Process 20 on node4
Process 2 on node2
Process 35 on node6
Process 34 on node6
Process 22 on node4
Process 7 on node2
Process 23 on node4
Process 5 on node2
Process 4 on node2
Process 37 on node6
Process 33 on node6
Process 30 on node5
Process 8 on node3
Process 26 on node5
Process 10 on node3
Process 15 on node3
Process 27 on node5
Process 31 on node5
Process 28 on node5
Process 24 on node5
Process 19 on node4
Process 21 on node4
Process 17 on node4
Process 6 on node2
Process 16 on node4
Process 25 on node5
Process 9 on node3
Process 11 on node3
Process 13 on node3
Process 14 on node3
Process 0 on node2
Process 1 on node2
Process 36 on node6
Process 39 on node6
Process 12 on node3
Process 29 on node5
pi is approximately 3.1416009869231245, Error is 0.0000083333333314
wall clock time = 0.128546

在普通用户下用openmpi并行计算cpi这个算例,输出则变成

[aojjj@node1 examples]$ mpirun -np 40 -machinefile test ./cpi
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
--------------------------------------------------------------------------
The OpenFabrics (openib) BTL failed to register memory in the driver.
Please check /var/log/messages or dmesg for driver specific failure
reason.
The failure occured here:

  Local host:    mthca0
  Device:        openib_reg_mr
  Function:      Cannot allocate memory()
  Errno says:   

You may need to consult with your system administrator to get this
problem fixed.
--------------------------------------------------------------------------
--------------------------------------------------------------------------
The OpenFabrics (openib) BTL failed to initialize while trying to
allocate some locked memory.  This typically can indicate that the
memlock limits are set too low.  For most HPC installations, the
memlock limits should be set to "unlimited".  The failure occured
here:

  Local host:    node4
  OMPI source:   btl_openib_component.c:1161
  Function:      ompi_free_list_init_ex_new()
  Device:        mthca0
  Memlock limit: 32768

You may need to consult with your system administrator to get this
problem fixed.  This FAQ entry on the Open MPI web site may also be
helpful:

    http://www.open-mpi.org/faq/?category=openfabrics#ib-locked-pages
--------------------------------------------------------------------------
--------------------------------------------------------------------------
WARNING: There was an error initializing an OpenFabrics device.

  Local host:   node4
  Local device: mthca0
--------------------------------------------------------------------------
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
libibverbs: Warning: RLIMIT_MEMLOCK is 32768 bytes.
    This will severely limit memory registrations.
Process 26 on node5
Process 8 on node3
Process 28 on node5
Process 1 on node2
Process 29 on node5
Process 4 on node2
Process 22 on node4
Process 2 on node2
Process 15 on node3
Process 25 on node5
Process 31 on node5
Process 38 on node6
Process 14 on node3
Process 30 on node5
Process 32 on node6
Process 39 on node6
Process 37 on node6
Process 33 on node6
Process 36 on node6
Process 35 on node6
Process 16 on node4
Process 18 on node4
Process 10 on node3
Process 21 on node4
Process 19 on node4
Process 20 on node4
Process 11 on node3
Process 17 on node4
Process 9 on node3
Process 0 on node2
Process 7 on node2
Process 6 on node2
Process 5 on node2
Process 23 on node4
Process 24 on node5
Process 3 on node2
Process 27 on node5
Process 34 on node6
Process 12 on node3
Process 13 on node3
pi is approximately 3.1416009869231245, Error is 0.0000083333333314
wall clock time = 3.002147
[node1:02112] 39 more processes have sent help message help-mpi-btl-openib.txt / mem-reg-fail
[node1:02112] Set MCA parameter "orte_base_help_aggregate" to 0 to see all help / error messages
[node1:02112] 36 more processes have sent help message help-mpi-btl-openib.txt / init-fail-no-mem
[node1:02112] 39 more processes have sent help message help-mpi-btl-openib.txt / error in device init

也计算出来了,但是多了许多warniing 和error的提示。

在各个节点修改了/etc/security/limits.conf 和/etc/init.d/sshd, 还是不行。

到底问题在哪里?
回复此楼

» 猜你喜欢

» 本主题相关价值贴推荐,对您同样有帮助:

已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

qh203

铜虫 (小有名气)

这个问题我自己已经解决了。 普通用户的memlock不够。root用户下,在每个节点的/etc/security/limits.conf文件里增加两行
某个普通用户名 soft memlock unlimited
某个普通用户名 hard memlock unlimited

然后要重启每个服务器节点。<----这一点很重要,否则切换到普通用户下,会出现
memlock cannot modify limit: Operation not permitte.
2楼2013-10-13 21:22:41
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 qh203 的主题更新
最具人气热帖推荐 [查看全部] 作者 回/看 最后发表
[基金申请] 静等基金结果 +5 gjjjzhong 2026-08-10 16/800 2026-08-10 17:19 by Tide man
[基金申请] filecode +6 documentary 2026-08-10 6/300 2026-08-10 17:09 by wdc28
[基金申请] 国自然结果 +4 Vierhys 2026-08-10 8/400 2026-08-10 15:06 by Vierhys
[基金申请] 奇怪,两个人的filecode固定段从头到尾一模一样 +4 布布和一二 2026-08-10 4/200 2026-08-10 14:50 by 医学老男孩
[基金申请] 综述论文作为代表作会不会影响评审专家的印象分? +10 yufeiwaner 2026-08-09 10/500 2026-08-10 13:44 by cdutwml
[基金申请] 关于代码变化问题,想知道的进来 +16 且听虎啸 2026-08-07 23/1150 2026-08-10 12:35 by majunge000
[基金申请] 2026国自然放榜时间 +9 布布和一二 2026-08-08 9/450 2026-08-10 11:22 by xxxx2020
[基金申请] 这样的filecode谁见过 +11 布布和一二 2026-08-08 22/1100 2026-08-10 11:10 by wmfsnow
[基金申请] 面上项目filecode邪修 +5 西山十月 2026-08-09 7/350 2026-08-10 07:32 by 仁砚薪传
[基金申请] filecode与中标关系的预测 +5 布布和一二 2026-08-07 5/250 2026-08-09 16:15 by 袁向阳007
[基金申请] fileCode有新解读? +10 Tide man 2026-08-08 18/900 2026-08-09 12:55 by 仁砚薪传
[基金申请] 关于filecode,很负责任的告诉大家 +6 爱看书的可乐 2026-08-08 7/350 2026-08-08 22:13 by a_niu
[基金申请] 关于filecode +4 布布和一二 2026-08-07 7/350 2026-08-07 22:55 by zhanghaozhu
[基金申请] 化学口download_prp&amp;fileCode的固定段好像这几天一直没变,有变的大神么? +3 Tide man 2026-08-07 4/200 2026-08-07 22:39 by Tide man
[基金申请] filecode变化情况 +6 布布和一二 2026-08-07 22/1100 2026-08-07 14:45 by 且听虎啸
[基金申请] filecode +14 等待解的谜 2026-08-06 19/950 2026-08-07 12:20 by wlwhappy
[基金申请] filecode +8 布布和一二 2026-08-06 11/550 2026-08-06 20:41 by tangpu318
[基金申请] 求各位大神看下 100+6 hpkpkpkp 2026-08-05 33/1650 2026-08-06 14:49 by zhiyanjiang
[基金申请] 有没有H口的?有收到消息的吗? +3 超级海虾 2026-08-04 3/150 2026-08-04 17:26 by 学教育滴
[基金申请] 纯娱乐,不喜欢勿喷 +7 Tide man 2026-08-04 10/500 2026-08-04 15:10 by loufangrui
信息提示
请填处理意见