Re: [mapserver-users] mapcache_seed segfault when using threading [SEC=UNCLASSIFIED]

2012-10-22 Thread Matthew Doyle
Hi Steve, Thomas,

Thanks for all the suggestions. I rebuilt MapCache yesterday using the
latest from github, and made sure that each dependency was up to date, so we
are looking at the latest and greatest.

Actions & results:

$ ulimit -c unlimited  (to ensure the core was dumped) 
$ /mapcache/bin/mapcache_seed -c /mapcache/config/meteye_test.xml -t
IDZ71000 -M 8,8 -n 32 -g AUS -z 0,4 -d /mapcache/data/adfd_active_area.shp
-D "TIMESTEP=5" -D "NOWTIME=201210221900"
Segmentation fault (core dumped)
$ gdb -c core.5808 mapcache_seed
(gdb) bt 

#0  0x7fdb313da786 in apr_palloc () from /usr/lib64/libapr-1.so.0
#1  0x7fdb313d0b0c in apr_pstrdup () from /usr/lib64/libapr-1.so.0
#2  0x7fdb313d25fe in apr_table_set () from /usr/lib64/libapr-1.so.0
#3  0x7fdb315f991d in mapcache_tileset_tile_create (pool=0x1ad0b98,
tileset=0x1b0da30, grid_link=0x1b0dc48) at tileset.c:530
#4  0x004039e3 in seed_worker () at mapcache_seed.c:611
#5  0x00403c62 in seed_thread (thread=0x7fdac4002ec0, data=0x0) at
mapcache_seed.c:658
#6  0x0035cb807851 in start_thread () from /lib64/libpthread.so.0
#7  0x0035cb0e76dd in clone () from /lib64/libc.so.6

Does that help? The core was around 300MB.

Best,
Matt




--
View this message in context: 
http://osgeo-org.1560.n6.nabble.com/mapcache-seed-segfault-when-using-threading-SEC-UNCLASSIFIED-tp5007582p5010358.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] TinyOWS wrong call in OpenLayers - 'InvalidParameterValue' - XML request isn't valid

2012-10-22 Thread Olivier Courtin
On Mon, Oct 22, 2012 at 4:55 PM, Riccardo Gaeta wrote:

HI Riccardo,


> I have "quite" solved the problem.
>

Great to hear it !


> P.S.: As GeoJSON I get the following error message (from FireBug of
> Mozilla):
> "JSON.parse: unexpected character"
> "Uncaught SyntaxError: Unexpected token ] "
>
> I don't know why. Anyway, for now is enough GML. Or if you know the
> reasons I get this error could be interesting to know...
>


Could you provide GeoJson output from TinyOWS for a single feature
i.e something like
http://your_server/cgi-bin/tinyows.fcgi?SERVICE=WFS&REQUEST=GetFeature&OUTPUTFORMAT=application/geojson&TYPENAME=ns:your_layer&MAXFEATURES=1


-- 
Olivier
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] TinyOWS 12.10rc1

2012-10-22 Thread Olivier Courtin
Hi Peter,

I was happily trying to build it on CentOS 6, but it seems that my libxml2
> is simply too old:
>
> checking for libxml2 version... 2.7.6
> configure: error: You need at least libxml 2.8.0
>
> Is there a real reason to require 2.8.0 or could this be relaxed?
>

The reason is related to a libxml2 bug on schema handling, been fixed in
2.8.0.
cf http://mapserver.org/trunk/fr/tinyows/libxmlschemagmlbug.html,

If you really don't want to upgrade (even if it's not a big deal to compile
libxml2)
you could either choose:
 - to slightly modified OGC XSD Schema as describted:
  http://mapserver.org/trunk/fr/tinyows/libxmlschemagmlbug.html

 - or be sure to never use GML 3.1.1 (as the bug only impact this schema)

HTH,

-- 
Olivier
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] TinyOWS 12.10rc1

2012-10-22 Thread Peter Hopfgartner

On 10/15/2012 12:21 AM, Olivier Courtin wrote:

Hi all,

TinyOWS 12.10rc1 is yet available:
http://www.tinyows.org/release/mapserver-tinyows-12.10rc1.tar.bz2

Thanks in advance in advance to test,
and report any bug or regression on this list

