[postgis-users] Fwd: Location of nadgrid file

Jan Hartmann j.l.h.hartmann at uva.nl
Thu Jan 17 06:52:23 PST 2013


That's it. I exported PROJ_DEBUG=5, and restarted the server. In the log 
I see a proj error message: "pj_open_lib  <path>/test.ntv2 failed", 
followed by the PostGIS error message. The location for ntv2-files seems 
to be:

<postgresql install dir>/share/contrib/postgis-2.1/proj

So I copied the ntv2 file there, restarted the server again, and the 
whole thing works.

Is this a bug? Even when I give an absolute path for the ntv2-file, it 
gets appended to the above location. And I would prefer the ntv2 files 
to be read from the standard proj installation directory. It's given 
with configure, so that shouldn't be a problem. Or should the postgresql 
server only have access to its own install dir? In that case, this 
should be documented.

Anyway, thanks Howard, for the fast reply.

Jan




On 01/17/2013 03:19 PM, Howard Butler wrote:
> Setting PROJ_DEBUG=ON in the shell environment before starting 
> postgres might be instructive.
>
> On Jan 17, 2013, at 8:11 AM, Jan Hartmann <j.l.h.hartmann at uva.nl 
> <mailto:j.l.h.hartmann at uva.nl>> wrote:
>
>> Or perhaps the place in the source code that generates the error message:
>>
>> ERROR:  transform: couldn't project point (155000 463000 0): failed 
>> to load datum shift file (-38)
>>
>> I did several greps on the postgis-2.1.0SVN tree, without any result
>>
>> -------- Original Message --------
>> Subject: 	[postgis-users] Location of nadgrid file
>> Date: 	Thu, 17 Jan 2013 14:46:08 +0100
>> From: 	Jan Hartmann <j.l.h.hartmann at uva.nl>
>> Reply-To: 	PostGIS Users Discussion <postgis-users at lists.osgeo.org>
>> To: 	<postgis-users at lists.osgeo.org>
>>
>>
>>
>> Can anyone tell me where the nadgrids-file, as used by proj4 to apply 
>> grid shifts to a projection, should be installed for postgis? I 
>> produced one, put it in the standard proj installation directory 
>> (/usr/share/proj), and it works from the commandline with cs2cs. 
>> However, when I put an entry in the postgis spatial_ref_sys table for 
>> a new projection with this nadgrids file, the st_transform command 
>> says: "failed to load datum shift file (-38). It also happens when I 
>> put in the whole path. What should I do?
>>
>> Jan
>>
>>
>> <Attached Message Part>
>> _______________________________________________
>> postgis-users mailing list
>> postgis-users at lists.osgeo.org <mailto:postgis-users at lists.osgeo.org>
>> http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
>
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at lists.osgeo.org
> http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20130117/b8b1879a/attachment.html>


More information about the postgis-users mailing list