Install Postgres on Cent OS.
Update System Packages:
sudo yum update
Check your specific repository configuration as package names
dnf search postgis
for eg: this is what I got
dnf search postgis
Last metadata expiration check: 0:30:23 ago on Mon 13 Jan 2025 10:06:03 AM UTC.
============================================================== Name Exactly Matched: postgis ===============================================================
postgis.x86_64 : Geographic Information Systems Extensions to PostgreSQL
============================================================= Name & Summary Matched: postgis ==============================================================
postgis-client.x86_64 : The CLI clients for PostGIS
postgis-docs.x86_64 : Extra documentation for PostGIS
postgis-gui.x86_64 : The shp2pgsql-gui utility for PostGIS
postgis-upgrade.x86_64 : Support for upgrading Postgis
postgis-utils.x86_64 : The utils for PostGIS
================================================================= Summary Matched: postgis =================================================================
SFCGAL.x86_64 : C++ wrapper library around CGAL for PostGIS
Paste whatever finding you have from dnf search postis
and ask for the installation procedure in chatgpt or claude.
Mine steps are below.
sudo dnf install postgis postgis-client postgis-utils
sudo dnf install postgis postgis-client postgis-utils
If you plan to do any shapefile imports through a GUI interface, you might also want:
sudo dnf install postgis-gui
Now finally login to your database from the client and
CREATE EXTENSION postgis;