Re: [MapServer-users] setting COLOR of SVG symbol ?

2024-03-28 Thread karsten via MapServer-users
Thanks,
looks like it.
 
In QGIS setting color and opacity plus stroke does only work if the *.svg is
edited to allow by setting variables such as these below:
style="fill:param(fill) #00;fill-opacity:1;stroke:param(outline)
#00;stroke-width:param(stroke-width) 1;fill-opacity:param(fill-opacity)
1;stroke-opacity:param(outline-opacity) "
 
I guess a simple approach could be to allow setting colors for svgs in
MapServer if the svg has the style color set to
fill="currentColor" 
in order to be styled 

For now seems that MapServer vector symbols seem to be the way to go 
 
Cheers
Karsten 
  _  

From: Seth G [mailto:se...@geographika.co.uk] 
Sent: Thursday, March 28, 2024 00:06
To: karsten; MapServer Users
Subject: Re: [MapServer-users] setting COLOR of SVG symbol ?


Hi,


Unfortunately, I don't think this is currently possible, based on a previous
reply from Steve Lime [1]:


> I don't believe you can muck with the SVG color since SVG can carry
multiple elements and colors. That complexity doesn't map very well to a
single color value in a styleObj. It's probably best to consider SVG as
immutable, same as an image symbol. You can use truetype fonts (or vector
symbols) if you want something scaleable where you can alter color.

I guess if it works in QGIS then it should be possible to implement this in
the MapServer codebase too. 


Seth


[1] https://lists.osgeo.org/pipermail/mapserver-users/2019-June/081218.html


--

web:https://geographika.net & https://mapserverstudio.net

twitter: @geographika


On Wed, Mar 27, 2024, at 10:45 PM, karsten via MapServer-users wrote:


Hi All,


 
for the first time trying to use svg symbols for a layer. The svgs I am
using can be styled in QGIS (have edited to allow). 
What is the status in MapServer should setting  the color via a style work ?


I had no luck setting the COLOR on the symbol so far

Here is my style

 
 STYLE
   SYMBOL "electric_point"
   SIZE 20
   COLOR 255 0 0
 END # STYLE 

 
symbol


 
SYMBOL
NAME 'electric_point'
TYPE svg
image 'symbols/annotation/electric.svg'
END

 
So far this renders black symbols , any ideas how to fix this ?


 
Cheers

Karsten


 
Karsten Vennemann
 <http://www.terragis.net> www.terragis.net

 
___

MapServer-users mailing list

MapServer-users@lists.osgeo.org

https://lists.osgeo.org/mailman/listinfo/mapserver-users




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


[MapServer-users] setting COLOR of SVG symbol ?

2024-03-27 Thread karsten via MapServer-users
Hi All,
 
for the first time trying to use svg symbols for a layer. The svgs I am
using can be styled in QGIS (have edited to allow). 
What is the status in MapServer should setting  the color via a style work ?


I had no luck setting the COLOR on the symbol so far

Here is my style
 
 STYLE
   SYMBOL "electric_point"
   SIZE 20
   COLOR 255 0 0
 END # STYLE  
 
symbol
 
SYMBOL
NAME 'electric_point'
TYPE svg
image 'symbols/annotation/electric.svg'
END
 
So far this renders black symbols , any ideas how to fix this ?
 
Cheers
Karsten
 
Karsten Vennemann
 <http://www.terragis.net> www.terragis.net
 
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [MapServer-users] Creating UTF grids with MapServer and MapCache

2022-09-07 Thread karsten
Yes that worked now to restart Apache ! 
 
Here is the final config snippets in case it helps someone 
and remember the format tags aka 'MVT' are case sensitive ;)
 
mapfile
OUTPUTFORMAT
   NAME "MVT"
   DRIVER MVT
   FORMATOPTION "EDGE_BUFFER=10"
END
 
LAYER 

# added:
UTFITEM   "gml_id"   
UTFDATA
"{\"gml_id\":\"[gml_id]\",\"fkz\":\"[flurstueckskennzeichen]\",\"gemeindenam
e\":\"[gemeindename]\",\"Gemarkungsname\":\"[Gemarkungsname]\",\"zaehler\":\
"[zaehler]\",\"nenner\":\"[nenner]\"}" 
END

mapcache.xml
 

 mvt
 application/vnd.mapbox-vector-tile
   
 
   
  
 
MVT
flurst_gff
/xyz/utfgrid.map
 
  
  
 http://theurl/cgi-bin/mapserv
  
   
 
   
  
 Flurst UTF
 Flurst UTF
  
  flurst_utf
  disk
  GoogleMapsCompatible
  MVT

 
 
  _  

From: karsten [mailto:kars...@terragis.net] 
Sent: Wednesday, September 07, 2022 14:49
To: 'mapserver-users@lists.osgeo.org'
Subject: RE: Creating UTF grids with MapServer and MapCache


Oh yes that could be the problem, so far I have
 
OUTPUTFORMAT
  NAME "utfgrid" 
  DRIVER UTFGRID
  MIMETYPE "application/json" 
  EXTENSION "json" 
  FORMATOPTION "UTFRESOLUTION=4" 
  FORMATOPTION "DUPLICATES=false" 
END
 
will try with mvt now (goal is to create utfgrid json though)


  _  

From: karsten [mailto:kars...@terragis.net] 
Sent: Wednesday, September 07, 2022 12:38
To: 'mapserver-users@lists.osgeo.org'
Subject: RE: Creating UTF grids with MapServer and MapCache


Thanks Scott,
 
I do have a tileset like this below
 
  
  
 Flurst UTF
 Flurst UTF
  
  flurst_utf
  disk
  GoogleMapsCompatible
  mvt
  5 5
  10
  3600

 
but also with this get the error
 
tileset "flurst_utf_tiles" references format "mvt", but it is not configured
 
  _  

From: karsten [mailto:kars...@terragis.net] 
Sent: Wednesday, September 07, 2022 12:08
To: 'mapserver-users@lists.osgeo.org'
Subject: Creating UTF grids with MapServer and MapCache



Hi All,
 
I am working on a correct configuration to cerate UTFGrid json tiles  via
MapCache and MapServer to seed a json tile set 
 
MapCache is up and running on my ubuntu 20 server and WMS requests (PNG,
Jpeg ) are working as is the seeding utility.
Now I am trying to add a UTFGrid tile layer and added the mvt format into
the (working for the other layers correctly) mapcache.xml:

 mvt
 application/vnd.mapbox-vector-tile
   
the layer is
   
  
 
mvt
flurst
/var/mapdata/utfgrid.map
 
  
  
 http://myserver/cgi-bin/mapserv
  
   
When tryign to restrart apache however I get this error message 
systemctl status apache2.service
● apache2.service - The Apache HTTP Server
 Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor
preset: enabled)
 Active: failed (Result: exit-code) since Wed 2022-09-07 20:31:58 CEST;
28s ago
   Docs: https://httpd.apache.org/docs/2.4/
Process: 1265907 ExecStart=/usr/sbin/apachectl start (code=exited,
status=1/FAILURE)
Sep 07 20:31:58 terraz systemd[1]: Starting The Apache HTTP Server...
Sep 07 20:31:58 terraz apachectl[1265919]: AH00526: Syntax error on line 43
of /etc/apache2/sites-enabled/000-default.conf:
Sep 07 20:31:58 terraz apachectl[1265919]: tileset "flurst_utf_tiles"
references format "mvt", but it is not configured
Sep 07 20:31:58 terraz apachectl[1265907]: Action 'start' failed.

What am I missing here ?
Thanks
 

Karsten Vennemann
 <http://www.terragis.net> www.terragis.net
 
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [MapServer-users] Creating UTF grids with MapServer and MapCache

2022-09-07 Thread karsten
Oh yes that could be the problem, so far I have
 
OUTPUTFORMAT
  NAME "utfgrid" 
  DRIVER UTFGRID
  MIMETYPE "application/json" 
  EXTENSION "json" 
  FORMATOPTION "UTFRESOLUTION=4" 
  FORMATOPTION "DUPLICATES=false" 
END
 
will try with mvt now (goal is to create utfgrid json though)


  _  

