mpirun-没有足够的可用插槽 [英] mpirun - not enough slots available

查看:245
本文介绍了mpirun-没有足够的可用插槽的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

通常,当我使用mpirun时,可以使用比计算机上实际可用数量更多的处理器来重载"它.例如,在我的四核Mac上,我可以运行mpirun -np 29 python -c "print 'hey'"没问题.我现在在另一台计算机上,这将引发以下错误:

Usually when I use mpirun, I can "overload" it, using more processors than there acctually are on my computer. For example, on my four-core mac, I can run mpirun -np 29 python -c "print 'hey'" no problem. I'm on another machine now, which is throwing the following error:

$ mpirun -np 25 python -c "print 'hey'"
--------------------------------------------------------------------------
There are not enough slots available in the system to satisfy the 25 slots 
that were requested by the application:
  python

Either request fewer slots for your application, or make more slots available
for use.
--------------------------------------------------------------------------

为什么超频"的mpirun在这里不起作用?有什么方法可以克服此错误消息,并成功使用比可用处理器更多的处理器运行?

Why isn't "overclocking" mpirun working here? Is there a way I can overcome this error message and successfully run with more processors than are available?

推荐答案

根据 https://www.open-mpi.org/faq/?category=running#oversubscribing ,您可以使用主机文件超额订阅节点.在继续操作之前,请注意,这种方式会严重降低节点的性能.另外,如果您用于运行应用程序的系统使用的是队列系统,则这可能无效.

According to https://www.open-mpi.org/faq/?category=running#oversubscribing you could oversubscribe your node using a hostfile. Before proceeding, be careful that this way you can severely degrade the performance of the node. Also, if the system you use to run the application is using a queue system, this may not be valid.

首先创建一个包含以下内容的主机文件(名为主机文件)

First create a hostfile (named hostfile) containing

localhost slots=25

像这样简单地运行您的应用程序

The simply run your application like

mpirun --hostfile hostfile -np 25 python -c "print 'hey'"

这篇关于mpirun-没有足够的可用插槽的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