timeouts + infinite loops

chakl (olafabbe@w250zrz.zrz.tu-berlin.de)
Fri, 2 Sep 1994 22:41:05 +0200 (MET DST)


Hi,

sounds somewhat familiar ...

> and got a result code of 200.  Unfortunately, it then dropped into
> an infinite loop somewhere between obtaining the result and indexing it 
[...]^^^^^^^^^^^^^
> When running the HEAD client, I was getting back a timed-out response.
[...]                                                ^^^^^^^^^^^^^^^^^^
> So, the upshot is that something very strange is happening with the
> alarm timeout which gets "fixed" when run under the debugger.  Also,
> the connect() system call (C version used by perl) seems to have an
> internal timeout as well.

Unfortunately, I'm not familiar with debuggers + system programming.

But I've seen similar problems while hacking/testing a libwww-perl based 
robot in a Linux environment (kernel 1.0, perl 4.036, libwww 0.12-0.30, 
NCSA httpd 1.1-1.3).  Symptoms:

- I get response 603 + the program seems to hang.  ps says it's 
  interrupted, waiting + swapped out.
- Plugged print()s in.  Seems to enter sleep($somenum) + never returns.
- $somenum seems to be a magic number, on my system it's around 20.
  If I up that $sleeptime-between-requests, the system will probably hang.
  If I stay below it, the program will probably run as desired.
- Seems to correlate with the load of my local system (starting large
  progs while running the spider gives a good chance to get 603)

I have run the same program in the real world from an SGI machine and
never encountered these problems ... but I'm not really convinced that
it's just a Linux problem, either.

just dropping observations,
chakl