develooper Front page | perl.perl5.porters | Postings from July 2008

RF help with a v5.10 Heisenbug, please?

From:
Tom Christiansen
Date:
July 30, 2008 13:29
Subject:
RF help with a v5.10 Heisenbug, please?
Message ID:
24218.1217449794@chthon
I haven't mentioned this, let alone bug-reported it, because I cannot
*dependably* reproduce it.  However, it happens too often for me to ignore
entirely, so I'm asking whether anyone else has seen anything at all like
this.  Once I'd installed 5.10.0, the following start-up line in my .tcshrc
hangs forever with perl running unchecked until I kill it--but only about
one time in 30 or 100, or some high number I can't count.

    set path = `echo $path | tr ' ' '\12' | perl -nle 'print if -d and ($dev,$ino) = stat(_) and not $seen{$dev,$ino}++'`

Specifically, the perl line is 

     perl -nle 'print if -d and ($dev,$ino) = stat(_) and not $seen{$dev,$ino}++'

The failure never, ever happened before 5.10, and now it happens 
a few times a day (I shell out to {!}afmt paragraphs in vi.)

What may have changed in 5.10 to cause that line to execute
differently?  

Nothing, right?  Right??

The input records are finite and well defined by 

    echo $path | tr ' ' '\12' 

but the -n loop seems very stuck, and I don't know why.

I have a sneaking suspicious its my hardware, not perl,
but then, *why* would this only crop up on v5.10, never before?

If it is hardware, then some dubious-looking items in /var/log/messages 
include:

    Jul 30 09:06:06 chthon pppd[3575]: write: No buffer space available
    Jul 30 09:06:22 chthon named[27640]: client 149.20.56.10#10053: error sending response: not enough free resources
    Jul 30 09:07:25 chthon named[27640]: client 149.20.56.10#10053: error sending response: not enough free resources
    Jul 30 09:08:06 chthon pppd[3575]: write: No buffer space available

And then just now editing the last message, there was a panic not long
after I had to twice kill the forever-spinning perl I've described:

    Jul 30 13:54:51 chthon savecore: reboot after panic: kernel diagnostic assertion "uvmexp.swpgonly <= uvmexp.swpages" failed: file "/usr/src/sys/uvm/uvm_pdaemon.c", line 581

If it is the page daemon having VM problems, I wonder why?  My real memory 
usage is <50% total, and swap is <10% total, so I don't know what's messing up.

I wonder if because I always have Perl running, there's some hardware
fault on the shared-text pages.  Hm...

I've thought of building a debugging perl and trying to remotely
attach to it once it's in spin-mode via gdb (if that's this
possible?).  

Has anybody ever attempted this?

--tom
-- 
    If at first you don't succeed, give up.  No use being a damn fool.



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About