how to run FDS on a multi-core PC

2,645 views
Skip to first unread message

hutalulu

unread,
Nov 20, 2007, 3:42:42 AM11/20/07
to FDS and Smokeview Discussions
Hi

I have a computer with 2CPUs, and each CPU have 4 cores. I have also
installed MPICH2. Then I write an input file with mesh lines:

&MESH IJK=40,80,80, XB=0,0.2,0,0.4,0,0.4
&MESH IJK=40,80,80, XB=0.2,0.4,0,0.4,0,0.4
&MESH IJK=40,80,80, XB=0.4,0.6,0,0.4,0,0.4
&MESH IJK=40,80,80, XB=0.6,0.8,0,0.4,0,0.4
&MESH IJK=40,80,80, XB=0.8,1.0,0,0.4,0,0.4

I run this model using the command:

fds5_mpi -np 5 casename.fds

and get the wrong message:

Mesh 1 of 1 is alive on SERVER-QZP(my computer name)
ERROR: The file, -np, does not exist in the current directory

Can someone help me?

chris_cfd

unread,
Nov 20, 2007, 5:21:29 AM11/20/07
to FDS and Smokeview Discussions
I cant even get even get that far.

Ive installed mpich2 from argonne, installed microsofts visual C++
whatever that teh MPICH2 installer told me to do. Ive added c:
\mpich2.bin to my path on the advice of a windows installation guide
for mpich2 and still when i try to run it, i get "mpiexec is not
recognized as an internal or external command, operable program or
batch file".

whats up with that????

pingouyn

unread,
Nov 20, 2007, 5:30:00 AM11/20/07
to FDS and Smokeview Discussions
Missprint in your previous post. Did you mean "C:\mpich2\bin"?
> > Can someone help me?- Hide quoted text -
>
> - Show quoted text -

Bryan Klein

unread,
Nov 20, 2007, 8:18:00 AM11/20/07
to FDS and Smokeview Discussions
That is not the correct command to run a job in parallel.
Please try using the instructions given in section 3.1.2 of the FDS
Users Guide and report back any difficulties you encounter. Note that
you will not have different host names listed in the config file, just
the one host you are running on and the number of processes to run on
it.

Regards,
Bryan

Christian Rogsch

unread,
Nov 20, 2007, 8:44:32 AM11/20/07
to FDS and Smokeview Discussions
Hi,

I think the command for mpi is different on the several mpi-
distributions. Sometimes I have to write fds5_mpi -np X casename.fds,
on another system I write only fds5_mpi casename.fds ...
I think for the "standard-mpi-version" the mpirun command (see U-Guide
3.1.2) is the right one...

Sorry for my posting with the "simple" -np command..., but I do not
use "standard" computers ;-)
> > Can someone help me?- Zitierten Text ausblenden -
>
> - Zitierten Text anzeigen -

Kevin

unread,
Nov 20, 2007, 9:24:07 AM11/20/07
to FDS and Smokeview Discussions
Please read the User's Guide. This is NOT how you run a parallel job.

On Nov 20, 3:42 am, hutalulu <hutal...@yahoo.com.cn> wrote:

hutalulu

unread,
Nov 20, 2007, 9:27:29 AM11/20/07
to FDS and Smokeview Discussions
Thanks for your attention!
I have solved it with the simple command(Windows Serve 2003):
mpiexec -np 4 fds5_mpi casename.fds
share with all!
> > Can someone help me?- 隐藏被引用文字 -
>
> - 显示引用的文字 -

Kevin

unread,
Nov 20, 2007, 9:28:00 AM11/20/07
to FDS and Smokeview Discussions
I ran into the same problem. Always check to see if a directory exists
before adding it to your path.

C:\Program Files\MPICH2\bin

I reported this to the MPICH site. The documentation for MPICH2 is not
very reliable. Some of the directions are old and need to be updated.
However, be patient, these guys at Argonne are working as hard as they
can to provide us all with a very useful piece of software that is
absolutely free.
> > - Show quoted text -- Hide quoted text -

chris_cfd

unread,
Nov 20, 2007, 10:37:24 AM11/20/07
to FDS and Smokeview Discussions
Thanks, sorted.

