cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: ftp testserver hung

From: James Housley <jim_at_thehousleys.net>
Date: Fri, 22 Jun 2007 11:50:45 -0400

On Jun 22, 2007, at 11:33 AM, Guenter Knauf wrote:

> Hi,
>> On Thu, 21 Jun 2007, Guenter Knauf wrote:
>
>> Well, if you can find and fix how they are not killed now then
>> I'll be
>> happy.
>> It really bothers me that it leaves a few servers around at times
>> since it
>> makes automated testing a pain.
>
> this is my idea - not sure if it really works because I would have
> to wait for another hung (which happened today again, argh!):
>
> --- testcurl.pl.orig Sun Apr 01 15:59:50 2007
> +++ testcurl.pl Fri Jun 22 17:26:26 2007
> @@ -200,6 +200,11 @@
> sub mydie($){
> my $text=$_[0];
> logit "$text";
> + # check if we have test servers hanging around...
> + while (<tests/.*.pid>) {
> + logit "trying to kill $_ process";
> + system("kill -kill < $_");
> + }
> chdir $pwd; # cd back to the original root dir
>
> if ($pwd && $build) {
>
> what do you think? could that work?

You might want to wait a second after sending the kill to allow time
for it to die before looping again.

--
/"\   ASCII Ribbon Campaign  .
\ / - NO HTML/RTF in e-mail  .
  X  - NO Word docs in e-mail .
/ \ -----------------------------------------------------------------
                      http://www.FreeBSD.org     The Power to Serve
jim@TheHousleys.Net  http://www.TheHousleys.net
---------------------------------------------------------------------
Q: Because it reverses the logical flow of conversation.
A: Why is putting a reply at the top of the message frowned upon?
Received on 2007-06-22