Re: mod_perl troubles with RedHat 8.0 and Perl 5.8.0

2002-12-18 Thread Aaron Johnson
On Wed, 2002-12-18 at 17:48, iansmith wrote:
 I have compiled apache_1.3.27 with mod_perl-1.27 and got no errors.
 I have mod_perl as a shared module.
 
 I can run Apache without mod_perl fine, but when I activate the
 mod_perl module, it gives me this in error_log for every connection
 and fails to deliver any pages at all.
 
 [notice] child pid 27049 exit signal Segmentation fault (11)
 
 My perl is: This is perl, v5.8.0 built for i386-linux-thread-multi
 
 I looked over the mod_perl documentation, but can't seem to find
 anything that says what works and what does not.
 

I had a similar issue with a fresh install of Mandrake 9.0.
(see below for the 'perl -V output')

I Embperl (2.0b9dev5 or 2.0b8) wouldn't work without compiling my own
non-threaded version of Perl. 

For my own install of Perl I used all the default Perl compile settings
and everything went fine.

The biggest problem for me under Mandrake with self compiled version of
Perl was the MDK::Common module that drakxconf uses and along with that
Gtk-Perl.  I have yet to get them all working 100%, but my mod_perl
server is running great.  The other stuff I can work around.

I was mainly trying to get Embperl setup. My Apache::ASP sites seemed to
work fine with the default Perl.

I realize this isn't exactly like your problem, but possibly there is a
commonality of troubles with the threaded 5.8 Perl and mod_perl.

Oddly enough on a machine I upgraded from Mandrake 8.2 to 9.0 (Perl
5.6.1 to 5.8.0) everything compiled and worked.

I should also not that my Apache/mod_perl compile was done using the
Apachetoolbox utility and mod_perl was static not DSO.

Aaron Johnson

Mandrake 9 default perl -V:

Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration:
  Platform:
osname=linux, osvers=2.4.19-2mdkenterprise,
archname=i386-linux-thread-multi
uname='linux no.mandrakesoft.com 2.4.19-2mdkenterprise #1 smp tue
aug 13 00:17:42 cest 2002 i686 unknown unknown gnulinux '
config_args='-des -Darchname=i386-linux -Dcc=gcc -Doptimize=-O3
-fomit-frame-pointer -pipe -mcpu=pentiumpro -march=i586 -ffast-math
-fno-strength-reduce -Dprefix=/usr -Dvendorprefix=/usr -Dsiteprefix=/usr
-Dman3ext=3pm -Dcf_by=MandrakeSoft -Dmyhostname=localhost
-Dperladmin=root@localhost -Dd_dosuid -Ud_csh -Duseshrplib -Dusethreads'
hint=recommended, useposix=true, d_sigaction=define
usethreads=define use5005threads=undef useithreads=define
usemultiplicity=define
useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=undef use64bitall=undef uselongdouble=undef
usemymalloc=n, bincompat5005=undef
  Compiler:
cc='gcc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm',
optimize='-O3 -fomit-frame-pointer -pipe -mcpu=pentiumpro
-march=i586 -ffast-math -fno-strength-reduce',
cppflags='-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing
-I/usr/include/gdbm'
ccversion='', gccversion='3.2 (Mandrake Linux 9.0 3.2-1mdk)',
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, prototype=define
  Linker and Libraries:
ld='gcc', ldflags =' -L/usr/local/lib'
libpth=/usr/local/lib /lib /usr/lib
libs=-lnsl -lndbm -lgdbm -ldl -lm -lpthread -lc -lcrypt -lutil
perllibs=-lnsl -ldl -lm -lpthread -lc -lcrypt -lutil
libc=/lib/libc-2.2.5.so, so=so, useshrplib=true, libperl=libperl.so
gnulibc_version='2.2.5'
  Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic
-Wl,-rpath,/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE'
cccdlflags='-fpic', lddlflags='-shared -L/usr/local/lib'


Characteristics of this binary (from libperl):
  Compile-time options: MULTIPLICITY USE_ITHREADS USE_LARGE_FILES
PERL_IMPLICIT_CONTEXT
  Built under linux
  Compiled at Sep  6 2002 23:24:44
  @INC:
/usr/lib/perl5/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/5.8.0
/usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.0
/usr/lib/perl5/site_perl/5.6.1
/usr/lib/perl5/site_perl
/usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.0
/usr/lib/perl5/vendor_perl
.


 Do I need to compile a non-threaded version of Perl?
 
 Thanks.
 
 --
 Ian
 
 
 




Re: mod_perl troubles with RedHat 8.0 and Perl 5.8.0

2002-12-18 Thread Aaron Johnson
On Wed, 2002-12-18 at 20:30, Stas Bekman wrote:
 iansmith wrote:
  I have compiled apache_1.3.27 with mod_perl-1.27 and got no errors.
  I have mod_perl as a shared module.
  
  I can run Apache without mod_perl fine, but when I activate the
  mod_perl module, it gives me this in error_log for every connection
  and fails to deliver any pages at all.
  
  [notice] child pid 27049 exit signal Segmentation fault (11)
  
  My perl is: This is perl, v5.8.0 built for i386-linux-thread-multi
  
  I looked over the mod_perl documentation, but can't seem to find
  anything that says what works and what does not.
  
  Do I need to compile a non-threaded version of Perl?
 
 Certainly Aaron's solution should work, but it'd be nice to figure out 
 the cause of segfaults, because a threaded 5.8 perl works just fine with 
 mod_perl for me (Mandrake 9.0). Though I built it by myself, I should 
 try using the Perl supplied by Mandrake.
 

How does your perl -V differ from the Mandrake one?  The default install
of Perl didn't have a perldoc either, I am wondering if it is a bad
build.

When I do an:
rpm -ql perl | grep 'perldoc'

I only get:
/usr/share/man/man1/perldoc.1.bz2

I don't think it is just a thread issue.

Aaron

 Before you rebuild it, if you can get the segfault backtrace, that would 
 be great. If you don't know how, check:
 http://perl.apache.org/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: How Can I Install ModPerl on My ISP-based Website???

2002-11-21 Thread Aaron Johnson
On Thu, 2002-11-21 at 19:00, David Simcik wrote:
 I would LOVE to use mod_perl on my personal website -- I have the diskspace
 to do so, but the question remains as to whether or not I have the rights.
 Can anyone point me to a guide for this? I've poked around the mod_perl site
 and didn't find anything too specific.
 

http://www.perlmonks.org/index.pl?node_id=145367

 Thanks!
 D. Simcik
 
 
 




Bricolage in eWeek

2002-10-30 Thread Aaron Johnson
This weeks print version of eWeek as well as the online version have an
article on Bricolage.

article - http://www.eweek.com/article2/0,3959,652977,00.asp
Bricolage - http://bricolage.thepritgroup.com 

Aaron Johnson




Re: Forking process

2002-10-09 Thread Aaron Johnson

On Wed, 2002-10-09 at 05:25, Anton Permyakov wrote:
 Hi all,
 
 I need to start process, which would get big amount of data from another
 server into my DataBase,
 and while it will do it, my browser should show me progress-bar on this data
 extraction.
 
 I have mod_perl based web-server, so, i should not use fork(), as explained
 in Mod_perl docs. But also i cannot invoke system(), as this proccess could
 take very long time.
 What i have to do?

I needed to do this recently myself.  I am using sessions (under
HTML::Embperl) so I created a temp file and added the name of the temp
file to my session data. 

I 'exec' off the external program after I have printed waiting page
content.  I pass the temp file name to the external script so it can
delete it when it is done running. The waiting page includes a meta
refresh, in my case the wait is dynamically determined based on the type
of action taken and the estimated time it will take to produce the
results.

The temp file is deleted once the process was done running. When the
meta refresh occurs it reloads the same page and determines if the temp
file matching the session value still existed and if so redisplays the
appropriate waiting page with a predefined wait time (30 seconds in my
case).  If the temp file is cleared I present the user with the results.

The temp file name should be from a counter file or some form of rand
seed and/or time to avoid duplicate names while processing.  Traffic
will determine how aggressive you need to be in the uniqueness of the
file name.

So in a nutshell

- Create a temp (flag) file
- Generate and send the HTML to the browser which includes a meta
refresh
- Add the temp file to their session data (or something similar)
- Exec a process and send the temp file name to it
- On page refresh look to see if the temp (flag) file still exists and
if so create a new waiting page ( meta refresh ), otherwise deliver end
results.

Aaron Johnson

 
 May be best solution is using CGI-script, which allows forking without all
 Apache process forking?
 
 Thank you,
 
 Best wishes!
 
 Anton Permyakov   Web-Developer
 [EMAIL PROTECTED]   WWW.SOLUDIUM.COM
 
 




Re: RedHat RPM for apache+mod_perl?

2002-09-25 Thread Aaron Johnson

On Wed, 2002-09-25 at 18:11, Dave Rolsky wrote:
 Has anyone here come up with an RPM for apache+mod_perl, with the
 following caveats:
 

