[GRASS-dev] [GRASS GIS] #2434: v.surf.bspline: WARNING: Unable to rename null file / WARNING: Unable to write quant rules:

GRASS GIS trac at osgeo.org
Sun Dec 6 06:37:38 PST 2015


#2434: v.surf.bspline: WARNING: Unable to rename null file / WARNING: Unable to
write quant rules:
-------------------------+-------------------------------------------------
  Reporter:  baharmon    |      Owner:  grass-dev@…
      Type:  defect      |     Status:  new
  Priority:  major       |  Milestone:  7.0.3
 Component:  Raster      |    Version:  svn-releasebranch70
Resolution:              |   Keywords:  v.surf.bspline, raster, quant
                         |  rules, null file, cell file
       CPU:  OSX/Intel   |   Platform:  MSWindows 8
-------------------------+-------------------------------------------------

Comment (by hellik):

 Replying to [comment:21 glynn]:
 > Replying to [ticket:2434 baharmon]:
 >
 > My main suspicion is that this is caused by the DBMI driver process
 being spawned after the output raster is opened (so it inherits a handle)
 and still being alive when Rast_close() is called (similar to issue
 #2775).
 >
 > If the driver inherits a handle to the temporary null and cell files,
 renaming them will fail as the files will be "open".
 >
 > If that's what's happening, either the close-on-exec flag needs to be
 set on those files, or DBMI drivers need to close all open files between
 the fork() and the exec(), or the DBMI driver needs to be terminated
 before closing the raster.
 >
 > Also, see the "Open/close db drivers order" thread (ca Oct 22) on the
 grass-dev list for some more discussion of this.

 {{{
 Author: annakrat
 Date: 2015-12-05 06:51:04 -0800 (Sat, 05 Dec 2015)
 New Revision: 67020

 Modified:
    grass/trunk/vector/v.surf.bspline/main.c
 Log:
 v.surf.bspline: move opening raster after opening driver, closing is in
 reverse order, attempt to fix #2434
 }}}

 tested with

 {{{
 System Info
 GRASS version: 7.1.svn
 GRASS SVN revision: 67023M
 Build date: 2015-12-06
 Build platform: i686-pc-mingw32
 GDAL: 1.11.3
 PROJ.4: 4.9.2
 GEOS: 3.5.0
 SQLite: 3.7.17
 Python: 2.7.4
 wxPython: 2.8.12.1
 Platform: Windows-7-6.1.7601-SP1 (OSGeo4W)
 }}}


 {{{
 g.region -p region=rural_1m at PERMANENT res=2
 projection: 99 (Lambert Conformal Conic)
 zone:       0
 datum:      nad83
 ellipsoid:  a=6378137 es=0.006694380022900787
 north:      220750
 south:      220000
 west:       638300
 east:       639000
 nsres:      2
 ewres:      2
 rows:       375
 cols:       350
 cells:      131250
 (Sun Dec 06 15:33:21 2015) Command finished (0 sec)

 (Sun Dec 06 15:33:38 2015)
 v.surf.bspline --verbose input=elev_lid792_bepts at PERMANENT
 raster_output=elev_lid792_rast ew_step=5 ns_step=5 method=bicubic
 lambda_i=0.1 memory=900
 Input is 3D: using z-coordinates for approximation
 Cells for raster map <elev_lid792_rast> will be interpolated
 Initializing output...
 Adjusted EW splines 121
 Adjusted NS splines 131
 Processing subregion 1 of 4...
 16805 points found in this subregion
 Processing subregion 2 of 4...
 13741 points found in this subregion
 Processing subregion 3 of 4...
 13512 points found in this subregion
 Processing subregion 4 of 4...
 11564 points found in this subregion
 Writing output...
 v.surf.bspline complete.
 (Sun Dec 06 15:33:54 2015) Command finished (15 sec)
 }}}

 so it seems to work now.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2434#comment:22>
GRASS GIS <https://grass.osgeo.org>



More information about the grass-dev mailing list