Perlbal - Perlbal 1.41 crash with buffered uploads

This is Interesting: Free IT Magazines  
Home > Archive > Perlbal > July 2006 > Perlbal 1.41 crash with buffered uploads





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Perlbal 1.41 crash with buffered uploads
Jay Buffington

2006-07-07, 7:11 pm

Pressing the stop button in the browser while doing an upload to
perlbal consistently kills perlbal with my set up. The error in
/var/log/messages is:

Jul 7 14:12:18 baker perlbal[12535]: crash log: Can't use string
("c") as a SCALAR ref while "strict refs" in use at
/usr/lib/perl5/site_perl/5.8.5/Perlbal/ClientProxy.pm line 923.

It looks like this is because of line 947 of ClientProxy.pm, it's
unshifting a string instead of a reference to a string into the
buffer.

I made this change and it stopped dying, but I got an error about an
undef $fh from AIO instead.
--- ClientProxy.pm 2006-01-19 21:33:52.000000000 -0800
+++ /usr/lib/perl5/site_perl/5.8.5/Perlbal/ClientProxy.pm
2006-07-07 14:23:49.000000000 -0700
@@ -944,7 +944,8 @@
# written out and update as appropriate.
if ($bytes < $len) {
my $diff = $len - $bytes;
- unshift @{$self->{read_buf}}, substr($$bref, $bytes, $diff);
+ my $b = substr($$bref, $bytes, $diff);
+ unshift @{$self->{read_buf}}, \$b;
$self->{read_ahead} += $diff;
}

Was that intentional?

Here is my config:
jay@baker:~$ cat /etc/perlbal/perlbal.conf
CREATE POOL my_apaches
POOL my_apaches ADD 216.35.12.150:80

SERVER aio_mode = ioaio

CREATE SERVICE balancer
SET listen = 216.35.12.151:80
SET role = reverse_proxy
SET pool = my_apaches
SET persist_client = on
SET persist_backend = on
SET verify_backend = on
SET enable_reproxy = true

SET buffer_uploads = true
SET buffer_backend_connect = 100000
SET buffer_size = 256000
SET buffer_upload_threshold_rate = 0
SET buffer_upload_threshold_size = 250000
SET buffer_upload_threshold_time = 5
SET buffer_uploads_path = /tmp/buffered_uploads/
ENABLE balancer

# management port
CREATE SERVICE mgmt
SET role = management
SET listen = 127.0.0.1:60000
ENABLE mgmt

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com