From: karsten [mailto:kars...@terragis.net] 
Sent: Wednesday, September 07, 2022 12:38
To: 'mapserver-users@lists.osgeo.org'
Subject: RE: Creating UTF grids with MapServer and MapCache


Thanks Scott,
 
I do have a tileset like this below
 
  
  
 Flurst UTF
 Flurst UTF
  
  flurst_utf
  disk
  GoogleMapsCompatible
  mvt
  5 5
  10
  3600

 
but also with this get the error
 
tileset "flurst_utf_tiles" references format "mvt", but it is not configured
 
  _  

From: karsten [mailto:kars...@terragis.net] 
Sent: Wednesday, September 07, 2022 12:08
To: 'mapserver-users@lists.osgeo.org'
Subject: Creating UTF grids with MapServer and MapCache



Hi All,
 
I am working on a correct configuration to cerate UTFGrid json tiles  via
MapCache and MapServer to seed a json tile set 
 
MapCache is up and running on my ubuntu 20 server and WMS requests (PNG,
Jpeg ) are working as is the seeding utility.
Now I am trying to add a UTFGrid tile layer and added the mvt format into
the (working for the other layers correctly) mapcache.xml:

 mvt
 application/vnd.mapbox-vector-tile
   
the layer is
   
  
 
mvt
flurst
/var/mapdata/utfgrid.map
 
  
  
 http://myserver/cgi-bin/mapserv
  
   
When tryign to restrart apache however I get this error message 
systemctl status apache2.service
● apache2.service - The Apache HTTP Server
 Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor
preset: enabled)
 Active: failed (Result: exit-code) since Wed 2022-09-07 20:31:58 CEST;
28s ago
   Docs: https://httpd.apache.org/docs/2.4/
Process: 1265907 ExecStart=/usr/sbin/apachectl start (code=exited,
status=1/FAILURE)
Sep 07 20:31:58 terraz systemd[1]: Starting The Apache HTTP Server...
Sep 07 20:31:58 terraz apachectl[1265919]: AH00526: Syntax error on line 43
of /etc/apache2/sites-enabled/000-default.conf:
Sep 07 20:31:58 terraz apachectl[1265919]: tileset "flurst_utf_tiles"
references format "mvt", but it is not configured
Sep 07 20:31:58 terraz apachectl[1265907]: Action 'start' failed.

What am I missing here ?
Thanks
 

Karsten Vennemann
 <http://www.terragis.net> www.terragis.net
 
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [MapServer-users] Creating UTF grids with MapServer and MapCache

2022-09-07 Thread karsten
Thanks Scott,
 
I do have a tileset like this below
 
  
  
 Flurst UTF
 Flurst UTF
  
  flurst_utf
  disk
  GoogleMapsCompatible
  mvt
  5 5
  10
  3600

 
but also with this get the error
 
tileset "flurst_utf_tiles" references format "mvt", but it is not configured
 
  _____  

From: karsten [mailto:kars...@terragis.net] 
Sent: Wednesday, September 07, 2022 12:08
To: 'mapserver-users@lists.osgeo.org'
Subject: Creating UTF grids with MapServer and MapCache



Hi All,
 
I am working on a correct configuration to cerate UTFGrid json tiles  via
MapCache and MapServer to seed a json tile set 
 
MapCache is up and running on my ubuntu 20 server and WMS requests (PNG,
Jpeg ) are working as is the seeding utility.
Now I am trying to add a UTFGrid tile layer and added the mvt format into
the (working for the other layers correctly) mapcache.xml:

 mvt
 application/vnd.mapbox-vector-tile
   
the layer is
   
  
 
mvt
flurst
/var/mapdata/utfgrid.map
 
  
  
 http://myserver/cgi-bin/mapserv
  
   
When tryign to restrart apache however I get this error message 
systemctl status apache2.service
● apache2.service - The Apache HTTP Server
 Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor
preset: enabled)
 Active: failed (Result: exit-code) since Wed 2022-09-07 20:31:58 CEST;
28s ago
   Docs: https://httpd.apache.org/docs/2.4/
Process: 1265907 ExecStart=/usr/sbin/apachectl start (code=exited,
status=1/FAILURE)
Sep 07 20:31:58 terraz systemd[1]: Starting The Apache HTTP Server...
Sep 07 20:31:58 terraz apachectl[1265919]: AH00526: Syntax error on line 43
of /etc/apache2/sites-enabled/000-default.conf:
Sep 07 20:31:58 terraz apachectl[1265919]: tileset "flurst_utf_tiles"
references format "mvt", but it is not configured
Sep 07 20:31:58 terraz apachectl[1265907]: Action 'start' failed.

What am I missing here ?
Thanks
 

Karsten Vennemann
 <http://www.terragis.net> www.terragis.net
 
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


[MapServer-users] Creating UTF grids with MapServer and MapCache

2022-09-07 Thread karsten

Hi All,
 
I am working on a correct configuration to cerate UTFGrid json tiles  via
MapCache and MapServer to seed a json tile set 
 
MapCache is up and running on my ubuntu 20 server and WMS requests (PNG,
Jpeg ) are working as is the seeding utility.
Now I am trying to add a UTFGrid tile layer and added the mvt format into
the (working for the other layers correctly) mapcache.xml:

 mvt
 application/vnd.mapbox-vector-tile
   
the layer is
   
  
 
mvt
flurst
/var/mapdata/utfgrid.map
 
  
  
 http://myserver/cgi-bin/mapserv
  
   
When tryign to restrart apache however I get this error message 
systemctl status apache2.service
● apache2.service - The Apache HTTP Server
 Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor
preset: enabled)
 Active: failed (Result: exit-code) since Wed 2022-09-07 20:31:58 CEST;
28s ago
   Docs: https://httpd.apache.org/docs/2.4/
Process: 1265907 ExecStart=/usr/sbin/apachectl start (code=exited,
status=1/FAILURE)
Sep 07 20:31:58 terraz systemd[1]: Starting The Apache HTTP Server...
Sep 07 20:31:58 terraz apachectl[1265919]: AH00526: Syntax error on line 43
of /etc/apache2/sites-enabled/000-default.conf:
Sep 07 20:31:58 terraz apachectl[1265919]: tileset "flurst_utf_tiles"
references format "mvt", but it is not configured
Sep 07 20:31:58 terraz apachectl[1265907]: Action 'start' failed.

What am I missing here ?
Thanks
 

Karsten Vennemann
 <http://www.terragis.net> www.terragis.net
 
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [MapServer-users] MB Tiles vs. UTF grids

2022-09-07 Thread karsten
Thanks for the hints on FlatGeoBuf and mbtiles vs.utfgrid specs.
My next steps will be configuring my MapCache installation correctly with
MapServer to create UTFgrid tiles ...

  _  

From: karsten [mailto:kars...@terragis.net] 
Sent: Friday, September 02, 2022 15:22
To: 'mapserver-users@lists.osgeo.org'
Subject: MB Tiles vs. UTF grids 


Hi All,
 
For the first time, I am diving into actually using vector tiles and or UTF
grids on an OpenLayers map. I am confused  about UTF grids, especially I
could not find clear answers whether UTF Grids have been completely replaced
by MB Tiles or if UTF Grids are now a subset of MB Tiles. Posts on the web
seem to suggest that
<https://medium.com/@pyin001/utfgrid-and-mbtiles-map-file-decoding-on-androi
d-864487697752> UTF grids can be stored inside MB Tiles . Note that I am
trying to stay outside the Mapbox empire (as much as possible) and trying to
use GDAL, MapServer etc.
GDAL can produce MB tiles (but not sure if that includes UTF grid info as
well) and MapServer can deliver UTF grid via WMS on the fly, but not sure
how performance is so far ...
Would anyone have some insights ?
 
Thanks
 
Karsten Vennemann
 <http://www.terragis.net> www.terragis.net
 
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


[MapServer-users] MB Tiles vs. UTF grids

2022-09-02 Thread karsten
Hi All,
 
