concept gdalinfo in category postgis

appears as: gdalinfo
PostGIS in Action, Third Edition

This is an excerpt from Manning's book PostGIS in Action, Third Edition.

Using gdalinfo to inspect rasters

When encounter raster data, it’s worth taking a closer look before you take the trouble of importing it. gdalinfo provides detailed information about specific raster sources.

Depending on your installation, gdalinfo will only be able to inspect certain raster formats. To see which, use the --formats switch as follows:

gdalinfo --formats

Besides providing information about the raster, gdalinfo gives you information that will help you troubleshoot when an import goes awry. To read the metadata of raster, run gdalinfo as shown in the following listing. (This example uses the file extracted from dds.cr.usgs.gov/srtm/version2_1/SRTM3/Eurasia/N48E086.hgt.zip.)