[Gdal-dev] gdal fails on vrt (virtual raster) file

Frank Warmerdam warmerdam at pobox.com
Wed Sep 5 10:21:30 EDT 2007


WolfgangZ wrote:
> Hi,
> 
> Gdal fails on my virtual raster file that links to JPEG graphics. Map 
> size is 17121x12100 pixel and 13.8 MB of filesize (JPEG images).
> 
> Here the command (but also gdal_translate fails with the same error):
> 
> D:\DOP>gdalinfo referenz.vrt
> ERROR 1: libjpeg: Failed to create temporary file
> gdalinfo failed - unable to open 'referenz.vrt'.
> Open GDAL Datasets:
>   1 N DriverIsNULL 512x512x0
> 
> Any help is welcome.
> Wolfgang

Wolfgang,

This is an issue in the JPEG driver.  It seems that libjpeg tries to
create a temporary file when an operation (like processing a progressive
jpeg) would require quite a bit of memory.  If it fails to create the file
you get the message you see.

I recently changed the amount of memory at which this happens to be 500MB
instead of 1MB in the builtin libjpeg for GDAL (SVN trunk)

   http://trac.osgeo.org/gdal/changeset/11706

If you are building GDAL from source, then you might want to apply the
same change.

It might also be sufficient to copy the jpeg file to a directory where
you have read-write access.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org




More information about the Gdal-dev mailing list