I use Apache ToolBox to get all these items and have been very pleased
with.  It allows you the option of creating a RPM as well, so if that
part works for you (mine didn't) you would have something you could take
from machine to machine.  The process allows for you to modify the
install path so it will play nice with other versions of Apache on the
same machine.

You can configure evey part and it even prompts you to edit the
configuration files during the process.

I have tested this on:
Custom Linux, the OS was assembiled from various GNU parts
Installed Apache/mod_perl/php/mod_ssl

Mandrake 8.2 Linux
Installed Apache/mod_perl/php/mod_ssl/mod_layout

Red Hat 7.?
Installed Apache/mod_perl/php/mod_ssl/mod_layout

I have only tested the recently RPM support one time under Mandrake so I
am not sure how well it might work on other platforms.

Even if the RPM portion doesn't work the Toolbox takes away most of the
grunt work.

http://www.apachetoolbox.com

 1. mod_perl is statically compiled
 
 2. I don't want SSL.  This will be backend server.  Only the frontend
 needs SSL.
 
 3. can co-exist with a non-mod_perl Apache on the same system, meaning
 that it has its own config dir, pid file, logs, etc.
 
 4. Including mod_rpaf would be a nice bonus, but adding this probably
 wouldn't be too hard.
 
 In other words, is there anything like the excellent apache-perl Debian
 package, but for Red Hat.  ARGH, I really hate Red Hat.  But in this case
 I'm stuck with it.
 
 I've been working on this myself for a few hours but I realized I should
 ask about it here first.
 
 
 -dave
 
 /*==
 www.urth.org
 we await the New Sun
 ==*/
 
 




Re: Installing Perl::Magick

2002-02-19 Thread Aaron Johnson

There is a package available in ppm for ActiveState Perl.
There is a short write up on it PerlMonks
http://www.perlmonks.org/index.pl?node_id=140321

Aaron Johnson

Ron Savage wrote:
 
 lamp
 
 See below.
 
 Cheers
 Ron Savage
 [EMAIL PROTECTED]
 http://savage.net.au/index.html
 
  Magick.xs:76:24: magick/api.h: No such file or directory
 
 This means you must, repeat must, have the ImageMagick source code on tap to compile 
PerlMagick. Being lazy, I wait for someone to
 create an ActiveState ppm file...
 
 As someone else mentioned, there are ImageMagick mailing lists:
 http://www.imagemagick.org/www/magick-list.html



Re: New mod_perl Logo

2002-01-29 Thread Aaron Johnson

Thanks for sharing your opinion and it has brought up some of my own
that I had held in reserve for sometime now.

I would 100% agree with a claim that a name is effecting usage if we
were selling a food product or something else to the general public, but
even then far more products have failed because they weren't properly
explained to the public.  mod_perl is a beast of tool/product.  It
harnesses the full power of Apache web server and Perl to allow you do
dam near anything with the data you need to handle.  Apache because of
its large platform support and well designed architecture has proven
that it is enterprise ready.  That brings me to the rub of this
discussion however, Perl.  I love Perl, I use Perl for almost every
programming task that I need in my work and personal computing use. 
That isn't enough though.  Perl has a rep, MySQL has a rep too.  These
*once* true statements such as Its just a scripting language for Unix
or It doesn't support transactions etc. are becoming more and more the
cripples of the acceptance not the name.  These great and power products
don't have someone dispelling the myths on national television while
none computer managers are watching TV, they only remember what the last
consultant said.  I am not knocking managers I am just showing human
nature, that is we don't change our opinions unless someone we trust
(the TV? ) more then the last person explains clearly why we should.

We have had several discussions over the last three years on this list
about advocating mod_perl. I think what it really boils down to is a
polished web presence and a strong statement of the power and efficiency
of the product at hand and in this case a place your favorite open
source application here page to refute known myths.

Aaron Johnson


Chris Thompson wrote:
 
 On Tue, 29 Jan 2002, Jonathan M. Hollin wrote:
  Ideas for logos, banners, powered by-type buttons are all welcome.
 
 Well, I'd like to just throw one idea into the mix. It's something that's
 bugged me for a long time, no better time than the present.
 
 mod_perl is a lousy name.
 
 There, I've said it.
 
 For any number of reasons, perl does now and will always face an uphill
 struggle in any Enterprise application.
 
 For example, at my place of employment, we just went through a rather
 arduous task that I fought against and lost.
 
 We had a production site that handled a decent amount of traffic. Apache,
 mod_perl, Linux and MySQL. It ran and ran with almost no intervention.
 
 The management team of the company that bought us a year ago had been trying
 to force a change in the product by throwing up various arguments, which
 were always false. (MySQL doesnt support Transaction, Yes it does. But
 they arent atomic., Yes they are. Well, you can't roll them back., Yes
 you can.)
 
 In the end, I lost. From October to mid January they set about taking our
 fully functional product and replatforming it to Win2k/IIS/ASP+VB/MSSQL.
 The final reason? Responsible enterprises do not use perl.
 
 mod_perl needs a name. Something marketable, something catchy. The java
 folks learned that a long time ago. Their systems are called
 Tomcat/Jakarta and Cocoon and Resin.
 
 THAT, in my opinion, is what should happen for mod_perl 2.0. It should be
 Adirondack or Orwell or any other generic, innocuous name. Even
 MonkeyButter v1.0 is probably a better deal than mod_perl.
 
 As for logos, Avoiding Camels or Eagles is a requirement. I don't blame ORA
 for requiring the trademark notices, the twisted concepts of US trademark
 law REQUIRE them to do that. The first time they didnt, they could lose
 their trademark. But we should have a mascot that makes sense and is OURS.
 Linux has the penguin, OpenBSD has the blowfish, the other BSD's have the
 devil. Those images are clearly associated with those products, and can be
 used WITHOUT corporate approval.
 
 --
 ___
 Chris Thompson



Re: Single login/sign-on for different web apps?

2002-01-16 Thread Aaron Johnson

I hadn't really taken a look at personal certificates until this thread
came up.  It looks like thawte is offering personal certificates at no
charge.

http://www.thawte.com/getinfo/products/personal/contents.html

This would make it a more likely method since lots of site
traffic wouldn't want to pay and people tyring out the service wouldn't
be forced to pay just to login.

When you say plug-in token are you talking about a browser plug-in?

Aaron Johnson

More Resources for PKI, CA, etc.
http://ospkibook.sourceforge.net/docs/OSPKI-2.4.6/OSPKI/impl-mozilla.htm
http://www.openca.org/
http://www.pki-page.org/


Gunther Birznieks wrote:
 
 
 Of course, the best authentication system for banking I've seen is
 from UBS.  They send you a scratchlist of around 100 numbers.  Every
 time you login you use one of the numbers and cross it off.  Very
 slick.
 
 Does that really work in practice? That sounds really annoying. Is this for
 business banking or for retail? How do they get the next 100 numbers to the
 user? Do they mail it out when they've used 90?
 
 It sounds like it would be less annoying to use certificates and some
 plug-in token there is going to be that much extra work to deal with a
 password sheet.



[JOB] Webmaster with lite programming

2001-12-20 Thread Aaron Johnson

The job is on site in Chicago and would require a wide range of talent, 
including , but not limited to:

Ability to create/write/edit content for the web site
Ability to work in a FreeBSD or Linux server environment
Able to troubleshoot and modify existing code that someone else has created
Able to extend other peoples work.

The company looking to fill the position is currently running a 
mod_perl/Apache::ASP driven site so the amount of hard core mod_perl 
programming is almost null, I am hoping however that someone on this 
list may be the right person or know the right person to apply for this 
position.

Please send resume and expected salary to [EMAIL PROTECTED]




Re: Regarding modperl installation (fwd)

2001-05-04 Thread Aaron Johnson

What version of the CPAN module do you have?  Version 1.56+ should no longer
force you to upgrade.

Aaron Johnson
( is it 1.56 or 1.57, anyway 1.59 is out now and it doesn't force you to
upgrade :^)

Mithun Bhattacharya wrote:

 Umm aren't we forgetting something here - like the average user who uses
 CPAN to keep track of his modules ??? I mean last time I did install
 Bundle::libnet or even install CPAN I think it went ahead and installed
 perl 5.6.1 Unless ofcourse installing everything from tar balls is what
 is suggested for the moment

 Mithun




Re: Loading Index.pl as the Root File

2001-04-23 Thread Aaron Johnson


Al Morgan wrote:

 I've been studying Slash to better understand mod_perl.  I think I
 understand everything that happens in the config file, except for this:

 Location ~ ^/$
 SetHandler perl-script
 PerlHandler Slash::Host::slashcode::rootHandler
 /Location

 Apparently, whenever the user reqests the root document (normally
 index.html), it calls rootHandler, which redirects it to index.pl.  My
 question is:  What does the ~ ^/$ mean?  I don't quite understand how


It is a regular expression:
the '~' tells apache it is a regex,
The '^' says starts with
The '$' says ends with
So in other words: If the location selected starts and ends with a / (which
would normally default to the index.html) it should be processed instead by
the command in the Location directive.


 they are doing what they're doing.

 Thanks,

 Al Morgan [ [EMAIL PROTECTED] ]




Run away processes

2001-04-04 Thread Aaron Johnson

Hello all,

Having some hard ( for me ) to track memory usage issues. We have moved
our production environment to a new machine with what we thought was
plenty of memory, but we seem to have an erratic bit of code somewhere
that eats all the available memory.  We did not have this problem on our
previous machine, but it was running RH 6.1 and Perl 5.005 so by moving
to RH 7.0 and Perl 5.6 we have really asked for trouble.

My research shows that it might be in a search routine we have that
calls in Swish-E, but we can't get a consistent run away process when
testing.

In "the guide" it is recommended that a sub in the startup.pl file:
sub UNIVERSAL::AUTOLOAD {
   my $class = shift;
   warn "$class can't \$UNIVERSAL::AUTOLOAD!\n";
 }
to trap undefined sub routines might help find the problem.  I added
that code and now I am getting a laundry list of "bad" calls.  Here is
just a short list:

Apache::ASP::Server=HASH(0x929ebc4) can't $UNIVERSAL::AUTOLOAD!
Apache::ASP::Collection=HASH(0x91d3374) can't $UNIVERSAL::AUTOLOAD!
Apache=SCALAR(0x8d61160) can't $UNIVERSAL::AUTOLOAD!
Apache::ASP::GlobalASA=HASH(0x91d31d0) can't $UNIVERSAL::AUTOLOAD!
Errno=ARRAY(0x8317564) can't $UNIVERSAL::AUTOLOAD!
DBI::DBI_tie=HASH(0x83d1d64) can't $UNIVERSAL::AUTOLOAD!
MLDBM::Serializer::Data::Dumper=HASH(0x917091c) can't
$UNIVERSAL::AUTOLOAD!

These are all repeated several times.  I ran the same
UNIVERSAL::AUTOLOAD sub on another server and got very similar results (
the older RH 6.1 and Perl 5.005 one ) so it seems the errors might be
"normal" or at least under Apache::ASP.

So the summary of my setup is:
RH 7.0 ( with all RPM updates and new gcc )
Perl 5.6
Apache 1.3.19 compiled with the corrected gcc
mod_perl 1.25
Apache::ASP 2.09

If any more info is needed let me know.

Aaron Johnson




Re: Run away processes

2001-04-04 Thread Aaron Johnson

In a private email someone mentioned that removing the \ before the $ might
make the messages more meaningful.  That code was copy and pasted from the
current guide so if it should be $ and no \$ in front of UNIVERSAL then Stas
might want to know :^)

