[GRASS-dev] v.in.ogr eats all memory

Markus Neteler neteler at itc.it
Fri May 19 05:53:20 EDT 2006


Hamish wrote:

>>importing a big SHAPE file, it appeared that most
>>of the operating was shifted to swap space (Linux). I
>>had to reboot the machine (no remote login, not even
>>caplock worked).
>>    
>>
>
>Usually you can get away with remote login if it is X that locked up,
>with a frozen kernel you have less options.. ctrl-alt-F1 sometimes?
>  
>

The ssh daemon was no longer responding (I waited only some minutes,
though) and
the keyboard also dead (no capslock light, no ctrl-alt-F1,nothing).

>>Question: Can we add some test to avoid that more
>>than xx percent of the memory are used? There won't
>>be any hot plugin of extra RAM, so v.in.ogr should
>>exit with memory allocation error.
>>    
>>
>
>attempt G_malloc(),G_free() of estimated size before processing. Back in
>the mailing list archives somewhere I figured out the current bytes per
>vector point needed (with valgrind) and suggested this?
>
>I don't know how to query available memory in a cross platform way.
>  
>

Eg. the 'top' application knows it
Mem:   2058056k total,  2013328k used,    44728k free,   452900k buffers
Swap:  4192888k total,        0k used,  4192888k free,   295372k cached

so there must be a way.

Markus




More information about the grass-dev mailing list