12.10 NEWS:
 - Generate PK value using PostgresSQL DEFAULT value if present (Serge 
Dikiy)
 - XSD max length and enumeration constraint handling (Serge Dikiy & 
Alan Boudreault)
 - include_items and exclude_items config handling. To choose exactly 
which columns to retrieve (Serge Dikiy)
 - Add pkey configuration in layer config. Usefull for instance when 
retrieving data from a VIEW. (Serge Dikiy)

 - Buffer copy performance improve (Serge Dikiy)
 - Rewrite/fix max features handling (Olivier Courtin)
 - Several bugfixes as usual (special thanks to Andreas Peri, Serge 
Dikiy and Jukka Rahkonen for detailled reports)



--
Olivier


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Hi Olivier,

I was happily trying to build it on CentOS 6, but it seems that my 
libxml2 is simply too old:


checking for libxml2 version... 2.7.6
configure: error: You need at least libxml 2.8.0

Is there a real reason to require 2.8.0 or could this be relaxed?

Regards,

Peter

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Memory access error when accessing Oracle database

2012-10-22 Thread Stefan Schantz

Hi,
I try to use MapServer 6.2.0-rc1 to display data from an Oracle database.

*mapserv -v*
MapServer version 6.2.0-rc1 OUTPUT = GIF OUTPUT = PNG OUTPUT = JPEG 
SUPPORTS = PROJ SUPPORTS = AGG SUPPORTS SUPPORTS = DG = FREETYPE 
SUPPORTS = ICONV SUPPORTS = WMS_SERVER SUPPORTS = WMS_CLIENT SUPPORTS = 
WFS_SERVER SUPPORTS = WFS_CLIENT SUPPORTS = WCS_SERVER SUPPORTS = 
FastCGI SUPPORTS = THREADS SUPPORTS = GEOS INPUT = JPEG INPUT = 
ORACLESPATIAL INPUT = OGR INPUT = GDAL INPUT = SHAPEFILE


*Error message:*
shp2img-m. / png oracle.map-i-o. / output.png s 500-500-5-l test all_debug

msLoadMap (): 0.011s
msDrawMap (): rendering using outputFormat named png (AGG / PNG).
msDrawMap (): WMS / WFS set-up and query, 0.000s
msOracleSpatialLayerOpen called with: GEOM FROM USING 
IMIS_GEO.TRAPKT_16386 NONE (Layer pointer 0x14dbad0)

msOracleSpatialLayerOpen. Shared connection not available. Creating one.
msConnPoolRegister (test, imis_geo / x @ IMISXENT, 0x1523f50)
msOracleSpatialLayerFreeItemInfo was called.
msOracleSpatialLayerWhichShapes was called.
msOracleSpatialLayerWhichShapes. Using this Sql to retrieve the data: 
SELECT rownum, GEOM FROM IMIS_GEO.TRAPKT_16386
msOracleSpatialLayerWhichShapes. Bind values: srid: -1 minx: -90.00 
miny: -90.00 maxx: 90.00 maxy: 90.00

msOracleSpatialLayerWhichShapes getting ordinate definition.
msOracleSpatialLayerWhichShapes converting to OCIColl.
msOracleSpatialLayerWhichShapes bind by name and object.
msOracleSpatialLayerWhichShapes name and object now bound.
msOracleSpatialLayerNextShape on layer 0x14dbad0 row_num,: 0
Segfaulting

*My mapfile:*
...
LAYER
NAME "test"
TYPE POINT
STATUS ON
CONNECTIONTYPE oraclespatial
CONNECTION "imis_geo / xxx @ IMISXENT"
DATA "GEOM FROM USING IMIS_GEO.TRAPKT_16386 NONE"
# CONNECTIONTYPE OGR
# CONNECTION "OCI: imis_geo / xx @ IMISXENT: imis_geo.TRAPKT_16386"
# DATA "IMIS_GEO.TRAPKT_16386"

PROJECTION
"Init = epsg: 4326"
END
...

When I use the Connectiontype OGR I get a *different error*:

shp2img-m. / png oracle.map-i-o. / output.png s 500-500-5-l test all_debug
msLoadMap (): 0.020s
msDrawMap (): rendering using outputFormat named png (AGG / PNG).
msDrawMap (): WMS / WFS set-up and query, 0.000s
msOGRFileOpen (OCI: imis_geo / x @ IMISXENT: imis_geo.TRAPKT_16386) ...
OGROPen (OCI: imis_geo / x @ IMISXENT: imis_geo.TRAPKT_16386)
(test, OCI: imis_geo / x @ IMISXENT: imis_geo.TRAPKT_16386, 
0x1c09c40) msConnPoolRegister
msOGRFileWhichShapes: Setting spatial filter to -90.00 -90.00 
90.00 90.00

msOGRFileNextShape: Returning shape tile = 0, = 0
msOGRFileNextShape: Returning shape tile = 1, = 0
msOGRFileNextShape: Returning shape tile = 2, = 0
msOGRFileNextShape: Returning shape tile = 3, = 0
msOGRFileNextShape: Returning shape tile = 4, = 0
msOGRFileNextShape: Returning shape tile = 5, = 0
msOGRFileNextShape: Returning shape tile = 6, = 0
msOGRFileNextShape (): OGR error. ORA-29902: error during execution of 
routine ODCIIndexStart ()
ORA-13208: Internal error when parsing operator [window SRID does not 
match layer SRID]

ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 333
 in SELECT COUNT(*) FROM imis_geo.TRAPKT_16386 WHERE sdo_filter(GEOM, 
MDSYS.SDO_GEOMETRY(2003,NULL,NULL,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,1),MDSYS.SDO_ORDINATE_ARRAY(-90.01,-90.01,90.01,-90.01,90.01,90.01,-90.01,90.01,-90.01,-90.01)), 
'querytype=window') = 'TRUE'

msOGRLayerClose (OCI: @ imis_geo/IMISXENT: imis_geo.TRAPKT_16386).
msOGRFileClose (OCI: imis_geo / x @ IMISXENT: imis_geo.TRAPKT_16386, 0).
msConnPoolRelease (test, OCI: imis_geo / x @ IMISXENT: 
imis_geo.TRAPKT_16386, 0x1c09c40)
msConnPoolClose (OCI: imis_geo / x @ IMISXENT: 
imis_geo.TRAPKT_16386, 0x1c09c40)

msDrawMap (): Image handling error. Failed to draw layer named 'test'.
msDrawMap (): Image handling error. Failed to draw layer named 'test'. 
msOGRFileNextShape (): OGR error. ORA-29902: error during execution of 
routine ODCIIndexStart ()
ORA-13208: Internal error when parsing operator [window SRID does not 
match layer SRID]

ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 333
 in SELECT COUNT(*) FROM imis_geo.TRAPKT_16386 WHERE sdo_filter(GEOM, 
MDSYS.SDO_GEOMETRY(2003,NULL,NULL,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,1),MDSYS.SDO_ORDINATE_ARRAY(-90.01,-90.01,90.01,-90.01,90.01,90.01,-90.01,90.01,-90.01,-90.01)), 
'querytype=window') = 'TRUE' 

msFreeMap (): freeing map at 0x1bbb400.
free layer (): freeing layer at 0x1bc3ad0.
free layer (): freeing layer at 0x1bc56d0.

As far as I see it, the problem is the lack of SRID (zero instead of 4326)


*The data from the database:*
ogrinfo OCI: imis / x @ imisxent: IMIS_GEO.TRAPKT_16386 -al -ro