I changed it out and now it appears that it is all the DESTROY calls that
are making its way to the error log.  Should these be trapped some where
else?
I still don't think this has anything to do with my memory being consumed,
but I thought it seemed odd that so many things were called with no defined
sub.

Aaron Johnson

Aaron Johnson wrote:

 Hello all,

 Having some hard ( for me ) to track memory usage issues. We have moved
 our production environment to a new machine with what we thought was
 plenty of memory, but we seem to have an erratic bit of code somewhere
 that eats all the available memory.  We did not have this problem on our
 previous machine, but it was running RH 6.1 and Perl 5.005 so by moving
 to RH 7.0 and Perl 5.6 we have really asked for trouble.

 My research shows that it might be in a search routine we have that
 calls in Swish-E, but we can't get a consistent run away process when
 testing.

 In "the guide" it is recommended that a sub in the startup.pl file:
 sub UNIVERSAL::AUTOLOAD {
my $class = shift;
warn "$class can't \$UNIVERSAL::AUTOLOAD!\n";
  }
 to trap undefined sub routines might help find the problem.  I added
 that code and now I am getting a laundry list of "bad" calls.  Here is
 just a short list:

 Apache::ASP::Server=HASH(0x929ebc4) can't $UNIVERSAL::AUTOLOAD!
 Apache::ASP::Collection=HASH(0x91d3374) can't $UNIVERSAL::AUTOLOAD!
 Apache=SCALAR(0x8d61160) can't $UNIVERSAL::AUTOLOAD!
 Apache::ASP::GlobalASA=HASH(0x91d31d0) can't $UNIVERSAL::AUTOLOAD!
 Errno=ARRAY(0x8317564) can't $UNIVERSAL::AUTOLOAD!
 DBI::DBI_tie=HASH(0x83d1d64) can't $UNIVERSAL::AUTOLOAD!
 MLDBM::Serializer::Data::Dumper=HASH(0x917091c) can't
 $UNIVERSAL::AUTOLOAD!

 These are all repeated several times.  I ran the same
 UNIVERSAL::AUTOLOAD sub on another server and got very similar results (
 the older RH 6.1 and Perl 5.005 one ) so it seems the errors might be
 "normal" or at least under Apache::ASP.

 So the summary of my setup is:
 RH 7.0 ( with all RPM updates and new gcc )
 Perl 5.6
 Apache 1.3.19 compiled with the corrected gcc
 mod_perl 1.25
 Apache::ASP 2.09

 If any more info is needed let me know.

 Aaron Johnson




Re: Run away processes

2001-04-04 Thread Aaron Johnson

So should the entry in the Guide be rewritten to:

sub UNIVERSAL::AUTOLOAD {
   my $class = shift;
if ($UNIVERSAL::AUTOLOAD !~ /DESTROY$/) {
   warn "$class can't $UNIVERSAL::AUTOLOAD!\n";
}
 }

??

Tim Tompkins wrote:

 You don't need to trap DESTROY calls.  But if you're defining an AUTOLOAD,
 you typically want to just return if the subroutine being called is DESTROY.

 Thanks,

 Tim Tompkins
 --
 Staff Engineer / Programmer
 http://www.arttoday.com/
 --

 - Original Message -
 From: "Aaron Johnson" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Wednesday, April 04, 2001 2:48 PM
 Subject: Re: Run away processes

  In a private email someone mentioned that removing the \ before the $
 might
  make the messages more meaningful.  That code was copy and pasted from the
  current guide so if it should be $ and no \$ in front of UNIVERSAL then
 Stas
  might want to know :^)
 
  I changed it out and now it appears that it is all the DESTROY calls that
  are making its way to the error log.  Should these be trapped some where
  else?
  I still don't think this has anything to do with my memory being consumed,
  but I thought it seemed odd that so many things were called with no
 defined
  sub.
 
  Aaron Johnson
 
  Aaron Johnson wrote:
 
   Hello all,
  
   Having some hard ( for me ) to track memory usage issues. We have moved
   our production environment to a new machine with what we thought was
   plenty of memory, but we seem to have an erratic bit of code somewhere
   that eats all the available memory.  We did not have this problem on our
   previous machine, but it was running RH 6.1 and Perl 5.005 so by moving
   to RH 7.0 and Perl 5.6 we have really asked for trouble.
  
   My research shows that it might be in a search routine we have that
   calls in Swish-E, but we can't get a consistent run away process when
   testing.
  
   In "the guide" it is recommended that a sub in the startup.pl file:
   sub UNIVERSAL::AUTOLOAD {
  my $class = shift;
  warn "$class can't \$UNIVERSAL::AUTOLOAD!\n";
}
   to trap undefined sub routines might help find the problem.  I added
   that code and now I am getting a laundry list of "bad" calls.  Here is
   just a short list:
  
   Apache::ASP::Server=HASH(0x929ebc4) can't $UNIVERSAL::AUTOLOAD!
   Apache::ASP::Collection=HASH(0x91d3374) can't $UNIVERSAL::AUTOLOAD!
   Apache=SCALAR(0x8d61160) can't $UNIVERSAL::AUTOLOAD!
   Apache::ASP::GlobalASA=HASH(0x91d31d0) can't $UNIVERSAL::AUTOLOAD!
   Errno=ARRAY(0x8317564) can't $UNIVERSAL::AUTOLOAD!
   DBI::DBI_tie=HASH(0x83d1d64) can't $UNIVERSAL::AUTOLOAD!
   MLDBM::Serializer::Data::Dumper=HASH(0x917091c) can't
   $UNIVERSAL::AUTOLOAD!
  
   These are all repeated several times.  I ran the same
   UNIVERSAL::AUTOLOAD sub on another server and got very similar results (
   the older RH 6.1 and Perl 5.005 one ) so it seems the errors might be
   "normal" or at least under Apache::ASP.
  
   So the summary of my setup is:
   RH 7.0 ( with all RPM updates and new gcc )
   Perl 5.6
   Apache 1.3.19 compiled with the corrected gcc
   mod_perl 1.25
   Apache::ASP 2.09
  
   If any more info is needed let me know.
  
   Aaron Johnson
 
 




DBIx::Easy

2001-01-15 Thread Aaron Johnson

Has any one  used DBIx::Easy under mod_perl?

I wrote the author and he indicated that someone had reported a memory
leak under mod_perl which they said has been fixed, but not released.  I
am curious if anyone else has had exprience with this module and if they
have used it in conjunction with Apache::DBI.

Should it work seamlessly or does it need to be overridden to work
correctly with it?

Aaron Johnson




Re: File upload of binary format not working

2001-01-12 Thread Aaron Johnson



Joshua Chamas wrote:

 Aaron Johnson wrote:
 
  I have tested other formats and they all work fine.
  For some reason I can't upload binary files anymore.
  There has been no change to the code for the pages that do the upload.
 
  The upload just hangs and never finishes.
 
  Apache 1.3.14
  mod_perl 1.24_01
  Apache::ASP 2.07
  RH 6.1
 

 binary upload of gif seem to work fine for me on:

 WinNT 4.0 SP6, Apache/1.3.12 (Win32) mod_perl/1.24_01-dev, perl 5.004_04
 Linux 2.2.14, Apache/1.3.14, modperl/1.24, perl 5.005_03

 I don't know if its relevant, but you might want to
 binmode the file handle that you are reading just
 in case.  Upgrade to the latest CGI.pm too, as that is
 what handles file uploads in Apache::ASP.  If that doesn't
 work, then see if older versions of CGI.pm work for you,
 then the bug is in there.


It was only a 19K doc I was testing with so I doubt it was a size issue and
yes as my tense indicates the problem has been solved.
I updated to the CGI pm and and all is well.
I was shocked to see that I had version 2.56 still installed on that server.

Upgraded to 2.74 and all seems to be well.

Is there a minimum version requirement for CGI in conjunction with
Apache::ASP?

Thanks for the help.

Aaron Johnson


 Also not that there might be a limit here that's relevant
 on the apache side.  See if you can upload smaller binaries
 fine, that are the same site as text files you can upload.
 It may also be a CGI.pm size limit that needs to be increased.

 -- Josh

 _
 Joshua Chamas   Chamas Enterprises Inc.
 NodeWorks  free web link monitoring   Huntington Beach, CA  USA
 http://www.nodeworks.com1-714-625-4051




Re: Apache::ASP compiling extensions

2001-01-11 Thread Aaron Johnson

Joshua Chamas wrote:

 Aaron Johnson wrote:
 
  If what you are saying is that current EmbPerl code would be able to run
  almost unchanged under ASP that would be very interesting, but presently
  my biggest issues with Apache::ASP are:
 
  - Doesn't "help" with any HTML.
 

 I think I know what you mean, and I'm not sure that's its worth
 developing those things, is this a big priority?

 Embperl:
 table
   tr bgcolor="[+ $row % 2?'gray':'white' +]"
 td align="center"font size="+1"[+ $multi[$row][$col] +]/font/td
   /tr
 /table

  VS.

 ASP:
 table
  % for my $row (0..$#multi) { %
tr bgcolor="%= $row % 2 ? 'gray' : 'white' %"
% for my $col (0..$#array) { %
  td align="center"font size="+1"%= $multi[$row][$col] %/font/td
% } %
/tr
  % } %
 /table


