# Openmpi support

**URL:** <https://community.openpbs.org/t/openmpi-support/1396>\
**Category:** Users/Site Administrators\
**Created:** [January 14, 2019, 3:17am UTC](https://community.openpbs.org/t/openmpi-support/1396 "2019-01-14T03:17:17Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![adarsh](https://avatars.discourse-cdn.com/v4/letter/a/f07891/32.png) [@adarsh](https://community.openpbs.org/u/adarsh)\
**Post date:** [January 15, 2019, 2:05pm UTC](https://community.openpbs.org/t/openmpi-support/1396/7 "2019-01-15T14:05:11Z")

</div>

Could you please update below script :

> [@liuxiaopiao](#):
>
> [test@pbspro-server ~]$ cat test.sh  
> #!/bin/bash  
> #PBS -N pbs-openmpi-sh  
> #PBS -l select=2  
> #PBS -l place=scatter  
> cat PBS\_NODEFILE hostnumber=(cat $PBS\_NODEFILE | wc -l)  
> /opt/openmpi/1.10.7/bin/mpirun hostname

**To :**

#!/bin/bash  
#PBS -N pbs-openmpi-sh  
#PBS -l select=2:ncpus=2:mpiprocs=2  
#PBS -l place=scatter  
/opt/openmpi/1.10.7/bin/mpirun -np `cat $PBS_NODEFILE | wc -l` /bin/hostname

> [@liuxiaopiao](#):
>
> Could you please help check why my two jobs have hanged?

The issue is DNS / Name resolution

1. Check DNS ( forward and reverse resolution of pbs server , pbs nodes on the pbs server and from the pbs nodes )
2. Make sure /etc/hosts is populated with pbs server and compute node names/ips/alias and exist on all the nodes of the PBS Complex.
3. without using PBS Pro , can you run open-mpi by having a static hostfile of node names – please check this.

---

_[View the full topic](https://community.openpbs.org/t/openmpi-support/1396)._