For the first time, I am diving into actually using vector tiles and or UTF
grids on an OpenLayers map. I am confused  about UTF grids, especially I
could not find clear answers whether UTF Grids have been completely replaced
by MB Tiles or if UTF Grids are now a subset of MB Tiles. Posts on the web
seem to suggest that
<https://medium.com/@pyin001/utfgrid-and-mbtiles-map-file-decoding-on-androi
d-864487697752> UTF grids can be stored inside MB Tiles . Note that I am
trying to stay outside the Mapbox empire (as much as possible) and trying to
use GDAL, MapServer etc.
GDAL can produce MB tiles (but not sure if that includes UTF grid info as
well) and MapServer can deliver UTF grid via WMS on the fly, but not sure
how performance is so far ...
Would anyone have some insights ?
 
Thanks
 
Karsten Vennemann
 <http://www.terragis.net> www.terragis.net
 
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] MapServer derived MVTiles Benchmark test vs. T-Rex tile server

2019-03-11 Thread karsten
Corrected map file link:
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/ne.map

  _  

From: karsten [mailto:kars...@terragis.net] 
Sent: Monday, March 11, 2019 23:15
To: 'mapserver-users@lists.osgeo.org'
Cc: 'Pirmin Kalberer'; 'Lime, Steve D (MNIT)'; 'l...@lingner.eu';
'jmcke...@gatewaygeomatics.com'; 'thomas.bonf...@gmail.com'
Subject: MapServer derived MVTiles Benchmark test vs. T-Rex tile server


Dear All,

I  am working on optimizing a MapServer /MapCache configuration of  a
benchmark for creating MVT tiles (seeding) of MapServer - versus T-Rex. 

This will be featured in a presentation at the German FOSS4g ('FOSSGIS')
2019 in Dresden at the end of this week. The whole thing is based on Pirmin
Kalberer's automated vector tile benchmark see -
http://blog.sourcepole.ch/2018/09/06/the-tale-of-a-vector-tile-benchmark/ .
Thus I created a similar configuration of the Natural Earth Data based world
map for MapServer (my favorite rendering engine !) to run it against T-REX..
Now Pirmin has added this into the GitHUB repository as a 'MapServer' branch
see - https://github.com/pka/mvt-benchmark/tree/mapserver

Results of one of my first trial benchmarks can be found here
https://github.com/karstenv/mvt-benchmark/tree/master/firsttests .

Unfortunately my favorite software (MapServer /MapCache.fcgi) is falling
pretty far behind in seeding speed in these tests 
see e.g. in
https://github.com/karstenv/mvt-benchmark/blob/master/firsttests/http.jpg

Thus, I wanted to call in the experts to find out what configuration tweaks
will help to increase the MapServer / Mapcache  performance.

So far my next steps I will be working on 

--
1.) Setting the correct map file parameters to match the T-Rex configuration
for the FORMATOPTIONS 
"EXTENT" and "EDGE_BUFFER" in the OUTPUTFORMAT  bloc.

OUTPUTFORMAT 
 NAME "mvt" 
 DRIVER MVT 
 FORMATOPTION "EXTENT=512" # default is 4096. # Comment by Pirmin for
t-rex this is 'tile_size' (per Layer): Width and height of the tile
(Default: 4096. Grid default size is 256)
 FORMATOPTION "EDGE_BUFFER=20"  # Comment by Pirmin -  seems to be the
'buffer_size' in mvtbench.toml , is set to 3 for the Country layer, for all
others
END

Any suggestions wthat my best bet settings are in the map file is for
MapServer for "EXTENT" and "EDGE_BUFFER" ?


--
2.) Tweaking the data statement of the map file to match the T-Rex config 
So far I have e.g. for the countries layer
DATA "wkb_geometry from (SELECT * FROM ne_10m_admin_0_countries) as temp
using unique ogc_fid using SRID=3857"
while T-Rex has
sql = """SELECT wkb_geometry, adm0_a3, mapcolor7 FROM
ne_10m_admin_0_countries WHERE min_zoom::integer <= !zoom! AND wkb_geometry
&& !bbox!""" 
see
https://github.com/karstenv/mvt-benchmark/blob/master/t-rex/mvtbench.toml
I am still trying to match the T-Rex statement above but did not come up
with a  suitable comparable MapServer data statement so far.

Any suggestions for this anyone ?

--

3.) Does anyone have any other/ additional suggestions what else might help
to increase MapServer /MapCache performance ?

Thanks 
Karsten 

PS: The map file used is here
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/mapcache_mvt
.xml,
the MapCache config here
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/mapcache_mvt
.xml 

 

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

[mapserver-users] MapServer derived MVTiles Benchmark test vs. T-Rex tile server

2019-03-11 Thread karsten
Dear All,

I  am working on optimizing a MapServer /MapCache configuration of  a
benchmark for creating MVT tiles (seeding) of MapServer - versus T-Rex. 

This will be featured in a presentation at the German FOSS4g ('FOSSGIS')
2019 in Dresden at the end of this week. The whole thing is based on Pirmin
Kalberer's automated vector tile benchmark see -
http://blog.sourcepole.ch/2018/09/06/the-tale-of-a-vector-tile-benchmark/ .
Thus I created a similar configuration of the Natural Earth Data based world
map for MapServer (my favorite rendering engine !) to run it against T-REX..
Now Pirmin has added this into the GitHUB repository as a 'MapServer' branch
see - https://github.com/pka/mvt-benchmark/tree/mapserver

Results of one of my first trial benchmarks can be found here
https://github.com/karstenv/mvt-benchmark/tree/master/firsttests .

Unfortunately my favorite software (MapServer /MapCache.fcgi) is falling
pretty far behind in seeding speed in these tests 
see e.g. in
https://github.com/karstenv/mvt-benchmark/blob/master/firsttests/http.jpg

Thus, I wanted to call in the experts to find out what configuration tweaks
will help to increase the MapServer / Mapcache  performance.

So far my next steps I will be working on 

--
1.) Setting the correct map file parameters to match the T-Rex configuration
for the FORMATOPTIONS 
"EXTENT" and "EDGE_BUFFER" in the OUTPUTFORMAT  bloc.

OUTPUTFORMAT 
 NAME "mvt" 
 DRIVER MVT 
 FORMATOPTION "EXTENT=512" # default is 4096. # Comment by Pirmin for
t-rex this is 'tile_size' (per Layer): Width and height of the tile
(Default: 4096. Grid default size is 256)
 FORMATOPTION "EDGE_BUFFER=20"  # Comment by Pirmin -  seems to be the
'buffer_size' in mvtbench.toml , is set to 3 for the Country layer, for all
others
END

Any suggestions wthat my best bet settings are in the map file is for
MapServer for "EXTENT" and "EDGE_BUFFER" ?


--
2.) Tweaking the data statement of the map file to match the T-Rex config 
So far I have e.g. for the countries layer
DATA "wkb_geometry from (SELECT * FROM ne_10m_admin_0_countries) as temp
using unique ogc_fid using SRID=3857"
while T-Rex has
sql = """SELECT wkb_geometry, adm0_a3, mapcolor7 FROM
ne_10m_admin_0_countries WHERE min_zoom::integer <= !zoom! AND wkb_geometry
&& !bbox!""" 
see
https://github.com/karstenv/mvt-benchmark/blob/master/t-rex/mvtbench.toml
I am still trying to match the T-Rex statement above but did not come up
with a  suitable comparable MapServer data statement so far.

Any suggestions for this anyone ?

--

3.) Does anyone have any other/ additional suggestions what else might help
to increase MapServer /MapCache performance ?

Thanks 
Karsten 

PS: The map file used is here
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/mapcache_mvt
.xml,
the MapCache config here
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/mapcache_mvt
.xml 

 

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

Re: [mapserver-users] styling based on attribute for MapServer derived MVTiles

2019-03-11 Thread karsten
Thanks , will use this from now on.
Cheers
Karsten
 

  _  

From: Lime, Steve D (MNIT) [mailto:steve.l...@state.mn.us] 
Sent: Saturday, February 09, 2019 15:55
To: karsten; mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] styling based on attribute for MapServer
derived MVTiles


You can specify a type in the gml metadata and that will impact how the
conversion is done in the mvt encoding. Something like:

   gml_mapcolor7_type integer

Otherwise things are treated as strings...

-Steve

  _  

From: karsten 
Sent: Tuesday, February 5, 2019 3:01:51 PM
To: mapserver-users@lists.osgeo.org
Cc: Lime, Steve D (MNIT)
Subject: RE: [mapserver-users] styling based on attribute for MapServer
derived MVTiles 
 
Great, Thanks Steve 
I added  "gml_include_items" "mapcolor7"
to the Metadata block and got it working. 
One quirk seems to be that when I am trying to the values as integer (from
the mapcolor7 column) specifying the style as in 1.) below did not work. 
However it I treat them as characters instead, quoted them and used "type":
"categorical" in the json file for the style as in 2.) below it is working.
 
Cheers
Karsten

1.)

{
"id": "country-fill",
"type": "fill",
"source": "compass",
"source-layer": "allcountries",
"paint": {
  "fill-color": {
"property": "mapcolor7",
"stops": [
[1, "#fdaf6b"],
[2, "#fdc663"],
[3, "#fae364"],
[4, "#d3e46f"],
[5, "#aadb78"],
[6, "#a3cec5"],
[7, "#ceb5cf"]
]
  }
}
}
 
2.)

{
"id": "country-fill",
"type": "fill",
"source": "compass",
"source-layer": "allcountries",
"paint": {
  "fill-color": {
"property": "mapcolor7",
"type": "categorical",
"stops": [
["1", "#fdaf6b"],
["2", "#fdc663"],
["3", "#fae364"],
["4", "#d3e46f"],
["5", "#aadb78"],
["6", "#a3cec5"],
["7", "#ceb5cf"]
]
  }
}
}

  _  

From: Lime, Steve D (MNIT) [mailto:steve.l...@state.mn.us] 
Sent: Tuesday, February 05, 2019 21:15
To: karsten; mapserver-users@lists.osgeo.org
Subject: RE: [mapserver-users] styling based on attribute for MapServer
derived MVTiles



I believe the default WxS behavior is to expose no attributes. You need to
be explicit and I don't see the gml_include_items metadata property in the
mapfile for the layer allcountries. You'd need something like:

 

"gml_include_items""mapcolor7"

 

Added to the allcountries layer. The mvt-demo does this for most layers.

 

--Steve

 

From: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] On
Behalf Of karsten
Sent: Monday, February 04, 2019 4:33 PM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] styling based on attribute for MapServer derived
MVTiles

 

Dear All,

 

I was working on the configuration of MapServer generated MVT tiles for a
demo country world map and had success with MS v 7.2 outputting tiles in MVT
format ( all thanks to https://github.com/sdlime/mvt-demo
<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com
%2Fsdlime%2Fmvt-demo=02%7C01%7Csteve.lime%40state.mn.us%7C8cad89d7aa6f4
f29f40e08d68bad2b0d%7Ceb14b04624c445198f26b89c2159828c%7C0%7C0%7C63684997321
4573577=5L4SwL6sPn9%2BFDEQbvM1%2BKzCQ6KtXdc6OACIm4afEDc%3D=0>
).

I am trying to work on the client side style for my demo map (using
mapbox-gl.js) and defined them in a similar way as JSON as in Steve's
mvt-demo above. The whole thing is later intended to be used in a benchmark
for MapServer MVT rendering speed versus T-Rex ( see
http://blog.sourcepole.ch/2018/09/06/the-tale-of-a-vector-tile-benchmark/
<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fblog.source
pole.ch%2F2018%2F09%2F06%2Fthe-tale-of-a-vector-tile-benchmark%2F=02%7C
01%7Csteve.lime%40state.mn.us%7C8cad89d7aa6f4f29f40e08d68bad2b0d%7Ceb14b0462
4c445198f26b89c2159828c%7C0%7C0%7C636849973214583591=x0OMGP7hH2SvVQysW
ctAAAlzU5kML4sxg1m9ZHj3yNM%3D=0>  ) .

 

For now I am struggling with specifying the correct style syntax for the
client side and it seem that I missing something as I was not yet able to
successfully use attribute properties to render Countries as different
colors based on an attribute field of my PostGIS source.

Re: [mapserver-users] styling based on attribute for MapServer derived MVTiles

2019-02-05 Thread karsten
Great, Thanks Steve 
I added  "gml_include_items" "mapcolor7"
to the Metadata block and got it working. 
One quirk seems to be that when I am trying to the values as integer (from
the mapcolor7 column) specifying the style as in 1.) below did not work. 
However it I treat them as characters instead, quoted them and used "type":
"categorical" in the json file for the style as in 2.) below it is working.
 
Cheers
Karsten

1.)

{
"id": "country-fill",
"type": "fill",
"source": "compass",
"source-layer": "allcountries",
"paint": {
  "fill-color": {
"property": "mapcolor7",
"stops": [
[1, "#fdaf6b"],
[2, "#fdc663"],
[3, "#fae364"],
[4, "#d3e46f"],
[5, "#aadb78"],
[6, "#a3cec5"],
[7, "#ceb5cf"]
]
  }
}
}
 
2.)

{
"id": "country-fill",
"type": "fill",
"source": "compass",
"source-layer": "allcountries",
"paint": {
  "fill-color": {
"property": "mapcolor7",
"type": "categorical",
"stops": [
["1", "#fdaf6b"],
["2", "#fdc663"],
["3", "#fae364"],
["4", "#d3e46f"],
["5", "#aadb78"],
["6", "#a3cec5"],
["7", "#ceb5cf"]
]
  }
}
}

  _  

From: Lime, Steve D (MNIT) [mailto:steve.l...@state.mn.us] 
Sent: Tuesday, February 05, 2019 21:15
To: karsten; mapserver-users@lists.osgeo.org
Subject: RE: [mapserver-users] styling based on attribute for MapServer
derived MVTiles



I believe the default WxS behavior is to expose no attributes. You need to
be explicit and I don't see the gml_include_items metadata property in the
mapfile for the layer allcountries. You'd need something like:

 

"gml_include_items""mapcolor7"

 

Added to the allcountries layer. The mvt-demo does this for most layers.

 

--Steve

 

From: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] On
Behalf Of karsten
Sent: Monday, February 04, 2019 4:33 PM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] styling based on attribute for MapServer derived
MVTiles

 

Dear All,

 

I was working on the configuration of MapServer generated MVT tiles for a
demo country world map and had success with MS v 7.2 outputting tiles in MVT
format ( all thanks to https://github.com/sdlime/mvt-demo
<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com
%2Fsdlime%2Fmvt-demo=02%7C01%7Csteve.lime%40state.mn.us%7C98620848f4584
46d1e2608d68af0c31b%7Ceb14b04624c445198f26b89c2159828c%7C0%7C1%7C63684916400
6408831=QYGGj%2FDN87pFfCjzP0CHZBoomTp38zRhupXy2%2BjGyi8%3D=0>
).

I am trying to work on the client side style for my demo map (using
mapbox-gl.js) and defined them in a similar way as JSON as in Steve's
mvt-demo above. The whole thing is later intended to be used in a benchmark
for MapServer MVT rendering speed versus T-Rex ( see
http://blog.sourcepole.ch/2018/09/06/the-tale-of-a-vector-tile-benchmark/
<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fblog.source
pole.ch%2F2018%2F09%2F06%2Fthe-tale-of-a-vector-tile-benchmark%2F=02%7C
01%7Csteve.lime%40state.mn.us%7C98620848f458446d1e2608d68af0c31b%7Ceb14b0462
4c445198f26b89c2159828c%7C0%7C1%7C636849164006418845=F7kfmr8XBKaraOdKc
glqApDt%2BSuWAHSJ7x%2BTI6GJCHw%3D=0>  ) .

 

For now I am struggling with specifying the correct style syntax for the
client side and it seem that I missing something as I was not yet able to
successfully use attribute properties to render Countries as different
colors based on an attribute field of my PostGIS source.

Below is the configuration of my 'allcountries' layer. The mapcolor7 filed
is an integer field (in the input PostGIS source) but my set-up fails to
output multiple colors , instead I am getting all default black for the
country fill color. A second layer where I specified only Italy as one
Country 'country-italy' to show up renders fine -  see
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/countries_mv
t.png
<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com
%2Fkarstenv%2Fmvt-benchmark%2Fblob%2Fmaster%2FMapServer%2Fcountries_mvt.png&
data=02%7C01%7Csteve.lime%40state.mn.us%7C98620848f458446d1e2608d68af0c31b%7
Ceb14b04624c445198f26b89c2159828c%7C0%7C1%7C636849164006428858=1Xeo

[mapserver-users] styling based on attribute for MapServer derived MVTiles

2019-02-04 Thread karsten
Dear All,
 
I was working on the configuration of MapServer generated MVT tiles for a
demo country world map and had success with MS v 7.2 outputting tiles in MVT
format ( all thanks to https://github.com/sdlime/mvt-demo ).
I am trying to work on the client side style for my demo map (using
mapbox-gl.js) and defined them in a similar way as JSON as in Steve's
mvt-demo above. The whole thing is later intended to be used in a benchmark
for MapServer MVT rendering speed versus T-Rex ( see
http://blog.sourcepole.ch/2018/09/06/the-tale-of-a-vector-tile-benchmark/ )
.
 
For now I am struggling with specifying the correct style syntax for the
client side and it seem that I missing something as I was not yet able to
successfully use attribute properties to render Countries as different
colors based on an attribute field of my PostGIS source.
Below is the configuration of my 'allcountries' layer. The mapcolor7 filed
is an integer field (in the input PostGIS source) but my set-up fails to
output multiple colors , instead I am getting all default black for the
country fill color. A second layer where I specified only Italy as one
Country 'country-italy' to show up renders fine -  see
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/countries_mv
t.png
 
My complete style JSON is at
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/ms_ne_simple
.json
and the corresponding map file is here
https://github.com/karstenv/mvt-benchmark/blob/master/MapServer/ne.map
 
Would anyone know what I need to change in order to render the countries
with different colors according to the 'mapcolor7' attribute ?
To me it seems that somehow the attribute is not available to the renderer
even though in the MapServer map file I am selecting all fields in the
sub-query ...
 
Thanks
Karsten
 

{
"id": "country-fill",
"type": "fill",
"source": "compass",
"source-layer": "allcountries",
"paint": {
  "fill-color": {
"property": "mapcolor7",
"stops": [
[1, "#fdaf6b"],
[2, "#fdc663"],
[3, "#fae364"],
[4, "#d3e46f"],
[5, "#aadb78"],
[6, "#a3cec5"],
[7, "#ceb5cf"]
]
  }
}
},{
"id": "country-italy",
"type": "fill",
"source": "compass",
"source-layer": "italy",
"paint": {
  "fill-color": "#fdc663"
  }
  }
 
Karsten Vennemann
Terra GIS 

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

[mapserver-users] mapcache tileset with multiple grids - set-up of custom grid

2018-06-22 Thread karsten
Hi All,
 
I set-up mapcache on an Ubuntu 16 LTS machine and got it working correctly.
I have seeded a tile set of aerials in PseudoMercator (using the
GoogleMapsCompatible grid) and is responding  correctly to  HTTP requests.
 
Now I am adding a second projection t that tiles set (EPSG:25832) and thus
added the entries in the mapcache.xml config file.  I started the seeding of
the new projection for the tile set and am not sure that it is set-up
correctly because at zoom level 11 (seeding levels 11-19) it already
produced (and id not finished yet) a huge amount of tiles (alerady over
12 and counting !) , while for the GoogleMapsCompatible grid the total
count for zoom level 11-19 is around 52000 or so. 
 
I was expecting about the same number of tiles for the other EPSG:25832 grid
(because I reprojected the exact same bounding box and calculated the 19
resolutions (to tried to match the Google grid) from those . Below is the
configuration file. Would anyone know what might be wrong and how to fix it
?
or why my assumptions are incorrect ?
 
Thanks
Karsten
 
Karsten Vennemann
www.terragis.net
 
 
-
 


 
   
  Terragis Mechernich Mapcache Service
  Luftbilder fuer Mechernich

   
  /var/www/mapdata/gisme/cache
  
   
 
   
  
 
image/png
luftbilder_mech
/var/www/mapdata/gisme/luftbilder.map  
 
  
  
  
 http://xyz.net/cgi-bin/mapserv
  
   
 
   
  
 
image/png
fg,gg,gff,lfn,lff,pff,shape_gff
/var/www/mapdata/gisme/alkis_mechernich_server.map
 
  
 
  
 http://xyz.net/cgi-bin/mapserv
  
   
 
   
  
 MechernichArea
  
  325000 5599000 343000 5615000
  EPSG:25832
  m
  256 256
  17.578125 8.7890625 4.39453125 2.197265625 1.098632813
0.549316406 0.274658203 0.137329102 0.068664551 0.034332275 0.017166138
0.008583069 0.004291534 0.002145767 0.001072884 0.000536442 0.000268221
0.00013411 6.70552E-05
   
 

  
 Flurstuecke und Gebaeude
 Flurstuecke und Gebaeude Mechernich
  
  alkis_mech
  disk
  GoogleMapsCompatible
  GK_Mech
  PNG
  5 5
  10
  3600
   
   

  
 Luftbilder Mechernich
 Luftbilder Mechernich
  
  luftbilder_mech
  disk 
  GoogleMapsCompatible 
  GK_Mech

  PNG
  5 5
  10
  3600
   
 
   PNG
 
   
  assemble
  bilinear
  PNG
  4096
   
   report
   /var/www/mapdata/gisme/cache



 

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

[mapserver-users] mapcache 1.6 with MapServer 7.07 - configuration problem ?

2018-02-28 Thread karsten
Hi all,
 
I have build and installed mapcache v 1.6.0 on an Ubuntu 14.04 server to sue
with MapServer version 7.0.7.
I got the test data to render via mapcache but afield so far to render a
MapServer layer I had already running on a local MS4W installation. The
Ubuntu based demo is at http://terra9.terragis.net/mapcache/demo/wms
I tried to set up verbose debugging and also tried seeding but both did not
give me good tiles nor any error output. 
The seeding process ( I used an adapted version of the command that worked
on my windows box like this:
 
/usr/local/bin/mapcache_seed -c
/var/www/mapdata/mapcache/mapcache_server.xml -t luftbilder_mech_tiles -g
GoogleMapsCompatible -e 726209,6535935,755143,6562556 -z 1,2 -n 4 -M 8,8
 
This seeding did render empty tiles (when I set the
empty_img tag in the mapcache config).
I could not get any error message so far and am stuck how to debug/fix my
configuration. Any ideas what I can do ?
 
Cheers
Karsten
 
Karsten Vennemann
Terra GIS 


 

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

Re: [mapserver-users] Will Mapserver work with newer Microsoft SQL Server Spatial Databases

2017-02-07 Thread karsten
 Dear Seth,

Thanks so much for sharing your experiences. Also that it works well is
great. 
The naming of the driver thus does not reflect that it does suports more
than only version 2008 ;)
Hope this answer will help out others as well.

Cheers
Karsten

-Original Message-
From: Seth G [mailto:se...@geographika.co.uk] 
Sent: Tuesday, February 07, 2017 12:18
To: kars...@terragis.net; mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Will Mapserver work with newer Microsoft SQL
Server Spatial Databases

Hi Karsten,

We were running a production system with MS SQL 2012 for 4 years without any
problems. We briefly moved to SQL 2014, and are now on SQL 2016 again
without issues.

Tamas Szekeres does a great job of maintaining and improving the MS SQL
driver - https://github.com/mapserver/mapserver/blob/master/mapmssql2008.c

The OGR driver also works, but I found it to be much less flexible in terms
of complex SQL and adding filters.

Regards,

Seth


On 07/02/2017 21:12, karsten wrote:
>   
> Dear All,
>
> I am trying to find out if MapServer (and/or OGR) will work with 
> spatial databases newer than Microsoft SQL Server 2008. I know that 
> the drivers work with that older version but did not want to promise 
> to a client that it would. At this point I am not able to test it 
> directly because I do not have access to a Microsoft SQL Server 2012 or
newer to verify.
> Does anyone have experience and succeed with this or anyone who can 
> share their experiences ?
>
> Cheers
> Karsten
>
> www.terragis.net
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/mapserver-users

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

[mapserver-users] Will Mapserver work with newer Microsoft SQL Server Spatial Databases

2017-02-07 Thread karsten
 
Dear All,

I am trying to find out if MapServer (and/or OGR) will work with spatial
databases newer than Microsoft SQL Server 2008. I know that the drivers work
with that older version but did not want to promise to a client that it
would. At this point I am not able to test it directly because I do not have
access to a Microsoft SQL Server 2012 or newer to verify.
Does anyone have experience and succeed with this or anyone who can share
their experiences ? 

Cheers
Karsten

www.terragis.net

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

Re: [mapserver-users] seemingly sucessfully compiled mapserver 7.0.1 on ubuntu 14.04 - but NO - gives binary output ?

2016-05-31 Thread karsten
 
Hi All,
 
thanks to all the responses. It was neither one of ( cgi-bin permissions for 
Apache nor the Script alias) Both where in line with what everyone said/ 
listed. The issue was that I did not have the cgi module for Apache enabled :(
I enabled it with 
a2enmod cgi
service apache2 restart
and then everything worked for mapserver, perl script etc. 
 
I did only find out because I places a simple Perl script in cgi-bin that also 
was downloaded instead of executed .
Thanks for the answers they brought me on the right track !
 
Cheers
Karsten

  _  

From: Rahkonen Jukka (MML) [mailto:jukka.rahko...@maanmittauslaitos.fi] 
Sent: Tuesday, April 05, 2016 0:17
To: kars...@terragis.net; mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] seemingly sucessfully compiled mapserver 7.0.1 
on ubuntu 14.04 - but NO - gives binary output ?



Hi,

 

I believe that there is something wrong with the configuration of your http 
server. It does not seem to know that you do not want to download the mapserv 
binary but make the binary to work for you. If you run Apache I would have a 
look at “ScriptAlias” in the httpd.conf file and check that the directory where 
you have placed the mapserv binary is configured to contain applications. This 
example is from Windows.

 

# ScriptAlias: This controls which directories contain server scripts. 

# ScriptAliases are essentially the same as Aliases, except that

# documents in the target directory are treated as applications and

# run by the server when requested rather than as documents sent to the

# client.  The same rules about trailing "/" apply to ScriptAlias

# directives as to Alias.

#

ScriptAlias /cgi-bin/ "/ms4w/Apache/cgi-bin/"

ScriptAlias /fcgi-bin/ "/ms4w/Apache/cgi-bin/"

 

-Jukka Rahkonen-

 

karsten wrote:



 

Hi All,

 

I just seemingly sucessfully compiled mapserver 7.0.1 on Ubuntu 14.04 and can 
getv the follwoing output  from the executable:

/usr/lib/cgi-bin# ./mapserv -v
MapServer version 7.0.1 OUTPUT=PNG OUTPUT=JPEG SUPPORTS=PROJ SUPPORTS=AGG 
SUPPORTS=FREETYPE SUPPORTS=CAIRO SUPPORTS=ICONV SUPPORTS=FRIBIDI 
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT 
SUPPORTS=WCS_SERVER SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL 
INPUT=SHAPEFILE

Howvere when I try to get a get aresponse to a request e.g. 
136.243.250.62/cgi-bin/mapserv

or aslo when I try a getcapabiliteis request like

http://136.243.250.62/cgi-bin/mapserv?map=/var/www/mapdata/ccrp/mapfiles/fingermillet2.map
 
<http://136.243.250.62/cgi-bin/mapserv?map=/var/www/mapdata/ccrp/mapfiles/fingermillet2.map=1.1.1=getCapabilities=wms>
 =1.1.1=getCapabilities=wms

I always get a 'binary file back' output like below the line . Would anybody 
know what could have gone wrong or where to start figuring this out ?

 

Cheers

Karsten

 

Karsten Vennemann
Terra GIS LTD

.binary output below? -

ELF  >ð
@ @   P"  @ 8   @ ‑@   @ @ @ @ ø  ø 
  8  8@ 8@      @ 
  @   ð  ð` ð`   (
‑  ‑` ‑` ð  ð   T  T@ T@ D  
 D  Påtd   È  È@ È@ <   <  Qåtd 
 Råtd   ð  ð` ð`
/lib64/ld-linux-x86-64.so.2  GNU   GNU 
O ~a¢; ¼k*BUÍš~6›   ‑ €!
ˆ @‑   "   *   j CÖºã’|(ŒCEÕìjš|2bÛíØqX8ò‹ÚÍ㞸ñ

:—
­KãÀêÓï
âž Ñ”óµ         
Ï      š      e        
   m     /   Â    
   –     Y     l    
  ¥      å      > 
  `     9     û      
£     Ý      ª      
R   t     /   
       y     ’      bè 
` Ï!` ˆ     !`¼ø ` ·  
 
 $@   h   
 ð
@ Ãø `     !`o   
 @@ e   y   
@ d è ` ‘    À@\   
 ´@ R   
 °@   
 Ý@ Glibmapserver.so.2 _ITM_deregisterTMCloneTable __gmon_start__ 
_Jv_RegisterClasses _ITM_registerTMCloneTable msIO_installHandlers 
msFreeMapServObj msDebug loadParams msCGIWriteError msIO_fprintf msGetVersion 
msCGIWriteLog msSet

Re: [mapserver-users] seemingly sucessfully compiled mapserver 7.0.1 on ubuntu 14.04 - but NO - gives binary output ?

2016-05-31 Thread karsten
Hi,
 
Thanks for our response. I don't think that is the issue because the apparent 
'download' of the mapserv executable is only because browsers in this case do 
not 'understand' the mine type of the response . Regularly the response is just 
a text file but apparently a 'download' of mapserv... I fact you can usually 
rename the downloaded mapserv and rename as a text file then read the error 
message.
I have in any  Apache configuration
 
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/

AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Require all granted


Cheers
Karsten

  _  

From: Rahkonen Jukka (MML) [mailto:jukka.rahko...@maanmittauslaitos.fi] 
Sent: Tuesday, April 05, 2016 0:17
To: kars...@terragis.net; mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] seemingly sucessfully compiled mapserver 7.0.1 
on ubuntu 14.04 - but NO - gives binary output ?



Hi,

 

I believe that there is something wrong with the configuration of your http 
server. It does not seem to know that you do not want to download the mapserv 
binary but make the binary to work for you. If you run Apache I would have a 
look at “ScriptAlias” in the httpd.conf file and check that the directory where 
you have placed the mapserv binary is configured to contain applications. This 
example is from Windows.

 

# ScriptAlias: This controls which directories contain server scripts. 

# ScriptAliases are essentially the same as Aliases, except that

# documents in the target directory are treated as applications and

# run by the server when requested rather than as documents sent to the

# client.  The same rules about trailing "/" apply to ScriptAlias

# directives as to Alias.

#

ScriptAlias /cgi-bin/ "/ms4w/Apache/cgi-bin/"

ScriptAlias /fcgi-bin/ "/ms4w/Apache/cgi-bin/"

 

-Jukka Rahkonen-

 

karsten wrote:



 

Hi All,

 

I just seemingly sucessfully compiled mapserver 7.0.1 on Ubuntu 14.04 and can 
getv the follwoing output  from the executable:

/usr/lib/cgi-bin# ./mapserv -v
MapServer version 7.0.1 OUTPUT=PNG OUTPUT=JPEG SUPPORTS=PROJ SUPPORTS=AGG 
SUPPORTS=FREETYPE SUPPORTS=CAIRO SUPPORTS=ICONV SUPPORTS=FRIBIDI 
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT 
SUPPORTS=WCS_SERVER SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL 
INPUT=SHAPEFILE

Howvere when I try to get a get aresponse to a request e.g. 
136.243.250.62/cgi-bin/mapserv

or aslo when I try a getcapabiliteis request like

http://136.243.250.62/cgi-bin/mapserv?map=/var/www/mapdata/ccrp/mapfiles/fingermillet2.map
 
<http://136.243.250.62/cgi-bin/mapserv?map=/var/www/mapdata/ccrp/mapfiles/fingermillet2.map=1.1.1=getCapabilities=wms>
 =1.1.1=getCapabilities=wms

I always get a 'binary file back' output like below the line . Would anybody 
know what could have gone wrong or where to start figuring this out ?

 

Cheers

Karsten

 

Karsten Vennemann
Terra GIS LTD

.binary output below? -

ELF  >ð
@ @   P"  @ 8   @ ‑@   @ @ @ @ ø  ø 
  8  8@ 8@      @ 
  @   ð  ð` ð`   (
‑  ‑` ‑` ð  ð   T  T@ T@ D  
 D  Påtd   È  È@ È@ <   <  Qåtd 
 Råtd   ð  ð` ð`
/lib64/ld-linux-x86-64.so.2  GNU   GNU 
O ~a¢; ¼k*BUÍš~6›   ‑ €!
ˆ @‑   "   *   j CÖºã’|(ŒCEÕìjš|2bÛíØqX8ò‹ÚÍ㞸ñ

:—
­KãÀêÓï
âž Ñ”óµ         
Ï      š      e        
   m     /   Â    
   –     Y     l    
  ¥      å      > 
  `     9     û      
£     Ý      ª      
R   t     /   
       y     ’      bè 
` Ï!` ˆ     !`¼ø ` ·  
 
 $@   h   
 ð
@ Ãø `     !`o   
 @@ e   y   
@ d è ` ‘    À@\   
 ´@ R   
 °@   
 Ý@ Glibmapserver.so.2 _ITM_deregisterTMCloneTable __gmon_start__ 
_Jv_RegisterClasses _ITM_registerTMCloneTable msIO_installHandlers 
msFreeMapServObj ms

[mapserver-users] seemingly sucessfully compiled mapserver 7.0.1 on ubuntu 14.04 - but NO - gives binary output ?

2016-04-05 Thread karsten
Hi All,
 
I just seemingly sucessfully compiled mapserver 7.0.1 on Ubuntu 14.04 and can 
getv the follwoing output  from the executable:
/usr/lib/cgi-bin# ./mapserv -v
MapServer version 7.0.1 OUTPUT=PNG OUTPUT=JPEG SUPPORTS=PROJ SUPPORTS=AGG 
SUPPORTS=FREETYPE SUPPORTS=CAIRO SUPPORTS=ICONV SUPPORTS=FRIBIDI 
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT 
SUPPORTS=WCS_SERVER SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL 
INPUT=SHAPEFILE

Howvere when I try to get a get aresponse to a request e.g. 
136.243.250.62/cgi-bin/mapserv
or aslo when I try a getcapabiliteis request like
http://136.243.250.62/cgi-bin/mapserv?map=/var/www/mapdata/ccrp/mapfiles/fingermillet2.map
 
<http://136.243.250.62/cgi-bin/mapserv?map=/var/www/mapdata/ccrp/mapfiles/fingermillet2.map=1.1.1=getCapabilities=wms>
 =1.1.1=getCapabilities=wms
I always get a 'binary file back' output like below the line . Would anybody 
know what could have gone wrong or where to start figuring this out ?
 
Cheers
Karsten
 

Karsten Vennemann
Terra GIS LTD

.binary output below? -

ELF  >    ð@ @   P"  @ 8   @         @   
@ @ @ @ ø  ø           8  8@ 8@    
          @   @           
ð  ð` ð`   (          ` ` 
ð  ð           T  T@ T@ D   D      
Påtd   È  È@ È@ <   <      Qåtd   
   Råtd   ð  ð` ð`     
   /lib64/ld-linux-x86-64.so.2          GNU                   
GNU O ~a¢; ¼k*BUÍš~6›            €!
ˆ @   "   *   j CÖºã’|(ŒCEÕìjš|2bÛíØqX8ò‹ÚÍ㞸ñ:—­KãÀêÓïâž Ñ”ó
µ         Ï      
š      e           
m     /   Â        
   –     Y     l      
¥      å      >   
`     9     û      £  
   Ý      ª          
R   t     /     
     y     ’      b  
  è ` Ï    !` ˆ     !`    ¼    ø ` 
·   
 $@   h   
 ð@ à    ø `     !`    o   
 @@ e   y    
@ d è ` ‘    À@    \    ´@   
  R   
 °@       
 Ý@ Glibmapserver.so.2 _ITM_deregisterTMCloneTable __gmon_start__ 
_Jv_RegisterClasses _ITM_registerTMCloneTable msIO_installHandlers 
msFreeMapServObj msDebug loadParams msCGIWriteError msIO_fprintf msGetVersion 
msCGIWriteLog msSetup msGetGlobalDebugLevel msCGIDispatchRequest msCGILoadMap 
msAllocMapServObj msCleanup msIO_setHeaderEnabled libc.so.6 fflush exit strncmp 
signal puts putchar putenv stdout stderr gettimeofday strcmp __libc_start_main 
_edata __bss_start _end 
/src/ms/mapserver-7.0.1/build:/usr/local/lib:
 __libc_csu_fini __data_start __libc_csu_init msCleanupOnSignal _IO_stdin_used 
GLIBC_2.2.5                           
               O     ui       ø`       
 !`    !`    %    `     ` 
      ( `       0 `       8 `       
@ `       H `       P `    
X `    
   ` `       h `       p `    
   x `       € `       ˆ `    
    `       ˜ `     `       ¨ `  
         ° `       ¸ `       À `    
   È `       Ð `       Ø `       
à `       HƒìH‹Õ  H…Àtèƒ   HƒÄà  ÿ5  ÿ%Ä  
@ ÿ%  héà%º  h   éÐ%²  h   éÀ%ª  h   é°%¢  h   
é %š  h   é%’  h   é€%Š  h   ép%‚  h   é`%z  h
éP%r  h
   é@%j  h   é0%b  h   é %Z  h
   é%R  h   é %J  h   éðþÿÿÿ%B  h   éàþÿÿÿ%:  h   éÐþÿÿÿ%2  
h   éÀþÿÿÿ%*  h   é°þÿÿÿ%"  h   é þÿÿÿ%  h   éþÿÿÿ%  h   é€þÿÿÿ%
  h   épþÿÿÿ%

[mapserver-users] UTF grid capabilities MapServer 7 ?

2015-10-15 Thread karsten
Hi all, 
 
I will be teaching a MapServer class the upcoming weekend and really wanted
to add an example about the new UTF grid capabilities for MapServer 7 (seen
this announced in the FOSS4G 2015 MapServer Status Report document I
downloaded.
Does anybody know if there is any working example our there I can look at ,
any documentation (could not even find a mention of UTF Grid in the new
MapServer.pdf  http://mapserver.org/MapServer.pdf for MS 7 nor could I find
any example of the map file syntax to use. 
 
Each and every insight or help is greatly appreciated.
 
Cheers
Karsten

Karsten Vennemann
Principal

Terra GIS LTD
2119 Boyer Ave E 
Seattle, WA  98112
USA 
 <http://www.terragis.net/> www.terragis.net
Phone ++1 206 905 1711


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

Re: [mapserver-users] fast cgi MapServer (version 6.0.3) vs cgi with awms getmap request

2012-11-08 Thread karsten
Hi Andreas,

 I just tested fast cgi MapServer (version 6.0.3) vs cgi with a wms 
 getmap request againtst a map file with 73 postgis layers (and 
 PROCESSING CLOSE_CONNECTION=DEFER setting for each layer.)

 IMHO that processing option avoids reopening a connection to the same
database for a single request. Once the request is done the the connection
will be closed.
I thought that setting allows to open the db connection only once , keep it
open until all layers data are read and will prevent closing and opening
connections in between layers ?

 FastCGI only reduces the startup time (as the processes are already
running) and therefore improves mostly simple requests where startup time is
significant compared to content generation - like GetCapabilities and
GetLegendGraphic. In your case parsing the map file with 73 layers already
introduces a significant workload for every request, independent of the
request type.
  That gap should be closed by mod_mapserver which associates a map file
with an URI and keeps a copy of the parsed object in memory wich usually
keeps database connections open.

I searched the list and the MapServer doc about the Apache ? Module
mod_mapserver, however I could not find almost any reference to it other
than it is on the wish list for v 6.2 ? Does it already exist in MapServer
6.0.3 And if so - is there any info how to configure that feature ?

Cheers
Karsten





===
Email scanned by PC Tools - No viruses or spyware found.
(Email Guard: 9.0.0.2308, Virus/Spyware Database: 6.20820)
http://www.pctools.com/
===
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] fast cgi MapServer (version 6.0.3) vs cgi with a wms getmap request

2012-11-07 Thread karsten
Hey there, 
 
I just tested fast cgi MapServer (version 6.0.3) vs cgi with a wms getmap
request againtst a map file with 73 postgis layers (and PROCESSING
CLOSE_CONNECTION=DEFER setting for each layer.)

However simple manual timing of the getmap request testing in Firebug of
rendering speed shows that fastcgi is bascially at the same speed or slower
than cgi so far , any ideas why that could be , any more tweaks need to
speed it up ? 
It is all on same linux server. Will I need to fiddle with any of the
FastCgiConfig settings ? 

Cheers
Karsten

Karsten Vennemann
Principal

Terra GIS LTD
2119 Boyer Ave E 
Seattle, WA  98112
USA 
www.terragis.net http://www.terragis.net/ 

Phone ++1 206 905 1711
Fax  ++1 925 905 1711






===
Email scanned by PC Tools - No viruses or spyware found.
(Email Guard: 9.0.0.2308, Virus/Spyware Database: 6.20820)
http://www.pctools.com/
===
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] limit GetLegendGraphic to feature types (classes) in dynamic layer

2011-06-29 Thread karsten vennemann
Hi Folks,

 

I have set up a dynamic WMS layer using MapServer variables (and a PostGIS
layer). That is working well. 

Depending on user input on the web map I would like not only to show only
the types of features in the dynamic layer on the map (that part is working
already) but also in the legend (i.e. legend icons limited to the current
feature class).

Is there a way to limit the wms GetLegendGraphic request to specific feature
type classes (define din map file) ? Specifically is the a way without using
SLDs , something even simpler like a filter ?

 

Thanks

Karsten

 

Karsten Vennemann
Principal

Terra GIS LTD
Seattle, WA
USA 
www.terragis.net blocked::http://www.terragis.net/ 

 

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


[mapserver-users] character encoding shape file with german umlaute

2011-04-28 Thread karsten vennemann
Hi List,
 
I had some trouble with getting correct character encoding to work with 
MapServer and with german Umlauten (ÄÜÖ and ß).
For a PostGIS layer I got it fixed setting the permanent variable 'client 
encoding'  to LATIN1 does the trick ;) The db otherwise is utf8 , the system 
german locale (which has impact really anyway for he most part).
 
However I have now trouble also with labels from a shape file based MapServer 
WMS which show screwed up as some symbols . The attributes are showing 
correctly inside the dbf table. The same layers just 'worked' on the old server 
- however something must be different on the new one since that is just came up 
with the move. Is there anything I can look for to coax MapServer to correctly 
encode label test annotations  ?
I tried setting
   ENCODING 'LATIN1'
in the label to no avail ..
 
Cheers
Karsten

Terra GIS LTD
www.terragis.net
 
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] RE: character encoding shape file with german umlaute

2011-04-28 Thread karsten vennemann
No stop. 
setting
   ENCODING 'LATIN1'
in the label fixed it :)
 
Sorry for the disturbance
Karsten



  _  

From: karsten vennemann [mailto:kars...@terragis.net] 
Sent: Thursday, April 28, 2011 00:55
To: 'mapserver-users@lists.osgeo.org'
Subject: character encoding shape file with german umlaute


Hi List,
 
I had some trouble with getting correct character encoding to work with 
MapServer and with german Umlauten (ÄÜÖ and ß).
For a PostGIS layer I got it fixed setting the permanent variable 'client 
encoding'  to LATIN1 does the trick ;) The db otherwise is utf8 , the system 
german locale (which has impact really anyway for he most part).
 
However I have now trouble also with labels from a shape file based MapServer 
WMS which show screwed up as some symbols . The attributes are showing 
correctly inside the dbf table. The same layers just 'worked' on the old server 
- however something must be different on the new one since that is just came up 
with the move. Is there anything I can look for to coax MapServer to correctly 
encode label test annotations  ?
I tried setting
   ENCODING 'LATIN1'
in the label to no avail ..
 
Cheers
Karsten

Terra GIS LTD
www.terragis.net
 

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


[mapserver-users] WMS title tags

2009-11-27 Thread karsten vennemann
I have been working for a while with WMS layers served by MapServer at they 
work great. One thing I was wondering about:  What are the wms_title and 
wms_group_title tags actually good for ?
When I tried to use them to access a WMS they actually don't work (in a http 
request as layer names), instead with MapServer the MapServer layer names has 
to be used (at least in all cases I checked). So for example I have a group of 
river layer in my map file just like the one below:
 
LAYER
 NAME Rivers
 GROUP Rivers
 TYPE LINE
 DUMP true
  METADATA  
   wms_group_title the_rivers
wms_title the_rivers
wms_srs epsg:4326
wms_feature_info_mime_type text/html 
 END
...
 
So Rivers I can use to get the layer in a getmap request but not 
the_rivers. So is there any use for  wms_group_title and wms_title ?
How is this handled by other map rendering engines (Geoserver, Mapnik , Degree?)

Thanks so much
Karsten

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


[mapserver-users] OS and MapServer related talks at WAURISA 2009, May 4th-6th, 2009, Bellevue, WA, USA

2009-04-15 Thread karsten vennemann
The CUGOS group  http://groups.google.com/group/cugos 
http://groups.google.com/group/cugos (a chapter of OSGEO) is doing an 
introductory workshop on Open Source GIS at the upcoming WAURISA conference in 
Bellevue, WA, USA from May 4th-6th. The half day workshop Introduction to Open 
Source GIS - A Practical Approach:  
http://www.waurisa.org/conferences/2009/Workshops.html 
http://www.waurisa.org/conferences/2009/Workshops.html will be held on May 4th, 
2009. CUGOS will also have an information table related to FOSS4G, OSGEO and 
related local resources. 
 
The conference will also be of interest to more advanced users and developers 
of FOSS4G since it will host a substantial number of talks related to OS GIS 
(12+ presentation out of 60 or so)  
http://www.waurisa.org/conferences/2009/Agenda.html 
http://www.waurisa.org/conferences/2009/Agenda.html 
 
Remember to sign up for the conference by 4/21/09 to get the early bird rate  
http://www.waurisa.org/conferences/2009_Conference_Index.html 
http://www.waurisa.org/conferences/2009_Conference_Index.html 
 
Karsten Vennemann 
Principal 
 
Terra GIS LTD 
Seattle, USA 
 http://www.terragis.net www.terragis.net 

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


[mapserver-users] Obama Campaign - Mapping voters with Mapserver, PostGIS and Openlayers

2008-11-24 Thread karsten vennemann
I wanted to share this with you all. 
http://www.terragis.net/2008/11/24/obama-campaign-mapping-voters-with-mapserver-postgis-and-openlayers/
Karsten
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[MAPSERVER-USERS] wms getfeatureinfo get multiple results back ?

2008-11-02 Thread Karsten Vennemann

Hi I'm using Mapserver with Openlayers to retrieve attributes via a
getfeatureinfo query to a postgis/wms layer. I defined templates and it
works fine to identify one point but if there are multiple points (with the
same geometry) on the same location I only get one to display in the html
template output. I added to my wms_onlineresource
http://xy.com/cgi-bin/mapserv?map=/mnt/maps/usa.mapmode=nquery;.
Any ideas what I might be missing to get multiple results back ?
-- 
View this message in context: 
http://www.nabble.com/wms-getfeatureinfo-get-multiple-results-back---tp20297727p20297727.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