sudo apt update
sudo apt -y upgrade
sudo apt -y install vim bash-completion wget
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
You can now add the repository to your source list
echo "deb http://apt.postgresql.org/pub/repos/apt/ `lsb_release -cs`-pgdg main" |sudo tee /etc/apt/sources.list.d/pgdg.list
You might need to change your /etc/apt/sources.list
if you get any dependancy issues to install some packages that are not available in Ubuntu 20
deb http://security.ubuntu.com/ubuntu bionic-security main
deb http://cz.archive.ubuntu.com/ubuntu bionic main
deb http://cz.archive.ubuntu.com/ubuntu bionic main universe
sudo apt install postgresql-13 postgresql-client-13 postgres-13-postgis-3
# Checking running clusters
pg_lsclusters
systemctl status [email protected]
cd /tmp/
DIR=mobility
VERSION=v1.0-beta4
wget https://github.com/MobilityDB/MobilityDB/archive/refs/tags/${VERSION}.tar.gz
mkdir ${DIR}-${VERSION} && cd ${DIR}-${VERSION}
echo "Extracting the tar ball"
tar xvfz MobilityDB-1.0.tar.gz
cd MobilityDB-1.0
echo "To compile assuming you have all the dependencies in your search path"
mkdir build
cd build
cmake ..
make
sudo make install
Connect to your DB and install the extensions needed
psql -h localhost -U postgres
psql (13.4 (Ubuntu 13.4-4.pgdg18.04+1))
SSL connection (protocol: TLSv1.3, cipher: TLS_AES_256_GCM_SHA384, bits: 256, compression: off)
postgres=#CREATE DATABASE mobility
postgres=#\c mobility
mobility=#CREATE EXTENSION postgis;
mobility=#CREATE EXTENSION MobilityDB;
If you get this error
ERROR: could not access file "$libdir/postgis-3": No such file or directory
try reinstalling the postgres-13-postgis-3 package again
If you're installing mobility and you get the error
CMake Error at cmake/FindPOSTGIS.cmake:35 (message):
No PostGIS library have been found
You need to check if you've added the POSTGIS
extension to your mobility databse in postgres
If you're installing mobility and you get the error
CMake Error at cmake/FindGEOS.cmake:200 (MESSAGE):
Could not find GEOS
Run this
sudo apt update && sudo apt upgrade -y
sudo apt install libgeos++-dev libgeos-3.8.0 libgeos-c1v5 libgeos-dev libgeos-doc
If you're installing mobility and you get the error
CMake Error at /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message):
Could NOT find GSL (missing: GSL_INCLUDE_DIR GSL_LIBRARY GSL_CBLAS_LIBRARY)
Run this
sudo apt update && sudo apt upgrade -y
sudo apt-get install libgsl-dev
So far stuck on this error
CMake Error at CMakeLists.txt:128 (math): math cannot parse the expression: " * 10 + ": syntax error, unexpected exp_TIMES (2). -- POSTGIS_GEOS_VERSION: ERROR -- JSON-C_INCLUDE_DIRS: /usr/include/json-c -- JSON-C_LIBRARIES: /usr/lib/x86_64-linux-gnu/libjson-c.so -- POSTGIS_PROJ_VERSION: 63 -- Substitution: /home/ahmedbaig/Encfs/DesicionLabs/MobilityDB-1.0-beta4/build/libMobilityDB-1.0.so -- XZ_EXECUTABLE: /usr/bin/xz -- XZCAT_EXECUTABLE: /usr/bin/xzcat -- PROJECT_DOC_TARGETS = -- PROJECT_BUILD_LANGUAGES = en -- PROJECT_BUILD_LANGUAGES_STRING = English
Looking for solutions