Kevin, Bryan, whats the problem with running mpiexec from the simple
command that seems to work for everyone? i got the simple command to
work but haven't been able to get the method presented in the user
guide to work. Ill need to spend a bit more time on it tomorrow, to
see if i can get the proper way to work. But is there a disadvantage
from using the "simple" method? using the simple method, from my task
manager, the simulation is taxing both my processors pretty hard so it
must be working, right?

also, i do appreciate the work of open source coders such as the guys
at argonne and you guys at NIST. my comment with all the "???"s was
just borne out of frustration and lack of sleep.

Kevin

unread,
Nov 20, 2007, 10:45:22 AM11/20/07
to FDS and Smokeview Discussions
Not sure what you mean by the "simple" command.

F-Sim.de

unread,
Nov 20, 2007, 10:50:05 AM11/20/07
to FDS and Smokeview Discussions
The problem is, that it does not work for everyone. At least it does
not work on my MPICH installation.
The second problem is, that this simple command cannot divide FDS
simulations on different machines but only on one multicore PC.
Using a config file one can use different PCs for a simulation.

F-Sim.de

unread,
Nov 20, 2007, 11:09:33 AM11/20/07
to FDS and Smokeview Discussions


On 20 Nov., 16:45, Kevin <mcgra...@gmail.com> wrote:
> Not sure what you mean by the "simple" command.

I think 'simple command' means:
fds5_mpi -np 4 casename.fds

'complex command' means:
mpiexec -file config.txt

The 'simple command' did not work for me...

Boris

Kevin

unread,
Nov 20, 2007, 11:17:03 AM11/20/07
to FDS and Smokeview Discussions
It does not work for me either. Nor can it ever. Both fds5.exe and
fds5_mpi.exe are programmed to get the input file from the next
character string. The error I get from the "simple" command is that "-
np" is not an input file.

Kevin

unread,
Nov 20, 2007, 11:19:04 AM11/20/07
to FDS and Smokeview Discussions
Your "simple" command may work with a single mesh case, but that is
not a true "parallel" job. It is really just the same as fds5.exe.

Use mpiexec for parallel jobs.

On Nov 20, 10:37 am, chris_cfd <c.abl...@cfdonline.com.au> wrote:

Bryan Klein

unread,
Nov 20, 2007, 11:20:26 AM11/20/07
to FDS and Smokeview Discussions
For clear understanding of mpiexec, Please read Chapter 5 of the MPICH
User's Guide.
http://www-unix.mcs.anl.gov/mpi/mpich/downloads/mpich2-doc-user.pdf

-Bryan

On Nov 20, 10:37 am, chris_cfd <c.abl...@cfdonline.com.au> wrote:

chris_cfd

unread,
Nov 20, 2007, 6:10:26 PM11/20/07
to FDS and Smokeview Discussions
well, this discussion is about running a parallel job on a multicore
pc, not on a cluster of networked machines.

i dont have a bunch of networked computers to work with, but i do have
a multicore computer, so that is what i am trying to use to run a
parallel job. i do have two meshes in my simulation, so it should be
able to be run as a parallel process.

Are you guys saying that using the so called "simple" command i.e.

fds5_mpi -np 2 fds5_mpi.exe casename.fds

does not run the simulation with one mesh per processor on my dual
core machine?

i found this document on the mpich2 homepage

http://www-unix.mcs.anl.gov/mpi/mpich/downloads/windows-mpich2-tips.doc

which gives the following advice


Running MPICH2 Programs
There are two methods. The first is on a dual processor machine. The
second is across a network by specifying the IP addresses. Across a
network is typically slow due to communication times.

DUAL PROCESSOR MACHINE

1. Make sure that "C:\mpich2\bin" is in your path.
2. Change to the directory where you executable is located and type
"mpiexec -n X filename.mpi". X is the number
of processors and filename.mpi is the name of
the executable. The first time you run in a given logon session you
will be asked for your userid and password. These are you Windows XP
logon and password. You can request more processors than there are
available, this does nothing except increase communication times.



