I installed PostgreSQL 12 and PostGIS on a new server. I want to use this environment as source for different projects and services.
When I try to import CSV files in the database using psql, I get an error when trying to execute the following:
UPDATE bet_srk_2020 SET geom = ST_SetSRID(ST_MakePoint(AISTrajectPositionLongitude, AISTrajectPositionLatitude) ,4326);
FATAL: failed to load summary "/usr/lib/postgresql/12/lib/bitcode/postgis-3.index.bc": Invalid summary version 7, 1, 2, 3 or 4 expected server closed the connection unexpectedly This probably means the server terminated abnormally before or while processing the request. The connection to the server was lost. Attempting reset: Succeeded.
I tried to find information about this error but can't really find solutions.
I am able to add data to the databases if I use the QGIS Toolbox feature: Export to PostgreSQL
Is this simply a syntax error in my request to the server? Or is there a problem with the installation of PostGIS?
EDIT: 2020 10 30:
Based on CL. comments I investigated the problem in my installation: I use a Ubuntu setup with the apt.postgresql.org repository.
For some reason Postgresql-12 was installed from the postgresql.org repository and postGIS 3.0 was installed from the standard Ubuntu repository. After installing postGIS from the same repo as postgreSQL the problem was solved and server operation is back to normal.