I've had all sorts of trouble getting GeoServer 2.0.2 to create an
ImageMosaic from GeoTIFF files. No matter what I try I get this error:
*Could not list layers for this store, an error occurred retrieving them:
Unable to acquire a reader for this coverage with format: ImageMosaic*
I finally managed to create an ImageMosaic by taking a hint from the *
mosaic_sample* that ships with GeoServer and converting my GeoTIFF files to
PNGs, but I don't feel that this is an ideal solution.
I suspect that the GeoServer GeoTIFF reader is not quite compatible with
the GeoTIFF files that I'm using, even though I've tried all sorts of
conversion tools including gdalwarp, Erdas ViewFinder. I've even followed
the old instructions for manually generating shape information with
gdaltindex.
The images that I'm attempting to mosaic are publically available at this
site:
http://aeronav.faa.gov/index.asp?xml=aeronav/applications/VFR/chartlist_sect
Notice that each image also comes with a world file (.tfw) and an HTML text
description.
These files are somewhat problematic to mosaic in their native state because
each has it's own localized projection. However, I found that I easily could
reproject the files to EPSG:4326 (WGS 84) with both Erdas ViewFinder and
gdalwarp.
In fact, I also had trouble creating a simple GeoTIFF store/layer from just
one of these files until I removed the .tif extension from the file. Once I
did that, GeoServer had no trouble processing the image! GeoServer could not
determine projection information unless I reprojected the files to EPSG:4326
first, but it did load the files either way, so long at the .tif extension
was removed. I also tried .tiff, .geotiff, .TIF, .TIFF, and .GeoTIFF; but
the only method that worked was no extension at all!
Let's consider creating a simple mosaic with just 2 images that are right
next to each other on a map of the earth:
Chicago 81 North.tif
Detroit 81 North.tif
The projection information for each of these files is identical (NAD83 ,
EPS:4269) except for the "latitude of origin":
Chicago: "latitude_of_origin",42.66666666666666
Detroit: "latitude_of_origin",42.1
The tif files also reference the .tfw files.
gdalwarp -t_srs EPSG:4326 "Chicago 81 North.tif" 4326_chicago_81_north.tif
gdalwarp -t_srs EPSG:4326 "Detroit 81 North.tif" 4326_detroit_81_north.tif
After these conversions, the GeoTIFF files no longer reference the tfw files
and the tif files share the exact same projection:
GEOGCS["WGS 84",
DATUM["WGS_1984",
SPHEROID["WGS 84",6378137,298.257223563,
AUTHORITY["EPSG","7030"]],
AUTHORITY["EPSG","6326"]],
PRIMEM["Greenwich",0],
UNIT["degree",0.0174532925199433],
AUTHORITY["EPSG","4326"]]
By copying them to a new chic_det_test directory under the geoserver
coverages directory, I can try to create a new ImageMosaic store:
Data Source Name: chic_det_test
URL: file:coverages/chic_det_test
I always see my favorite error, even if I remove the .tif extensions from
the files:
*Could not list layers for this store, an error occurred retrieving them:
Unable to acquire a reader for this coverage with format: ImageMosaic*
A survey of the geoserver.log file provides no additional information on the
cause of the problem:
2011-02-03 10:57:50,343 INFO [geoserver.web] - Getting list of coverages for
saved store file:coverages/chic_det_test
java.lang.RuntimeException: Could not list layers for this store, an error
occurred retrieving them: Unable to acquire a reader for this coverage with
format: ImageMosaic
The Erdas ViewFinder method is similar. I open the files in that GUI
tool, choose to save as TIFF, with the following Output File Options:
Change Output Pixel Size to Degrees
Change Output Projection to Category: Geographic and Projection: Lat/Lon
(WGS 84)
Resample Method: Nearest Neighbor
Erdas ViewFinder produces a .tfw AND an .aux file, which are both referenced
in the .tif file, so I copy the .tif, .tfw, and .aux files to a new
erdas_chic_det_test folder under geoserver coverages and try again.
Data Source Name: erdas_chic_det_test
URL: file:coverages/erdas_chic_det_test
Same error!
I finally got smart and renamed the .tfw files to .pgw files, grabbed the
projection information the .tif files and created a .prj for each tif, then
opened the tifs in an image editing tool and saved as .png. At least the
image editing allowed me to strip off the legend information (which we
really do not want to display on map of the earth).
That did the trick, but it's not a great solution. These maps are regularly
updated, so we'll need to follow this process every couple months to keep
our site up to date.
If you have any other recommendations, I'd be very grateful!
Thanks for your help,
Juanita Dahlin
------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires
February 28th, so secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users