There are other things, like auto href, form elements etc. that are very helpful.  
Perhaps it is the
lack of examples then on how to emulate some of the functions from other modules.


  - QueryString and Form from the Response are separate, this makes a
  programming headache if you are used to Embperl or if you are not sure
  what type of input is coming in for some reason.



 sub Script_OnStart {
   $Form = { %{$Request-{Form}}, %{$Request-{QueryString} };
 }

 does this need a config?


I think to help people coming from CGI or EmbPerl that are used to having all params 
in the same
place that having $Form be automatic is a must have. You can have it be an option in 
the globals if
there is any potential performance hit for doing it I suppose ( could it even be on if 
the passed
information was huge since it is referenced or does it have dereference then build a 
new reference?
).  One less thing to add to "remember/keep track" of.  Remember I am a Lazy Perl 
programmer :^).  I
want things under mod_perl to be as simple as possible for new comers, I think have 
POST and GET in
separate variables is only relevant to people coming from MS ASP platform, which is 
good, but not at
the expense of proficient CGI programmers.


  Shouldn't they just be the same information?
  Is there a need to keep them separate?

 Its the ASP API.  I just ported it.

  - Slow processing time, on the Hello World test it is one of the slower
  ones.  EmbPerl 2.0 is supposed to be even faster then the present
  version.
 

 Huh?  From http://www.chamas.com/bench/hello.tar.gz, so you
 can run it yourself ...

 hello]# ./bench.pl -version -time=15 ASP Embperl

 Test Name  Test File  Hits/sec   Total Hits Total Time sec/Hits  
 Bytes/Hit
    -- -- -- -- 
-- --
 Apache::ASP v2.09 2000 h2000.asp   229.1 3444 hits  15.03 sec  0.004365  
 28997 byte
 HTML::Embperl v2.0a18 2000 h2000.epl   248.7 3732 hits  15.01 sec  0.004022  
 28809 byte
 Apache::ASP v2.09  hello.asp   395.1 5933 hits  15.02 sec  0.002531  
 241 bytes
 HTML::Embperl v2.0a18  hello.epl   461.4 6933 hits  15.03 sec  0.002167  
 219 bytes

 Apache Server Header Tokens
 ---
 (Unix)
 Apache/1.3.14
 OpenSSL/0.9.6
 PHP/4.0.3pl1
 mod_perl/1.24
 mod_ssl/2.7.1

 PERL Version: 5.00503

 Operating System: Linux 2.2.14-5.0smp (root@porky) (gcc egcs-2.91.66) #1 2CPU [gate]

 Sorry, I can't get it much faster on hello world, Embperl is written
 in C, Apache::ASP in perl.  But check out the h2000 tests, much more
 representative of real world templates, not just startup time.


My bad, I hadn't looked at the latest results and I wasn't reading the h2000 results 
correctly.


  - Poor error reporting.  This seems to be possibly a resurfaced bug, but
  when use strict is turned on ( not the global one, but on a per page
  level ) when testing a page for compliance it gives no intelligent error
  message as to where the problem might be.  I see in the docs where this
  has been addressed (fixed) before.

 I haven't seen this in a while, give me a test script  I'll fix it.


%
use strict;
$greeting = "Hello";
print "$greeting";
%
( used Apache::ASP 2.03 and it worked correctly, 2.07 on a different machine and it 
didn't )

This gets me undefined subroutine as the error message.  If I comment out 'use strict' 
it runs fine.

I am getting different messages on more complex pages, but this was working correctly 
before, but I
am not sure when it broke. ( post 2.03 maybe )


  - No automatic variable clean up.  I think EmbPerl runs each page as its
  own package to keep things "clean" is that possible under Apache::ASP?
 

 ASP does have a UniquePackages feature that could possibly make use
 of this garbage collection, but then you are not in the same package
 as global.asa where you get to init easy to use globals  such,
 its a trade off.

 To do things really cleanly, keep one global hash for per
 process data, and then undef it in Scri

File upload of binary format not working

2001-01-11 Thread Aaron Johnson

I have tested other formats and they all work fine.
For some reason I can't upload binary files anymore.
There has been no change to the code for the pages that do the upload.

The upload just hangs and never finishes.

Apache 1.3.14
mod_perl 1.24_01
Apache::ASP 2.07
RH 6.1

Has anyone else had this problem?




Re: File upload of binary format not working

2001-01-11 Thread Aaron Johnson

I guess putting my name on this would have been nice :^)

There is nothing in the log file indicating any errors on the upload
process and the browser just hangs.  Both NN and IE.

Aaron Johnson

Aaron Johnson wrote:

 I have tested other formats and they all work fine.
 For some reason I can't upload binary files anymore.
 There has been no change to the code for the pages that do the upload.

 The upload just hangs and never finishes.

 Apache 1.3.14
 mod_perl 1.24_01
 Apache::ASP 2.07
 RH 6.1

 Has anyone else had this problem?




Re: Apache::ASP compiling extensions

2001-01-10 Thread Aaron Johnson

If what you are saying is that current EmbPerl code would be able to run
almost unchanged under ASP that would be very interesting, but presently
my biggest issues with Apache::ASP are:

- Doesn't "help" with any HTML.

- QueryString and Form from the Response are separate, this makes a
programming headache if you are used to Embperl or if you are not sure
what type of input is coming in for some reason.
Shouldn't they just be the same information?
Is there a need to keep them separate?
Why don't other modules do it that way if there is?

- Slow processing time, on the Hello World test it is one of the slower
ones.  EmbPerl 2.0 is supposed to be even faster then the present
version.

- Poor error reporting.  This seems to be possibly a resurfaced bug, but
when use strict is turned on ( not the global one, but on a per page
level ) when testing a page for compliance it gives no intelligent error
message as to where the problem might be.  I see in the docs where this
has been addressed (fixed) before.

- No automatic variable clean up.  I think EmbPerl runs each page as its
own package to keep things "clean" is that possible under Apache::ASP?

- No auto form fillin.  I know this has been discussed, I have even made
crude code that allows it.

To be fair I better list some of what I like:

- Script_OnStart and Stop: This makes it easy to build headers and
footers for even complex applications.
- Built in Session handling
- Only one type of tag to remember ( % ), well ok two if you count %=

There are others, but those are the main ones I can think of off the top
of my head.

I think making it do its job better and faster is more important then
trying to allow for other delimiters IMHO.

Aaron Johnson

Joshua Chamas wrote:

 Hey,

 I am considering long belated compile time extensions
 that would allow at least partial handling of other languages
 formats like Cold Fusion, XSP, Embperl, ... a developer would
 be able to rewrite a template at compile time into ASP.

 Here's what I have in mind:

 PerlSetVar TagParseMatch ^xsp:
 ## for XSP conversion of xsp:logic.../xsp:logic
 # global.asa
 sub Script_OnTagParse {
my($tag, $begin, $args) = @_;
if($tag eq 'xsp:logic') {
   my $replace = $begin ? '%' : '%';
} ...
 }

 PerlSetVar TokenParseMatch [+,+],[*,*]
 ## for Embperl conversion of [* *] type constructs
 # global.asa
 sub Script_OnTokenParse {
my $token = shift;
if($token eq '[*') {
   '%';
} elsif($token eq '*]') {
   '%';
} ...
 }

 The results would then be inserted into the parse stream
 for ASP before other language parsing is done.
 Once compiled, there would be no extra overhead to
 running the code, unlike with XMLSubsMatch.  XMLSubsMatch
 will continue to be the only way to handle the text
 contained within a tag like tag text /tag.

 So what do you think?  Will anyone use this?

 -- Josh




Best way to handle gobal hash assignment under Apache::ASP

2001-01-08 Thread Aaron Johnson

I have a configuration hash that controls all the aspects of my
application.

It is updated while the server is running so it needs to be "refreshed"
for all processes.

What is the best way to share it globally and insure that updates are
read by all processes?

I currently store the hash using the Storable module so it is always in
a hash ( well ok a hash reference ) format, that is no database access
or ini file to modify/keep track of.  When updates are made the hash is
saved in the Storable format.

I have tried some of the suggestions outlined by Stas on the Perl Month
web site, but I am getting inconsistent results. (
http://www.perlmonth.com/columns/perl_apache/perl_apache.html?issue=11 )

I need to have the values available inside of several preloaded modules
as well as at the page level.

The configuration file is working great, expect for having to reboot
when changes are made.

Aaron Johnson




Re: File name conversion

2000-12-11 Thread Aaron Johnson

That is just what I was looking for.

I just modified the $r-filename and left $r-uri untouched.

10 lines of code and I have it doing exactly what I needed and Apache::ASP reads
the correct file.
I still have the $ENV{REQUEST_URI} to check for the orginal name requested, there
by allow me to set options based on it.

I see now it is in the Guide as well at:
http://thingy.kcilink.com/modperlguide/snippets/PerlTransHandler_example.html

Not knowing what I needed to do was called (or what phase it was best handled) was
the root of my problem.

Thanks!

Aaron Johnson

darren chamberlain wrote:

 Hi Aaron,

 Check out the section titled "Using a Translation Handler to Change the
 URI" in Chapter 7 of the Eagle book, at
 http://www.modperl.com/book/chapters/ch7.html#Using_a_Translation_Handler_to_C.

 Aaron Johnson ([EMAIL PROTECTED]) said something to this effect:
  Is there a module that allows you to translate the file name into
  something else, but keeps the requested filename in an enviroment
  variable or other location?

 (darren)

 --
 So far as a man thinks, he is free.




[OT] Re: 'why mod_perl' rebate anybody?

2000-12-11 Thread Aaron Johnson

Actually in some context rebate will do.

One meaning of rebate is:
Middle English rabet, from Old French rabat:
recess in a wall, act of beating down,
from rabattre,
to beat down again;

Is rebate in the sense of the word that the amount is reduced an American thing?

Aaron Johnson

[EMAIL PROTECTED] wrote:

 Er. I think you mean 'rebuttal'.
 I don't know what kind of rebate anyone's expecting from mod_perl, since it's free.
 In fact, more people might be expecting to pay for it ;-)

 Tom




File name conversion

2000-12-10 Thread Aaron Johnson

Is there a module that allows you to translate the file name into
something else, but keeps the requested filename in an enviroment
variable or other location?

For instance, say I request
http://www.mydomain.com/myfile.html
That works fine and is a real file.
Now I want to request:
http://www.mydomain.com/abc_myfile.html

abc_myfile.html is not a real file.  I need to be able to access the
real name via $r-filename, but have something telling me the original
request had abc_ as a prefix.  I need to use the prefix to set options
in the page under Apache::ASP.

If I was going to stay on an OS that would support symlinks I would just
use symlinks for the different names and all would be fine, but for NT
this is not doable, or at least doesn't seem to be.

I see where I can get at the $r-filename value and modify it, but I
hope to be able to do the translation before Apache::ASP gets a hold of
it so I don't have to modify the Apache::ASP script.

