Danny,

it looks like the NetCDF libraries are guessing that your station 
variable is a dimension because its name matches its dimension name, but 
it is not a standard axis and not a supported type. If this was the only 
problem, you could rename the variable.

The larger problem is that this file appears to be a collection of point 
data. As far as I know, NetCDF support is limited to coverages, that is, 
files that define a variable over a two-dimensional spatial grid (and 
higher dimensions). Your file does not have a supported spatial 
structure because it represents a collection of points.

Can you extract the samples and store them in a database, or convert 
them to another file format such as shapefiles or a property file that 
supports point data?

Kind regards,
Ben.

On 11/10/16 22:13, Danny Smit wrote:
> Hello everyone,
>
> I have downloaded the NetCDF file from:
> https://data.knmi.nl/download/Actuele10mindataKNMIstations/1/noversion/2016/10/11/KMDS__OPER_P___10M_OBS_L2.nc
> and am trying to add it as a store to the geoserver.
>
> However when trying to add the store the geoserver gives the error:
>
>     Could not list layers for this store, an error occurred retrieving
> them: Failed to create reader from file:data/KMDS__OPER_P___10M_OBS_L2
> (1).nc and hints null
>
> The geoserver.log gives a couple of warnings and exceptions. However,
> since I'm not very experienced with the netcdf format, I don't know
> what to make of it.  Is there something wrong with the content of the
> .nc file, or perhaps is some of its syntax not supported by the netcdf
> plugin?
>
>
> See below the headers of the .nc file and the warnings and start of
> the exceptions from the logfile.
>
> ncdump outoutp:
>
> netcdf KMDS__OPER_P___10M_OBS_L2\ \(1\) {
> dimensions:
>         station = 48 ;
>         time = 1 ;
> variables:
>         string station(station) ;
>                 station:long_name = "Station id" ;
>                 station:cf_role = "timeseries_id" ;
>         double time(time) ;
>                 time:long_name = "time of measurement" ;
>                 time:standard_name = "time" ;
>                 time:units = "seconds since 1950-01-01 00:00:00" ;
>         string stationname(station) ;
>                 stationname:long_name = "Station name" ;
>         double lat(station) ;
>                 lat:long_name = "station  latitude" ;
>                 lat:standard_name = "latitude" ;
>                 lat:units = "degrees_north" ;
>         double lon(station) ;
>                 lon:long_name = "station longitude" ;
>                 lon:standard_name = "longitude" ;
>                 lon:units = "degrees_east" ;
>         double height(station) ;
>                 height:long_name = "Station height" ;
>                 height:standard_name = "height" ;
>                 height:units = "m" ;
>         double dd(station) ;
>                 dd:_FillValue = -9999. ;
>                 dd:standard_name = "wind_from_direction" ;
>                 dd:units = "degree" ;
>                 dd:long_name = "Wind Direction 10 Min Average" ;
>         double ff(station) ;
>                 ff:_FillValue = -9999. ;
>                 ff:standard_name = "wind_speed" ;
>                 ff:units = "m s-1" ;
>                 ff:long_name = "Wind Speed at 10m 10 Min Average" ;
>         double gff(station) ;
>                 gff:_FillValue = -9999. ;
>                 gff:standard_name = "wind_speed_of_gust" ;
>                 gff:units = "m s-1" ;
>                 gff:long_name = "Wind Gust at 10m 10 Min Maximum" ;
>         double ta(station) ;
>                 ta:_FillValue = -9999. ;
>                 ta:standard_name = "air_temperature" ;
>                 ta:units = "degrees Celsius" ;
>                 ta:long_name = "Air Temperature 1 Min Average" ;
>         double rh(station) ;
>                 rh:_FillValue = -9999. ;
>                 rh:standard_name = "relative_humidity" ;
>                 rh:units = "%" ;
>                 rh:long_name = "Relative Humidity 1 Min Average" ;
>         double pp(station) ;
>                 pp:_FillValue = -9999. ;
>                 pp:standard_name = "air_pressure_at_sea_level" ;
>                 pp:units = "hPa" ;
>                 pp:long_name = "Air Pressure at Sea Level 1 Min Average" ;
>         double zm(station) ;
>                 zm:_FillValue = -9999. ;
>                 zm:standard_name = "visibility_in_air" ;
>                 zm:units = "m" ;
>                 zm:long_name = "Meteorological Optical Range 10 Min Average" ;
>         double D1H(station) ;
>                 D1H:_FillValue = -9999. ;
>                 D1H:long_name = "Rainfall Duration in last Hour" ;
>                 D1H:standard_name = "rainfall_duration" ;
>                 D1H:units = "min" ;
>         double dr(station) ;
>                 dr:_FillValue = -9999. ;
>                 dr:long_name = "Precipitation Duration (Rain Gauge) 10
> Min Sum" ;
>                 dr:standard_name = "precipitation_duration" ;
>                 dr:units = "sec" ;
>         double hc(station) ;
>                 hc:_FillValue = -9999. ;
>                 hc:long_name = "Cloud Base" ;
>                 hc:standard_name = "cloud_base_altitude" ;
>                 hc:units = "ft" ;
>         double hc1(station) ;
>                 hc1:_FillValue = -9999. ;
>                 hc1:long_name = "Cloud Base First Layer" ;
>                 hc1:standard_name = "cloud_base_altitude" ;
>                 hc1:units = "ft" ;
>         double hc2(station) ;
>                 hc2:_FillValue = -9999. ;
>                 hc2:long_name = "Cloud Base Second Layer" ;
>                 hc2:standard_name = "cloud_base_altitude" ;
>                 hc2:units = "ft" ;
>         double hc3(station) ;
>                 hc3:_FillValue = -9999. ;
>                 hc3:long_name = "Cloud Base Third Layer" ;
>                 hc3:standard_name = "cloud_base_altitude" ;
>                 hc3:units = "ft" ;
>         double nc(station) ;
>                 nc:_FillValue = -9999. ;
>                 nc:long_name = "Total cloud cover" ;
>                 nc:standard_name = "cloud_cover" ;
>                 nc:units = "octa" ;
>         double nc1(station) ;
>                 nc1:_FillValue = -9999. ;
>                 nc1:long_name = "Cloud Amount First Layer" ;
>                 nc1:standard_name = "cloud_cover" ;
>                 nc1:units = "octa" ;
>         double nc2(station) ;
>                 nc2:_FillValue = -9999. ;
>                 nc2:long_name = "Cloud Amount Second Layer" ;
>                 nc2:standard_name = "cloud_cover" ;
>                 nc2:units = "octa" ;
>         double nc3(station) ;
>                 nc3:_FillValue = -9999. ;
>                 nc3:long_name = "Cloud Amount Third Layer" ;
>                 nc3:standard_name = "cloud_cover" ;
>                 nc3:units = "octa" ;
>         double pg(station) ;
>                 pg:_FillValue = -9999. ;
>                 pg:long_name = "Precipitation Intensity (PWS) 10 Min Average" 
> ;
>                 pg:standard_name = "lwe_precipitation_rate" ;
>                 pg:units = "mm/h" ;
>         double pr(station) ;
>                 pr:_FillValue = -9999. ;
>                 pr:long_name = "Precipitation Duration (PWS) 10 Min Sum" ;
>                 pr:standard_name = "precipitation_duration" ;
>                 pr:units = "sec" ;
>         double qg(station) ;
>                 qg:_FillValue = -9999. ;
>                 qg:long_name = "Global Solar Radiation 10 Min Average" ;
>                 qg:standard_name = "total_downwelling_shortwave_flux_in_air" ;
>                 qg:units = "W m-2" ;
>         double R12H(station) ;
>                 R12H:_FillValue = -9999. ;
>                 R12H:long_name = "Rainfall in last 12 Hours" ;
>                 R12H:standard_name = "rainfall_amount" ;
>                 R12H:units = "mm" ;
>         double R1H(station) ;
>                 R1H:_FillValue = -9999. ;
>                 R1H:long_name = "Rainfall in last Hour" ;
>                 R1H:standard_name = "rainfall_amount" ;
>                 R1H:units = "mm" ;
>         double R24H(station) ;
>                 R24H:_FillValue = -9999. ;
>                 R24H:long_name = "Rainfall in last 24 Hours" ;
>                 R24H:standard_name = "rainfall_amount" ;
>                 R24H:units = "mm" ;
>         double R6H(station) ;
>                 R6H:_FillValue = -9999. ;
>                 R6H:long_name = "Rainfall in last 6 Hours" ;
>                 R6H:standard_name = "rainfall_amount" ;
>                 R6H:units = "mm" ;
>         double rg(station) ;
>                 rg:_FillValue = -9999. ;
>                 rg:long_name = "Precipitation Intensity (Rain Gauge)
> 10 Min Average" ;
>                 rg:standard_name = "precipitation_rate" ;
>                 rg:units = "mm/h" ;
>         double ss(station) ;
>                 ss:_FillValue = -9999. ;
>                 ss:long_name = "Sunshine Duration" ;
>                 ss:standard_name = "duration_of_sunshine" ;
>                 ss:units = "min" ;
>         double td(station) ;
>                 td:_FillValue = -9999. ;
>                 td:long_name = "Dew Point Temperature 1.5m 1 Min Average" ;
>                 td:standard_name = "dew_point_temperature" ;
>                 td:units = "degrees Celsius" ;
>         double tgn(station) ;
>                 tgn:_FillValue = -9999. ;
>                 tgn:long_name = "Grass Temperature 10cm 10 Min Minimum" ;
>                 tgn:standard_name = "air_temperature" ;
>                 tgn:units = "degrees Celsius" ;
>         double Tgn12(station) ;
>                 Tgn12:_FillValue = -9999. ;
>                 Tgn12:long_name = "Grass Temperature Minimum last 12 Hours" ;
>                 Tgn12:standard_name = "air_temperature" ;
>                 Tgn12:units = "degrees Celsius" ;
>         double Tgn14(station) ;
>                 Tgn14:_FillValue = -9999. ;
>                 Tgn14:long_name = "Grass Temperature Minimum last 14 Hours" ;
>                 Tgn14:standard_name = "air_temperature" ;
>                 Tgn14:units = "degrees Celsius" ;
>         double Tgn6(station) ;
>                 Tgn6:_FillValue = -9999. ;
>                 Tgn6:long_name = "Grass Temperature Minimum last 6 Hours" ;
>                 Tgn6:standard_name = "air_temperature" ;
>                 Tgn6:units = "degrees Celsius" ;
>         double tn(station) ;
>                 tn:_FillValue = -9999. ;
>                 tn:long_name = "Ambient Temperature 1.5m 10 Min Minimum" ;
>                 tn:standard_name = "air_temperature" ;
>                 tn:units = "degrees Celsius" ;
>         double Tn12(station) ;
>                 Tn12:_FillValue = -9999. ;
>                 Tn12:long_name = "Air Temperature Minimum last 12 Hours" ;
>                 Tn12:standard_name = "air_temperature" ;
>                 Tn12:units = "degrees Celsius" ;
>         double Tn14(station) ;
>                 Tn14:_FillValue = -9999. ;
>                 Tn14:long_name = "Air Temperature Minimum last 14 Hours" ;
>                 Tn14:standard_name = "air_temperature" ;
>                 Tn14:units = "degrees Celsius" ;
>         double Tn6(station) ;
>                 Tn6:_FillValue = -9999. ;
>                 Tn6:long_name = "Air Temperature Minimum last 6 Hours" ;
>                 Tn6:standard_name = "air_temperature" ;
>                 Tn6:units = "degrees Celsius" ;
>         double tx(station) ;
>                 tx:_FillValue = -9999. ;
>                 tx:long_name = "Ambient Temperature 1.5m 10 Min Maximum" ;
>                 tx:standard_name = "air_temperature" ;
>                 tx:units = "degrees Celsius" ;
>         double Tx12(station) ;
>                 Tx12:_FillValue = -9999. ;
>                 Tx12:long_name = "Air Temperature Maximum last 12 Hours" ;
>                 Tx12:standard_name = "air_temperature" ;
>                 Tx12:units = "degrees Celsius" ;
>         double Tx24(station) ;
>                 Tx24:_FillValue = -9999. ;
>                 Tx24:long_name = "Air Temperature Maximum last 24 Hours" ;
>                 Tx24:standard_name = "air_temperature" ;
>                 Tx24:units = "degrees Celsius" ;
>         double Tx6(station) ;
>                 Tx6:_FillValue = -9999. ;
>                 Tx6:long_name = "Air Temperature Maximum last 6 Hours" ;
>                 Tx6:standard_name = "air_temperature" ;
>                 Tx6:units = "degrees Celsius" ;
>         double ww(station) ;
>                 ww:_FillValue = -9999. ;
>                 ww:long_name = "wawa Weather Code" ;
>                 ww:units = "code" ;
>                 ww:comment = "WMO table 4680" ;
>         double pwc(station) ;
>                 pwc:_FillValue = -9999. ;
>                 pwc:long_name = "Present Weather" ;
>                 pwc:units = "code" ;
>                 pwc:comment = "KNMI: Handboek waarnemingen" ;
>         double ww-10(station) ;
>                 ww-10:_FillValue = -9999. ;
>                 ww-10:long_name = "wawa Weather Code for Previous 10
> Min Interval" ;
>                 ww-10:units = "code" ;
>                 ww-10:comment = "WMO table 4680" ;
>         char iso_dataset ;
>                 iso_dataset:title = "KMDS__OPER_P___10M_OBS_L2" ;
>                 iso_dataset:abstract = "Most recent 10 minute in situ
> observations of the Dutch meteorological observation network" ;
>                 iso_dataset:status = "ongoing" ;
>                 iso_dataset:type = "dataset" ;
>                 iso_dataset:uid = "c3a312e2-2d8f-440b-ae7d-3406c9fe2f77" ;
>                 iso_dataset:topic = "climatology, meteorology, atmosphere" ;
>                 iso_dataset:keyword = "temperature, pressure, relative
> humidity, visibility, wind speed, wind direction, wind gust" ;
>                 iso_dataset:max-x = 10.f ;
>                 iso_dataset:min-x = 0.f ;
>                 iso_dataset:max-y = 60.f ;
>                 iso_dataset:min-y = 40.f ;
>                 iso_dataset:temporal_extent = "1950-01-01 and ongoing" ;
>                 iso_dataset:date = "2013-10-10" ;
>                 iso_dataset:dateType = "publication date" ;
>                 iso_dataset:statement = "KNMI operates in the
> Netherlands 33 automatic weather stations on land, 15 wind poles in
> coastal areas and 13 automatic weather stations on North Sea platforms
> (Dutch part of the Continental Shelf North Sea). These weather
> stations report meteorological paramaters such as temperature,
> relative humidity, wind (speed, gust, direction), air pressure and
> visibility every 10 minutes. Only stations that report within 6
> minutes after observation time - 47 in total - are part of this
> dataset: actual synoptic observations per 10 minutes." ;
>                 iso_dataset:code = "4326" ;
>                 iso_dataset:codeSpace = "EPSG" ;
>                 iso_dataset:accessConstraints = "No limitations" ;
>                 iso_dataset:useLimitation = "No use limitations" ;
>                 iso_dataset:organisationName_dataset = "Royal
> Netherlands Meteorological Institute (KNMI)" ;
>                 iso_dataset:email_dataset = "[email protected]" ;
>                 iso_dataset:role_dataset = "pointOfContact" ;
>                 iso_dataset:metadata_id =
> "fbfad5b9-1dd2-425e-bb35-c96386380c0e" ;
>                 iso_dataset:organisationName_metadata = "Royal
> Netherlands Meteorological Institute (KNMI)" ;
>                 iso_dataset:role_metadata = "pointOfContact" ;
>                 iso_dataset:email_metadata = "[email protected]" ;
>                 iso_dataset:url_metadata = "http://data.knmi.nl"; ;
>                 iso_dataset:datestamp = "2014-07-23" ;
>                 iso_dataset:language = "eng" ;
>                 iso_dataset:metadataStandardName = "ISO 19115" ;
>                 iso_dataset:metadataStandardNameVersion = "Nederlandse
> metadatastandaard op ISO 19115 voor geografie 1.2" ;
>         char product ;
>                 product:units = "1" ;
>                 product:long_name = "ADAGUC Data Products Standard" ;
>                 product:ref_doc = "ADAGUC Data Products Standard" ;
>                 product:ref_doc_version = "1.1" ;
>                 product:format_version = "1.1" ;
>                 product:originator = "Royal Netherlands Meteorological
> Institute (KNMI)" ;
>                 product:type = "P" ;
>                 product:acronym = "KMDS__OPER_P___10M_OBS_L2" ;
>                 product:level = "L2" ;
>                 product:style = "camelCase" ;
>         char projection ;
>                 projection:EPSG_code = "EPSG:4326" ;
>
> // global attributes:
>                 :featureType = "timeSeries" ;
>                 :Conventions = "CF-1.4" ;
>                 :title = "KMDS__OPER_P___10M_OBS_L2" ;
>                 :institution = "Royal Netherlands Meteorological
> Institute (KNMI)" ;
>                 :source = "Royal Netherlands Meteorological Institute (KNMI)" 
> ;
>                 :history = "File created from KMDS ASCII file. " ;
>                 :references = "http://data.knmi.nl"; ;
>                 :comment =  ;
> }
>
>
>
> geoserver.log:
>
> 11 Oct 10:59:51 WARN [netcdf.NetCDFGeoreferenceManager] - Unsupported
> axis: String station(station=48);
>   :long_name = "Station id";
>   :cf_role = "timeseries_id";
>   :_ChunkSizes = 48; // int
>  in input: C:/Program Files (x86)/GeoServer
> 2.9.1/data_dir/data/KMDS__OPER_P___10M_OBS_L2 (1).nc has been found
> 11 Oct 10:59:51 WARN [netcdf.NetCDFFormat] - Unable to connect
> org.geotools.data.DataSourceException: Unable to connect
>         at 
> org.geotools.coverage.io.netcdf.NetCDFReader.<init>(NetCDFReader.java:159)
>         at 
> org.geotools.coverage.io.netcdf.NetCDFFormat.getReader(NetCDFFormat.java:95)
>         at 
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.java:1441)
>         at 
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.java:1369)
>         at 
> org.geoserver.catalog.impl.CoverageStoreInfoImpl.getGridCoverageReader(CoverageStoreInfoImpl.java:59)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>         at java.lang.reflect.Method.invoke(Unknown Source)
>         at 
> org.geoserver.catalog.impl.ModificationProxy.invoke(ModificationProxy.java:147)
>         at com.sun.proxy.$Proxy9.getGridCoverageReader(Unknown Source)
>         ...
>
> 11 Oct 10:59:51 INFO [geoserver.web] - Getting list of coverages for
> saved store file:data/KMDS__OPER_P___10M_OBS_L2 (1).nc
> java.lang.RuntimeException: Could not list layers for this store, an
> error occurred retrieving them: Failed to create reader from
> file:data/KMDS__OPER_P___10M_OBS_L2 (1).nc and hints null
>         at 
> org.geoserver.web.data.layer.NewLayerPageProvider.getItemsInternal(NewLayerPageProvider.java:150)
>         at 
> org.geoserver.web.data.layer.NewLayerPageProvider.getItems(NewLayerPageProvider.java:57)
>         at 
> org.geoserver.web.wicket.GeoServerDataProvider.fullSize(GeoServerDataProvider.java:243)
>         at 
> org.geoserver.web.wicket.GeoServerTablePanel$PagerDelegate.updateMatched(GeoServerTablePanel.java:583)
>         at 
> org.geoserver.web.wicket.GeoServerTablePanel$PagerDelegate.<init>(GeoServerTablePanel.java:576)
>         at 
> org.geoserver.web.wicket.GeoServerTablePanel.<init>(GeoServerTablePanel.java:176)
>         at 
> org.geoserver.web.wicket.GeoServerTablePanel.<init>(GeoServerTablePanel.java:97)
>         ...
>
>
> 2016-10-11 10:59:51,754 WARN [netcdf.NetCDFGeoreferenceManager] -
> Unsupported axis: String station(station=48);
>   :long_name = "Station id";
>   :cf_role = "timeseries_id";
>   :_ChunkSizes = 48; // int
>  in input: C:/Program Files (x86)/GeoServer
> 2.9.1/data_dir/data/KMDS__OPER_P___10M_OBS_L2 (1).nc has been found
> 2016-10-11 10:59:51,754 WARN [netcdf.NetCDFFormat] - Unable to connect
> org.geotools.data.DataSourceException: Unable to connect
>         at 
> org.geotools.coverage.io.netcdf.NetCDFReader.<init>(NetCDFReader.java:159)
>         at 
> org.geotools.coverage.io.netcdf.NetCDFFormat.getReader(NetCDFFormat.java:95)
>         at 
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.java:1441)
>         at 
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.java:1369)
>         at 
> org.geoserver.catalog.impl.CoverageStoreInfoImpl.getGridCoverageReader(CoverageStoreInfoImpl.java:59)
>        ...
>

-- 
Ben Caradoc-Davies <[email protected]>
Director
Transient Software Limited <http://transient.nz/>
New Zealand

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to