2

When I try to enable PostGis extension on my database I receive the following:

postgis=# CREATE EXTENSION postgis;
ERROR:  could not load library "/usr/pgsql-9.3/lib/rtpostgis-2.1.so": libhdf5.so.6: cannot open shared object file: No such file or directory

I used find -name to find the files:

[root@digihaul3-pc /]# find -name rtpostgis-2.1.so
./usr/pgsql-9.3/lib/rtpostgis-2.1.so

[root@digihaul3-pc /]# find -name libhdf5.so.6
./usr/lib64/mpich2/lib/libhdf5.so.6
./usr/pgsql-9.3/lib/libhdf5.so.6
./usr/lib/mpich2/lib/libhdf5.so.6
3
  • Which operating system are you running? You might find an answer here -- but without more details I can't advise further. Commented Mar 29, 2014 at 2:47
  • CentOS, Ruby on rails 3, ruby 1.9.3 Commented Mar 29, 2014 at 5:31
  • That's unfortunate, I'm guessing you've found most of the other help I've seen which is that there appear to be issues installing in CentOS. However, this looks most useful and this may also help, although not about CentOS. Sorry I can't help further, I don't use CentOS much because of issues like this... Commented Mar 29, 2014 at 12:42

1 Answer 1

1

Credit to Thinking Monkey @ on this post

it is for fordora 15. But i tried everything else and this actually fixed my issue and allowed me to install the postgis extentions. Doesn't take long to install.

Thinking Monkeys Post:

Checked for whether /etc/ld.so.conf has a reference to the path /usr/lib64/mpich2/lib.

by doing  ldconfig -p | grep libhdf5.

Which did not output anything.

On checking that /etc/ld.so.conf had  include ld.so.conf.d/*.conf.

Checked for the files in directory ld.so.conf.d. One of the conf file in include ld.so.conf.d was /etc/ld.so.conf.d/atlas-x8664.conf which contained /usr/lib64/atlas.

So I,

    created a file called gdal.conf in the directory ld.so.conf.d.
    Added the string /usr/lib64/mpich2/lib to the file.
    Ran ldconfig.
    Now, ldconfig -p | grep libhdf5 had the paths to llibhdf5 files.
    After doing the above, postgis raster support installation went smoothly.
Sign up to request clarification or add additional context in comments.

1 Comment

its looking for .6 but my libhdf5 files are all .7

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.