Can I chain the handlers?
Does altering the $r-filename alter the %ENV in anyway?


Aaron Johnson






Dependent modules

2000-12-07 Thread Aaron Johnson

I saw reference in some of the advocacy thread to having some way to
list what modules are dependent on others.  When I use CPAN (the module
not the site) to install some modules it automatically installs the
other required modules, but I assume this only works with modules that
are on CPAN (the site not the module).  If a module has a dependency on
an item outside of CPAN shouldn't CPAN allow for a hook or something
that can tell CPAN where to look for a dependency?

I also notice that not all modules will auto install dependent modules,
i.e. Apache::ASP.  But most will.  I suppose this is all documented some
where, but since I don't have anything on CPAN currently I haven't
really looked.

Did I miss understand the comments inside of the other thread?

Aaron Johnson



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Alliance? WAS - Re: RFC: mod_perl advocacy project resurrection

2000-12-07 Thread Aaron Johnson

What about working with ActiveState?  I know they were primarily Windows
focused, but they now have Linux and Solaris versions of Perl pre compiled.
mod_perl can now be gotten to work with the latest ActivePerl build (622) for
Windows.
(thanks to Randy Kobes, or at least I think that is who has pushed for this)

I have to admit that until their compile worked with mod_perl I saw them as
'evil' through the eyes of Perl.

ActiveState (c|w)ould give credibility to the mod_perl from a business
standpoint.
ActiveState also has the new Komodo IDE which is a cross platform IDE for Perl
and Python.  It uses the Mozilla engine.
http://www.activestate.com/Corporate/Communications/Releases/Press974947521.html

(for the seperate discussion of GUI interfaces)

Should someone try to form an alliance with ActiveState to insure they don't
ignore mod_perl users or want to be users?

Aaron Johnson

Stas Bekman wrote:

 Well as you've probably figured out, based on the load of email from me,
 I've dropped my last job, in order to finally finish the mod_perl book,
 have some rest and make a push to mod_perl.

 Yesterday I've updated the stats page:
 http://perl.apache.org/netcraft/ and the results are so-so, we go down on
 the number of domains. Which I suppose mainly caused by people reading the
 guide and deploying the front-end proxy solution, thus making mod_perl
 un-seen by various scanners like netcraft.

 In Paris we couldn't hire a single mod_perl programmer, because people
 don't even know what that. They know a lot about php and ASP. It's true
 that they don't even know what's Perl :(

 But, you all know that php pretty much takes over. Why? For two reasons:
 1) initial corporate pushing (press/ads)
 2) once well known, the word of the mouth does the rest.

 mod_perl lucks the corporate money/PR to get pushed. But we can still work
 on the exposure, which will bring corporate money/PR thru the word of the
 mouth.

 Luckily Matt has got sick of waiting for someone to work on the advocacy
 of mod_perl and he has just taken over it. Having a good informational
 site is good, but it's not enough. We need to solve the problem of people
 to find this site and wanting to use mod_perl. Solution? Spreading the
 word.

 I see two main streams:
 1) Online zines.
 2) Conferences.

 I think that we should start working on locating ezines wanting to publish
 mod_perl related articles (preferrably for a fee, to give incentives for
 others to write) and conferences where mod_perl can be relevant. The data
 is to be collected and distributed to the people who wish to advocate
 mod_perl, thru written articles and conference classes. I suppose that we
 will also look for companies who want to order mod_perl classes and find
 the teachers in the appropriate areas.

 May be we could organize some certification classes, to give more PR to
 mod_perl.

 I suppose that much more can be done. Comments are welcome.

 _
 Stas Bekman  JAm_pH --   Just Another mod_perl Hacker
 http://stason.org/   mod_perl Guide  http://perl.apache.org/guide
 mailto:[EMAIL PROTECTED]   http://apachetoday.com http://jazzvalley.com
 http://singlesheaven.com http://perl.apache.org http://perlmonth.com/

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: RFC: mod_perl advocacy project resurrection

2000-12-05 Thread Aaron Johnson

mod_perl is NOT PHP.  It wasn't meant to be.
PHP allows for embedding a scripting language inside of HTML and allows for some
"neat" things.  It is also I believe easier to install and setup then a related
mod_perl server.
Reasons/questions of new users:
1) You have to get all kinds of modules and install them just to get to a usable
environment
(lets face it you can't do much with a fresh install on mod_perl unless you already
know mod_perl)
2) Which embedded perl code should I use if I want one? (Embperl, Apache::ASP,
Mason, etc.)
3) What security module do I use?
4) How do I set up session tracking?
5) What good is session tracking?
6) How do I access a database?
7) How do I get mod_perl to work with x database?

Yes some of this is in the guide, but at some point it becomes to easy just to
point a user a document and assume three things:
1) The guide is written generic enough that users at any level can understand it
2) The "real" question is locatable even if the person doesn't know the "real"
question
3) The guide is in a language that is familiar to them.

I am all for advocating the use of mod_perl, but the basics of setup, install and
usability are always going to be key.

Does anyone have any figures on how long it takes to setup a mod_perl server vs. a
php server?
(correctly, not just running)

Before we determine whether to advocate we need to term what and how to advocate.

I have been using mod_perl on Windows and Linux for the last 3 years.  I find it be
an extremely powerful addition to a normal apache server, but the tool kit is too
large and diverse for most people that are simply looking to get a little dynamic
scripting done.

My personal vote for how to advocate, would be better summaries of the various
modules and how they can be used in real life scenarios.
i.e. the thread a few months ago about have a summary of all the embedded Perl
modules (Mason, Embperl, Apache::ASP etc.) outlining their strength and weaknesses
in laymens terms if possible.

We are also advocating the use of Perl which should be much easier since there are
numerous books and example code available in print and online that will work inside
of mod_perl with little or no change.

I just checked out the PHP site and their online manual allows for user comments
that are displayed at the end of each page.  Hmm

Aaron Johnson

martin langhoff wrote:

 kevin montuori wrote:

additionally, i think that some consideration should be given to
how mod_perl is packaged.

 I think it's of crucial importance the fact that a distro as widespread
 as RHLinux 6.x had mod_perl messed up. That has forced quite a lot of
 developers that were trying to get their feet wet with mod_perl to get
 in a complex compile sequence. That's a source of 'bad reputation', and
 of php developers, as the included php was old but working ;)

 I don't know how messed up are other distros regarding apache/mod_perl,
 but making sure the main distros *do* get it right is paramount to make
 mod_perl catch.

 Another item that we should really have is a good (and somehow
 sanctioned) RPM that replaces the apache rpm (or deb) included in broken
 distros. Then we can include in the guide and related pages a link for
 [broken-distro-name] users, so they get a suitable replacement with a
 similar config. That's an important issue, because a redhat user has
 other non-standard modules included in his rpm, such as PHP, and
 compiling a *complete* apache, with mod_perl, php and the kitchen sink
 is a daunting task -- and too high an entry price.

 anyway, not an easy task ... mmhhh..

 martin

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: WebDAV support in mod_perl

2000-11-29 Thread Aaron Johnson

Is the HTTP::DAV module of any use?  I just ran across it in TPJ.

http://theoryx5.uwinnipeg.ca/CPAN/data/HTTP-DAV/DAV.html

Aaron

Joao Pedro Goncalves wrote:

 Hi, is there any current project going on for using the WebDAV protocol
 in
 mod_perl, something like Apache::WebDAV?

 I am familiar with the mod_dav efforts however they seem to be oriented
 to
 filesystem repositories and i would like to use WebDAV in a more dynamic
 environment such as repositories being in a database, or for supporting
 new stuff like Outlook HTTPmail, that uses WebDAV to connect to Hotmail.

 If not, is there any people out there interested in starting one?

 Core features of the WebDAV protocol already have several CPAN modules
 that would help
 its development, such as locking and XML processing.

 Thanks in advance,
 Joao Pedro

 --
 João Pedro Gonçalves
 www.sapo.pt

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: Using MHonArc inside of mod_perl

2000-11-29 Thread Aaron Johnson

Thanks for the replies from people on the list.

I solved my problem with the suggestion from Chris Nokleberg.

He suggested the IO::String module.  It did the trick.

I had been using the qx function previously, but I needed variables from
within my module to be available inside of MHonArc.

Aaron Johnson

Ask Bjoern Hansen wrote:

 On Mon, 27 Nov 2000, Aaron Johnson wrote:

  I am trying to get the MHonArc package to work in conjunction with an in
  house module.
  When MHonArc (http://www.mhonarc.org) is run and told to process a
  single file instead of a directoy full of files, it sends the output to
  STDOUT which inside of mod_perl in this case is the browser.  I am using
  the process_input() function as outlined in the MHonArc mailing list
  archives.
 
  I need to save the output to a variable.  [...]

 What are you trying to do? It sounds an awful like you're doing
 whatever it is the wrong way. :)

 My brain is running in powersave mode, so maybe I am missing
 something, but why can't you just use $foo = qx[mhonarc ...] or open
 FOO, "mhonarc ...|"? ... if you really want to call mhonarc for each
 request. :)

  - ask

 --
 ask bjoern hansen - http://ask.netcetera.dk/
 more than 70M impressions per day, http://valueclick.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Using MHonArc inside of mod_perl

2000-11-27 Thread Aaron Johnson

