develooper Front page | perl.perl5.porters | Postings from May 2015

Misbehaving watchdog on Windows?

Thread Next
Steve Hay
May 9, 2015 18:35
Misbehaving watchdog on Windows?
Message ID:
In the course of trying to test 5.22.0-RC0 with multiple
compilers/configurations I keep running into a nasty thing that I've
seen happen before and heard others mention before too: random
processes on my machine sometimes get killed during the test run,
sometimes even leading to the machine locking up or rebooting itself,
presumably depending on how fundamental to Windows the nuked processes

I would log it as a blocker bug, but for the fact that I think it's
quite an old problem, surely pre-5.20 at least. I recall talk of the
problem at the time of the kill process tree feature (broken in
5.17.2) getting fixed (in 5.19.10) and watchdog() switching to using
it (in commit
The kill process tree bug was reported in perl #121230 and there is
talk there (after the fix was applied) of this kind of problem
affecting George's smokers -- see and

Does anyone recall if we had this problem before the watchdog() change
cited above, changing kill('KILL', ...) to kill('-KILL', ...)?

The purpose of that change was to kill the cmd.exe->perl.exe process
tree, rather than just the cmd.exe (i.e. wrongly leaving the perl.exe
behind), since the system(1, $cmd) done in watchdog() unexpectedly
launched perl.exe via a cmd.exe rather than directly.

However, as I've just commented on perl #121283 (see there
are ways to guarantee launching the watchdog perl.exe directly, rather
than via a cmd.exe. If we did that, e.g. change the system(1, $cmd) to
system(1, @multi_element_cmd), then we could revert the kill('-KILL',
...) to kill('KILL, ...), which *might* stop this occasional
process-nuking nastiness, unless it predated the switch to -KILL

I'm going to try it out locally, anyway, to see if it does indeed seem
to fix the problem (although it's always hard to be sure with such
intermittent problems): That in itself would be a useful data point
regarding whether it's the restored -KILL feature that is the trouble,
or whether it's something else entirely.

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About