mapnik.render causing segmentation fault

View: New views
6 Messages — Rating Filter:   Alert me  

mapnik.render causing segmentation fault

by Philip Stubbs-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi all,

I am new hear but I don't know where else to look. I have installed
mapnik and am trying to get the generate_tiles script to work. It is
causing a segmentation fault when mapnik.render is called. I have
tried the 'hello world' example and that works, but I notice that uses
mapnik.render_to_file. Therefore I tried to adjust that script to use
the mapnik.render method, and it also then seg faulted.

I am not a programmer, and what little I do know is not in Python :-(
My Google foo is also weak today. Any help would be appreciated.

Regards,
--
Philip Stubbs
_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: mapnik.render causing segmentation fault

by Dane Springmeyer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Philip,

Are you running Mapnik 0.6.1 and debian sid or ubuntu karmic?

If so you'll likely need to upgrade to Mapnik trunk, as we've recently  
fixed a bug that slipped into 0.6.1 that would cause segfaults when  
reading from shapefiles:

http://trac.mapnik.org/ticket/436

Before you do this you could try commenting out the xml <Layer>  
definitions that reference shapefiles in the osm.xml and see if that  
fixed the problem.

Dane


On Nov 1, 2009, at 12:52 PM, Philip Stubbs wrote:

> Hi all,
>
> I am new hear but I don't know where else to look. I have installed
> mapnik and am trying to get the generate_tiles script to work. It is
> causing a segmentation fault when mapnik.render is called. I have
> tried the 'hello world' example and that works, but I notice that uses
> mapnik.render_to_file. Therefore I tried to adjust that script to use
> the mapnik.render method, and it also then seg faulted.
>
> I am not a programmer, and what little I do know is not in Python :-(
> My Google foo is also weak today. Any help would be appreciated.
>
> Regards,
> --
> Philip Stubbs
> _______________________________________________
> Mapnik-users mailing list
> Mapnik-users@...
> https://lists.berlios.de/mailman/listinfo/mapnik-users

_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: mapnik.render causing segmentation fault

by Philip Stubbs-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

2009/11/1 Philip Stubbs <philip@...>:

> Hi all,
>
> I am new hear but I don't know where else to look. I have installed
> mapnik and am trying to get the generate_tiles script to work. It is
> causing a segmentation fault when mapnik.render is called. I have
> tried the 'hello world' example and that works, but I notice that uses
> mapnik.render_to_file. Therefore I tried to adjust that script to use
> the mapnik.render method, and it also then seg faulted.
>
> I am not a programmer, and what little I do know is not in Python :-(
> My Google foo is also weak today. Any help would be appreciated.

Ops! Should have said that I am running Ubuntu 9.10, I installed
python-mapnik and Postgres from the Ubuntu repositories, and followed
the set-up guide from the openstreetmap wiki.

Now I have made a copy of the generate_image.py script and changed it
to use mapnik.render_to_file, and it has just successfully rendered an
image of the UK. This is going to be of more use to me than the tiles,
so I think I am sorted. Still, it would be good to know why the one
method works when the other does not. I may in the future want a local
tile server.


--
Philip Stubbs
_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: mapnik.render causing segmentation fault

by Dane Springmeyer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks for the added details Philip.

If changing the render method fixed the problem then that may not be  
the bug I previously mentioned.

I'm running a beta release of 9.10 and have not seen this problem, but  
I will try to get the release going to test further.

It would be great if you could provide the output of:

$ apt-cache show python-mapnik

Thanks,

Dane

On Nov 1, 2009, at 1:13 PM, Philip Stubbs wrote:

> 2009/11/1 Philip Stubbs <philip@...>:
>> Hi all,
>>
>> I am new hear but I don't know where else to look. I have installed
>> mapnik and am trying to get the generate_tiles script to work. It is
>> causing a segmentation fault when mapnik.render is called. I have
>> tried the 'hello world' example and that works, but I notice that  
>> uses
>> mapnik.render_to_file. Therefore I tried to adjust that script to use
>> the mapnik.render method, and it also then seg faulted.
>>
>> I am not a programmer, and what little I do know is not in Python :-(
>> My Google foo is also weak today. Any help would be appreciated.
>
> Ops! Should have said that I am running Ubuntu 9.10, I installed
> python-mapnik and Postgres from the Ubuntu repositories, and followed
> the set-up guide from the openstreetmap wiki.
>
> Now I have made a copy of the generate_image.py script and changed it
> to use mapnik.render_to_file, and it has just successfully rendered an
> image of the UK. This is going to be of more use to me than the tiles,
> so I think I am sorted. Still, it would be good to know why the one
> method works when the other does not. I may in the future want a local
> tile server.
>
>
> --
> Philip Stubbs
> _______________________________________________
> Mapnik-users mailing list
> Mapnik-users@...
> https://lists.berlios.de/mailman/listinfo/mapnik-users

_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: mapnik.render causing segmentation fault

by Jon Burgess-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Sun, 2009-11-01 at 20:52 +0000, Philip Stubbs wrote:
> Hi all,
>
> I am new hear but I don't know where else to look. I have installed
> mapnik and am trying to get the generate_tiles script to work. It is
> causing a segmentation fault when mapnik.render is called. I have
> tried the 'hello world' example and that works, but I notice that uses
> mapnik.render_to_file. Therefore I tried to adjust that script to use
> the mapnik.render method, and it also then seg faulted.

Try editing the script to set:

NUM_THREADS = 1

For reference, what OS & Mapnik version are you running?

        Jon



_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Parent Message unknown Fwd: mapnik.render causing segmentation fault

by Artem Pavlenko-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

And another one :)

---------- Forwarded message ----------
From: Artem Pavlenko <artem@...>
Date: 2009/11/1
Subject: Re: [Mapnik-users] mapnik.render causing segmentation fault
To: Philip Stubbs <philip@...>


Hi Philips,
Welcome to Mapnik! Please, provide more information about your setup e.g OS, mapnik version etc
Regards
Artem

2009/11/1 Philip Stubbs <philip@...>

Hi all,

I am new hear but I don't know where else to look. I have installed
mapnik and am trying to get the generate_tiles script to work. It is
causing a segmentation fault when mapnik.render is called. I have
tried the 'hello world' example and that works, but I notice that uses
mapnik.render_to_file. Therefore I tried to adjust that script to use
the mapnik.render method, and it also then seg faulted.

I am not a programmer, and what little I do know is not in Python :-(
My Google foo is also weak today. Any help would be appreciated.

Regards,
--
Philip Stubbs
_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users



_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users