I am trying to get the MHonArc package to work in conjunction with an in
house module.
When MHonArc (http://www.mhonarc.org) is run and told to process a
single file instead of a directoy full of files, it sends the output to
STDOUT which inside of mod_perl in this case is the browser.  I am using
the process_input() function as outlined in the MHonArc mailing list
archives.

I need to save the output to a variable.  It was suggested by Earl Hood
(author of MHonArc) that I tie a string to a filehandle and then dup the
filehandle to STDOUT.   This sounds great, but I am unsure where to
place the code that will allow for this or how this needs to be done
with mod_perl. (I read perltie and perlopentut, but it didn't light any
bulbs). I got some results, but none that produced the desired results.
The closest was getting the output to be directed to the resulting HTML
page, but not the variable.

I saw a email from 97 in the mod_perl archives that discussed untie
*STDOUT and then retying it back to Apache after the section of code was
complete, but it showed STDOUT being linked to a file open, how could I
assign that to a tied string then a filehandle as suggested by Earl
Hood? Is anything like this bulit into mod_perl or another module at
this time?

http:[EMAIL PROTECTED]

The process_input function is running under mod_perl.
If any other information is needed please let me know.

I have a horribly ugly hack working currently, but it prevents MHonArc
from running in a normal manner (i.e. processing mailinglists)

Aaron Johnson


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




How do I redirect STDOUT to a string WAS Using MHonArc inside of mod_perl

2000-11-27 Thread Aaron Johnson

After one response and my own re-read of my first email, it appears that
I have asked far too
vague a question.

The correct question is:
How do I redirect STDOUT to a string?

A suggestion was to tie a string to a filehandle and dup the filehandle
to STDOUT.
Is that valid?
If it is, how in blue blazes do I do that?
I read the perltie docs, the perlopentut and others I just don't see it.

I will re-read them and hope my light bulb works.

If anyone can point me to another source of information I would be
grateful.
Are there any modules for such oddness?

I am posting to the mod_perl list in case there are any gotchas doing
this under mod_perl.  I realize it is border line off topic.

I have MHonArc doing what I need it to, but it required a butcher knife
when all I think I need is a butter knife.

Aaron




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: [OT?] Cross domain cookie/ticket access

2000-09-08 Thread Aaron Johnson

Well even if I thought it might be possible with a single cookie the user
agents are by
by RFC2109 supposed to not allow it so even if I got something to work there is
no guarantee that it will work in the future, since it will most likely be a
security hole of the user agent.
See RFC2109 section 8.3 - Unexpected Cookie Sharing

Thanks, Simon, for the RFC number it really helped.

So based on some other responses here is my new idea -

Each machine has a login screen that is custom to its "app".  It shares the
login information via LDAP or SQL for user information across the different
domains.

The user will only see the login app if they do not have a valid session or
cookie for that app/domain

The user gives user name and pass and are authenticated.  The user, once
authenticated is updated in the "session" table as being online and are given a
unique number and various information about them is stored under that key (user
name, pass, time of access, IP*, etc.).

When the user on domain1.net is given a link to domain2.net we could do one of
two things:
a) the link actually goes to a local page that then pulls the unique code for
that user and appends it to the
URL for the domain2.net site and they are sent with the unique code via post.
domain2.net then looks up the info for unique code in the shared session
database.  Along with the code as the key the session database also would hold
the user name and "clearance" of the user (possibly other fields like IP) and
the server would also check the HTTP_REFERER  to see if it is in the "valid"
list.

- or -

b) The link to domain2.net or domain3.net is pre appended with the unique code
when the navigation is generated and we rely only on the HTTP_REFERER.

(a) is a little more paranoid and doesn't require processing on every page to
add the code to the off domain URLS, but requires more "work" to get the person
to the correct URL.

(b) Is certainly quick and dirty, but has more potential to expose the unique
code.

Is it hard to spoof a HTTP_REFERER?
Is it as easy as sending a modified header?

domain2.net once it has received the URL will create it owns session/cookie
information for the user based on the information in the session database and
subsequent requests to that domain would automatically be passed to the correct
URL with out creating session information again.  ( I am basing that off
existing work with Apache::ASP and app entry points )

Any major flaws with this plan or suggested improvements?

Aaron Johnson

Simon Rosenthal wrote:

 At 11:37 PM 9/7/00 -0600, Joe Pearson wrote:
 I thought you could set a cookie for a different domain - you just can't
 read a different domain's cookie.  So you could simply set 3 cookies when
 the user authenticates.

 I don't think you can set a cookie for a completely different domain, based
 on my reading of RFC2109 and some empirical tests ... it would be a massive
 privacy/security hole, yes ?

 - Simon

 Now I'm curious, I'll need to try that.
 
 --
 Joe Pearson
 Database Management Services, Inc.
 208-384-1311 ext. 11
 http://www.webdms.com
 
 -Original Message-
 From: Aaron Johnson [EMAIL PROTECTED]
 To: [EMAIL PROTECTED] [EMAIL PROTECTED]
 Date: Thursday, September 07, 2000 10:08 AM
 Subject: [OT?] Cross domain cookie/ticket access
 
 
  I am trying to implement a method of allowing access to three separate
  servers on three separate domains.
  
  The goal is to only have to login once and having free movement across
  the three protected access domains.
  
  A cookie can't work due to the limit of a single domain.
  
  Has anyone out there had to handle this situation?
  
  I have thought about several different alternatives, but they just get
  uglier and uglier.
  
  One thought was that they could go to a central server and login.  At
  the time of login they would be redirected to a special page on each of
  the other two servers with any required login information.  These pages
  would in turn return them to the login machine.  At the end of the login
  process they would be redirected to the web site they original wanted.
  
  This is a rough summary of what might happen -
  
  domain1.net - user requests a page in a protected directory.   They
  don't have a cookie.
  They are redirected to the cookie server.  This server asks for the user
  name and pass and authenticates the user.  Once authenticated the cookie
  server redirects the client to each of the other (the ones not matching
  the originally requested domain) domains.  This redirect is a page that
  hands the client a cookie and sets up the session information.
  domain2.net gets the request and redirects the user to a page that will
  return them to the cookie machine which will add the domain2.net to the
  list of domains in the cookie. And then the process will repeat for each
  domain that needs to be processed.
  
  Am I crazy?  Did I miss something in the documenta

[OT?] Cross domain cookie/ticket access

2000-09-07 Thread Aaron Johnson

I am trying to implement a method of allowing access to three separate
servers on three separate domains.

The goal is to only have to login once and having free movement across
the three protected access domains.

A cookie can't work due to the limit of a single domain.

Has anyone out there had to handle this situation?

I have thought about several different alternatives, but they just get
uglier and uglier.

One thought was that they could go to a central server and login.  At
the time of login they would be redirected to a special page on each of
the other two servers with any required login information.  These pages
would in turn return them to the login machine.  At the end of the login
process they would be redirected to the web site they original wanted.

This is a rough summary of what might happen -

domain1.net - user requests a page in a protected directory.   They
don't have a cookie.
They are redirected to the cookie server.  This server asks for the user
name and pass and authenticates the user.  Once authenticated the cookie
server redirects the client to each of the other (the ones not matching
the originally requested domain) domains.  This redirect is a page that
hands the client a cookie and sets up the session information.
domain2.net gets the request and redirects the user to a page that will
return them to the cookie machine which will add the domain2.net to the
list of domains in the cookie. And then the process will repeat for each
domain that needs to be processed.

Am I crazy?  Did I miss something in the documentation for the current
Session/Auth/Cookie modules?

I did some hacking of the Ticket(Access|Tool|Master) Example in the
Eagle book, but the cookie limit is keeping it from working correctly.
( BTW: I already use it for a single server login and it works great. )

Any information would be appreciated.

Aaron Johnson





Re: question on code snippet in mod_perl guide

2000-08-31 Thread Aaron Johnson

I don't work on Oracle so I will speak from my experience with MySQL.  MySQL
servers time out after the 8 hour standard disconnect for inactivity (this
can be adjusted in your my.conf file).  To compensate for this we now run our
own connect checks for a valid dbh handle before it goes it all the trouble
to make one along with Apache::DBI

We have not had any more issues with the database connects since we moved to
this method.  We do a ping and validate the dbh handle rather then blindly
accessing the dbh handle since Apache::DBI will only validate the dbh handle
on a connect.

Aaron Johnson

Perrin Harkins wrote:

 On Thu, 31 Aug 2000 [EMAIL PROTECTED] wrote:
  What I think is going on is that the script gets killed by Oracle for
  being idle and tries to ping the connection, but the ping fails.

 It is supposed to reconnect when the ping fails.  I've had problems
 getting reconnects to Oracle 8 working.  The "solution" we ended up with
 was to make processes that can't reconnect send an error page and
 exit.  New processes are able to connect.  I'm not sure what causes this
 problem.

 Since your problem is caused by your processes being idle for too long,
 this may go away when you move out of testing mode into a public release.
 You might want to tweak your MinSpareServers settings so that you won't
 have lots of idle processes hanging around.

  Rebild your mod_perl with the EVERYTHING=1 flag.  That will get rid
  of the above error message.
 
  So I have to re-install it?  Is there anything I need to do when I
  rebuild it?  Or do I just need to reinstall mod_perl as it's done in
  the documentation?

 Just rebuild it and re-install as it shows in the docs.

 - Perrin




Storable problem?

2000-08-22 Thread Aaron Johnson

I made some changes to a module to use a hash stored with the Storable
module.  On our development server all is well, but when I moved it to
the production server I was greeted with this when I stopped and
attempted to restart the server:

Out of memory!
Callback called exit.
END failed--cleanup aborted at /dev/null line 26.
Callback called exit at /dev/null line 26.

The only change in configuration was the use of the Storable module
versus an embedded hash.  Like I said it works great on the development
machine.

I compared the too servers versions for all loaded modules and the perl
stratup scipts and everthing is the same or newer on the production
machine, except DBI which is 1.13 vs. 1.14.

What can I run to get more information then the above?

Storable 0.7.0.2
mod_perl 1.24
Apache 1.3.12
perl 5.005_03

Aaron Johnson




Re: Storable problem?

2000-08-22 Thread Aaron Johnson



Aaron Johnson wrote:

 I made some changes to a module to use a hash stored with the Storable
 module.  On our development server all is well, but when I moved it to
 the production server I was greeted with this when I stopped and
 attempted to restart the server:

 Out of memory!
 Callback called exit.
 END failed--cleanup aborted at /dev/null line 26.
 Callback called exit at /dev/null line 26.

I had transfered them to the other machine with ftp set to ASCII thereby
botching the binary storage of the storable files. DUH!

Thanks to those who responded to me personally.

Aaron


 The only change in configuration was the use of the Storable module
 versus an embedded hash.  Like I said it works great on the development
 machine.

 I compared the too servers versions for all loaded modules and the perl
 stratup scipts and everthing is the same or newer on the production
 machine, except DBI which is 1.13 vs. 1.14.

 What can I run to get more information then the above?

 Storable 0.7.0.2
 mod_perl 1.24
 Apache 1.3.12
 perl 5.005_03

 Aaron Johnson