INFO: Open of `OCI: imis / x @ imisxent: IMIS_GEO.TRAPKT_16386 '

Re: [mapserver-users] TinyOWS wrong call in OpenLayers - 'InvalidParameterValue' - XML request isn't valid

2012-10-22 Thread Riccardo Gaeta
Hi all.
I have "quite" solved the problem.
I need just to load another OpenLayers.js built with inside the GML vector
style.
So I add on my .html file this row:

http://openlayers.org/dev/OpenLayers.js
">

Obviously I've to load my layer not as a GeoJSON but as GML:

readFormat: new OpenLayers.Format.GML({
   'internalProjection': new OpenLayers.Projection("EPSG:900913"),
   'externalProjection': new OpenLayers.Projection("EPSG:900913")
})

Now it works!

Thanks at all,
Riccardo

P.S.: As GeoJSON I get the following error message (from FireBug of
Mozilla):
"JSON.parse: unexpected character"
"Uncaught SyntaxError: Unexpected token ] "

I don't know why. Anyway, for now is enough GML. Or if you know the reasons
I get this error could be interesting to know...

2012/10/18 Riccardo Gaeta 

> I go to the link you suggest but I didn't find the rc4 version for windows
> to download...
>
> Anyway, I copy some dll (like gdal, geos,xercers,libxml2,etc) into my
> cgi-bin directory from a previous version of an Apache2 windows
> installation.
> And the error message change!
> Now I obtain (from tinyows.log):
> [ERROR] Element '{http://www.w3.org/2001/XMLSchema}import': Skipping
> import of schema located at '
> http://schemas.opengis.net/gml/2.1.2/feature.xsd' for the namespace '
> http://www.opengis.net/gml', since this namespace was already imported
> with the schema located at '
> http://127.0.0.1:8080/tinyows/schema/gml/2.1.2/feature.xsd'.
> [ERROR] Filter parameter doesn't validate WFS Schema
>
> On QGIS always work well.
> Mmmmhh
>
> I suppose I have maybe 2 problem:
> 1-I need some dll library in window
> 2-the tinyows.exe of version 1.0.0rc3 is damaged in someway
>
> Thanks again for your help, any other tips is appreciated!
>
> riccardo
>
>
> 2012/10/18 Olivier Courtin 
>
>> 0.9 version is that old, and should not be used anymore, for any
>> reasons...
>> 1.0.0rc3, well was an rc, and several fixes was corrected before
>> launching 1.0.0
>>
>> You could give a look at OSGeo4W as they provide a 1.0.0rc4 (yeap still
>> an rc)
>> http://trac.osgeo.org/osgeo4w/wiki/pkg-tinyows
>>
>> But a real solution would be that someone take Win32 packaging in charge,
>>  Also for information:
>>
>> http://gis-lab.info/qa/tinyows-compile-vce-eng.html
>>
>>  --
>> Olivier
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapcache_seed segfault when using threading [SEC=UNCLASSIFIED]

2012-10-22 Thread Stephen Woodbridge

On 10/22/2012 3:39 AM, Matthew Doyle wrote:

Hi Thomas,

Thanks for getting back to me.

It seems we have reached an interesting situation.  After reconfiguring
(with --enable-debug), reinstalling, executing gdb and seeding using 'run'
with the same params, I can not reproduce the segfault no matter how many
threads I throw at it, even all the way up to 64. However, outside of gdb I
get the segfault as always.

Perhaps we have some sort of race condition or timing issue. Some googling
shows that this is not entirely uncommon. Some others in the same boat have
suggested running with Valgrind.
(http://stackoverflow.com/questions/7057651/cannot-reproduce-segfault-in-gdb)

Could you please advise on the next step? Would the core dump be useful?


Hi Matt,

Get the core file and start  gdb -c corefile mapcache_seed and then do a 
bt that would be useful.


Also please check that you do not have an old version of the libraries 
or executable in the path. I recently had a mapcache_seed segv problem 
that went away when I pulled a recent copy and rebuilt.


If you start:

gdb mapcache_seed- this looks in the path for the executable
gdb ./mapcache_seed  - this looks in the file system

So be careful with this, I have been tripped up on occasion by it.

-Steve

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapcache_seed segfault when using threading [SEC=UNCLASSIFIED]

2012-10-22 Thread Matthew Doyle
Hi Thomas,

Thanks for getting back to me.

It seems we have reached an interesting situation.  After reconfiguring
(with --enable-debug), reinstalling, executing gdb and seeding using 'run'
with the same params, I can not reproduce the segfault no matter how many
threads I throw at it, even all the way up to 64. However, outside of gdb I
get the segfault as always. 

Perhaps we have some sort of race condition or timing issue. Some googling
shows that this is not entirely uncommon. Some others in the same boat have
suggested running with Valgrind.
(http://stackoverflow.com/questions/7057651/cannot-reproduce-segfault-in-gdb) 

Could you please advise on the next step? Would the core dump be useful?

Best,
Matt



--
View this message in context: 
http://osgeo-org.1560.n6.nabble.com/mapcache-seed-segfault-when-using-threading-SEC-UNCLASSIFIED-tp5007582p5010188.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users