helvalius / nominatim-docker

Standalone nominatim server in a docker container
44 stars 43 forks source link

Postgis: 2.1 installed, 2.2 required #27

Open Osypchuk opened 4 years ago

Osypchuk commented 4 years ago

2019-11-06 19:43:53 UTC FATAL: database "nominatim" does not exist 2019-11-06 19:43:53 == Setup DB Postgres version found: 9.03 Postgis version found: 2.1 Minimum required Postgis version 2.2 The command '/bin/sh -c sudo -u postgres /usr/lib/postgresql/9.3/bin/pg_ctl start -w -D /etc/postgresql/9.3/main/ && sudo -u nominatim ./utils/setup.php --osm-file /app/data.pbf --all --threads 2' returned a non-zero code: 1

[error]The command '/bin/sh -c sudo -u postgres /usr/lib/postgresql/9.3/bin/pg_ctl start -w -D /etc/postgresql/9.3/main/ && sudo -u nominatim ./utils/setup.php --osm-file /app/data.pbf --all --threads 2' returned a non-zero code: 1

[error]/usr/bin/docker failed with return code: 1

Osypchuk commented 4 years ago

It looks like Postgis 2.2 bundled with Postgre 9.5 https://trac.osgeo.org/postgis/wiki/UsersWikiPostGIS22UbuntuPGSQL95Apt

However, postgre 9.5 supports only Ubuntu 16.04 https://www.postgresql.org/download/linux/ubuntu/

Osypchuk commented 4 years ago

Once I changed apt get to use postgresql-9.5-postgis-2.2 got into dll hell with cmake:

Step 24/52 : RUN cmake /app/git/ ... -- Found Protozero: /app/git/osm2pgsql/contrib/protozero/include (found suitable version "1.6.8", minimum required is "1.6.3") CMake Warning at osm2pgsql/cmake/FindOsmium.cmake:130 (message): Osmium: Can not find some libraries for PBF input/output, please install them or configure the paths. Call Stack (most recent call first): osm2pgsql/CMakeLists.txt:94 (find_package)

-- Found EXPAT: /usr/lib/x86_64-linux-gnu/libexpat.so (found version "2.1.0") -- Found BZip2: /usr/lib/x86_64-linux-gnu/libbz2.so (found version "1.0.6") -- Looking for BZ2_bzCompressInit in /usr/lib/x86_64-linux-gnu/libbz2.so -- Looking for BZ2_bzCompressInit in /usr/lib/x86_64-linux-gnu/libbz2.so - found -- Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR) CMake Warning at osm2pgsql/cmake/FindOsmium.cmake:156 (message): Osmium: Can not find some libraries for XML input/output, please install them or configure the paths. Call Stack (most recent call first): osm2pgsql/CMakeLists.txt:94 (find_package)

CMake Error at /usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:108 (message): Could NOT find Osmium (missing: ZLIB_FOUND) (found suitable version "2.15.3", minimum required is "2.14") Call Stack (most recent call first): /usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:315 (_FPHSA_FAILURE_MESSAGE) osm2pgsql/cmake/FindOsmium.cmake:281 (find_package_handle_standard_args) osm2pgsql/CMakeLists.txt:94 (find_package)