code I item #355, was opened at 2007-04-03 22:15
Status: Open
Priority: 3
Submitted By: Francesco Lovergine (frankie)
Assigned to: Nobody (None)
Summary: A lot of <defunct> processes around while working
Issue type: module bug
Issue status: None
GRASS version: 6.2.1
GRASS component: gis.m
Operating system: Linux
Operating system version: Debian sid
GRASS CVS checkout date, if applies (YYMMDD):
Initial Comment:
While using georectifier a lot of pending defuncts appear for g.region. It seems (?) parent does not loop on wait() while managing SIGCHLD process as it should. All processes are closed when gm.tcl is terminated.
frankie 5484 1 2 16:49 pts/11 00:00:32 wish /usr/lib/grass/etc/gm/gm.tcl -name gm_tcl
frankie 5525 5484 0 16:49 pts/11 00:00:00 [g.region] <defunct>
frankie 5527 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5529 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5590 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5602 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5605 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5608 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5616 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5623 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5654 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5683 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5706 5484 0 16:51 pts/11 00:00:00 [g.region] <defunct>
frankie 5718 5484 0 16:51 pts/11 00:00:00 [g.region] <defunct>
frankie 5729 5484 0 16:51 pts/11 00:00:00 [g.region] <defunct>
frankie 5739 5484 0 16:52 pts/11 00:00:00 [g.region] <defunct>
frankie 5751 5484 0 16:52 pts/11 00:00:00 [g.region] <defunct>
frankie 5763 5484 0 16:52 pts/11 00:00:00 [g.region] <defunct>
frankie 5774 5484 0 16:53 pts/11 00:00:00 [g.region] <defunct>
frankie 5784 5484 0 16:53 pts/11 00:00:00 [g.region] <defunct>
frankie 5794 5484 0 16:53 pts/11 00:00:00 [g.region] <defunct>
frankie 5805 5484 0 16:54 pts/11 00:00:00 [g.region] <defunct>
frankie 5821 5484 0 16:54 pts/11 00:00:00 [g.region] <defunct>
frankie 5922 5484 0 16:55 pts/11 00:00:00 [g.region] <defunct>
frankie 5932 5484 0 16:56 pts/11 00:00:00 [g.region] <defunct>
frankie 5943 5484 0 16:56 pts/11 00:00:00 [g.region] <defunct>
frankie 5955 5484 0 16:57 pts/11 00:00:00 [g.region] <defunct>
frankie 5965 5484 0 16:57 pts/11 00:00:00 [g.region] <defunct>
frankie 6030 5484 0 16:58 pts/11 00:00:00 [g.region] <defunct>
frankie 6054 5484 0 16:58 pts/11 00:00:00 [g.region] <defunct>
frankie 6086 5484 0 16:58 pts/11 00:00:00 [g.region] <defunct>
frankie 6096 5484 0 16:58 pts/11 00:00:00 [g.region] <defunct>
frankie 6128 5484 0 16:58 pts/11 00:00:00 [g.region] <defunct>
frankie 6160 5484 0 16:58 pts/11 00:00:00 [g.region] <defunct>
----------------------------------------------------------------------
You can respond by visiting:
http://wald.intevation.org/tracker/?func=detail&atid=204&aid=355&group_id=21
grass-codei@wald.intevation.org wrote:
code I item #355, was opened at 2007-04-03 22:15
Status: Open
Priority: 3
Submitted By: Francesco Lovergine (frankie)
Assigned to: Nobody (None)
Summary: A lot of <defunct> processes around while working
Issue type: module bug
Issue status: None
GRASS version: 6.2.1
GRASS component: gis.m
Operating system: Linux
Operating system version: Debian sid
GRASS CVS checkout date, if applies (YYMMDD):
Initial Comment:
While using georectifier a lot of pending defuncts appear for
g.region. It seems (?) parent does not loop on wait() while managing
SIGCHLD process as it should. All processes are closed when gm.tcl is
terminated.
frankie 5484 1 2 16:49 pts/11 00:00:32 wish /usr/lib/grass/etc/gm/gm.tcl -name gm_tcl
frankie 5525 5484 0 16:49 pts/11 00:00:00 [g.region] <defunct>
frankie 5527 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5529 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
[snip]
AFAICT, this is due to MapCanvas::set_wind; it should be using "exec"
rather than "open |...".
--
Glynn Clements <glynn@gclements.plus.com>
This is because of the need to run g.region -gp and read the results back,
in order to get current region information.
Michael
On 4/3/07 7:38 PM, "Glynn Clements" <glynn@gclements.plus.com> wrote:
grass-codei@wald.intevation.org wrote:
code I item #355, was opened at 2007-04-03 22:15
Status: Open
Priority: 3
Submitted By: Francesco Lovergine (frankie)
Assigned to: Nobody (None)
Summary: A lot of <defunct> processes around while working
Issue type: module bug
Issue status: None
GRASS version: 6.2.1
GRASS component: gis.m
Operating system: Linux
Operating system version: Debian sid
GRASS CVS checkout date, if applies (YYMMDD):
Initial Comment:
While using georectifier a lot of pending defuncts appear for
g.region. It seems (?) parent does not loop on wait() while managing
SIGCHLD process as it should. All processes are closed when gm.tcl is
terminated.
frankie 5484 1 2 16:49 pts/11 00:00:32 wish
/usr/lib/grass/etc/gm/gm.tcl -name gm_tcl
frankie 5525 5484 0 16:49 pts/11 00:00:00 [g.region] <defunct>
frankie 5527 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5529 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
[snip]
AFAICT, this is due to MapCanvas::set_wind; it should be using "exec"
rather than "open |...".
__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University
phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton
Michael Barton wrote:
>> frankie 5484 1 2 16:49 pts/11 00:00:32 wish
>> /usr/lib/grass/etc/gm/gm.tcl -name gm_tcl
>> frankie 5525 5484 0 16:49 pts/11 00:00:00 [g.region] <defunct>
>> frankie 5527 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
>> frankie 5529 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
>
> [snip]
>
> AFAICT, this is due to MapCanvas::set_wind; it should be using "exec"
> rather than "open |...".
This is because of the need to run g.region -gp and read the results back,
in order to get current region information.
Nope. The code in question is:
proc MapCanvas::set_wind {mon args overwrite} {
variable zoom_attrs
global devnull
set values [MapCanvas::currentzoom $mon]
set options {}
foreach attr $zoom_attrs value $values {
if {$attr != "rows" && $attr != "cols"} {
lappend options "$attr=$value"
}
}
if {$overwrite == 1} {
open [concat "|g.region --o" $options $args "2> $devnull"]
} else {
open [concat "|g.region" $options $args "2> $devnull"]
}
}
Nothing is using the returned descriptor. More importantly, nothing is
closing it, so the process will remain a zombie forever.
This should be using exec, not open.
--
Glynn Clements <glynn@gclements.plus.com>
Thanks. This is easily fixable.
Michael
On 4/4/07 12:06 PM, "Glynn Clements" <glynn@gclements.plus.com> wrote:
Michael Barton wrote:
frankie 5484 1 2 16:49 pts/11 00:00:32 wish
/usr/lib/grass/etc/gm/gm.tcl -name gm_tcl
frankie 5525 5484 0 16:49 pts/11 00:00:00 [g.region] <defunct>
frankie 5527 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5529 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
[snip]
AFAICT, this is due to MapCanvas::set_wind; it should be using "exec"
rather than "open |...".
This is because of the need to run g.region -gp and read the results back,
in order to get current region information.
Nope. The code in question is:
proc MapCanvas::set_wind {mon args overwrite} {
variable zoom_attrs
global devnull
set values [MapCanvas::currentzoom $mon]
set options {}
foreach attr $zoom_attrs value $values {
if {$attr != "rows" && $attr != "cols"} {
lappend options "$attr=$value"
}
}
if {$overwrite == 1} {
open [concat "|g.region --o" $options $args "2> $devnull"]
} else {
open [concat "|g.region" $options $args "2> $devnull"]
}
}
Nothing is using the returned descriptor. More importantly, nothing is
closing it, so the process will remain a zombie forever.
This should be using exec, not open.
__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University
phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton
Fixed in cvs.
Michael
On 4/4/07 12:06 PM, "Glynn Clements" <glynn@gclements.plus.com> wrote:
Michael Barton wrote:
frankie 5484 1 2 16:49 pts/11 00:00:32 wish
/usr/lib/grass/etc/gm/gm.tcl -name gm_tcl
frankie 5525 5484 0 16:49 pts/11 00:00:00 [g.region] <defunct>
frankie 5527 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
frankie 5529 5484 0 16:50 pts/11 00:00:00 [g.region] <defunct>
[snip]
AFAICT, this is due to MapCanvas::set_wind; it should be using "exec"
rather than "open |...".
This is because of the need to run g.region -gp and read the results back,
in order to get current region information.
Nope. The code in question is:
proc MapCanvas::set_wind {mon args overwrite} {
variable zoom_attrs
global devnull
set values [MapCanvas::currentzoom $mon]
set options {}
foreach attr $zoom_attrs value $values {
if {$attr != "rows" && $attr != "cols"} {
lappend options "$attr=$value"
}
}
if {$overwrite == 1} {
open [concat "|g.region --o" $options $args "2> $devnull"]
} else {
open [concat "|g.region" $options $args "2> $devnull"]
}
}
Nothing is using the returned descriptor. More importantly, nothing is
closing it, so the process will remain a zombie forever.
This should be using exec, not open.
__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics and Complexity
Arizona State University
phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton