From john56@example.net Sun Aug 01 11:49:37 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 29263 invoked from network); 1 Aug 2004 11:49:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 11:49:37 -0000 Received: (qmail 41019 invoked by uid 500); 1 Aug 2004 11:49:26 -0000 Delivered-To: john56@example.net Received: (qmail 40479 invoked by uid 500); 1 Aug 2004 11:49:24 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 40464 invoked by uid 99); 1 Aug 2004 11:49:24 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FORGED_RCVD_HELO X-Spam-Check-By: apache.org From: Boris Zentner <john56@example.net> To: john56@example.net Subject: Re: mod_perl2, HEAD request and Content-Length Date: Sun, 1 Aug 2004 13:47:43 +0200 User-Agent: KMail/1.6.2 References: <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Message-Id: <john56@example.net> X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Hi, Am Samstag 31 Juli 2004 10:20 schrieb Stas Bekman: > Geoffrey Young wrote: > > Boris Zentner wrote: > >>Hi, > >> > >>I have a handler, that serve dynamic pages or static ones. If the handl= er > >> gets a HEAD request, it answers with > > [...] > > > it is desired - you no longer need to set the Content-Length header for > > requests in Apache 2.0. > > It's somewhat documented: > http://perl.apache.org/docs/2.0/user/handlers/http.html#Handling_HEAD_Req= ue >sts > I just read it, thanks for the pointer. I think the text should make clear,= =20 that even if it is not needed to return early with 'return OK if=20 $r->header_only;' with apache2, it is recommended, since it is ( or can be = )=20 a big waste of time to construct the body, that is removed in the next pass. =46rom reading the comments in modules/http/http_protocol.c=20 ( ap_http_header_filter ), I get the impression, that apache2 recommend=20 generating and throwing away the content. Here is the comment in question: /* This is a hack, but I can't find anyway around it. The idea is that * we don't want to send out 0 Content-Lengths if it is a head request. * This happens when modules try to outsmart the server, and return * if they see a HEAD request. Apache 1.3 handlers were supposed to * just return in that situation, and the core handled the HEAD. In * 2.0, if a handler returns, then the core sends an EOS bucket down * the filter stack, and the content-length filter computes a C-L of * zero and that gets put in the headers, and we end up sending a * zero C-L to the client. We can't just remove the C-L filter, * because well behaved 2.0 handlers will send their data down the stac= k, * and we will compute a real C-L for the head request. RBB */ also The comment implies, that I get a Content-Length header for a HEAD=20 request, if I waste my time and generate the body of the message. I tried i= t=20 and got _no_ Content-Length header! $apr->content_type($media_type) unless $apr->main; if ( $apr->header_only ) { $apr->print( ' ' x $size ); # just to see if I got a content-length hea= der return DONE; } The only way to get the Content-Length header for a HEAD request is=20 $apr->headers_out->{'Content-Length'} =3D $size ; $apr->content_type($media_type) unless $apr->main; if ( $apr->header_only ) { $apr->rflush; return DONE; } But I fail to see why this works, I thought the data walks the same filter= =20 chain only in more buckets. I used=20 Server: Apache/2.0.49 (Unix) mod_perl/1.99_14 Perl/v5.8.3 mod_ssl/2.0.49=20 OpenSSL/0.9.7d DAV/2 SVN/1.0.2 > > basically, any C-L header you set in the content-generation phase of the > > request has the potential to be incorrect, since any filter can come > > along and alter the content. so, what apache does is it runs the new > > content-length filter, which will decide whether a C-L header is requir= ed > > and take appropriate steps. for instance, apache will abandon the C-L > > header if it decides it can use a chunked transfer encoding instead. > > Geoff, feel free to improve that section to be more complete. Thanks. > =2D-=20 Boris -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 16:14:03 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 98787 invoked from network); 1 Aug 2004 16:14:03 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 16:14:03 -0000 Received: (qmail 55419 invoked by uid 500); 1 Aug 2004 16:13:50 -0000 Delivered-To: john56@example.net Received: (qmail 55227 invoked by uid 500); 1 Aug 2004 16:13:49 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 55213 invoked by uid 99); 1 Aug 2004 16:13:48 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 09:13:41 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Boris Zentner <john56@example.net> Cc: john56@example.net Subject: Re: mod_perl2, HEAD request and Content-Length References: <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Boris Zentner wrote: > Hi, > > Am Samstag 31 Juli 2004 10:20 schrieb Stas Bekman: > >>Geoffrey Young wrote: >> >>>Boris Zentner wrote: >>> >>>>Hi, >>>> >>>>I have a handler, that serve dynamic pages or static ones. If the handler >>>>gets a HEAD request, it answers with >> >>[...] >> >> >>>it is desired - you no longer need to set the Content-Length header for >>>requests in Apache 2.0. >> >>It's somewhat documented: >>http://perl.apache.org/docs/2.0/user/handlers/http.html#Handling_HEAD_Reque >>sts >> > > > I just read it, thanks for the pointer. I think the text should make clear, > that even if it is not needed to return early with 'return OK if > $r->header_only;' with apache2, it is recommended, since it is ( or can be ) > a big waste of time to construct the body, that is removed in the next pass. > > From reading the comments in modules/http/http_protocol.c > ( ap_http_header_filter ), I get the impression, that apache2 recommend > generating and throwing away the content. Here is the comment in question: > > /* This is a hack, but I can't find anyway around it. The idea is that > * we don't want to send out 0 Content-Lengths if it is a head request. > * This happens when modules try to outsmart the server, and return > * if they see a HEAD request. Apache 1.3 handlers were supposed to > * just return in that situation, and the core handled the HEAD. In > * 2.0, if a handler returns, then the core sends an EOS bucket down > * the filter stack, and the content-length filter computes a C-L of > * zero and that gets put in the headers, and we end up sending a > * zero C-L to the client. We can't just remove the C-L filter, > * because well behaved 2.0 handlers will send their data down the stack, > * and we will compute a real C-L for the head request. RBB > */ That's what I understood as well. Does anybody have any statistics on the percentage of HEAD requests vs. GET? The purpose of HEAD request is not to save your CPU cycles, but to avoid data transfer which is precisely what Apache 2.0 does, without making you do the extra work to deal with HEAD requests. > also The comment implies, that I get a Content-Length header for a HEAD > request, if I waste my time and generate the body of the message. I tried it > and got _no_ Content-Length header! > > $apr->content_type($media_type) unless $apr->main; > if ( $apr->header_only ) { > $apr->print( ' ' x $size ); # just to see if I got a content-length header > return DONE; > } > > The only way to get the Content-Length header for a HEAD request is > > $apr->headers_out->{'Content-Length'} = $size ; > $apr->content_type($media_type) unless $apr->main; > if ( $apr->header_only ) { > $apr->rflush; > return DONE; > } > > But I fail to see why this works, I thought the data walks the same filter > chain only in more buckets. In dynamic scripts you never get the C-L header unless you set it explicitly and some filter doesn't remove it. It's not possible for Apache to add one, since headers are sent *before* it knows how much data your handler is going to send. So HEAD or GET, you won't get it. So HEAD on dynamic scripts that doesn't set their own C-L is a wasted operation on behalf of the client. Unless you use some E-Tag (but I haven't checked the RFC). BTW, what's wrong with $r->set_content_length()? http://perl.apache.org/docs/2.0/api/Apache/Response.html#C_set_content_length_ Neither you need to rflush. Neither you should return DONE, but OK. -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 17:31:24 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 14418 invoked from network); 1 Aug 2004 17:31:24 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 17:31:24 -0000 Received: (qmail 3785 invoked by uid 500); 1 Aug 2004 17:31:13 -0000 Delivered-To: john56@example.net Received: (qmail 3665 invoked by uid 500); 1 Aug 2004 17:31:12 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 3652 invoked by uid 99); 1 Aug 2004 17:31:12 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 10:31:07 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: "Nathan L. Kugland" <john56@example.net> Cc: john56@example.net Subject: Re: Running separate dev/prod modperl environments References: <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Nathan L. Kugland wrote: > Hi all, > > I'm working on a mason/modperl project that needs separate development > and production environments. I only have one machine to work with, and > I've realized that using a single httpd process for both of these sites > (with my current VirtualHost config) will probably result in some > unhealthy memory sharing between the dev and prod sites. Both codebases > are mirrors of each other, i.e. the perl package name spaces are > identical in both environments. > > Any thoughts on how best to separate these sites on the same machine? An > obvious solution would be to make a separate install of apache, but that > seems overkill, since all I need (I think) to fully separate the > environments at the apache level is a) separate instances of the httpd > process, and b) separate httpd.conf settings (which I already have). Is > it feasible to do it with a single apache installation? Absolutely. Just run the two instances on different ports. If you have the "Practical mod_perl" book [1] refer to the section: Running More than One mod_perl Server on the Same Machine in chapter 12: Server Setup Strategies [1] http://modperlbook.org/ -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 17:55:40 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 20872 invoked from network); 1 Aug 2004 17:55:39 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 17:55:39 -0000 Received: (qmail 21278 invoked by uid 500); 1 Aug 2004 17:55:24 -0000 Delivered-To: john56@example.net Received: (qmail 21180 invoked by uid 500); 1 Aug 2004 17:55:23 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 21058 invoked by uid 99); 1 Aug 2004 17:55:22 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 10:55:15 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Dan Wilga <john56@example.net> Cc: john56@example.net Subject: Re: ModPerl888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Registry: Software caused connection abort References: <john56@example.net> <p06002066bd2ff839c139@[83.161.120.155]> In-Reply-To: <p06002066bd2ff839c139@[83.161.120.155]> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Dan Wilga wrote: [...] > I have written to the Apache Developers' list, but the only suggestion I > got was that the initial "Connection reset by peer" error is to be > expected, but that mod_perl probably shouldn't be generating the pair of > "[error]" level log messages. > > I don't entirely buy this, since there was a behavior change when only > Apache was upgraded (I kept the same mod_perl version when this started > happening.) It also only happens when SSL is added to the mix. > > However, if you do agree that mod_perl needs to be more tolerant of this > particular condition then, in my opinion, not only should the error not > be logged with the "[error]" severity, but the ErrorDocument 500 should > also not be called. Thanks for the detailed report, Dan. I'm not 100% sure it's a good idea to always ignore connection reset errors, since it may come in a different context (e.g. a registry script doing its own socket IO). But please give a try to this patch. I haven't tested it. Index: ModPerl-Registry/lib/ModPerl/RegistryCooker.pm =================================================================== RCS file: /home/cvs/modperl-2.0/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm,v retrieving revision 1.50 diff -u -r1.50 RegistryCooker.pm --- ModPerl-Registry/lib/ModPerl/RegistryCooker.pm 27 Jun 2004 21:26:45 -0000 1.50 +++ ModPerl-Registry/lib/ModPerl/RegistryCooker.pm 1 Aug 2004 17:52:00 -0000 @@ -42,6 +42,7 @@ use Fil888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Basename; use Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Const -compile => qw(:common &OPT_EXECCGI); +use APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4onst -compile => qw(ECONNABORTED); use ModPerl888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4onst -compile => 'EXIT'; unless (defined $ModPerl888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Registry888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4MarkLine) { @@ -724,9 +725,14 @@ # ModPerl888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Util888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4xit() throws an exception object whose rc is # ModPerl888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4XIT # (see modperl_perl_exit() and modperl_errsv() C functions) - if ($@ && !(ref $@ eq 'APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4rror' && $@ == ModPerl888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4XIT)) { - $self->log_error($@); - return Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4SERVER_ERROR; + if ($@) { + if ($@ == APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4ONNABORTED) { + # silently ignore client connection abort + } + elsif (!(ref $@ eq 'APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4rror' && $@ == ModPerl888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4XIT)) { + $self->log_error($@); + return Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4SERVER_ERROR; + } } return Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4OK; } -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 17:58:27 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 21472 invoked from network); 1 Aug 2004 17:58:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 17:58:27 -0000 Received: (qmail 25850 invoked by uid 500); 1 Aug 2004 17:58:19 -0000 Delivered-To: john56@example.net Received: (qmail 25071 invoked by uid 500); 1 Aug 2004 17:58:15 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 25057 invoked by uid 99); 1 Aug 2004 17:58:15 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 10:58:10 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Tom Schindl <john56@example.net> Cc: ModPerl List <john56@example.net>, Mod_Perl <john56@example.net> Subject: Re: How to use, after install... References: <002201c475e0$78570730$6400a8c0@FRHwebPortable> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Tom Schindl wrote: > Hi, > > the best thing would be: > > 1. Read john56@example.net > 2. Get one of the various good books which are out there: > e.g. > http://www.amazon.de/exec/obidos/ASIN/0596002270/qid=1091174088/ref=sr_8_xs_ap_i1_xgl/028-6908240-1456549 BTW, the complete list of mod_perl books is available from here: http://perl.apache.org/docs/offsite/books.html#Learn_mod_perl As mentioned several times on this list, one needs to have all 3 books to get a complete coverage, as there is very little overlap between them. And the pocket book reference is handy too! -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 18:04:04 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 22603 invoked from network); 1 Aug 2004 18:04:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 18:04:04 -0000 Received: (qmail 30938 invoked by uid 500); 1 Aug 2004 18:03:50 -0000 Delivered-To: john56@example.net Received: (qmail 30916 invoked by uid 500); 1 Aug 2004 18:03:50 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 30903 invoked by uid 99); 1 Aug 2004 18:03:50 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 11:03:37 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Tom Schindl <john56@example.net> Cc: YY Liu <john56@example.net>, john56@example.net Subject: Re: "error 111" has been solved and some error occurred when configure apache References: <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Tom Schindl wrote: > Well once more let mod_perl do everything for you, see howto do that > using INSTALL.simple.mod_ssl. or better, read the mp1 guide: http://perl.apache.org/docs/1.0/guide/install.html#Installation_Scenarios_for_mod_perl_and_Other_Components -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 18:10:57 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 24136 invoked from network); 1 Aug 2004 18:10:57 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 18:10:57 -0000 Received: (qmail 37709 invoked by uid 500); 1 Aug 2004 18:10:46 -0000 Delivered-To: john56@example.net Received: (qmail 37693 invoked by uid 500); 1 Aug 2004 18:10:46 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 37680 invoked by uid 99); 1 Aug 2004 18:10:45 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 11:10:38 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Boris Zentner <john56@example.net> Cc: Tom Schindl <john56@example.net>, john56@example.net, Chris Ochs <john56@example.net>, Ask Bjoern Hansen <john56@example.net> Subject: Re: Using DBI and Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4DBI together References: <03d601c4745c$7cab9790$6400a8c0@chris2> <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Boris Zentner wrote: > Hi, > > Am Mittwoch 28 Juli 2004 12:20 schrieb Tom Schindl: > >>Boris Zentner wrote: > > > [...] > > >>># bypass Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4DBI >>>$dbh = DBI->connect($data_source, $username, $password, { >>>dbi_connect_method => 'connect' }) || die; >> >>I knew there is such a parameter, but couldn't remember it. So I took a >>look at Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4DBI's manpage but this parameter is not mentionned. Have >>I missed that somewhere or where did you find it? If its not in the >>man-page it might me good idea to contact the module author and ask :-) >>him to add this parameter. >> > > > Thats because you lokked in the Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4DBI manpage. > Look in the DBI man page: > > The "dbi_connect_method" attribute can be used to > specify which driver method should be called to estab- > lish the connection. The only useful values are 'con- > nect', 'connect_cached', or some specialized case like > 'Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4DBI888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4onnect' (which is automatically the > default when running within Apache). I think the Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4DBI manpage should mention that DBI's feature (plus example), since it's very relevant. Please send a doc patch to Ask. -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 18:20:28 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 30442 invoked from network); 1 Aug 2004 18:20:28 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 18:20:28 -0000 Received: (qmail 45742 invoked by uid 500); 1 Aug 2004 18:20:16 -0000 Delivered-To: john56@example.net Received: (qmail 45452 invoked by uid 500); 1 Aug 2004 18:20:14 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 45439 invoked by uid 99); 1 Aug 2004 18:20:14 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 11:20:09 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: john56@example.net Cc: john56@example.net Subject: Re: Software caused connection abort References: <5ac301c473ef$94fcf400$0200a8c0@analog> <john56@example.net> <01a901c47619$5c0bbe70$0200a8c0@analog> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N [Please always send a new email when starting a new thread. Do not reply to another thread, changing the subject, since you are still replying to the same thread. Thanks!] Casey Songer wrote: > Hello all, > > I'm running mod_perl 1.99_13 with apache 2.0.49. I'm also running > HTML888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Mason. Not sure if this is a Mason error or just a mod_perl > thing, but I keep getting these errors in my error log: > > [Fri Jul 30 16:37:12 2004] [error] [client x.x.x.x] 103:Software caused > connection abort at > /usr/lib/perl5/site_perl/5.8.0/MasonX/Apache2Handler.pm line > 93.\n\nStack:\n > [/usr/lib/perl5/site_perl/5.8.0/MasonX/Apache2Handler.pm:93]\n > [/usr/lib/perl5/site_perl/5.8.0/HTML/Mason/Request.pm:358]\n, referer: > https://www.dynamicfeedback.com/leader/groupinformation/index.html?&i_index=0 > > > The errors happen intermittently, but the users experience slow or > hanging pages when it happens. I don't know if these errors are a > result of something timing out or if they explain what they actual > problem is. > > My first question is, can somebody tell me what this error means? And > second, how can I find out what is causing the error? This server is in > production, and I never have experience the error on my test machine > which is set up very similarly. > > Hope somebody out there can shed some light on the subject. Take a look at this thread: http://marc.theaimsgroup.com/?t=109120300600002&r=1&w=2 The error happens when the client aborts the connection (e.g. hits reload button, before the previous request was finished) -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 18:34:46 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 32881 invoked from network); 1 Aug 2004 18:34:46 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 18:34:46 -0000 Received: (qmail 58308 invoked by uid 500); 1 Aug 2004 18:34:37 -0000 Delivered-To: john56@example.net Received: (qmail 57517 invoked by uid 500); 1 Aug 2004 18:34:34 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 57504 invoked by uid 99); 1 Aug 2004 18:34:34 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 11:34:24 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: john56@example.net Cc: Randy Kobes <john56@example.net>, john56@example.net Subject: Re: [mp2] NetBSD-1.6.2 modperl snapshot build error References: <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N john56@example.net wrote: >>The xs/APR/aprext/ stuff is only needed on certain platforms >>(Win32, perhaps AIX) for which the way the APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4* modules >>are built by default doesn't work (this is related to having >>APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4* usable outside a mod_perl environment). I'm not sure >>why it's trying to build something here - on linux, for >>example, it just goes into that directory, sees there's >>nothing to do, and then moves on. That'll have to be fixed; >>in the meantime, in the Makefile.PL of xs/APR/aprext/ >>there's a couple of lines: >> my @skip = qw(dynamic test}; >> push @skip, q{static} unless Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Buil888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4WIN32; >>Could you try commenting these out to see if that helps? > > > commented out the above lines and line # 27 as well: > > # SKIP => [ @skip ] , > > as well, now modperl build OK, but tests give the errors below. > > snapshots used: > --------------- > apr-iconv_20040729101255.tar.gz httpd-2.0_20040729101922.tar.gz > apr-util_20040729101259.tar.gz modperl-2.0_20040729042917.tar.gz > apr_20040729101246.tar.gz > > errors: > ------- > Failed Test Stat Wstat Total Fail Failed List of Failed > ------------------------------------------------------------------------------- > t/api/custom_response.t 4 1 25.00% 4 > t/apr-ext/base64.t 255 65280 ?? ?? % ?? > t/apr-ext/bucket.t 255 65280 ?? ?? % ?? > t/apr-ext/date.t 255 65280 ?? ?? % ?? > t/apr-ext/finfo.t 255 65280 ?? ?? % ?? > t/apr-ext/perlio.t 255 65280 ?? ?? % ?? > t/apr-ext/pool.t 255 65280 ?? ?? % ?? > t/apr-ext/string.t 255 65280 ?? ?? % ?? > t/apr-ext/table.t 255 65280 ?? ?? % ?? > t/apr-ext/threadmutex.t 255 65280 ?? ?? % ?? > t/apr-ext/uri.t 255 65280 ?? ?? % ?? > t/apr-ext/util.t 255 65280 ?? ?? % ?? > t/apr-ext/uuid.t 255 65280 ?? ?? % ?? > t/apr/constants.t 255 65280 ?? ?? % ?? > t/filter/both_str_con_add.t 4 3 75.00% 2-4 > t/protocol/echo_block.t 3 2 66.67% 2-3 > t/protocol/echo_filter.t 3 2 66.67% 2-3 > t/protocol/pseudo_http.t 13 9 69.23% 3-8 11-13 > 16 tests skipped. > Failed 18/202 test scripts, 91.09% okay. 17/1167 subtests failed, 98.54% > okay. Obviously apr-ext tests have the same problem, and I suppose Randy is looking into it. But for the rest of the tests please read: http://perl.apache.org/docs/2.0/user/help/help.html#_C_make_test___Failures -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 18:43:26 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 34540 invoked from network); 1 Aug 2004 18:43:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 18:43:26 -0000 Received: (qmail 64022 invoked by uid 500); 1 Aug 2004 18:43:15 -0000 Delivered-To: john56@example.net Received: (qmail 64008 invoked by uid 500); 1 Aug 2004 18:43:15 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 63995 invoked by uid 99); 1 Aug 2004 18:43:14 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 11:43:05 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Alexei Bozrikov <john56@example.net> Cc: Randy Kobes <john56@example.net>, john56@example.net Subject: Re: [mp2] registry tests problems (powerpc-aix-83.161.120.155 platform / IBM RS6000) References: <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Alexey Bozrikov wrote: [taking the ModPerl-Registry branch of this multi-faced thread] > Now, make test in ModPerl-Registry yields some error messages: [...] > t/404.t 2 2 100.00% 1-2 > t/bad_scripts.t 1 1 100.00% 1 > t/basic.t 18 1 5.56% 17 > t/cgi.t 2 1 50.00% 2 > 2 tests skipped. > Failed 4/14 test scripts, 71.43% okay. 5/70 subtests failed, 92.86% okay. > [warning] server localhost:8529 shutdown > [warning] port 8529 still in use... > ...done > [ error] error running tests (please examine t/logs/error_log) > [unquote] > > The Apache error log contains following: > > [quote cat t/logs/error_log] > [Fri Jul 30 08:55:15 2004] [notice] Apache/2.0.49 (Unix) mod_perl/1.99_15-dev Perl/v5.8.4 PHP/5.0.0 DAV/2 configured -- resuming normal operations > [Fri Jul 30 08:55:15 2004] [info] Server built: Jul 15 2004 12:00:32 > [Fri Jul 30 08:55:15 2004] [debug] prefork.c(955): AcceptMutex: sysvsem (default: sysvsem) > > *** The following error entry is expected and harmless *** > [Fri Jul 30 08:55:55 2004] [error] /home/bozy/src/modperl-2.0/ModPerl-Registry/t/cgi-bin/cannot_be_found not found or unable to stat > [Fri Jul 30 08:55:55 2004] [error] mpxs_Apache__RequestRec_print: $r->print can't be called before the response phase during global destruction.\n > [Fri Jul 30 08:55:56 2004] [notice] child pid 16168 exit signal Segmentation fault (11) You have a few segfaults reported. could you arrange for core files to be allowed? Apache-Test is already doing that (ulimit -c unlimited), but it doesn't seem to have an affect. Do you know why? Once you get the core files, show us their backtraces. http://perl.apache.org/docs/2.0/user/help/help.html#Resolving_Segmentation_Faults Now while you are rebuilding things, please use the current modperl cvs, so we will be in sync. Thanks. http://perl.apache.org/download/source.html#Development_mod_perl_2_0_Source_Distribution -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 18:55:03 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 36840 invoked from network); 1 Aug 2004 18:55:03 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 18:55:03 -0000 Received: (qmail 70950 invoked by uid 500); 1 Aug 2004 18:54:52 -0000 Delivered-To: john56@example.net Received: (qmail 70915 invoked by uid 500); 1 Aug 2004 18:54:51 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 70896 invoked by uid 99); 1 Aug 2004 18:54:51 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 11:54:45 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Richard Bauer <john56@example.net> Cc: john56@example.net Subject: Re: HTML888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Mason segfault References: <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Richard Bauer wrote: > On Wednesday 21 July 2004 21:03, Stas Bekman wrote: > >>Richard Bauer wrote: >> >>>Hi List, >>> >>>It's my first post. >> >>welcome :) >> >> >>>I'm running a remote dedicated webserver running a RH 7.2. >>>Originally perl5.6.1 was pre-installed (rpm), so I downloaded and >>>installed perl5.8.4. I decided to download some fresh Apache and >>>mod_perl: -Apache 1.3.31 >>>-mod_perl 1.29 >>> >>>When I set an HTML888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Mason handler to serve a VirtualHost, httpd logs: >>>[notice] child pid 9943 exit signal Segmentation fault (11) >>> >>>Note that if the HTML888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Mason module is not installed, the httpd does not >>>segfault. >>> >>>It seems to be a shared lib issue, but I'm not a pro of that. I hope this >>>issue is related to this mailing list and I hope that you will be able to >>>give me some help to solve this problem. >> >>[...] >> >> >>>(gdb) bt >>>#0 0x0809fc4b in XS_Apache__Table_FETCH () >> >>In case it uses XML modules it could be an EXPAT issue, mentioned here: >>http://marc.free.net.ph/message/20030904.192959.83632cb7.html >> > > > Thank you Stas for your input. I read the link above with a lot of interest > and tried to compile mod_perl and Apache without EXPAT. The first attempt did > not success, and I worked around re-installing some perl modules. After some > hours and a last try, HTML888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Mason works fine. :-) I feel that like black > magic because I cannot explain why it works. Not much magic here. It all comes down to the common problem of libraries collision. It's the same problem with conflicting Berkley DB and other libs. When you run an app, you need to make sure that you've one implementation loaded and not two. >>I'm not on the mod_perl mailing list, but I saw your recent post in the >>archives. I'm not sure if you resolved it, but I was having a similar >>problem recently. >> >>1. Using mod_perl only, everything worked fine. >>2. When I add the Mason handler, Apache starts fine, but segfaults on first >>request. >>3. (I'm on FreeBSD, Apache 1.x, most recent Perl.) >> >>I was really puzzled, as I build systems like this frequently, and never had >>this problem. But, then I realized that I had forgotten to install MM >>(http://www.ossp.org/pkg/lib/mm/). When I installed MM and rebuilt Apache, >>the problem disappeared. >> >>I built MM as follows: >> >>fetch ftp://ftp.ossp.org/pkg/lib/mm/mm-1.3.0.tar.gz >>tar xzf mm-1.3.0.tar.gz >>cd mm-1.3.0 >>./configure --disable-shared >>make >>make test >>make install >>./libtool --finish /usr/local/lib >> >>Then, when installing Apache, I used: >> >>setenv EAPI_MM SYSTEM >>setenv SSL_BASE SYSTEM >>./configure --activate-module=src/modules/perl/libperl.a >> >>Hope this might help! > > > On my system, this lib seems to be installed since a lot of time, so I think > it is not the cause of my issue. > > What do you think of this? I don't know. I never had this problem. > Stas, I'd like to ask you another question: > > Scenario1: > I configure mod_perl with NO_HTTPD=1, PREP_HTTPD=1 and > APACI_ARGS='--disable-rule=EXPAT', after that, make and make install. In the > Apache dir, ./configure ... (other mods to be included), make and finally > make install. > Result: The server crashes > > Scenario2: > I configure mod_perl with DO_HTTPD=1 and APACI_ARGS='--disable-rule=EXPAT', > make and make install. In the Apache dir: make install > Result: The server doesn't crash. > > What do you think about these two scenarios, does it make sense to you? It makes perfect sense. In the first scenario you tell Apache to reconfigure itself, completely forgetting the config mod_perl told it to use. The first scenario is by all means invalid. > And finally, how to know if Apache has been compiled with/without expate-lite? I've never used it myself so I can't tell. But if it's build as a shared lib, you can find that out using ldd(1). If it's statically built you can use nm(1) or even strings(1). May be apxs can be of help too. -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 18:57:28 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 37226 invoked from network); 1 Aug 2004 18:57:28 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 18:57:28 -0000 Received: (qmail 73178 invoked by uid 500); 1 Aug 2004 18:57:17 -0000 Delivered-To: john56@example.net Received: (qmail 73143 invoked by uid 500); 1 Aug 2004 18:57:17 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 73130 invoked by uid 99); 1 Aug 2004 18:57:17 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 11:57:12 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: David Arnold <john56@example.net> Cc: john56@example.net Subject: Re: Having to restart browser to see changes to CGI References: <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N David Arnold wrote: > All, > > With the following entries in our httpd.conf, can anyone see any reason why > we are having to close and reopen our browser to see any effect of the > changes made to to /online_testing/perl/Quiz1Solns.cgi? If you need to restart the browser (not the server), then it has nothing to do with the server configuration, but with the client configuration. Most likely the response gets cached and restarting the client gets it uncached. -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 19:24:30 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 52578 invoked from network); 1 Aug 2004 19:24:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 19:24:30 -0000 Received: (qmail 97204 invoked by uid 500); 1 Aug 2004 19:24:17 -0000 Delivered-To: john56@example.net Received: (qmail 97188 invoked by uid 500); 1 Aug 2004 19:24:17 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 97175 invoked by uid 99); 1 Aug 2004 19:24:17 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Date: Sun, 1 Aug 2004 14:25:34 -0500 (CDT) From: Randy Kobes <john56@example.net> To: Stas Bekman <john56@example.net> cc: john56@example.net, john56@example.net Subject: Re: [mp2] NetBSD-1.6.2 modperl snapshot build error In-Reply-To: <john56@example.net> Message-ID: <john56@example.net> References: <john56@example.net> <john56@example.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N On Sun, 1 Aug 2004, Stas Bekman wrote: > john56@example.net wrote: [ ... ] > > snapshots used: > > --------------- > > apr-iconv_20040729101255.tar.gz httpd-2.0_20040729101922.tar.gz > > apr-util_20040729101259.tar.gz modperl-2.0_20040729042917.tar.gz > > apr_20040729101246.tar.gz > > > > errors: > > ------- > > Failed Test Stat Wstat Total Fail Failed List of Failed > > ------------------------------------------------------------------------------- > > t/api/custom_response.t 4 1 25.00% 4 > > t/apr-ext/base64.t 255 65280 ?? ?? % ?? > > t/apr-ext/bucket.t 255 65280 ?? ?? % ?? > > t/apr-ext/date.t 255 65280 ?? ?? % ?? > > t/apr-ext/finfo.t 255 65280 ?? ?? % ?? > > t/apr-ext/perlio.t 255 65280 ?? ?? % ?? > > t/apr-ext/pool.t 255 65280 ?? ?? % ?? > > t/apr-ext/string.t 255 65280 ?? ?? % ?? > > t/apr-ext/table.t 255 65280 ?? ?? % ?? > > t/apr-ext/threadmutex.t 255 65280 ?? ?? % ?? > > t/apr-ext/uri.t 255 65280 ?? ?? % ?? > > t/apr-ext/util.t 255 65280 ?? ?? % ?? > > t/apr-ext/uuid.t 255 65280 ?? ?? % ?? > > t/apr/constants.t 255 65280 ?? ?? % ?? > > t/filter/both_str_con_add.t 4 3 75.00% 2-4 > > t/protocol/echo_block.t 3 2 66.67% 2-3 > > t/protocol/echo_filter.t 3 2 66.67% 2-3 > > t/protocol/pseudo_http.t 13 9 69.23% 3-8 11-13 > > 16 tests skipped. > > Failed 18/202 test scripts, 91.09% okay. 17/1167 subtests failed, 98.54% > > okay. > > Obviously apr-ext tests have the same problem, and I suppose Randy is > looking into it. > > But for the rest of the tests please read: > http://perl.apache.org/docs/2.0/user/help/help.html#_C_make_test___Failures I haven't tried this, but is it known in particular that the mod_perl 2 APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4* modules work with these apr/apr-util/httpd-2.0 snapshots (which are in the development trees)? -- best regards, randy -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 21:04:58 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 73078 invoked from network); 1 Aug 2004 21:04:58 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 21:04:58 -0000 Received: (qmail 83381 invoked by uid 500); 1 Aug 2004 21:04:45 -0000 Delivered-To: john56@example.net Received: (qmail 83250 invoked by uid 500); 1 Aug 2004 21:04:43 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 83219 invoked by uid 99); 1 Aug 2004 21:04:43 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 14:04:26 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Randy Kobes <john56@example.net> Cc: john56@example.net, john56@example.net Subject: Re: [mp2] NetBSD-1.6.2 modperl snapshot build error References: <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Randy Kobes wrote: > On Sun, 1 Aug 2004, Stas Bekman wrote: > > >>john56@example.net wrote: > > [ ... ] > >>>snapshots used: >>>--------------- >>>apr-iconv_20040729101255.tar.gz httpd-2.0_20040729101922.tar.gz >>>apr-util_20040729101259.tar.gz modperl-2.0_20040729042917.tar.gz >>>apr_20040729101246.tar.gz [...] > I haven't tried this, but is it known in particular that the > mod_perl 2 APR888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4* modules work with these > apr/apr-util/httpd-2.0 snapshots (which are in the > development trees)? You mean the apr/apr-util/httpd-2.0 snapshots are apr-1.x httpd-2.1 branches? You are right, Randy. The snapshots are of the cvs HEAD, whereas httpd-2.0 is not HEAD. HEAD is httpd-2.1. So Mikhail, please use cvs as explained here: http://perl.apache.org/download/source.html#Development_mod_perl_2_0_Source_Distribution -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 21:51:48 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 81504 invoked from network); 1 Aug 2004 21:51:48 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 21:51:48 -0000 Received: (qmail 23379 invoked by uid 500); 1 Aug 2004 21:51:37 -0000 Delivered-To: john56@example.net Received: (qmail 23358 invoked by uid 500); 1 Aug 2004 21:51:36 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 23345 invoked by uid 99); 1 Aug 2004 21:51:36 -0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=FORGED_RCVD_HELO,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Date: Sun, 1 Aug 2004 17:51:31 -0400 To: john56@example.net Subject: apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4session888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4mysql: layout Message-ID: <john56@example.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i From: Mark Copper <john56@example.net> X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N I created a table "sessions" in my db with columns "id" and "a_session" per the Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Session888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Stor888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4MySQL pod, in particular, "a_session" is of type text. Everything worked fine but I have a (rather silly) question: Why can't I see the key/value pairs when I simply "select a_session from sessions" at the mysql shell prompt? Sheepishly, Mark -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 23:42:27 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 99768 invoked from network); 1 Aug 2004 23:42:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 23:42:26 -0000 Received: (qmail 37925 invoked by uid 500); 1 Aug 2004 23:42:15 -0000 Delivered-To: john56@example.net Received: (qmail 37820 invoked by uid 500); 1 Aug 2004 23:42:14 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 37802 invoked by uid 99); 1 Aug 2004 23:42:14 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FORGED_RCVD_HELO X-Spam-Check-By: apache.org From: Boris Zentner <john56@example.net> To: john56@example.net Subject: Re: mod_perl2, HEAD request and Content-Length Date: Mon, 2 Aug 2004 01:07:55 +0200 User-Agent: KMail/1.6.2 References: <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Message-Id: <john56@example.net> X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Hi, Am Sonntag 01 August 2004 18:13 schrieb Stas Bekman: > Does anybody have any statistics on the percentage of HEAD requests vs. > GET? The purpose of HEAD request is not to save your CPU cycles, but to > avoid data transfer which is precisely what Apache 2.0 does, without > making you do the extra work to deal with HEAD requests. > > > also The comment implies, that I get a Content-Length header for a HEAD > > request, if I waste my time and generate the body of the message. I tri= ed > > it and got _no_ Content-Length header! > > > > =A0$apr->content_type($media_type) unless $apr->main; > > =A0 if ( $apr->header_only ) { > > =A0 =A0 $apr->print( ' ' x $size ); # just to see if I got a content-le= ngth > > header return DONE; > > =A0 } > > > > The only way to get the Content-Length header for a HEAD request is > > > > =A0$apr->headers_out->{'Content-Length'} =3D $size ; > > =A0$apr->content_type($media_type) unless $apr->main; > > =A0 if ( $apr->header_only ) { > > =A0 =A0 $apr->rflush; > > =A0 =A0 return DONE; > > =A0 } > > > > But I fail to see why this works, I thought the data walks the same > > filter chain only in more buckets. > > In dynamic scripts you never get the C-L header unless you set it > explicitly and some filter doesn't remove it. It's not possible for > Apache to add one, since headers are sent *before* it knows how much > data your handler is going to send. So HEAD or GET, you won't get it. But my point is, for a HEAD request, there is no data so apache should not= =20 touch my content-length header. I really dislike to generate the full data= =20 for the request and apache throws it away ( and even the I get no=20 Content-Length header ).=20 > > So HEAD on dynamic scripts that doesn't set their own C-L is a wasted > operation on behalf of the client. Unless you use some E-Tag (but I > haven't checked the RFC). > > BTW, what's wrong with $r->set_content_length()? Nothing, I searched for the function, but I did not find it! I know I shoul= d=20 use mp2doc, but as I searched for it, I did not think on the tool. I tryed= =20 first with perldoc Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4RequestRec and then I searched=20 http://perl.apache.org/docs/2.0/api/Apache/RequestRec.html =46or some reason I thought if there is no function content_length then I h= ave=20 no function like this.=20 =20 > http://perl.apache.org/docs/2.0/api/Apache/Response.html#C_set_content_le= ng >th_ Neither you need to rflush. Neither you should return DONE, but OK. I tried it now and even with set_content_length and return OK I got no=20 content-length header. PS: Much thanks for the pointer to Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Response, I found more functions= =20 that I missed already! =2D-=20 Boris -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Sun Aug 01 23:51:56 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 15714 invoked from network); 1 Aug 2004 23:51:55 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 1 Aug 2004 23:51:55 -0000 Received: (qmail 70067 invoked by uid 500); 1 Aug 2004 23:51:27 -0000 Delivered-To: john56@example.net Received: (qmail 70022 invoked by uid 500); 1 Aug 2004 23:51:26 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 69978 invoked by uid 99); 1 Aug 2004 23:51:26 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 16:51:18 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 To: Boris Zentner <john56@example.net> Cc: john56@example.net Subject: Re: mod_perl2, HEAD request and Content-Length References: <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Boris Zentner wrote: [...] > Nothing, I searched for the function, but I did not find it! I know I should > use mp2doc, but as I searched for it, I did not think on the tool. I tryed > first with perldoc Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4RequestRec and then I searched > > http://perl.apache.org/docs/2.0/api/Apache/RequestRec.html > > For some reason I thought if there is no function content_length then I have > no function like this. > > >>http://perl.apache.org/docs/2.0/api/Apache/Response.html#C_set_content_leng >>th_ Neither you need to rflush. Neither you should return DONE, but OK. > > > I tried it now and even with set_content_length and return OK I got no > content-length header. (sure, it was unrelated to the problem you were mentioned) let me try to write a test and I'll be back to you. Me thinking that we should drop the /^set_/ prefix in set_content_length, to be consistent with the rest of the API. > PS: Much thanks for the pointer to Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4Response, I found more functions > that I missed already! All Apach888a:dbb7:2d49:b3f6:8605:bf4e:caed:e5a4RequestRec classes now xref themselves from their Description sections, e.g.: http://perl.apache.org/docs/2.0/api/Apache/RequestRec.html#Description -- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:john56@example.net http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html From john56@example.net Mon Aug 02 00:27:50 2004 Return-Path: <john56@example.net> Delivered-To: john56@example.net Received: (qmail 26918 invoked from network); 2 Aug 2004 00:27:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155) by minotaur-2.apache.org with SMTP; 2 Aug 2004 00:27:50 -0000 Received: (qmail 99607 invoked by uid 500); 2 Aug 2004 00:27:40 -0000 Delivered-To: john56@example.net Received: (qmail 98950 invoked by uid 500); 2 Aug 2004 00:27:36 -0000 Mailing-List: contact john56@example.net; run by ezmlm Precedence: bulk list-help: <mailto:john56@example.net> list-unsubscribe: <mailto:john56@example.net> list-post: <mailto:john56@example.net> Delivered-To: mailing list john56@example.net Received: (qmail 98929 invoked by uid 99); 2 Aug 2004 00:27:35 -0000 X-ASF-Spam-Status: No, hits=1.1 required=10.0 tests=MISSING_HEADERS X-Spam-Check-By: apache.org Message-ID: <john56@example.net> Date: Sun, 01 Aug 2004 17:27:30 -0700 From: Stas Bekman <john56@example.net> Organization: Hope, Humanized User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040708 X-Accept-Language: en-us, en, he, ru MIME-Version: 1.0 Cc: Boris Zentner <john56@example.net>, john56@example.net Subject: Re: mod_perl2, HEAD request and Content-Length References: <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> <john56@example.net> In-Reply-To: <john56@example.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Stas Bekman wrote: > let me try to write a test and I'll be back to you. I get indentical behavior with either of the two methods: my $body = "This is a response string"; #$r->headers_out->{'Content-Length'} = length $body; $r->set_content_length(length $body); $r->print('a'); if the one-char-print line is commented out, I *never* get the C-L header for HEAD requests. Otherwise I always get the correct C-L header. Normally, Apache is not able to figure out how much data the content handler is going to send, since it needs to send headers early. However in the case where your handler returns w/o sending anything at all, the headers_out filter sees EOS and no data, so it
{'source': 'Apache Software Foundation Public Mail Archives'}