# Using clusters on AWS - OpenFoam

**URL:** <https://precice.discourse.group/t/using-clusters-on-aws-openfoam/843>\
**Category:** Official adapters and tutorials\
**Tags:** openfoam, hpc\
**Created:** [December 24, 2021, 6:06pm UTC](https://precice.discourse.group/t/using-clusters-on-aws-openfoam/843 "2021-12-24T18:06:30Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jmcentee](https://avatars.discourse-cdn.com/v4/letter/j/ea5d25/32.png) [@jmcentee](https://precice.discourse.group/u/jmcentee)\
**Post date:** [December 24, 2021, 6:06pm UTC](https://precice.discourse.group/t/using-clusters-on-aws-openfoam/843/1 "2021-12-24T18:06:31Z")

</div>

I am trying to use a large cluster for FSI work. I am using AWS, but I suspect this issue may affect other cluster too.

The cluster processors don’t seem to be able to locate the preciceAdapterFunctionObject.

OpenFOAM reports  
“[10] → FOAM FATAL ERROR:  
[10] Unknown function type preciceAdapterFunctionObject”

I have found the location for libpreciceAdapterFunctionObject.so, and it appears to be on the head node.

How do I tell the other nodes where this function is located?

When I run the problem on the headnode only it runs fine.

---

<div class="post-metadata">

**Author:** ![Satish\_Chimakurthi](https://yyz2.discourse-cdn.com/free1/user_avatar/precice.discourse.group/satish_chimakurthi/32/989_2.png) [@Satish\_Chimakurthi](https://precice.discourse.group/u/Satish_Chimakurthi)\
**Post date:** [December 30, 2021, 4:40pm UTC](https://precice.discourse.group/t/using-clusters-on-aws-openfoam/843/2 "2021-12-30T16:40:53Z")

</div>

Have you tried this on an Amazon ECS Cluster ([Amazon ECS clusters - Amazon Elastic Container Service](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/clusters.html))? (OR) Are you using a single instance such as c5a.16xlarge (32 cores)? Perhaps, you are referring to the former? If it is the latter, you should have no problem as far as I know.

---

<div class="post-metadata">

**Author:** ![jmcentee](https://avatars.discourse-cdn.com/v4/letter/j/ea5d25/32.png) [@jmcentee](https://precice.discourse.group/u/jmcentee)\
**Post date:** [January 28, 2022, 10:51pm UTC](https://precice.discourse.group/t/using-clusters-on-aws-openfoam/843/3 "2022-01-28T22:51:53Z")

</div>

I think I fixed this problem  
On AWS when compiling openfoam, calculix and precice, many of the libraries are placed on the headnode. However to run a problem, it is submitted as a batch job to the compute nodes. I am also using a separate file system (Lustre) to hold the run files. This separate file system cannot find the libraries on the head node, (even with the proper path given by the LD\_LIBRARY\_PATH variable). The fix is to copy the library files onto the Lustre file system and set the LD\_LIBRARY\_PATH variable to that location.

(Satish…I am using a ECS Cluster with Lustre file system)

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/free1/uploads/precice/original/1X/67d2a5fa6f80e597e2267ff17fa8c1673cd11caa.svg) [@system](https://precice.discourse.group/u/system)\
**Post date:** [January 31, 2022, 10:52pm UTC](https://precice.discourse.group/t/using-clusters-on-aws-openfoam/843/4 "2022-01-31T22:52:24Z")

</div>

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.
