Page 1 of 1

unable to execute 'mpicc': No such file or directory

Posted: Thu Oct 27, 2016 6:16 pm
by pascal
I am trying to install NEURON on CentOS 7. I need it to have parallel capabilities and work with Python, so I am following these steps:

Code: Select all

1. Clone InterViews and NEURON sources into the current directory:
hg clone http://www.neuron.yale.edu/hg/neuron/iv
hg clone http://www.neuron.yale.edu/hg/neuron/nrn
2. Install InterViews:
	cd iv
./build.sh
./configure
make
sudo make install
3. Install NEURON:
cd ../nrn
./build.sh
./configure --with-iv --with-nrnpython --with-paranrn 
make
sudo make install
I have managed to make it all the way to the very last step, but when I issue the command sudo make install, I get the following error:

unable to execute ‘mpicc’: No such file or directory
error: command ‘mpicc’ failed with exit status 1

I am confused by this, as I have installed openmpi, and the command which mpicc returns /usr/lib64/openmpi/bin/mpicc.

This is my first time attempting to install NEURON on my own personal Linux machine, and NEURON is basically the first thing I've installed on it, so am I possibly missing some libraries? Or maybe I did not install openmpi correctly?

Re: unable to execute 'mpicc': No such file or directory

Posted: Fri Oct 28, 2016 11:54 am
by hines
Since mpicc is in /usr/lib64/openmpi/bin , I would guess you need
export LD_LIBRARY_PATH=/usr/lib64/openmpi/lib:$LD_LIBRARY_PATH
But I don't know why openmpi would end up in /usr/lib64/openmpi on installation.

Re: unable to execute 'mpicc': No such file or directory

Posted: Fri Oct 28, 2016 1:48 pm
by pascal
I checked, and /usr/lib64/openmpi/bin is already included in LD_LIBRARY_PATH. To install openmpi, I simply executed the command yum install openmpi openmpi-devel, and it apparently installed it in /usr/lib64. Should I perhaps uninstall it and then re-install in /usr/local ?

Re: unable to execute 'mpicc': No such file or directory

Posted: Fri Oct 28, 2016 2:05 pm
by hines
/usr/lib64/openmpi/bin is already included in LD_LIBRARY_PATH.
I assume you mean /usr/lib64/openmpi/bin is in PATH and /usr/lib64/openmpi/lib is in LD_LIBRARY_PATH.
Actually, it is rare for installers to require changes to LD_LIBRARY_PATH. I tends to be used when things are not setup correctly to force a program to look in a particular
place for its libraries. Anyway, what is the result of
mpicc --version
sudo mpicc --version
If the first is working but not the second, you can consider installing NEURON in a location that does not require sudo. I.e. in your nrn folder
./configure --prefix=`pwd` --with-iv --with-nrnpython --with-paranrn
make
make install
Otherwise you can diagnose what is going wrong by inspecting
ldd `which mpicc`
sudo ldd `which mpicc`

Re: unable to execute 'mpicc': No such file or directory

Posted: Sat Oct 29, 2016 6:58 pm
by pascal
Whoops...yes, I meant /usr/lib64/openmpi/lib was in LD_LIBRARY_PATH.

Okay, I re-installed openmpi from source, putting it in /usr/local/openmpi. Then I installed interviews in ~/local/iv. No problem. Then I tried installing nrn in ~/local/nrn, so that I would not have to use sudo to install it. Unfortunately, this still did not work. Executing 'make install' generated a similar error, though not exactly the same:


Fatal error: can't create build/temp.linux-x86_64-2.7/graphicsPrimitives.o: Permission denied
error: command 'mpicc' failed with exit status 1


So it seems now it's a problem that I'm not using sudo, plus it's still having trouble with mpicc. I have made sure that LD_LIBRARY_PATH includes /usr/local/openmpi/lib , and the command 'which mpicc' returns /usr/local/openmpi/bin/mpicc .

Any other ideas?

Re: unable to execute 'mpicc': No such file or directory

Posted: Sun Oct 30, 2016 9:10 am
by hines
Let's see if this is related to the python module. Configure and build again leaving out the --with-nrnpyton option.
If there is an error, it is helpful to know what file was being compiled.
Let's take this to email.