[postgis-users] NAD conversion problem

Richard Greenwood richard.greenwood at gmail.com
Fri Dec 5 22:03:09 PST 2008


On Thu, Dec 4, 2008 at 1:19 PM, Peter N. Schweitzer
<pschweitzer at usgs.gov> wrote:
> Hello,
>
> I have two PostgreSQL installations.  One uses 8.3.3 with PostGIS 1.3.3,
> GEOS 3.0.1, and PROJ 4.6.1 (with proj-datumgrid-1.4).  With it I am able to
> run a command like
>
> update county set nad27_geom=ST_Transform(the_geom,4267);
>
> My newer installation uses 8.3.5 with PostGIS 1.3.4, GEOS 3.0.3, and
> PROJ 4.6.1.  With this system I get the error message
>
> WARNING:  transform: -38 (failed to load NAD27-83 correction file)
> ERROR:  transform: couldn't project point: -38 (failed to load NAD27-83
> correction file)
>
> I know that proj-datumgrid-1.4.zip must be unzipped in the nad/
> directory of proj-4.6.1 PRIOR to running configure.  I have done this.
> I have also recompiled and reinstalled proj, GEOS, and PostGIS in that
> order, running ldconfig at the end of each step.  The directory
> /usr/local/share/proj on each of these systems is identical.
>
> I've tried recreating the database cluster, starting and stopping
> the database instance, rebooting the machine, dropping and rebuilding
> the spatial database, all to no avail.
>
> So I'm looking for some setting that I may have missed, some environment
> variable, or some trick to tell libproj.so.0.5.5 where its transform
> files should go.
>
> Both systems run Slackware 12.1.
>
> I'm at wit's end.  Any clues?
>
> Pete

PROJ_LIB is an environment variable that points to the directory
containing grid shift files and EPSG parameter files.

The grid shift files are binary and platform specific. Is it possible
that you are using Windows grid shift files on a Linux system?

You could also rule out issues related to the different versions of
Postgres and PostGIS on you two systems by testing at the command line
with the cs2cs utility which is a part of Proj.

Good luck,
Rich

-- 
Richard Greenwood
richard.greenwood at gmail.com
www.greenwoodmap.com



More information about the postgis-users mailing list