<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re:Fatal error: mpi.h: no such file or directory in Intel® MPI Library</title>
    <link>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489907#M10635</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Glad to know that your issue is resolved. If you need any additional information, please post a new question as this thread will no longer be monitored by Intel.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards&lt;/P&gt;&lt;P&gt;Shivani&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;</description>
    <pubDate>Thu, 25 May 2023 08:53:45 GMT</pubDate>
    <dc:creator>ShivaniK_Intel</dc:creator>
    <dc:date>2023-05-25T08:53:45Z</dc:date>
    <item>
      <title>Fatal error: mpi.h: no such file or directory</title>
      <link>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1488769#M10616</link>
      <description>&lt;P&gt;Hello all,&lt;BR /&gt;&lt;BR /&gt;I have just installed the oneAPI basic and HPC toolkits for compiling some parallelised cpp code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have added the "mpi/&amp;lt;version&amp;gt;/bin" and the "mpi/&amp;lt;version&amp;gt;/include" routes to the path, however when I try to compile the code with make using the mpicxx compiler I get the error mentioned in the subject:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Fatal error: mpi.h: no such file or directory&lt;/P&gt;&lt;P&gt;#include "mpi.h"&amp;nbsp; (inside one of the .cpp files of the code)&lt;/P&gt;&lt;P&gt;compilation terminated&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am not very used to compiling cpp code, and it is my first time using intel compilers, so this might be a very basic and easy to solve issue but I have no idea how to approach it.&lt;/P&gt;&lt;P&gt;Any insight is appreciated, thank you!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Max.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 May 2023 11:53:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1488769#M10616</guid>
      <dc:creator>MaxAmer</dc:creator>
      <dc:date>2023-05-23T11:53:22Z</dc:date>
    </item>
    <item>
      <title>Re:Fatal error: mpi.h: no such file or directory</title>
      <link>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489162#M10621</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for posting in the Intel forum.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please provide us with the details of the OS, and output of lscpu command?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Let us know the Intel mpi version you have been using by running the below command.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;mpirun --version&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you also please provide us with the command line you have been using to compile the code?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards&lt;/P&gt;&lt;P&gt; Shivani&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 24 May 2023 10:02:40 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489162#M10621</guid>
      <dc:creator>ShivaniK_Intel</dc:creator>
      <dc:date>2023-05-24T10:02:40Z</dc:date>
    </item>
    <item>
      <title>Re: Re:Fatal error: mpi.h: no such file or directory</title>
      <link>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489222#M10622</link>
      <description>&lt;P&gt;Hi Shivani,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;- OS is Ubuntu 22.04.2 LTS&lt;/P&gt;&lt;P&gt;- lscpu output:&lt;/P&gt;&lt;P&gt;Architecture: x86_64&lt;BR /&gt;CPU op-mode(s): 32-bit, 64-bit&lt;BR /&gt;Address sizes: 46 bits physical, 48 bits virtual&lt;BR /&gt;Byte Order: Little Endian&lt;BR /&gt;CPU(s): 32&lt;BR /&gt;On-line CPU(s) list: 0-31&lt;BR /&gt;Vendor ID: GenuineIntel&lt;BR /&gt;Model name: 13th Gen Intel(R) Core(TM) i9-13900KS&lt;BR /&gt;CPU family: 6&lt;BR /&gt;Model: 183&lt;BR /&gt;Thread(s) per core: 2&lt;BR /&gt;Core(s) per socket: 24&lt;BR /&gt;Socket(s): 1&lt;BR /&gt;Stepping: 1&lt;BR /&gt;CPU max MHz: 6000,0000&lt;BR /&gt;CPU min MHz: 800,0000&lt;BR /&gt;BogoMIPS: 6374.40&lt;BR /&gt;Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni p&lt;BR /&gt;clmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault invpcid_single ssbd ibrs ibpb stibp ibrs_enhanced tpr_shadow v&lt;BR /&gt;nmi flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid rdseed adx smap clflushopt clwb intel_pt sha_ni xsaveopt xsavec xgetbv1 xsaves split_lock_detect avx_vnni dtherm ida arat pln pts hwp hwp_notify hwp_act_window hwp_epp hwp_pkg&lt;BR /&gt;_req hfi umip pku ospke waitpkg gfni vaes vpclmulqdq tme rdpid movdiri movdir64b fsrm md_clear serialize pconfig arch_lbr ibt flush_l1d arch_capabilities&lt;BR /&gt;Virtualization features:&lt;BR /&gt;Virtualization: VT-x&lt;BR /&gt;Caches (sum of all):&lt;BR /&gt;L1d: 896 KiB (24 instances)&lt;BR /&gt;L1i: 1,3 MiB (24 instances)&lt;BR /&gt;L2: 32 MiB (12 instances)&lt;BR /&gt;L3: 36 MiB (1 instance)&lt;BR /&gt;NUMA:&lt;BR /&gt;NUMA node(s): 1&lt;BR /&gt;NUMA node0 CPU(s): 0-31&lt;BR /&gt;Vulnerabilities:&lt;BR /&gt;Itlb multihit: Not affected&lt;BR /&gt;L1tf: Not affected&lt;BR /&gt;Mds: Not affected&lt;BR /&gt;Meltdown: Not affected&lt;BR /&gt;Mmio stale data: Not affected&lt;BR /&gt;Retbleed: Not affected&lt;BR /&gt;Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl&lt;BR /&gt;Spectre v1: Mitigation; usercopy/swapgs barriers and __user pointer sanitization&lt;BR /&gt;Spectre v2: Mitigation; Enhanced IBRS, IBPB conditional, RSB filling, PBRSB-eIBRS SW sequence&lt;BR /&gt;Srbds: Not affected&lt;BR /&gt;Tsx async abort: Not affected&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;- mpirun --version output:&lt;/P&gt;&lt;P&gt;Intel(R) MPI Library for Linux* OS, Version 2021.9 Build 20230307 (id: d82b3071db)&lt;BR /&gt;Copyright 2003-2023, Intel Corporation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;- The code I'm using is an open-source code called Sparta, following the user guide I compile it with Make, using a Makefile to specify the compiler. It compiles a bunch of files but to summarise, first, it compiles each file individually with:&lt;/P&gt;&lt;P&gt;mpicxx -O3 -DSPARTA_GZIP -DSPARTA_BIGBIG -c ../write_grid.cpp&lt;/P&gt;&lt;P&gt;mpicxx -O3 -DSPARTA_GZIP -DSPARTA_BIGBIG -c ../write_surf.cpp&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;And in the end, it compiles all output files into one executable with:&lt;/P&gt;&lt;P&gt;mpicxx -O write_grid.o write_surf.o -o ../spa_mpi_big_intel&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I think I solved the "cannot find mpi.h" error by myself by adding to the /.bashrc:&lt;/P&gt;&lt;P&gt;export CPATH=/opt/intel/oneapi/mpi/2021.9.0/include:$CPATH&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But now on the last step of compiling everything into a single executable, I get the following error:&lt;/P&gt;&lt;P&gt;/usr/bin/ld: cannot find -lmpicxx: No such file or directory&lt;BR /&gt;/usr/bin/ld: cannot find -lmpifort: No such file or directory&lt;BR /&gt;/usr/bin/ld: cannot find -lmpi: No such file or directory&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I understood that mpicxx automatically resolved the libraries it needed, but seeing this error I tried to solve it by adding to the /.bashrc:&lt;/P&gt;&lt;P&gt;export LD_LIBRARY_PATH=/opt/intel/oneapi/mpi/2021.9.0/lib/release:$LD_LIBRARY_PATH&lt;/P&gt;&lt;P&gt;However, this has not resolved the issues with the three -lmpi***&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope this is enough information and I made myself clear!&lt;/P&gt;&lt;P&gt;(I also wanted to add that it seems weird to me that I get an error for the -lmpifort library as the code is written in cpp, so I don't get why fortran should come up, maybe one of the multiple files of the code is written in fortran, but it seemed weird).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 10:43:36 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489222#M10622</guid>
      <dc:creator>MaxAmer</dc:creator>
      <dc:date>2023-05-24T10:43:36Z</dc:date>
    </item>
    <item>
      <title>Re: Fatal error: mpi.h: no such file or directory</title>
      <link>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489329#M10628</link>
      <description>&lt;P&gt;Update!&lt;/P&gt;&lt;P&gt;I had mistakenly assumed that setting the environment variables with ". /opt/intel/oneapi/setvars.sh" was all good and done, but I did not remember that the environment must be reloaded each session.&lt;/P&gt;&lt;P&gt;So what I did is source the setvars.h to the bashrc so I don't have to load it each time and now it compiled without issues.&lt;/P&gt;&lt;P&gt;Happy to have solved it by myself even though this is probably a very basic mistake!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2023 16:39:46 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489329#M10628</guid>
      <dc:creator>MaxAmer</dc:creator>
      <dc:date>2023-05-24T16:39:46Z</dc:date>
    </item>
    <item>
      <title>Re:Fatal error: mpi.h: no such file or directory</title>
      <link>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489907#M10635</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Glad to know that your issue is resolved. If you need any additional information, please post a new question as this thread will no longer be monitored by Intel.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards&lt;/P&gt;&lt;P&gt;Shivani&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 25 May 2023 08:53:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-MPI-Library/Fatal-error-mpi-h-no-such-file-or-directory/m-p/1489907#M10635</guid>
      <dc:creator>ShivaniK_Intel</dc:creator>
      <dc:date>2023-05-25T08:53:45Z</dc:date>
    </item>
  </channel>
</rss>

