Re: Apache::ServerUtil pb in modperl2
apache 2.0.35 / mod_perl 1.99_01 / winnt or win2k I confirm that using a module in startup.pl consisting of use Data::Dumper ; use XML::LibXML() ; [1] use Apache::ServerUtil ; [2] my $s=Apache-server ; [3] my $base=$s-dir_config('some'); [4] my $xml=XML::LibXML-new(); [5] print Dumper $xml ; causes the line [3] to output message Attempt to free unreferenced scalar line [4] causes apache segfaults unhandled exception perl56.dll (XML::LibXML in version 1.31 or 1.40) line [5] is executed before apache stops $VAR1 = bless( {}, 'XML::LibXML' ); here is a backtrace in case useful PERL56! 28021683() PERL56! 28071c17() PERL56! 2805c910() PERL56! 2805c5b1() PERL56! 2805c577() PERL56! 2805c577() PERL56! 2805c870() PERL56! 2805ba24() PERL56! 2800c882() PERL56! 2805c7f3() PERL56! 2805ba24() PERL56! 2800c882() PERL56! 2805b9fd() PERL56! 2800c882() PERL56! 2805b9fd() PERL56! 2800c882() PERL56! 2805b9fd() PERL56! 2800c882() PERL56! 2805c248() PERL56! 2805d510() PERL56! 2805d16f() MOD_PERL! 10001fb3() MOD_PERL! 10002a22() MOD_PERL! 10001840() MOD_PERL! 10001796() ap_run_post_config(apr_pool_t * 0x0078a830, apr_pool_t * 0x007ba660, apr_pool_t * 0x007bc6a8, server_rec * 0x007a2508) line 130 + 89 bytes main(int 1, const char * const * 0x00782760) line 569 + 22 bytes mainCRTStartup() line 338 + 17 bytes KERNEL32! 77e77903() if I drop line [4] and [5], there is the line [3] message, but apache does not seem to segfault. pascal Accédez au courrier électronique de La Poste : www.laposte.net ; 3615 LAPOSTENET (0,13 ?/mn) ; tél : 08 92 68 13 50 (0,34?/mn)
Re: mod_perl 1.99 (for Apache 2.0.35) building on W2K
Hi chuck for DBI and DBD::xx it makes no difference if you use them with regular cgi modperl 1 or 2 because they are unrelated to web environment. (at least i suppose so a priori). at least in my test they are used without problem in startup.pl. for cgi.pm used outside modpelr with 2.0.35 no difference as well and for cgi.pm used with modperl I don't know. i guess there is a difference, at leastin the Apache::registry setup of the location to use the cgi like script pascal - Original Message - From: Chuck Goehring To: pascal barbedor Sent: Saturday, April 13, 2002 5:11 AM Subject: Re: mod_perl 1.99 (for Apache 2.0.35) building on W2K Pascal and anyone else who can help, I've seen your other posts and I'm wondering how your testing is going with "regular" cgi programs. I don't use any of the exotic mod_perl specifics, so I'm no help there. I'll have to "aquire" more facilities to setup like you have (nt boxes in short supply). I'm mostly concerned about the cgi.pm, dbi.pm dbd::oracle etc. Anybody know the impact that Apache 2.0 has on these modules? Chuck - Original Message - From: pascal barbedor To: Chuck Goehring Sent: Thursday, April 11, 2002 4:40 AM Subject: Re: mod_perl 1.99 (for Apache 2.0.35) building on W2K Hi I am trying to build modperl under win2k saw your message. don't know about your problem but : i use already built asperl build 631 I havebuilt apache succesfully, but when trying to build modperl2 i am asked apxs did you find the apxs program ? thanks pascal barbedor
Re: Apache::ServerUtil pb in modperl2
Does the following, or some variation, work? == package Apache::Test; # PerlModule Apache::Test # Location /hello-world # SetHandler modperl # PerlResponseHandler Apache::Test # PerlSetVar TEST jdjdsds # /Location use strict; # based on t/conf/modperl_extra.pl in the mod_perl-2 sources use Apache::RequestRec (); use Apache::RequestIO (); use Apache::ServerUtil (); use Apache::RequestUtil (); use APR::Table; use Apache::Const -compile = qw(:common); use APR::Const -compile = qw(:common); sub handler { my $r = shift; my $key = $r-dir_config-get('TEST'); $r-content_type('text/plain'); $r-print($key); Apache::OK; } 1; === best regards, randy kobes yes it works perfectly well. but you are accessing dir_config through a request object and in my example I am accessing it through the server object in a use module in startup.pl best regards pascal
Equiv Apache list to this list?
Hi, I have been having lots of questions about Apache recently, not many of them are really mod_perl questions, so what is the best place to post those? Thanks, Eric http://www.kwinternet.com/eric (250) 655 - 9513 (PST Time Zone) Learn about the net, not the .Net!
Re: Equiv Apache list to this list?
On Sat, Apr 13, 2002 at 12:06:53AM -0400, Eric Frazier wrote: Hi, I have been having lots of questions about Apache recently, not many of them are really mod_perl questions, so what is the best place to post those? Thanks, Eric See http://httpd.apache.org/lists.html . It depends upon exactly what you're looking for, but the 'User Support and Disscussion' list is probably a good place to start. Eric (no relation)
Re: Mem usage of modules
Using mod_rewrite instead of symlink should solve your problem. The auk_ch_de and auk_ch_fr scripts are preloaded with RegistryLoader. But these scripts are also mentioned later on that list - is that means they were loaded into memoey twice yes http://perl.apache.org/guide/performance.html#Be_Careful_with_Symbolic_Links (in fact all the auk_ scripts are sym links to the same script auk) ? Thanks Pawel -- Sammy Lau mailto: [EMAIL PROTECTED] - Tell me what you want and I'll tell you how you can live without it.
Several problems for mod_perl2 in compatibility mode (Win32)
Greetings. This is relative to several problems on Win32/NTSP6/AP build 630. Short executive report: nothing seems to work :-) -8-- Start Bug Report 8-- 1. Problem Description: I have tried these with both the released mod_perl *AND* the latest CVS snapshot (no difference in either). The report was generated with the snapshot, but symptoms are identical for the released version. While building: if MP_DEBUG is set to 1: Complaints of Filter.obj : error LNK2001: unresolved external symbol _MP_debug_level ..\..\..\blib\arch/Apache2\auto\Apache\Filter\Filter.dll : \ fatal error LNK1120: 1 unresolved externals If MP_DEBUG is defined on Win32. While Testing: D:\Perl\bin\perl.exe -Iblib\arch/Apache2 -Iblib\lib/Apache2 t/TEST -clean D:\Perl\bin\perl.exe -Iblib\arch/Apache2 -Iblib\lib/Apache2 t/TEST D:\Apache2/bin/Apache.exe -d D:/builds/modperl-2.0/t \ -f D:/builds/modperl-2.0/t/conf/httpd.conf -DAPACHE2 -DPERL_USEITHREADS using Apache/2.0.35 (winnt MPM) waiting for server to start: ok (waited 1 secs) server localhost:8529 started server localhost:8530 listening (TestDirective::perlmodule) server localhost:8531 listening (TestDirective::perlrequire) server localhost:8532 listening (TestProtocol::echo) server localhost:8533 listening (TestProtocol::echo_filter) server localhost:8534 listening (TestProtocol::eliza) server localhost:8535 listening (TestFilter::input_msg) *** : cannot build c-modules without apxs the server is down, giving up after 61 secs !!! : failed to start server! (please examine D:t\logs\error_log) NMAKE : fatal error U1077: 'D:\Perl\bin\perl.exe' : return code '0x1' Stop. (apache keeps running afterwards) Trying to actually use mod_perl in compatibility mode nothing appears to work (see detailed configuration below). I tested scripts/application that run fine under Apache 1, mod_perl 1.26, Apache::Registry or straight CGI. Scripts using CGI.pm return either: o) an empty body (Apache::Registry) o) a perl error - [Fri Apr 12 14:05:33 2002] [error] PerlRun: `Can't call method args on an undefined value at D:/Perl/lib/CGI.pm line 433.' (Apache::PerlRun) The offending line contains a reference to Apache-request-args. o) a stack overflow that crashes apache (complex app, under either registry or perlrun) (but since I cannot compile a debug version - see above - I can only see what appears to be a deep recursion somewhere in mod_perl.) Not using CGI I can only get an empty body viz.: !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN HTMLHEAD META http-equiv=Content-Type content=text/html; charset=iso-8859-1/HEAD BODYXMP/XMP/BODY/HTML This happens on elementary, Hello world type of scripts under either PerRun or Registry. Configuration: PerlModule Apache2 PerlModule Apache::compat PerlRequire conf/startup.pl Location /webteam/perl/bin/ Options +ExecCGI SetHandler modperl PerlResponseHandler Apache::Registry PerlOptions +ParseHeaders PerlOptions +SetupEnv allow from all /Location startup.pl: $ENV{MOD_PERL} or die not running under mod_perl!; use Apache2 (); use Apache::compat (); use Apache::Registry (); use Apache::PerlRun (); use Carp (); use CGI (); CGI-compile(':all'); use CGI::Carp; 1; 2. Used Components and their Configuration: *** using lib/Apache/BuildConfig.pm *** Makefile.PL options: MP_AP_PREFIX= D:\Apache2 MP_DEBUG= MP_GENERATE_XS = 1 MP_INST_APACHE2 = 1 MP_LIBNAME = mod_perl MP_USE_DSO = 1 *** D:\Apache2/bin/Apache.exe -V Server version: Apache/2.0.35 Server built: Apr 12 2002 09:31:06 Server's Module Magic Number: 20020329:0 Architecture: 32-bit Server compiled with -D APACHE_MPM_DIR=server/mpm/winnt -D APR_HAS_SENDFILE -D APR_HAS_MMAP -D APR_HAS_OTHER_CHILD -D AP_HAVE_RELIABLE_PIPED_LOGS -D HTTPD_ROOT=/apache -D SUEXEC_BIN=/apache/bin/suexec -D DEFAULT_ERRORLOG=logs/error.log -D SERVER_CONFIG_FILE=conf/httpd.conf *** D:\Perl\bin\perl.exe -V Summary of my perl5 (revision 5 version 6 subversion 1) configuration: Platform: osname=MSWin32, osvers=4.0, archname=MSWin32-x86-multi-thread uname='' config_args='undef' hint=recommended, useposix=true, d_sigaction=undef usethreads=undef use5005threads=undef useithreads=define usemultiplicity=define useperlio=undef d_sfio=undef uselargefiles=undef usesocks=undef use64bitint=undef use64bitall=undef uselongdouble=undef Compiler: cc='cl', ccflags ='-nologo -O1 -MD -DNDEBUG -DWIN32 -D_CONSOLE -DNO_STRICT -DHAVE_DES_FCRYPT -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -DPERL_MSVCRT_READFIX', optimize='-O1 -MD -DNDEBUG', cppflags='-DWIN32' ccversion='', gccversion='', gccosandvers=''
Re: Apache::File correction
Rob Nagler [EMAIL PROTECTED] writes: undef $/; # enable slurp mode I think the local is pretty important, especially in mod_perl: local $/; This has the same effect (the undef is unnecessary). It's also a good idea to enclose the code in a subroutine with error checking: sub read_file { my($file) = @_; open(FH, $file) || die(error opening $file: $!); local($/); my($content) = FH; close(FH) defined($content) || die(error reading $file: $!); return \$content; } A similiar idiom that I saw recently: sub file_contents { my $fn = shift; open(FOO, $fn) or die file_contents: open($fn): $!\n; my $stuff; read FOO, $stuff, -s FOO; close(FOO); return $stuff; } Take your pick as to which one is clearer... -Dom -- | Semantico: creators of major online resources | | URL: http://www.semantico.com/ | | Tel: +44 (1273) 72 | | Address: 33 Bond St., Brighton, Sussex, BN1 1RD, UK. |
DSO on Solaris - child dies with seg fault
Hi, I was trying to run mod_perl as DSO on Solaris. I see the following line in the logs: [notice] child pid 24323 exit signal Segmentation Fault (11) This happens whenever I send a USR1 to the server for restart. Also I see the same message whenever the child is about to exit (ie. after handling the prescribed no.of requests). Is DSO stable enough to be used under Solaris ? I have searched through the archives see differing opinions. Additional Info: $perl -V:uselargefiles -V:bincompat5005 uselargefiles='define'; bincompat5005='undef'; perl: 5.6.1, Apache: 1.3.23, mod_perl: 1.26 Using SunOS 5.6 Generic_105181-16 sun4u sparc SUNW,Ultra-80 I've compiled mod_perl with PERL_USELARGEFILES=0 and USE_DSO. The above problem is repeatable with PerlFreshRestart On and Off. Any clues ? Thanx Sreeji (BTW, make test has gone through w/o any errors) __ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
Re: [ANNOUNCE] Cache::Cache 1.0
--On dimanche 7 avril 2002 12:50 -0400 DeWitt Clinton [EMAIL PROTECTED] wrote: Hi, The following is an announcement of Cache::Cache 1.0. Please read the summary below for more details. I want to ask a special favor of the modperl community (who tend to get a lot of mileage out of this code) -- I'm concerned with the use of Digest::MD5, particularly version 2.16, which is used by the code to generate unique filenames in the file-based cache. I've been seeing some pretty ugly bugs with the the MD5 code, and this has been confirmed on a few mailing lists and CPAN bug reports. Please let me know if you notice any weird behavior with your system after upgrading to version 1.0. (All unit test pass consistently, but under certain conditions, such as when XML::DOM is loaded, I think that Digest::MD5 may always return the same hash, no matter what the key.) I'm seeing this problem when using Apache::SOAP, using Cache::Cache 0.99 or 1.0. Downgrading to Digest::MD5 2.12 indeed solves it. -- Eric Cholet
Re: DSO on Solaris - child dies with seg fault
Sreeji K Das wrote: Hi, I was trying to run mod_perl as DSO on Solaris. I see the following line in the logs: [notice] child pid 24323 exit signal Segmentation Fault (11) This happens whenever I send a USR1 to the server for restart. Also I see the same message whenever the child is about to exit (ie. after handling the prescribed no.of requests). Is DSO stable enough to be used under Solaris ? I have searched through the archives see differing opinions. Additional Info: $perl -V:uselargefiles -V:bincompat5005 uselargefiles='define'; bincompat5005='undef'; perl: 5.6.1, Apache: 1.3.23, mod_perl: 1.26 Using SunOS 5.6 Generic_105181-16 sun4u sparc SUNW,Ultra-80 I've compiled mod_perl with PERL_USELARGEFILES=0 and USE_DSO. The above problem is repeatable with PerlFreshRestart On and Off. Any clues ? Thanx Sreeji (BTW, make test has gone through w/o any errors) See if it helps you:http://perl.apache.org/guide/install.html#When_DSO_can_be_Used __ 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: [JOB] ModPerl developer at PrintMe.Com
John, I saw your post for a ModPerl Developer on the mod_perl list and would like to apply. Please find enclosed my resume. As a quick overview, please note my experience leading a team of engineers and specialists in remotely developing and delivering an Apache/ModPerl/HTML::Mason/PostgreSQL-based enterprise content management application for Salon.com and later Primedia. In my planning and implementation of this software, I strove to provide an effective yet intuitive application to meet the content management needs of large organizations. I also managed the project development schedule, recruiting talent, and managing the development infrastructure and process from end to end. The payoff for this work is reflected in the success of the software: It is now a critical part of the enterprise asset management infrastructure of Primedia; Salon.com; and the World Health Organization in Geneva, Switzerland. I'd like to put my skills developing successful enterprise-class applications to work for PrintMe.com. I thrive in an environment where I work hard to architect, design and develop successful products that exceed expectations. Please feel free to contact me any time. I live in San Francisco, so it will be easy for me to commute to Foster City. I look forward to hearing from you. Regards, David -- David Wheeler AIM: dwTheory [EMAIL PROTECTED] ICQ: 15726394 http://david.wheeler.net/ Yahoo!: dew7e Jabber: [EMAIL PROTECTED] resume.txt Description: Binary data
Re: [JOB] ModPerl developer at PrintMe.Com
On 4/13/02 1:54 PM, David Wheeler [EMAIL PROTECTED] claimed: John, I saw your post for a ModPerl Developer on the mod_perl list and would like to apply. Please find enclosed my resume. Did I *really* I reply to the whole list??? Oh, god, am I embarrassed. Sorry for the spam, everyone! David -- David Wheeler AIM: dwTheory [EMAIL PROTECTED] ICQ: 15726394 http://david.wheeler.net/ Yahoo!: dew7e Jabber: [EMAIL PROTECTED]