Form Filling - was Re: Templating System

2000-07-28 Thread Aaron Johnson

There is the HTML::FillInForm module that will pre fill your forms.
It is pure Perl.  It seems to work well, haven't stress tested it yet.

I am using it in conjunction with Apache::ASP, but haven't hacked
the Apache::ASP module to include it as a function.  It is much easier
to work with now that Joshua has added the $Response-TrapInclude
function (thank you).  I just keep my form in an include file, read it in to
my script/page
with the $Response-TrapInclude then send the it through HTML::FillInForm
with my values I want in the form.

This is all it takes -
use HTML::FillInForm;

my $fif = new HTML::FillInForm;

my $html = $Response-TrapInclude('dbd_form.inc');

my $output = $fif-fill(scalarref = $html,
  fdat = \%form_content);

print "$output";

(note the %form_content is defined previously and contains the from elements
names
as the keys and then the "default" value as the value.)

As far as templating systems go there is NO Perl or "funky" HTML in any of
the forms.

Of course this behavior is built-in and handled extremely nicely in
HTML::Embperl, as far as handling and working with HTML I find HTML::Embperl
to be the most powerful of the ones available.

Drew Taylor wrote:

 Joshua Chamas wrote:
 
  I'll be bringing auto formfilling to the Apache::ASP table
  just as soon as I work out the details with other interested
  parties.  I'm thinking of some kind of $Response-{FormFill}
  attribute, and possibly a FormFill config setting, to specify
  runtime form filling, then there's that whole ASP+ syntax
  to possibly support as well.
 That would be most excellent! I have yet to take more than a cursory
 look at Apache::ASP and Embperl, so I don't know what feature set they
 offer. I think the thing that is most difficult to currently do in my
 modules is the form pre-filling.

 In my case, it is imperative to save all input that the user entered,
 except for fields incorrectly entered or missing. I currently do it my
 grabbing form input, do some basic checking for each group of info, save
 it to the DB, and then display either for form again with the
 missing/error fields highlighted or show a response.

 Anything that would make the above scenario easier would get a thorough
 look in future templating system decisions. In short, I'm looking for a
 good, FLEXIBLE application framework. I'm tired of writing it all
 myself. And while it has been excellent experience, I say build on the
 backs of other giants. :-)

 I spent the first 1.5 hours today reading all the threads of "templating
 system", and it was worth every second. :-) IMHO, the lack of a
 "standard" framework is the perl community's biggest drawback. But then
 we also have many systems to choose from, so that is a big benefit. As
 someone else mentioned, interoperability, even in just it's a most basic
 form, would be a major feature.

 Oh yeah, and throw in a CMS to boot ;-) Keep up the _excellent_ work
 folks.

 --
 Drew Taylor
 Vialogix Communications, Inc.
 501 N. College Street
 Charlotte, NC 28202
 704 370 0550
 http://www.vialogix.com/




Re: howto config apache to allow perl to filter php pages

2000-07-22 Thread Aaron Johnson

I was thinking about the same thing awhile back.  It was interesting to me that
lots of neat applications are PHP based.  I would like to be able to take the
processed PHP page and include it inside of my mod_perl page.  I was thinking
there are several ways I could handle.  I can have a seperate directory that
process the php files and just use the LWP::Simple to get the page as a
processed string.  Then replace any content with =~ s/blah/cool/ inside of the
mod_perl processed page.  I do this with some cgi programs that I use
currently.  It works ok, but the overhead must be tremendous.  Anybody else done
anything similar?

Aaron Johnson

Page is called ez_archive.html, there is a lot more going on then this simple
post, but this is the crux of what I am saying.
code sample (Apache::ASP based):

%  use LWP::Simple;
my $get_string;
foreach my $key (keys %{$Request-QueryString}) {
$get_string .= $key;
# this should be concated with a  in regular cases, but this cgi
program
# only has one element connected by ':'
# i.e. $get_string .= "$key";
}


my $content = get("http://www.mydomain.com/cgi-bin/ezmlm-cgi?$get_string");

$content =~ s#cgi-bin/ezmlm-cgi#$Session-{Instance}/email/ez_archive.html#g;
$content =~ s#ezmlm-cgi#ez_archive.html#g;
print $content;

%

Rob Tanner wrote:

 --On 07/16/00 16:11:07 -0400 Sam Carleton [EMAIL PROTECTED] wrote:

  I would like perl to process a php page before or after the php
  interpreter get's it hands on the file.  I am trying to add a navbar to
  the PHP code.  How would I go about doing that?
 
  Sam

 The simple answer is wait for Apache 2.x, but since that's just barely
 alpha now, that's a looong [sic] while away.

 The issue in Apache 1.x is that you can use only one handler in any
 particular phase to process you're request.  Thus, php or mod_perl (or cgi,
 depending on how you meant to invoke perl).

 But the real question is why?  I have never done a navbar on a page (most
 of my web work is server app development, not pages), si I may be making
 some wrong assumptions here.  If you are creating the page with a cgi or a
 mod-perl app, I would think you would be able to do the whole thing without
 ever using PHP.

 But, if what you are really doing is displaying a page with server-side
 components, PHP is a much better chice by far than cgi or mod-perl.  What
 are you trying to do that php won't do for you?

 -- Rob

_ _ _ _   __ _ _ _ _
   /\_\_\_\_\/\_\ /\_\_\_\_\_\
  /\/_/_/_/_/   /\/_/ \/_/_/_/_/_/  QUIDQUID LATINE DICTUM SIT,
 /\/_/__\/_/ __/\/_//\/_/  PROFUNDUM VIDITUR
/\/_/_/_/_/ /\_\  /\/_//\/_/
   /\/_/ \/_/  /\/_/_/\/_//\/_/ (Whatever is said in Latin
   \/_/  \/_/  \/_/_/_/_/ \/_/  appears profound)

   Rob Tanner
   McMinnville, Oregon
   [EMAIL PROTECTED]




Re: still can't find mod_perl for win9x/NT

2000-06-08 Thread Aaron Johnson

 ftp://theoryx5.uwinnipeg.ca/pub/other/perl-win32-bin-0.6.exe

That is the full URL for the file.
It contains Perl Apache and mod_perl + tons of other modules.

As for mod_perl by itself, I haven't seen that yet, and that is very ify
because you have to use the same compiler for the modules as you did Perl.

Aaron Johnson

Walter Hissink wrote:

 Hello,
 I still can't find the mod_perl for win32.
 On the mod_perl website now no mention is even made about that specific
 port.

 Does anyone know where i can get me a mod_perl which works in the win32
 version of apache ??

 Hope someone can help.

 Walter




Re: windows 98 apache and perl

2000-04-10 Thread Aaron Johnson

Harald,

Randy Kobes has been keeping the Win32 mod_perl crowd happy for the last
few months with his compile that is available at:

ftp://theoryx5.uwinnipeg.ca/pub/other/
(the link is on the perl.apche.org home page as well :^) ).

Jeffery Baker has a version as well, but it is not as up to date.

Compiling on the Win98 is not an easy task and unless there is somthing
specific you need to have compiled in I would recommend using one of the
above.

Someone please correct me if I am wrong, but Randy's is compiled with VC 6
and Jeffery's is compiled with VC 5.0, which if you have VC and want to
compile in additional modules you would want to have the same compiler.

I have compiled my own under NT with VC 5.0 and used it on 9x with no
problem.  I have also installed and tested both of the above in the past
and they have worked very well.

Aaron Johnson



Light Software wrote:

 Is it possible to install apache and perl succesfully on windows 98 ?

 I have tried and failed !

 I want to run server-side perl script on apache...

 Is there anyone in this mailing list that has installed apache and perl
 succesfully on windows 98 so that this is possible ?

 Please let me know...

 Please also send a copy of your reply to:
 [EMAIL PROTECTED]

 Greetings
   Harald

 __
 Get Your Private, Free Email at http://www.hotmail.com




Re: Perl 5.6 and mod_perl

2000-03-31 Thread Aaron Johnson

Jeff,

These issues are very resent in the archives of the mailing list.
Did you look there?
Did you look on CPAN for the latest copy of mod_perl?

I have mod_perl 1.22 with Apache 1.3.12 and Perl 5.6 on Linux with kernel
2.0.35 with libs that are just as old.  This includes a large number of
additional modules one of which is DBI.

I saw another post that said they were getting seg faults, that can or maybe
caused by a module other then mod_perl.  There was a strange issue with Emperl
that was causing a seg fault on the above, but the author of Embperl quickly
fixed it and it is available in CVS section of Embperl.  May want to see what
you have for handlers and run the server without them to see if it is infact a
mod_perl issue.

I am going to be duplicating on SuSE 6.3 , RH 6.1 and RH 6.0 this week.  I
will post my success stories here, if there are any. :^)

Aaron Johnson

Jeff Stuart wrote:

 Has anyone tried to use mod_perl with perl 5.6 yet?  If so, how did it go?
 Oh, are we still at 1.21 for mod_perl?  If so, when's the next release?  I
 hear that there are some important memory leak fixes in there.

 --
 Jeff Stuart
 [EMAIL PROTECTED]




Perl 5.6 issues?

2000-03-28 Thread Aaron Johnson

I have a sucessfully compiled on Linux (Slackware 3.5) 5.6/1.22/1.3.12 with no
modifications.  All these items worked fine together with 100% pass rate on
tests.

mod_perl - perl Makefile.PL EVERYTHING=1
NON DSO

I have it installed and serving pages with numerous Perl modules.

The two remanining issues for me are HTML::Embperl and SSI.

I have been in contact with Gerald Richter (the author of HTML::Embperl) and he
is looking into it.  See the [EMAIL PROTECTED] mailling list for more
information.

So until that is resolved each child can only serve one request and then dies.
Which is not good if you are running a high traffic site.

I have also noticed that SSI pages are not working.  I notice in the compile
that it says USE_PERL_SSI or something similar, does that in fact mean that SSI
is handled by mod_perl on a mod_perl enabled httpd?  It handles the first SSI
fine, but the page that is called has SSIs inside of it and these cause the page
to "stop". I removed these and then when the included page finishes it does not
return and finish the opening page it "stops" at the end of the include file.  I
believe it causes a segmentation fault and kills the apache child at this point.

