[mpich-discuss] install mpich2 on a single pc with 2 cpus
Seungho Choe
sec53 at pitt.edu
Wed Jul 2 21:11:01 CDT 2008
Dear Gus,
I was confusing with the device setup.
Thank you very much for your comments.
They are very helpful.
Best,
Seungho
Gus Correa ì^Ó´ ê¸^À:
> Hello Seungho and list
>
> I assume your RedHat Linux is using the SMP kernel (i.e. symmetric
> multi-processor).
> Check this out with "uname -a", which should print a string containing
> "smp".
>
> In a dual processor machine running the smp Linux kernel
> I installed mpich2 with the "communication devices" shm (shared
> memory) and nemesis. Both work well in a single machine with multiple
> processors, including multi-core processors.
>
> For instance, I use both shm and nemesis (with different programs) in
> a dual-core dual-processor machine,
> and it looks as four actual processors.
> Beware that speedup in multi-core machines is not really linear w.r.t.
> the number of cores!
>
> You can use either one: shm or nemesis.
> Even the ch3:ssm (shared memory + sockets) and ch3:sock (sockets)
> devices would work,
> but they are probably not the best for a single machine with SMP.
>
> You should read the MPICH Installer's Guide (at least section 4 for
> "devices"), available on the MPICH2 site,
> and also the configure options (do a "./configure --help" on the main
> mpich2 directory).
>
> Below is a short script I used to configure mpich2
> with the ch3:shm device, gcc, and the Intel Fortran compiler in the
> Linux machine I mentioned above.
>
> If you have the PGI Fortran compiler, replace "ifort" by "pgf90".
> I never used the gfortran free compiler, but it may work.
> If you only have the Gnu g77 Fortran compiler,
> remove the "env" line, and it will configure only the
> C, and Fortran77 interfaces, but not the Fortran90 one.
> To change the "device" replace ch3:shm by
> ch3.nemesis or other.
>
> #! /bin/tcsh
> env F77=ifort F90=ifort \
> ./configure \
> -prefix=/your/installation/directory \
> --with-device=ch3:shm \
> | & tee configure.log
>
> To avoid frustration when you try to run your first program,
> first read the Installer's Guide section 5, to learn how to use the
> mpd daemon.
> It is easy in a single machine.
>
> If your machine has two CPUs but they aren't multi-core,
> run the programs with "mpiexec -n 2".
> If the CPUs are dual-core you can go up to "-n 4".
> If they are quad-core you can go up to "-n 8".
>
> I hope this helps.
> Gus Correa
>
More information about the mpich-discuss
mailing list