mod_perl/apache: unreferenced scalar seg fault (?)
I am encountering an intermittent error while running mod_perl 1.26 on Apache 1.3.19. In Apache's error log there appears two different kinds of errors message with no pattern and varying frequency. The first is: null: Attempt to free unreferenced scalar.. The second is: [notice] child pid X exit signal Segmentation fault (11) ...where X is a process number like 14318, 14564 etc. My configuration is completed basic, I am simply running the Hello World example exactly as it appears in the O'Reilly Writing Apache modules with Perl and C. I have searched the web and I can see many queries similar to this one, leading me to believe it is a common problem - but I am yet to find the solution. Can someone please tell me what this is or how to go about debugging it? I am at my wits end. Thanks in advance. Regards, Andrew.
Re: mod_perl/apache: unreferenced scalar seg fault (?)
Andrew Tomazos wrote: I am encountering an intermittent error while running mod_perl 1.26 on Apache 1.3.19. In Apache's error log there appears two different kinds of errors message with no pattern and varying frequency. The first is: null: Attempt to free unreferenced scalar.. The second is: [notice] child pid X exit signal Segmentation fault (11) ...where X is a process number like 14318, 14564 etc. My configuration is completed basic, I am simply running the Hello World example exactly as it appears in the O'Reilly Writing Apache modules with Perl and C. I have searched the web and I can see many queries similar to this one, leading me to believe it is a common problem - but I am yet to find the solution. Can someone please tell me what this is or how to go about debugging it? I am at my wits end. http://perl.apache.org/preview/modperl-docs/dst_html/docs/1.0/guide/help.html#How_to_Report_Problems -- __ Stas BekmanJAm_pH -- Just Another mod_perl Hacker http://stason.org/ mod_perl Guide --- http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
Re: mod_perl/apache: unreferenced scalar seg fault (?)
On 20/4/02 7:08 PM, Stas Bekman [EMAIL PROTECTED] wrote: Andrew Tomazos wrote: I am encountering an intermittent error while running mod_perl 1.26 on Apache 1.3.19. In Apache's error log there appears two different kinds of errors message with no pattern and varying frequency. The first is: null: Attempt to free unreferenced scalar.. The second is: [notice] child pid X exit signal Segmentation fault (11) ...where X is a process number like 14318, 14564 etc. My configuration is completed basic, I am simply running the Hello World example exactly as it appears in the O'Reilly Writing Apache modules with Perl and C. I have searched the web and I can see many queries similar to this one, leading me to believe it is a common problem - but I am yet to find the solution. Can someone please tell me what this is or how to go about debugging it? I am at my wits end. http://perl.apache.org/preview/modperl-docs/dst_html/docs/1.0/guide/help.html# How_to_Report_Problems I've included an excerpt from the Error_Log, perl -v and some of the installed mod_perl files belows. Let me know if I need to include anything else. -Andrew. ERROR_LOG: [Sat Apr 20 05:11:54 2002] null: Attempt to free unreferenced scalar. [Sat Apr 20 05:11:55 2002] [notice] child pid 14919 exit signal Segmentation fault (11) [Sat Apr 20 05:12:02 2002] null: Attempt to free unreferenced scalar. [Sat Apr 20 05:12:03 2002] [notice] child pid 14918 exit signal Segmentation fault (11) [Sat Apr 20 05:12:12 2002] null: Attempt to free unreferenced scalar. [Sat Apr 20 05:12:13 2002] [notice] child pid 14920 exit signal Segmentation fault (11) [Sat Apr 20 05:12:25 2002] null: Attempt to free unreferenced scalar. [Sat Apr 20 05:12:26 2002] [notice] child pid 14922 exit signal Segmentation fault (11) PERL -V: Summary of my perl5 (revision 5.0 version 6 subversion 1) configuration: Platform: osname=linux, osvers=2.4.2, archname=i386-linux uname='linux grommet 2.4.2 #1 smp sun feb 25 16:33:33 pst 2001 i686 unknown ' config_args='-de -Dprefix=/usr -Darchname=i386-linux -Dprivlib=/usr/lib/perl5 -Darchlib=/usr/lib/perl5/i386-linux -Dsitelib=/usr/lib/perl5/site_perl -Dsitearch=/usr/lib/perl5/site_perl/i386-linux' hint=recommended, useposix=true, d_sigaction=define usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef useperlio=undef d_sfio=undef uselargefiles=define usesocks=undef use64bitint=undef use64bitall=undef uselongdouble=undef Compiler: cc='cc', ccflags ='-fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', optimize='-O2', cppflags='-fno-strict-aliasing -I/usr/local/include' ccversion='', gccversion='2.95.3 20010315 (release)', gccosandvers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8 alignbytes=4, usemymalloc=n, prototype=define Linker and Libraries: ld='cc', ldflags =' -L/usr/local/lib' libpth=/usr/local/lib /lib /usr/lib libs=-lnsl -lndbm -lgdbm -ldl -lm -lc -lcrypt -lutil perllibs=-lnsl -ldl -lm -lc -lcrypt -lutil libc=/lib/libc-2.2.2.so, so=so, useshrplib=false, libperl=libperl.a Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic' cccdlflags='-fpic', lddlflags='-shared -L/usr/local/lib' Characteristics of this binary (from libperl): Compile-time options: USE_LARGE_FILES Built under linux Compiled at Apr 11 2001 22:57:30 @INC: /usr/lib/perl5/i386-linux /usr/lib/perl5 /usr/lib/perl5/site_perl/i386-linux /usr/lib/perl5/site_perl /usr/lib/perl5/site_perl . SOME MOD_PERL FILES: /usr/lib/perl5/site_perl/i386-linux/auto/Apache/mod_perl.exp /usr/lib/perl5/site_perl/i386-linux/auto/Apache/include/modules/perl/mod_per l.h /usr/lib/perl5/site_perl/i386-linux/auto/Apache/include/modules/perl/mod_per l_xs.h /usr/lib/perl5/site_perl/i386-linux/auto/Apache/include/modules/perl/mod_per l_version.h /usr/lib/perl5/site_perl/i386-linux/auto/mod_perl /usr/lib/perl5/site_perl/i386-linux/auto/mod_perl/.packlist /usr/lib/perl5/site_perl/i386-linux/mod_perl_hooks.pm.PL /usr/lib/perl5/site_perl/i386-linux/mod_perl.pm /usr/lib/perl5/site_perl/i386-linux/mod_perl_cvs.pod /usr/lib/perl5/site_perl/i386-linux/mod_perl_method_handlers.pod /usr/lib/perl5/site_perl/i386-linux/mod_perl.pod /usr/lib/perl5/site_perl/i386-linux/mod_perl_tuning.pod /usr/lib/perl5/site_perl/i386-linux/mod_perl_traps.pod /usr/lib/perl5/site_perl/i386-linux/mod_perl_hooks.pm /usr/lib/perl5/site_perl/i386-linux/cgi_to_mod_perl.pod
Re: PDF generation
On 4/19/02 10:33 PM, Stas Bekman [EMAIL PROTECTED] claimed: If your end goal is PS, better generated PS in first place. From my experience ps - pdf - ps, makes the final PS a much bigger file (5-10 times bigger). I use html2ps for generating PS files (used for generating the mod_perl guide's pdf). Actually, I realized the same thing yesterday. I'm looking at possibly just using PostScript::Document to create PS and forgetting about PDF for now. Regards, David -- David Wheeler AIM: dwTheory [EMAIL PROTECTED] ICQ: 15726394 http://david.wheeler.net/ Yahoo!: dew7e Jabber: [EMAIL PROTECTED]
Re: Inline generation of error document?
Bas A.Schulte wrote: Hi all, On Thursday, April 18, 2002, at 04:58 PM, Geoffrey Young wrote: I'm a little confused (honestly). I want to handle parameter errors in a content handler. When there's a parameter missing in the URL, my handler returns HTTP_BAD_REQUEST. Now Apache sees the HTTP_BAD_REQUEST return value from my handler and generates an error (HTML) document. How can I create this document right from within my handler? I could create another handler of course and use the ErrorDocument directive to point to that but I am wondering if I can do it in my handler directly. Somehow I can't find this in the eagle book. look for $r-custom_response I did, even before my post ;) My confusion was caused by the client testing tool I used: lwp-request. Apparently, it generates HTML-formatted documents in error conditions that *do not come from the webserver*. I was doing something like this: $request-custom_response(HTTP_NOT_ACCEPTABLE,'invalid request (application identifier not found)'); return (HTTP_NOT_ACCEPTABLE); Expecting a plain text document in the response. lwp-request however creates an HTML document itself and displays that. Going in with telnet to the appropriate port etc. revealed this was actually working as advertised. One of those 'put it in quickly at the end of the day' things ;) Bas. MSIE also overwrites custom responses with built-in ones, per the response number. Netscape and Mozilla are VERY nice, though :-) Issac
[OT] Doubt on directories for development
I am working in my first mod_perl real-life project, I would like to ask you for a directory layout for development. The fact is that developers in my team have Apache under /usr/local in Linux machines, but we would prefer to develop as normal users, not as www or nobody, though that will be the user in production. What is the standard way to configure things for that? We have created somehow the Apache directory layout under the root of the project tree and call httpd -f project_root/conf/httpd.conf, where we customize the user and group (in my case fxn), full paths to log and pid files writable by that user, etc. but ServerRoot is /usr/local/apache and the original modules under /usr/local/apache are there, so we cannot use $r-server_root_relative to access, say, to application config files which seems to be standard (and quite natural) idiom. The httpd.conf in CVS is a template customized once per-machine with a script. I would appreciate any hint very much, we could begin right with a good layout next Monday. Thank you very much! -- fxn
Re: mod_perl installation on Win32
On Sat, 20 Apr 2002, xk wrote: Hi. I have apache 2.0.35 and ActivePerl 5.6.1 installed on Win32, and I can't install mod_perl 1.99_01. When I do perl Makefile.PL MP_AP_PREFIX=C:/Program Files/Apache Group/Apache2, it says Configuring Apache/2.0.35 mod_perl/1.99_01 Perl/v5.6.1 unlink...lib/Apache/BuildConfig.pm C:/Program Files/Apache Group/Apache2/bin/Apache.exe -l failed: Bad file descriptor at Apache-Test/lib/Apache/TestConfig.pm line 777, DATA chunk 1. You might try, if possible, installing Apache to a directory without spaces in the name - sometimes the spaces can cause problems ... Does anybody know where I could find an already compiled module for Win32? A mod_perl-2 ppm package is available for installation via ppm as ppm install http://theoryx5.uwinnipeg.ca/ppmpackages/mod_perl-2.ppd best regards, randy kobes