This indicates that you can start a parallel job on a single multicore
machine from the "simple" command rather than using the config file
method.

Glenn Forney

unread,
Nov 20, 2007, 9:05:36 PM11/20/07
to fds...@googlegroups.com
I assume you mistyped the line below (**********) and meant to type:

mpiexec -np 2 fds5_mpi.exe casename.fds

The above is what is documented in the link you reference.


If you type fds5_mpi -np 2 ....

then fds5 will fail because it does not (as Kevin said earlier) parse
the -np option .


chris_cfd wrote:
> well, this discussion is about running a parallel job on a multicore
> pc, not on a cluster of networked machines.
>
> i dont have a bunch of networked computers to work with, but i do have
> a multicore computer, so that is what i am trying to use to run a
> parallel job. i do have two meshes in my simulation, so it should be
> able to be run as a parallel process.
>
> Are you guys saying that using the so called "simple" command i.e.
>

> fds5_mpi -np 2 fds5_mpi.exe casename.fds (*************)

--
Glenn Forney
National Institute of Standards and Technology
100 Bureau Drive, Stop 8663
Gaithersburg MD 20899-8663

Telephone: (301) 975 2313
FAX: (301) 975 4052

Pre-decisional and sensitive information. Not for attribution, distribution, or reproduction.


Message has been deleted

chris_cfd

unread,
Nov 20, 2007, 11:25:25 PM11/20/07
to FDS and Smokeview Discussions

ok, im a little confused. you are correct, i used -np originally, but
i just started the same simulation using -n instead and it still runs
and taxes my computer more than when i just ran fds5 rather than
fds5_mpi. Page 7 of the document i linked in my previous post refers
to -n not -np. The quote of this paragraph is correct in my original
post, i just copied and pasted it.


but if i understand you correctly, this still doesnt run as a
parallel
job.


could you please give an example, then, on how to run a mpi job on a
single machine with a dual core processor using the config.txt
method?


Im sorry to keep bringing this up, but this is all new to me. I guess
the main think is, im not sure how to refer to each processor in my
computer individually, unless you just refer to the machine itself
and
have two lines in the config.txt file referring to the same machine.


I think an example will really help.....please?


cheers
> Pre-decisional and sensitive information. Not for attribution, distribution, or reproduction.- Hide quoted text -

Kevin

unread,
Nov 21, 2007, 8:38:43 AM11/21/07
to FDS and Smokeview Discussions
Yes, this is getting confusing, but I think you have taught us
something. I just entered the following command on my XP (single CPU,
single core) laptop:

mpiexec -n 2 fds5_mpi device_test.fds

I was asked for a user name and password, and I entered the same ones
I use to login. Then it worked -- FDS tells me that

Mesh 1 of 2 is alive on my_machine.nist.gov
Mesh 2 of 2 is alive on my_machine.nist.gov

Fire Dynamics Simulator

Compilation Date : ...
Version : 5.0.2 Parallel
SVN ...

Note that the mpiexec command uses -n instead of -np. This is somewhat
confusing, because of all the different versions of MPICH, MPICH2,
configuration files, etc. Type

mpiexec -help

and you will see that there are many ways to run an MPI job. You can
still use a configuration file to run an MPI job on your own machine,
but you need not specify which CPU or core to use. That is the job of
the OS. All you do is specify which machine or machines are to run the
job, and make sure the number of meshes is equal to the number of
"threads."
> > - Show quoted text -- Hide quoted text -

Hostikka Simo

unread,
Nov 21, 2007, 8:46:38 AM11/21/07
to fds...@googlegroups.com
To avoid the confusion with the command line arguments, I always use
the config.txt to run the job. Copying old files helps to memorize the
format.

To run the case at single machine, the config.txt would look like this:

exe c:\NIST\FDS\fds_5.0.2_mpi_win32.exe inputfile.fds
dir d:\working_directory\whatever
hosts
my_computer #

where # is the number of meshes in inputfile.

Then I would start the job by typing
mpiexec -file config.txt

Simo


>
> Yes, this is getting confusing, but I think you have taught
> >

Reply all
Reply to author
Forward
0 new messages