Thanks Tim, That was so detailed and helpful, so appreciated ! However, other libraries are still missing: libhdf5_hl.so.6 and libhdf5.so.6. I have tried to link these libraries to existing ones (after copying) as suggested in here: https://sr6033.github.io/linux/2017/05/26/Installing-libhdf5-in-Ubuntu.html > sudo ln -s libhdf5_serial.so libhdf5.so.6> sudo ln -s libhdf5_serial_hl.so > libhdf5_hl.so.6 Then I got another library missing:mris_make_surfaces: error while loading shared libraries: libhdf5.so.8: cannot open shared object file: No such file or directory
So I got confused having different versions of the same library missing. I have found different versions of the library in here https://launchpad.net/ubuntu/xenial/+package/libhdf5-dev but I cannot find the ones I need. Do you please have an idea how can I fix this issue ? Thanks, Amal Le vendredi 13 juillet 2018 à 12:40:01 UTC−4, Timothy B. Brown <tbbr...@wustl.edu> a écrit : Hello Amal, The error that is likely to be causing the problem you are having is reported very early in the screen shot you sent. Notice that about 10 lines from the top of the screen shot there is a line that reads: mris_make_surfaces: error while loading shared libraries: libnetcdf.so.6: cannot open shared object file: No such file or directory Unfortunately, the mris_make_surfaces binary that is part of FreeSurfer v5.3.0-HCP is linked to use a very specific version of the libnetcdf.so shared library, libnetcdf.so.6. But that version of the library is not distributed with Ubuntu 16.04. In fact, you may not have any version of libnetcdf.so installed on your machine. Try the following: 1. Get the latest netcdf libraries and interfaces installed on your system. $ dpkg -l | grep netcdf If this returns no results, then no netcdf libraries or interfaces are installed. If it returns only a line that ends with "Interface for scientific data access to large binary data", then the interface files are installed, but not an actual implementation of the interface. In either of these cases, try the following command to install the latest libnetdcf interface and development library: $ sudo apt install libnetcdf-dev Once that installation succeeds, you should issue another dpkg command like above and see results indicating that both the interface files and the development library are installed. $ dpkg -l | grep netcdf ii libnetcdf-dev 1:4.4.0-2 amd64 creation, access, and sharing of scientific data ii libnetcdf11 1:4.4.0-2 amd64 Interface for scientific data access to large binary data This indicates that you have the latest copies installed. You should be able to find a copy of libnetcdf.so.11 in your /usr/lib/x86_64_linux_gnu directory now. A command like: $ sudo ls -l /usr/lib/x86_64-linux-gnu/libnetcdf* should show /usr/lib/x86_64-linux-gnu/libnetcdf.so.11 linked to libnetcdf.so.11.0.0. 2. Install a 64-bit copy of version 6 of the libnetcdf.so library Visit https://launchpad.net/ubuntu/precise/amd64/libnetcdf6/1:4.1.1-6 Under "Downloadable files" on that page, select the link to download libnetcdf6_4.1.1-6_amd64.deb. (You may be warned that this type of file can harm your computer. Keep/download the file anyhow. Do not automatically open the file, just save it.) Find the downloaded libnetcdf6_4.1.1-6_amd64.deb file. You should not do a simple installation using the libnetcdf6_4.1.1-6_amd64.deb file and the Ubuntu Software Installation application. Instead, you should open the deb file with the Ubuntu Archive Manager (right click on the file in your file manager and select Open With --> Archive Manager). The archive will contain 3 files: control.tar.gz, data.tar.gz, and debian-binary. Extract the data.tar.gz file, by selecting it in the Archive Manager and dragging it to a temporary directory in your file manager. In my case the libnetcdf6_4.1.1-6_amd64.deb file was put in my ${HOME}/Downloads directory, and I put the data.tar.gz file in the ${HOME}/Downloads/tmp directory. Then you'll need to extract out the contents of the data.tar.gz file to a directory that you will add to your LD_LIBRARY_PATH environment variable so that libnetcdf.so.6 is found when mris_make_surfaces is run. Use commands similar to the following: $ cd $ mkdir shared_libraries $ cd shared_libraries $ tar xvf ${HOME}/Downloads/tmp/data.tar.gz This should create a usr subdirectory below your shared_libraries subdirectory and if you look in ${HOME}/shared_libraries/usr/lib you should see files like: $ cd $ cd shared_libraries/usr/lib $ ls libcf.so.0 libnetcdf_c++.so.5 libnetcdff.so.5 libnetcdf.so.6 netcdf.pc libcf.so.0.0.0 libnetcdf_c++.so.5.0.0 libnetcdff.so.5.0.0 libnetcdf.so.6.0.0 $ Next, you'll need to set your LD_LIBRARY_PATH environment variable before running any script that uses mris_make_surfaces so that when looking for shared libraries it will look in your ${HOME}/shared_libraries/usr/lib directory before looking in the remaining "standard" locations. $ export LD_LIBRARY_PATH=${HOME}/shared_libraries/usr/lib Note: If your LD_LIBRARY_PATH already has some value, you'll want to use a command like: $ export LD_LIBRARY_PATH=${HOME}/shared_libraries/usr/lib:${LD_LIBRARY_PATH} instead of the earlier command. Note: You only want to use version 6 of the libnetcdf library when using FreeSurfer v5.3.0-HCP. You don't want to use it for any other software on your system that happens to use libnetcdf because that other software may depend upon behavior in later versions of the libnetcdf library. That is why it is safer to not allow version 6 to be installed in /usr/lib where it might be found by other software using the libnetcdf library. Basically, you don't want to contaminate your standard library locations with old libraries. That is also why you should only set the LD_LIBRARY_PATH environment variable as shown above when you are running FreeSurfer v5.3.0-HCP. Once you've installed version 6 of the libnetcdf library in a directory and made sure LD_LIBRARY_PATH points to that directory, try running the FreeSurferPipeline.sh script again. Lastly, in the future please ask questions like this to the HCP-Users mailing list. That way other people can either benefit from the answer if it is correct or correct my answer if I've made mistakes. I've gone ahead and sent this response to that list and to your email address too because I don't know if you are subscribed to the list. You can subscribe to the HCP-Users mailing list by visiting https://www.humanconnectome.org/contact-us. There is a place to join our two email lists, HCP-Announce and HCP-Users, on the right hand side of that page. Hope that's helpful, Tim On 2018-07-12 04:51 PM, Boukhdhir Amal wrote: Hello Tim, After running the PreFreesurferHCP pipeline in the HCP connectome course and reproducing that on my computer successfully, I am getting thgis issue with the Freesurfer pipeline (as a second step in the structural pipeline). I attached the reconn-all.log file and a screenshot of the error. The freesurfer version I am using is: freesurfer-Linux-centos6_x86_64-stable-pub-v5.3.0-HCP These are more informations related to the distribution I am using: aboukhdhir@thuya:/mnt/home_sq/aboukhdhir$ cat /etc/os-release NAME="Ubuntu" VERSION="16.04.3 LTS (Xenial Xerus)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 16.04.3 LTS" VERSION_ID="16.04" HOME_URL="http://www.ubuntu.com/" SUPPORT_URL="http://help.ubuntu.com/" BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/" VERSION_CODENAME=xenial UBUNTU_CODENAME=xenial I have also tried the same pipeline on 2 other computers with different RAMs and I am getting the same error. Do you please have an idea why I am getting this error and how can I solve it ? Best, Amal -- Timothy B. Brown Business & Technology Application Analyst III Pipeline Developer (Connectome Coordination Facility) tbbrown(at)wustl.edu The material in this message is private and may contain Protected Healthcare Information (PHI). If you are not the intended recipient, be advised that any unauthorized use, disclosure, copying or the taking of any action in reliance on the contents of this information is strictly prohibited. If you have received this email in error, please immediately notify the sender via telephone or return mail. _______________________________________________ HCP-Users mailing list HCP-Users@humanconnectome.org http://lists.humanconnectome.org/mailman/listinfo/hcp-users