Ron,
This is a greivous FAQ. Please read the guide at
http://perl.apache.org/guide
You'll find much more than this question answered.
Ed
Ron Rademaker wrote:
Hello,
I'm just starting with mod_perl and I'm using Apache::Registry(). The
second line after #!/usr/bin/perl -w is use
You would think so, however every doc I read (including the one you
pointed out to me) told me that perl gives me a warning:
Variable $foo will not stay shared at
I do use -w so I should get that warning, but I don't. The variable stays
defined, but it doesn't have the value of the old
On Tue, 7 Nov 2000, Ron Rademaker wrote:
Hi,
You would think so, however every doc I read (including the one you
pointed out to me) told me that perl gives me a warning:
Variable $foo will not stay shared at
I do use -w so I should get that warning, but I don't. The variable stays
Just tried, it didn't give me any useful information, I always got any
other warning without PerlWarn on, so I don't think it made any
difference. Anyway, even with PerlWarn on, the error.log still shows
exactly the same output, everything goes well for a while, but then
suddenly my defined($foo)
Are you running with httpd -X ?
What you describe sounds like it "stops working" when it hits a child for
the second time.
As advised, all this is described in the guide. You might want to start
here:
Hi there,
On Tue, 7 Nov 2000, Ron Rademaker wrote:
Just tried, it didn't give me any useful information,...
Try 'httpd -X'.
73,
Ged.
Hi there,
On Mon, 6 Nov 2000, Andrew Chen wrote:
According to my trusty Eagle book, I can chain Perl handlers (by using
$r-pushhandlers(), but can I chain a C handler after a Perl handler??
Not until Apache 2.0, Eagle Book p175, "Chaining Content Handlers".
A C handler either handles the
I just read that part of the guide, for the third time today, but still I
didn't see anything that could help, I don't get any warnings and I'm not
using globals. The problem does occur when trying to use a child more then
once. So when I tried running with httpd -X I got the wrong output the
Then it is definitely variable persistence !
If you really can't track down the bug, you might try posting your code to
the list.
Perhaps someone will spot something you've missed ?
Simon.
From Ron Rademaker [EMAIL PROTECTED]
Date 7
Okay, here's the part where it's going wrong:
my @fields; # The variable that's causing the trouble, should be
undefined after this declaration
my $printedfields = 0;
foreach my $hash_ref (@$data_ref)
{
if (!defined(@fields)) # Passes the second time the child gets a
Sorry if you receive this message twice!!!
-Original Message-
From: Guido Moonen [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November 07, 2000 10:20 AM
To: Mason
Subject: Problem: Number after header
Hi All,
I have a little problem with my Mason site:
IEplore doesn't have
Have you found a workable approach yet? Just curious :-).
- Barrie
Hi there,
On Tue, 7 Nov 2000, Guido Moonen wrote:
I found that the problem is that Mason sends a Number of some
sort at from of the html (after the response header) but i cannot
find where the number gets printed to the output stream.
Something very similar was mentioned on the List a
Hello Alexander,
maybe this one is a rookie-question ;)
Only unsaid questions are rookie-ones :-)
Is your script doing some system() or `command` ? If so, this will explain
the fork/exec-ing you see.
Beware, some modules do make calls to system() or `command`, so check your
It looks like you are trying to determine if an array is empty, in that case
replace
if (!defined(@fields))
with
if (!scalar(@fields)).
- Original Message -
From: Ron Rademaker [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, November 07, 2000 5:26 AM
Subject:
I'm not quite looking for a workaround, I already got one, I'd like to
know why it's going wrong.
Ron
On Sun, 7 Nov 1999, lporcano wrote:
It looks like you are trying to determine if an array is empty, in that case
replace
if (!defined(@fields))
with
if (!scalar(@fields)).
-
I'm not quite looking for a workaround, I already got one, I'd like to
know why it's going wrong.
From the perlfunc page:
defined - Returns a Boolean value telling whether EXPR has a value
other than the undefined value undef. [...] On the other hand, use
of defined() upon aggregates
from the camel book: "Use of defined on aggregates (hashes and arrays) is
deprecated."
so, change
if (!defined @fields)
to
unless (@fields)
and not only be idiomatic, but exhibit the behavior you want :)
but seriously, it's a perl thing, not a mod_perl thing:
#!/usr/bin/perl
sub test {
Okay, thanks (everyone).
On Tue, 7 Nov 2000, Geoffrey Young wrote:
from the camel book: "Use of defined on aggregates (hashes and arrays) is
deprecated."
so, change
if (!defined @fields)
to
unless (@fields)
and not only be idiomatic, but exhibit the behavior you want :)
On Mon, Nov 06, 2000 at 05:49:05PM -0500, Buddy Lee Haystack wrote:
I'm using
RedHat Linux v6.1 on an Intel PII SMP box
Apache v1.3.14
mod_perl v 1.23
Apache::DBI 0.87
DBI v1.13
DBD Pg v0.93
PostgreSQL v6.5.3
The morning after "logrotate" runs on my system, the memory usage
"G.W. Haywood" wrote:
Hi there,
On Mon, 6 Nov 2000, Buddy Lee Haystack wrote:
The morning after "logrotate" runs on my system, the memory usage
increases by about 30 megabytes, and continues to do so after each
weekly run of the "logrotate" utility.
What happens if you then do a
Thank you very much! Now I know why most of the people on this list don't use DSO.
Is there any other work around for this situation other than rotating my logs less
frequently? Maybe a different method of rotating my logs like using the TERM signal
instead of the HUP signal?
Thanks!
Hi,
Sorry but i cannot find the e-mail you are describing, could you please
point to me wich e-mail you referring to?
Greetings,
Guido Moonen
-Original Message-
From: G.W. Haywood [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November 07, 2000 1:04 PM
To: Guido Moonen
Cc:
On Tue Nov 7 09:37:02 2000 -0500 Buddy Lee Haystack wrote:
Thank you very much! Now I know why most of the people on this list don't use DSO.
Is there any other work around for this situation other than rotating my logs less
frequently? Maybe a different method of rotating my logs like
Hi there,
On Tue, 7 Nov 2000, Buddy Lee Haystack wrote:
What happens if you then do a graceful restart?
The logrotate scripts use HUP to restart the server. I don't think
the USR1 would be appropriate for log rotation - according to the
Apache documentation...
Yeah, I read that. I
Hi,
I have compiled mod_perl version 1.24 with apache version
1.3.9; The compilation completes without errors, but whenever I run the
new httpd daemon, I get the following error message:
Syntax error on line 207 of /usr/local/apache/conf/httpd.conf:
Invalid command 'LoadModule', perhaps
Hi there,
On Tue, 7 Nov 2000, Marco Marchi wrote:
Hi,
I have compiled mod_perl version 1.24 with apache version
1.3.9; The compilation completes without errors, but whenever I run the
new httpd daemon, I get the following error message:
Syntax error on line 207 of
On Tue, Nov 07, 2000 at 03:59:34PM +, G.W. Haywood wrote:
I also never build mod_perl as a DSO. For the life of me I can't
understand why so many people do it, and then they act all surprised
when things go wrong.
It is a matter of flexibility, especially if you are a distribution
Is Apache::DBI absolutely necessary if you want to establish persistent
database connection per child?
Thanks,
Jason
-Original Message-
From: David Hodgkinson [mailto:[EMAIL PROTECTED]]
Sent: Monday, November 06, 2000 5:10 AM
To: Jason Liu
Cc: [EMAIL PROTECTED]
Subject: Re:
Has anyone had any problems with failure to write locks on Apache:ASP
under Solaris or any other platform? Getting quite a number of the
following in the log files...
[Tue Nov 7 10:23:11 2000] [error] [asp] [6708] [error] can't write
lock
What happens if you then do a graceful restart?
The memory consumption increases by about 1 megabyte for each child process every time
I issued the USR1 signal. Which is kind of what I expected given Jens-Uwe Mager's
explanation of DSO's failings with mod_perl.
I can always rotate my logs
Hi again,
On Tue, 7 Nov 2000, Buddy Lee Haystack wrote:
Maybe someone should include this information in the Apache
documentation covering the DSO issues. It would be very helpful to
people starting out, such as myself.
It *does* say in the docs that DSO is experimental.
73,
Ged.
Hi there,
On Tue, 7 Nov 2000, Buddy Lee Haystack wrote:
The memory consumption increases by about 1 megabyte for each child
process every time I issued the USR1 signal.
Ugh.
I can always rotate my logs manually, I'm leaning along the lines of
just killing the process, rotating the logs,
I may have missed that, but it dosen't mention the "experimental" nature of DSO in the
"DSO has the following disadvantages:" section of the documentation located at
"http://www.apache.org/docs/dso.html"
"G.W. Haywood" wrote:
Hi again,
On Tue, 7 Nov 2000, Buddy Lee Haystack wrote:
Hi there,
On Tue, 7 Nov 2000, Daniel Little wrote:
Has anyone had any problems with failure to write locks on Apache:ASP
under Solaris or any other platform?
I just grepped one of my logfiles (a small one, about 70 megabytes:)
and there was no occurrence of this message. Linux 2.2.16, Perl
-Original Message-
From: Louis-David Mitterrand [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November 07, 2000 11:09 AM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: modperl workaround for bug in netscape-4.7x with Expires:
headers?
Hello,
When sending a POST request
HI Jason,
Have a look at the source of Apache::DBI.
An important part of the module is a ping method that ensures the
connection handle (e.g., $dbh) doesn't go stale.
You can write your own ping method by doing something like:
Hi again,
On Tue, 7 Nov 2000, Buddy Lee Haystack wrote:
I may have missed that, but it dosen't mention the "experimental"
nature of DSO in the "DSO has the following disadvantages:" section
of the documentation located at
"http://www.apache.org/docs/dso.html"
Extract from my copy of the
If you have a caching proxy server running in front of your mod_perl
server (like mod_proxy or Squid), you can just set Expires headers in your
pages and this will be handled for you by the proxy.
True, both methods have advantages and disadvantages. The advantages of
using mod_rewrite and
-Original Message-
From: Guido Moonen [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November 07, 2000 10:20 AM
To: Mason
Subject: Problem: Number after header
Hi All,
I have a little problem with my Mason site:
IEplore doesn't have a problem accessing the site, But when i
Thanks, but as a RedHat [or other typical major distribution] user, I would never see
the documentation you mentioned below. Since DSO is still experimental, would it not
be an absolute necessity to include that information in the location where most users
are directed to look for information
Thanks!
I was under the mistaken impression that I was finally finished with the
administration side of things...
Oh well...
"G.W. Haywood" wrote:
Hi there,
On Tue, 7 Nov 2000, Buddy Lee Haystack wrote:
The memory consumption increases by about 1 megabyte for each child
process
On Tue, Nov 07, 2000 at 12:38:09PM -0500, Buddy Lee Haystack wrote:
I may have missed that, but it dosen't mention the "experimental"
nature of DSO in the "DSO has the following disadvantages:" section of
the documentation located at "http://www.apache.org/docs/dso.html"
Wait a sec, not
Thank you for the help everyone.
Jason
I've got a question related to encryption and mod_perl. I'm running
an apache mod_perl server (AIX and Linux platforms) to serve HTML
forms, query backend databases, and print formatted results. I currently
use .htaccess for authentication, although this will probably change.
My problem is
On Tue, 7 Nov 2000, Marinos J. Yannikos wrote:
If you have a caching proxy server running in front of your mod_perl
server (like mod_proxy or Squid), you can just set Expires headers in your
pages and this will be handled for you by the proxy.
True, both methods have advantages and
You are not setting your Content-Type correctly.
The response contains:
Content-Type: text/plain
This needs to be
Content-Type: text/html
to be rendered as HTML.
-Original Message-
From: Guido Moonen [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November 07, 2000 3:06 AM
To: Modperl;
Hi all,
On Tue, 7 Nov 2000, Geoffrey Young wrote:
you may also want to search the archives concerning NS and MSIE caching
Browsers drive me nuts. I've seen this work well for Apache::ASP.
$Response-{Expires} = -86400 * 100;
73,
Ged.
On Tue Nov 7 11:57:44 2000 -0500 Buddy Lee Haystack wrote:
I can always rotate my logs manually, or use the Apache rotatelogs program that
Ri?ardas ?epas recommended, although if the "rotatelogs" program restarts the server
I'll be back to square one - the program's man page just states
At 10:25 AM +0100 11/7/00, [EMAIL PROTECTED] wrote:
On Tue, 7 Nov 2000, Ron Rademaker wrote:
Hi,
You would think so, however every doc I read (including the one you
pointed out to me) told me that perl gives me a warning:
Variable $foo will not stay shared at
I do use -w so I
From: "G.W. Haywood" [EMAIL PROTECTED]
On Tue, 7 Nov 2000, Daniel Little wrote:
Has anyone had any problems with failure to write locks on
Apache:ASP
under Solaris or any other platform?
I just grepped one of my logfiles (a small one, about 70 megabytes:)
and there was no
Hello everyone, does anyone know how to retrieve the Object Identifier
(OID) from a record that was just inserted into a postgres database from
within perl?
These are the commands I'm using to insert the record:
$sth = $dbh-prepare("Insert into inventory Values ($id)");
$rc = $sth-execute;
$rc
Hi Daniel,
On Tue, 7 Nov 2000, Daniel Little wrote:
we're on a Sparc - I presume yours is Intel?
Yes. Er, well, AMD K6-2/450 in that case.
All I can say is 'use strict;'
Like it says in the Guide :)
Anyway, thanks for the response. I think we're going to have to
build a load test
Hello everyone, does anyone know how to retrieve the Object Identifier
(OID) from a record that was just inserted into a postgres database from
within modperl?
These are the commands I'm using to insert the record:
$sth = $dbh-prepare("Insert into inventory Values ($id)");
$rc = $sth-execute;
Hi,
i also posted this on the mysql-list and on the phpdb-list!
i've got the following configuration:
apache_1.3.12 with php and mod_perl statically linked. Php has
compiled-in mysql-support and mod_perl of course uses DBI.
When i use a mod_perl-script that uses the DBI-Interface i get a
I also never build mod_perl as a DSO. For the life of me I can't
understand why so many people do it, and then they act all surprised
when things go wrong.
I do it out of a desire to not have multiple builds of apache lying around
for the various needs I have of each service I run. For those
I'm leaning along the lines of just killing the
process, rotating the logs, and restarting it. It should take
no more than 5 seconds once a week a 4:00am.
This is exactly what I do, except I have it scripted. The downside is that
your service is unavailable for a few seconds (maybe more
Thanks Christian!
Scripts would be nice.;-)
I take it you've used DSO much more than I have, so I'm interested in any information
in addition to that provided by the kind "G.W. Haywood" to the following:
"What concerns me even more is the fact that I have Apache restart child processes
after
Hi,
I already have an older version of modperl installed
in the standard location. I would like to try out the
newer version of apache/modperl without disturbing those
in production. So I did this:
/export/home/chenri/mod_perl-1.24_01$ perl Makefile.PL PREFIX=/export/home/chenri
"B. Burke" wrote:
I've got a question related to encryption and mod_perl. I'm running
an apache mod_perl server (AIX and Linux platforms) to serve HTML
forms, query backend databases, and print formatted results. I currently
use .htaccess for authentication, although this will probably
i have the modperl in /root/.cpan/build/mod_perl-1.2.24
Funny place to put it.
that's right :)
but i must confess, i didn't find the "right" place yet...
i changed that to /tools/CPAN/build/mod_perl-1.2.24
Is that where you have Apache too? More
commonly things are in /usr/src/ or
hi guys
this is probaly OT
but does anyone know which browsers support digest auth ??
im just have written a mod_perl authentication module and was intending to
convert it to use digest auth
if anyone could point me at a url that could tell me that would be good
thanks in advance
On Mon, 6 Nov 2000, Ken Williams wrote:
A patch to Apache.pm docs, to match what is actually going on already:
committed. thanks. :)
--
ask bjoern hansen - http://www.netcetera.dk/~ask/
First off, the complaint about the lack of documentation for DSO being
experimental is a bit offbase IMO. It isn't up to the mod_perl group to
make sure RedHat includes complete documentation in their build of
mod_perl.
Also, this issue has been talked about many times on this mailing list.
I want to enhance Apache::AutoIndex. I have tried to contact Philippe M.
Chiasson, but have not had any success. Can someone please tell me how to
contact Philippe or whom ever is maintaining the module.
Thanks,
According to the DBD::Pg docs,
$sth-pg_oid_status
Returns the OID of the last INSERT command.
See: http://theoryx5.uwinnipeg.ca/CPAN/data/DBD-Pg/dbd-pg.html
Thanks,
Tim Tompkins
--
Programmer / Staff Engineer
http://www.arttoday.com/
Daniel Little wrote:
Has anyone had any problems with failure to write locks on Apache:ASP
under Solaris or any other platform? Getting quite a number of the
following in the log files...
[Tue Nov 7 10:23:11 2000] [error] [asp] [6708] [error] can't write
lock
Find attached the rotatelogs.pl script. My experience is that killing off
children after so much usage is a GoodThing (tm). So long as the parent
remains at a stable size, things should go ok.
Regards,
Christian
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On
Only if you don't already have a proxy front-end. Most large sites will
need one anyway.
After playing around for a while with mod_proxy on a second server, I'm not
so convinced; we have been doing quite well without such a setup for some
time now, despite up to 70-80 httpd processes (with
OK, so the documentation for PERL_STASH_POST_DATA reads:
There is an experimental option for Makefile.PL
called PERL_STASH_POST_DATA. If you turn it on,
you can get at it again with $r-subprocess_env("POST_DATA").
This is
One potential tip to offer is that if you want to rotate your logs but not
do a hard restart on the server, use something else for the log generation.
You may want to try out mod_log_spread from the mod_backhand site. If it's
not too difficult to setup, then you might be able to use another
Hi there,
On Tue, 7 Nov 2000, Richard Chen wrote:
when I do 'make install', make detects that I already have an older
version of modperl and tried to rm them:
Don't use it then! Install the files where you want them manually.
Make yourself familiar with an ordinary layout before you try to
Hi Everyone,
I've been bashing my head over this problems for the last couple of
days, so I thought I'd post and see if anybody has experienced something
similiar, and what they've done to solve it.
Basically, I have an Apache::Registry script that creates an expect
script, then executes it and
Hi all,
We've moved all our old perl cgi scripts to run
under mod_perl(PerlRun) now.
There's a peculiar problem I'm seeing with POST
requests. Basically, I'm not able to read anything from stdin at
all.
For eg, if I just have a form that takes some data,
that data is just not available at
On Wed, 8 Nov 2000, Marinos J. Yannikos wrote:
Only if you don't already have a proxy front-end. Most large sites will
need one anyway.
After playing around for a while with mod_proxy on a second server, I'm not
so convinced; we have been doing quite well without such a setup for some
I thought I'd let the list know that I resolved the problem,
even though the lack of response leads me to believe that it
is a problem that only I am experiencing.
It turns out that the installation of Solaris that I was
on lacked the patch 106950-13, which among other things
addressed problems
Hi Paul,
On Tue, 7 Nov 2000, Paul G. Weiss wrote:
I thought I'd let the list know that I resolved the problem, even
though the lack of response leads me to believe that it is a problem
that only I am experiencing.
It turns out that the installation of Solaris that I was on lacked
the
What I really dislike on this discussion is, that it mixes
two topics that are, IMO, really different:
- Using a pool of database connections from an application,
typically a threaded application.
- Accessing a database connection which really lives on
another machine via some sort
You can now build mod_ssl and mod_perl together. Instructions
are in the guide http://perl.apache.org/guide. You have to
build openssl first.
OpenSSL: http://www.openssl.org
mod_ssl: http://www.modssl.org
I do this now on Solaris (all with DSO's)
-Paul
-Original Message-
From: B.
richter 00/11/07 11:34:00
Modified:embperl Changes.pod.1.html Changes.pod.2.html
Changes.pod.cont.html Embperl.pod.1.html
Embperl.pod.10.html Embperl.pod.11.html
Embperl.pod.12.html Embperl.pod.14.html
ask 00/11/07 15:09:27
Modified:.Changes
Apache Apache.pm
Log:
Improved Apache-send_http_header documentation
[Ken Williams [EMAIL PROTECTED]]
Revision ChangesPath
1.548 +3 -0 modperl/Changes
Index: Changes
richter 00/11/07 23:49:37
Modified:embperl Changes.pod.1.html
Log:
Embperl Webpages - Changes
Revision ChangesPath
1.182 +3 -1 modperl-site/embperl/Changes.pod.1.html
Index: Changes.pod.1.html
82 matches
Mail list logo