Question

Few days ago I've tried to compile and make CUDA Toolkit 5.0 samples to verify installation. But, during make process there was error while making simpleMPI sample. Without going into details I assumed I need to install Open MPI to my host. I've downloaded latest version for that moment, e.g. openmpi-1.6.2. Then according to Open MPI FAQ page I've run

    ./configure --prefix=/usr/local
    make all install

But unfortunately there was error during make command. I've decided to go into depth and figured out, that Mac OS X have a built-in Open MPI bundle. I've found one more FAQ page for Mac OS X users, and tried to install Open MPI in /opt/openmpi folder this way

    ./configure --prefix=/opt/openmpi 2>&1 | tee config.out
    shell$ make -j 4 2>&1 | tee make.out`

There was no luck again. Make failed. At that moment I've understood that I could skip simpleMPI sample and I did so!

Than once again, without going into details I've decided to clean my system from unneccessary files and did stupid thing make unistall instead of make clean.

Now, nvcc compiler seems to be broken and I need to reinstall or repair built-in Open MPI bundle.

The question is how can I achieve that? Alsough I have TimeMachine backups.

P.S. The issue with simpleMPI CUDA sample is descibed here. There is a already a clear answer how to make simpleMPI sample build.

UPDATE [22:09 UTC 03 NOV 2012]

Have no luck after successfull MPICH2 installation. Proper values added to PATH:

    vim ~/.bash_profile
    export MPI_DIR=/usr/local/Cellar/mpich2/1.5/
    export PATH=$MPI_DIR/bin:/usr/local/cuda/bin:/Developer/NVIDIA/CUDA-5.0/bin:$PATH
    export LD_LIBRARY_PATH=$MPI_DIR/lib:$LD_LIBRARY_PATH
    export DYLD_LIBRARY_PATH=/usr/local/cuda/lib:$DYLD_LIBRARY_PATH
    export EDITOR=vim

Running NSight via terminal call nsight. It's important, because I've tried to lock NSight into Docks. But when running from Dock NSight couldn't find GPU device. So each time I use terminal.

I tried to create new CUDA Runtime C/C++ Project and simply run it. But NSight make fails each time the same way. Here it is:

    nvcc -G -g -O0   "src/Simple CUDA RT Proj.o" "../src/Simple CUDA RT Proj.cu"
    i686-apple-darwin11-llvm-g++-4.2: src/Simple CUDA RT Proj.o: No such file or directory
    make: *** [src/Simple CUDA RT Proj.o] Error 1

Each project the same issue major .o file missing.

UPDATE [10:36 UTC 4 NOV 2012]

I've installed Fortran Compiler via brew. And tried to build OMPI (according OSX FAQ entity) with prefix urs/local. After an hour or two make failed with error:

    sh: usr/local/cuda/bin/echo: No such file or directory
    make[2]: *** [util/hostfile/orte_hosts.7] Error 127
    make[2]: *** Waiting for unfinished jobs....
    make[1]: *** [all-recursive] Error 1
    make: *** [all-recursive] Error 1

UPDATE [13:40 UTC 5 NOV 2012]

Tried to build open-mpi-v1.9 with follow parameters:

   ./configure --enable-shared --enable-sharedlibs=osx-gcc --enable-fast=all --prefix=/usr/local --with-cuda=/usr/local/cuda --with-cudalib=/usr/local/cuda/lib

Now make failed with similar error:

   sh: usr/local/cuda/bin/mv: No such file or directory

Looks like make-script try to access top level binaries inside cuda/bin directory and make fails. It seems make-script incorrectly converts relative fast system-wide calls such mv or echo to absolute path using cuda bin directory. Is that incorrect configure options or Open MPI bug?

Or, maybe Open MPI is not major issue? Maybe I should looks for something else? My main coal is running CUDA code!

Was it helpful?

Solution

Turns out the problem was caused by whitespaces in the file path, similar to the case in this question.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top