You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I got a segmentation fault when I make runtest in Ubuntu 15.10, this problem is similar to the following issue: ubuntu16.04 runtest failed [----------] 9 tests from AdaGradSolverTest/2, where TypeParam = caffe::GPUDevice<float> [ RUN ] AdaGradSolverTest/2.TestAdaGradLeastSquaresUpdateWithWeightDecay *** Aborted at 1464576931 (unix time) try "date -d @1464576931" if you are using GNU date *** PC: @ 0x7f99aa977143 (unknown) *** SIGSEGV (@0x706d742f) received by PID 12752 (TID 0x7f99b1f20740) from PID 1886221359; stack trace: *** @ 0x7f99a8de43d0 (unknown) @ 0x7f99aa977143 (unknown) @ 0x480463 caffe::MakeTempDir() @ 0x49444a caffe::GradientBasedSolverTest<>::RunLeastSquaresSolver() @ 0x4a533d caffe::GradientBasedSolverTest<>::TestLeastSquaresUpdate() @ 0x893d13 testing::internal::HandleExceptionsInMethodIfSupported<>() @ 0x88a9f7 testing::Test::Run() @ 0x88aa9e testing::TestInfo::Run() @ 0x88aba5 testing::TestCase::Run() @ 0x88dee8 testing::internal::UnitTestImpl::RunAllTests() @ 0x88e177 testing::UnitTest::Run() @ 0x46215f main @ 0x7f99a8a2a830 (unknown) @ 0x469649 _start Makefile:523: recipe for target 'runtest' failed make: *** [runtest] Segmentation fault (core dumped)
My environment is: Ubuntu 15.10 64bit mate intel MKL Cuda 7.5 g++/gcc 4.9.3
I've searched many information and I find this is a common problem.In order to make compile successful,I compiled protobuf, glog,gflags manually with GCC4.9. But I got a runtime error: Segmentation fault.
With the @seanbell 's suggestion in #4235 ,I read the source code of caffe/include/caffe/util/io.hpp
I guess the boost may be the error's reason, so I autoremove libboost-all-dev and compile the boost 1.58 manually with GCC 4.9 .Fortunately , I make runtest successfully !
_The truth:_
@ferrouswheel's post in #4417 inspired me:" I had previously tryed to make CUDA work by changing to gcc 4.9. Unfortunately the c++ ABI changed so compiling stuff with 4.9 and trying to link to system libraries built with gcc 5 won't work."
On thegoogle mailing listDarren Garvey's mail https://groups.google.com/d/msg/caffe-users/a6TDx89IByY/fvsWbwqzCwAJ
clarified the core reason: The issue with linking to protobu, boostf is down to c++ ABI changes between GCC 4.9 and GCC 5.x. The ABI for std::string has changed so you need to be sure to link with compatible libraries.
Since CUDA doesn't officially support GCC >= 4.9, I had set CUDA_HOST_COMPILER to get CUDA stuff compiled. The issue with doing just that is that caffe will build with the default GCC which is 5.2.
If you go ahead and build caffe with GCC 4.9 as well then you'll have link problems against the libprotobuf-dev package which is built with GCC 5.x as with all other Ubuntu packages in 15.10.
You can recompile CUDA and Caffe with GCC 5.2 to make sure the library links between the caffe and libraries in the repository is campatible.You should change the file /usr/local/cuda/include/host_config.h and follow the Ubuntu 16.04 or 15.10 Installation Guide.
Moreover,you may want to build everything with GCC 4.9 but you'll also have to build protobuf and possibly also all other system packages that export c++ functions containing std::string, std::vector, etc.with GCC 4.9 (eg. glog, gflags, boost .etc).
That‘s why compile the boost manually can solve the problem :D
The text was updated successfully, but these errors were encountered:
Please ask installation questions on the mailing list. If you're having trouble, you might want to try the Caffe Dockerfile to take care of installation for you.
Please do not post usage, installation, or modeling questions, or other requests for help to Issues.
Use the caffe-users list instead. This helps developers maintain a clear, uncluttered, and efficient view of the state of Caffe.
I got a segmentation fault when I make runtest in Ubuntu 15.10, this problem is similar to the following issue:
ubuntu16.04 runtest failed
[----------] 9 tests from AdaGradSolverTest/2, where TypeParam = caffe::GPUDevice<float> [ RUN ] AdaGradSolverTest/2.TestAdaGradLeastSquaresUpdateWithWeightDecay *** Aborted at 1464576931 (unix time) try "date -d @1464576931" if you are using GNU date *** PC: @ 0x7f99aa977143 (unknown) *** SIGSEGV (@0x706d742f) received by PID 12752 (TID 0x7f99b1f20740) from PID 1886221359; stack trace: *** @ 0x7f99a8de43d0 (unknown) @ 0x7f99aa977143 (unknown) @ 0x480463 caffe::MakeTempDir() @ 0x49444a caffe::GradientBasedSolverTest<>::RunLeastSquaresSolver() @ 0x4a533d caffe::GradientBasedSolverTest<>::TestLeastSquaresUpdate() @ 0x893d13 testing::internal::HandleExceptionsInMethodIfSupported<>() @ 0x88a9f7 testing::Test::Run() @ 0x88aa9e testing::TestInfo::Run() @ 0x88aba5 testing::TestCase::Run() @ 0x88dee8 testing::internal::UnitTestImpl::RunAllTests() @ 0x88e177 testing::UnitTest::Run() @ 0x46215f main @ 0x7f99a8a2a830 (unknown) @ 0x469649 _start Makefile:523: recipe for target 'runtest' failed make: *** [runtest] Segmentation fault (core dumped)
My environment is:
Ubuntu 15.10 64bit mate
intel MKLCuda 7.5
g++/gcc 4.9.3I've searched many information and I find this is a common problem.In order to make compile successful,I compiled protobuf, glog,gflags manually with GCC4.9. But I got a runtime error: Segmentation fault.
With the @seanbell 's suggestion in #4235 ,I read the source code of caffe/include/caffe/util/io.hpp
caffe/include/caffe/util/io.hpp
Line 24 in be163be
I guess the boost may be the error's reason, so I autoremove libboost-all-dev and compile the boost 1.58 manually with GCC 4.9 .Fortunately , I make runtest successfully !
_The truth:_
@ferrouswheel's post in #4417 inspired me:" I had previously tryed to make CUDA work by changing to gcc 4.9. Unfortunately the c++ ABI changed so compiling stuff with 4.9 and trying to link to system libraries built with gcc 5 won't work."
On thegoogle mailing list Darren Garvey's mail
https://groups.google.com/d/msg/caffe-users/a6TDx89IByY/fvsWbwqzCwAJ
clarified the core reason: The issue with linking to protobu, boostf is down to c++ ABI changes between GCC 4.9 and GCC 5.x. The ABI for std::string has changed so you need to be sure to link with compatible libraries.
Since CUDA doesn't officially support GCC >= 4.9, I had set CUDA_HOST_COMPILER to get CUDA stuff compiled. The issue with doing just that is that caffe will build with the default GCC which is 5.2.
If you go ahead and build caffe with GCC 4.9 as well then you'll have link problems against the libprotobuf-dev package which is built with GCC 5.x as with all other Ubuntu packages in 15.10.
You can recompile CUDA and Caffe with GCC 5.2 to make sure the library links between the caffe and libraries in the repository is campatible.You should change the file
/usr/local/cuda/include/host_config.h
and follow the Ubuntu 16.04 or 15.10 Installation Guide.Moreover,you may want to build everything with GCC 4.9 but you'll also have to build protobuf and possibly also all other system packages that export c++ functions containing std::string, std::vector, etc.with GCC 4.9 (eg. glog, gflags, boost .etc).
That‘s why compile the boost manually can solve the problem :D
The text was updated successfully, but these errors were encountered: