Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#1427 closed bug (fixed)

GRASS vectors support: memory leak?

Reported by: msieczka Owned by: nobody
Priority: critical: causes crash or data corruption Milestone:
Component: GRASS Version: Trunk
Keywords: Cc:
Must Fix for Release: Yes Platform: Debian
Platform Version: Awaiting user input: no

Description

  1. Add a fairly big GRASS vector. In my case with 2 GB RAM, 512 MB swap a 1,500,000 vertices map was enough.
  1. Zoom, pan, query, change symbology etc - notice how your memory usage grows constantly. Finalyy you run out of memory and QGIS is killed by OS.

This doesn't take place with even circa 10x bigger Shapefiles.

Debian testing amd64, SVN trunk r9705.

Change History (9)

comment:1 by warmerdam, 15 years ago

Cc: warmerdam added

Hi,

Has any effort been made to see if this is a QGIS or OGR problem?

ALso, particulars of the versions of OGR and grass libraries used would be helpful.

in reply to:  1 comment:2 by msieczka, 15 years ago

Replying to warmerdam:

Hi,

Has any effort been made to see if this is a QGIS or OGR problem?

Good point. I don't know how to do it though.

ALso, particulars of the versions of OGR and grass libraries used would be helpful.

GRASS 6.4 SVN develbranch6 r34483, GDAL SVN trunk r15759. GDAL-GRASS plugin built from the specified GDAL version against the specified GRASS version.

comment:3 by warmerdam, 15 years ago

One approach to testing if it is an OGR problem would be to run ogrinfo against a grass dataset under valgrind and examine what leaks show up in a leak report, if any.

Alternatively, writes a small program or script using OGR that repeatedly scans over a grass vector dataset and see if the memory of the process grows for each iteration.

It sounds like you are running against trunk of everything, so presumably this does represent a real and current leak at some level of the software stack.

comment:4 by wonder, 15 years ago

QGIS has its own implementation of GRASS vector layers, independent from OGR, so this issue is probably a QGIS problem (or GRASS problem).

comment:5 by warmerdam, 15 years ago

Cc: warmerdam removed

Ah, my error. Sorry for the noise!

comment:6 by pcav, 15 years ago

Resolution: worksforme
Status: newclosed

Please check if this still applies - I tested extensively, without problems. If it still holds true, please reopen the ticket. Thanks

in reply to:  6 comment:7 by msieczka, 15 years ago

Resolution: worksforme
Status: closedreopened

Replying to pcav:

Please check if this still applies - I tested extensively, without problems. If it still holds true, please reopen the ticket.

Replying to pcav:

Tested with spearfish, and it works. Please check whether it is a local problem on your computer and reopen it if necessary.

The bug is still present. I don't see how it could be a problem with my machine. Can you elaborate?

The same dat as a GRASS vector map make QGIS allocate memory but not free it - I can make QGIS crash this way due to depleting all RAM and swap within minutes, only panning and zooming around. However, the same data as a Shapefile don't pose memory allocation problems to QGIS.

QGIS trunk r91492, GDAL 1.6+SVN r87108, GRASS 6.5 r73468.

comment:8 by wonder, 15 years ago

Resolution: fixed
Status: reopenedclosed

I can replicate with a large grid layer that qgis slowly leaks memory.

Fixed in r9985 (trunk) and r9986 (branch 1.0)

comment:9 by (none), 15 years ago

Milestone: Version 1.0.1

Milestone Version 1.0.1 deleted

Note: See TracTickets for help on using tickets.