[GRASS-dev] opencell opening temp null file: no temp files available
Hello, I am writing a Grass programm which creates a raster, reads the values of the raster map at certain points and creates a new rastermap having the same name as the old one. I am using the function G_open_cell_new() to overwrite the existing raster map. and the function G_close_cell() It works fine. But after about 1000 loops I get the following messsage. WARNING: opencell opening temp null file: no temp files available Does anyone know what it means. I have enough space left in my ./tmp folder. And I also have write permissions on it. Thanks in advance. Andi -- Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer ___ grass-dev mailing list grass-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/grass-dev
[GRASS-dev] (no subject)
It seems that the files are not closed, but I use if((elev_fd = G_open_cell_old (name, mapset)) 0) G_fatal_error( _(can't open %s), name); if((output_fd = G_open_cell_new(outname)) 0) G_fatal_error( _(can't open outname %s), outname); to open the files and G_close_cell(output_fd); G_close_cell(elev_fd); to close the files again. Is there anything wrong? Andi Glynn Clements wrote: [EMAIL PROTECTED] wrote: I am writing a Grass programm which creates a raster, reads the values of the raster map at certain points and creates a new rastermap having the same name as the old one. I am using the function G_open_cell_new() to overwrite the existing raster map. and the function G_close_cell() It works fine. But after about 1000 loops I get the following messsage. WARNING: opencell opening temp null file: no temp files available Does anyone know what it means. I have enough space left in my ./tmp folder. And I also have write permissions on it. It probably means that files aren't getting closed, so you are exceeding the limit on the number of open files per process (by default 1024, check with ulimit -n). On Linux, you can check which files a process has open by looking in the /proc/pid/fd directory, where pid is the PID of the process. If you're modifying a map in-place, you'll need to close and re-open the input map in order to see the changes. Opening a map for write creates a temporary file, which is renamed over the original when closed. If the original cell/fcell file is still open for read at that point, it will still exist and still be open (it will show up as (deleted) in /proc/pid/fd). -- Ist Ihr Browser Vista-kompatibel? Jetzt die neuesten Browser-Versionen downloaden: http://www.gmx.net/de/go/browser ___ grass-dev mailing list grass-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/grass-dev
Re: [GRASS-dev] opencell opening temp null file: no temp files available
It seems that the files are not closed, but I use if((elev_fd = G_open_cell_old (name, mapset)) 0) G_fatal_error( _(can't open %s), name); if((output_fd = G_open_cell_new(outname)) 0) G_fatal_error( _(can't open outname %s), outname); to open the files and G_close_cell(output_fd); G_close_cell(elev_fd); to close the files again. Is there anything wrong? Andi Glynn Clements wrote: [EMAIL PROTECTED] wrote: I am writing a Grass programm which creates a raster, reads the values of the raster map at certain points and creates a new rastermap having the same name as the old one. I am using the function G_open_cell_new() to overwrite the existing raster map. and the function G_close_cell() It works fine. But after about 1000 loops I get the following messsage. WARNING: opencell opening temp null file: no temp files available Does anyone know what it means. I have enough space left in my ./tmp folder. And I also have write permissions on it. It probably means that files aren't getting closed, so you are exceeding the limit on the number of open files per process (by default 1024, check with ulimit -n). On Linux, you can check which files a process has open by looking in the /proc/pid/fd directory, where pid is the PID of the process. If you're modifying a map in-place, you'll need to close and re-open the input map in order to see the changes. Opening a map for write creates a temporary file, which is renamed over the original when closed. If the original cell/fcell file is still open for read at that point, it will still exist and still be open (it will show up as (deleted) in /proc/pid/fd). -- Ist Ihr Browser Vista-kompatibel? Jetzt die neuesten Browser-Versionen downloaden: http://www.gmx.net/de/go/browser -- Feel free - 10 GB Mailbox, 100 FreeSMS/Monat ... Jetzt GMX TopMail testen: http://www.gmx.net/de/go/topmail ___ grass-dev mailing list grass-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/grass-dev