Could the segmentation fault be due to the mod_perl code (or more likely changes
in the Perl 5.6 code) and in turn cause the Embperl problems? The Embperl issue
is on file cleanup/close so I am thinking that the same area is handling the
clean up on the SSI page, but the mod_perl test suite shows a pass on SSI. Of
course I am totally guessing here.  (See
http://www.mail-archive.com/embperl@perl.apache.org/ for more information. The
subject is "Compile problems")

I tried the compile with Apache 1.3.9 and it had the same results.

Aaron Johnson

Charles Day wrote:

 H, I removed .../apache/src/modules and it failed "couldn't find
 .../apache/src/modules/standard directory"

 Here was my apache configure script...

 ./configure \
 --prefix=/usr/local/apache \
 --activate-module=src/modules/perl/libperl.a

 There is no libperl.a and here's the ole error message...

 mod_perl.c: In function `perl_handler':
 mod_perl.c:783: `PL_siggv' undeclared (first use in this function)
 mod_perl.c:783: (Each undeclared identifier is reported only once
 mod_perl.c:783: for each function it appears in.)
 make[4]: *** [mod_perl.o] Error 1
 make[3]: *** [all] Error 1
 make[2]: *** [subdirs] Error 1
 make[2]: Leaving directory `/usr/src/apache_1.3.12/src'
 make[1]: *** [build-std] Error 2
 make[1]: Leaving directory `/usr/src/apache_1.3.12'
 make: *** [build] Error 2

 There is a libperl.module, so I tried agian, with...

 --acitvate-module=src/modules/perl/libperl.module

 and low an behold, I get an error message "coundn't find libperl.a"

 LOL

 It installs fine without this --activate-module line, but I think I need
 this.

 I'm trying AddModule modules/perl/libperl.a into Configuration now.

 apache 1.3.12
 mod_perl 1.21
 perl 5.6

 
  -Original Message-
  From: Jim Serio [mailto:[EMAIL PROTECTED]]
  Sent: Monday, March 27, 2000 4:08 PM
  To: Charles Day
  Cc: [EMAIL PROTECTED]
  Subject: Re: perl 5.6/mod_perl 1.22/apache 1.3.12
 
 
   Just spent half the day trying marry these 3.  mod_perl doesn't build.
   DSO/apxs errors as described by others.  Went back to 1.21, apache
 doesn't
   build, PL_siggv errors as described by others.  Don't know what to do
 with
   the modperl 2.0XXX.  I think I'll head back to Mr. stable 5.00503.  Sure
   wish I knew C.
 
  I had initial problems with Apache 1.3.12 and mod_perl 1.21
  but after removing the perl modules dir and installing
  mod_perl 1.22 things compiled without any problems. I
  suggest you try a clean Apache and mod_perl source tree.
 
  Jim
 

 --
 Jim Serio - [EMAIL PROTECTED]
 Producer, World of Coasters




Re: redhat apache and modperl oh my!

2000-01-17 Thread Aaron Johnson

I have had the same exprience as Stas.

The Red Hat RPM uses Dynamic Shared Objects (DSO) for all the
modules.  This is NOT the ideal way to run mod_perl, I am not saying
you can't, but a lot of modules won't preload under these conditions.

my $.02

Aaron Johnson

Stas Bekman wrote:
 
  Clay wrote:
  
   so i am just wanting to know what anyone
   has found out on mod perl not working properly
   under redhat 6.1?
 
 Clay, did you try to find your answer in the list's archives? (hint: at
 perl.apache.org) There is no need to roll the broken record again. Thank
 you!
 
  If you install everything (including modperl) from RedHat's RPMs, no
  problem (I did this on five very different boxes, some new, some
  upgraded). If you try to do it yourself by building from sources, etc,
  ... oh well - then RedHat is in the way and gets all confused..
 
 Gerd, there is no problems to build mod_perl from scratch. I did it with
 all versions from the past 2.5 years I think. Make sure to remove the
 apache and mod_perl RPMs first!!!
 
 ___
 Stas Bekmanmailto:[EMAIL PROTECTED]  http://www.stason.org/stas
 Perl,CGI,Apache,Linux,Web,Java,PC http://www.stason.org/stas/TULARC
 perl.apache.orgmodperl.sourcegarden.org   perlmonth.comperl.org
 single o- + single o-+ = singlesheavenhttp://www.singlesheaven.com



Re: redhat apache and modperl oh my!

2000-01-17 Thread Aaron Johnson

Clay,

Well I agree after seeing your startup.pl that the problem you are
expriencing is not with the DSO, however from past posts with problems
there are several modules that do not play well with DSO.

However as far as any problem with using the Red Hat distributed RPM
of Apache and mod_perl on 6.1 I can not say, I always compile my own.

Aaron Johnson

Clay wrote:
 
 DSO is not the issue
 
 that works just fine
 i know it does,
 the problem seems to be with the default binary packages that redhat 6.1
 comes with
 
 i ve just uninstalled/installed twice same results
 and there is no errors out in the error log
 
 i need this for work or i wouldnt be stressin!



Re: FAQ for NT mod_perl

2000-01-11 Thread Aaron Johnson

mod_perl currently does not run with ActivePerl.

I believe the current status of the patch is it compiles, but does not
run.

Aaron Johnson

"Dickerson, Monty W." wrote:
 
 Please point me to a FAQ document for running mod_perl with
 Apache/ActivePerl on Windows NT? thx.



Embperl with DSO

1999-12-02 Thread Aaron Johnson

I went ahead and compiled my own Apache and mod_perl for Red Hat, but
was curious if there is a solution for using Embperl with DSO and
allowing for the modules to be loaded one time.

I thought I had the above working with the default Red Hat 6.0
Apache/mod_perl, but it was not "permanently" loading the modules. When
I removed refernece to HTML::Embperl from my startup.pl file I got:
Undefined subroutine HTML::Embperl::handler called

Mine is working now, just curious if there is something I could have
done to keep from compiling my own. (one less step in new server setup
and testing)

Aaron Johnson



DBI/Sessions/Embperl

1999-11-27 Thread Aaron Johnson

I am using HTML::Embperl in conjunction with Apache::Session to control
session information and create pages.  I have started to create a module
that will trim the amount of code and keep a connection with MySQL
engine alive.  Below is a section of my module.
My problem is that when I connect again with a different computer my
connect all my previous connects are changed to the last one.

So in short:

Can I assign each session a seperate "permanent" connection?

Aaron Johnson

# I pass this - $dbh = db_connect( { database = "$udat{location}",
change = 1, } );
# for those of you who haven't used HTML::Embperl $udat{location} is
session data

sub db_connect {
 my $pd = shift;
 if ($pd-{change}) { db_disconnect };
 if ($pd-{change} || !$dbh) {

 $dbh=DBI-connect(
"dbi:mysql:$pd-{database}", 'user', 'password', {
 PrintError = 1,
RaiseError = 1,
}
) || die $DBI::errstr;

 return($dbh)
 }

 else {
  # warn "No need to change!\n";
  return($dbh)
 }

}



Re: DBI/Sessions/Embperl

1999-11-27 Thread Aaron Johnson

Ok, but I don't know how to set up unique handlers for each connection.  Where
can I read how to do this.  I own the Writing Apache Modules with Perl and C,
Advanced Perl, Learning Perl, The UNIX Resource Kit, the Win32 Resource Kit,
Programming Perl and Perl in a Nut Shell with the CD.  So if you can reference
a section in one on these I am willing do my homework.  I just haven't a clue
as to where to look.  :^)

Aaron Johnson

Jeff Beard wrote:

 How 'bout this:

 http://perl.apache.org/guide/performance.html#Persistent_DB_Connections

 --Jeff

 At 04:39 PM 11/27/99 -0500, Aaron Johnson wrote:
 I am using HTML::Embperl in conjunction with Apache::Session to control
 session information and create pages.  I have started to create a module
 that will trim the amount of code and keep a connection with MySQL
 engine alive.  Below is a section of my module.
  My problem is that when I connect again with a different computer my
 connect all my previous connects are changed to the last one.
 
 So in short:
 
 Can I assign each session a seperate "permanent" connection?
 
 Aaron Johnson
 
 # I pass this - $dbh = db_connect( { database = "$udat{location}",
 change = 1, } );
 # for those of you who haven't used HTML::Embperl $udat{location} is
 session data
 
 sub db_connect {
   my $pd = shift;
   if ($pd-{change}) { db_disconnect };
   if ($pd-{change} || !$dbh) {
 
   $dbh=DBI-connect(
  "dbi:mysql:$pd-{database}", 'user', 'password', {
   PrintError = 1,
  RaiseError = 1,
  }
  ) || die $DBI::errstr;
 
   return($dbh)
   }
 
   else {
# warn "No need to change!\n";
return($dbh)
   }
 
 }

 Jeff Beard
 Web Systems Engineer
 World Wide Web Associates
 Web: http://wwwa.com
 Phone: 303.545.2399



Followup DBI/Sessions/Embperl

1999-11-27 Thread Aaron Johnson

Below is my new code that seems to work.
I can now connect from Terminal A and B at the same time in different
databases.
Instead of my standard $dbh I used a hash instead.
Any glaring flaws?

Thanks to Joe Beard for his reply that directed me to some helpful
material.

Aaron Johnson

sub db_connect {
 my $pd = shift;

 if ($pd-{change}) { db_disconnect($pd-{database}) };
 if ($pd-{change} || !$dbh{$pd-{database}}) {

 $dbh{$pd-{database}}=DBI-connect(
"dbi:mysql:$pd-{database}", 'user', 'password', {
 PrintError = 1,
RaiseError = 1,
}
) || die $DBI::errstr;

 return($dbh{$pd-{database}})
 }

 else {
  # warn "No need to change!\n";
  return($dbh{$pd-{database}})
 }

}

sub db_disconnect {
 my $db_to_disconnect = shift;
 if ($dbh{$db_to_disconnect}) {
  $dbh{$db_to_disconnect}-disconnect;
  warn "Disconnected from: $db_to_disconnect\n";
 }
}