Mark Hedges wrote:
That's a normal thing. All installed modules put their
config into mods-available. Then you use `a2enmod` to
manage those symlinks and turn them on or off in
mods-enabled.
+1
I believe all Debian-based distributions have done this with Apache 2
for a few years now.
It s
John ORourke wrote:
Expertly brought back on topic there, Torsten... if I ask about the
price of beans and how it relates to global warming can you give me a
mod_perl related answer? :)
Price of beans increases due to fuel costs, driven by the economy,
affected by global warming... um... all
� wrote:
Just for the rest of us : does anyone care to summarise what works
and works not (inasfar as not necessarily documented and/or
intuitive) ? And maybe what the original point of this interesting
thread was ?
Sure, but I don't think we're finished quite yet. ;)
Colin
Jonathan Vanasco wrote:
On Mar 28, 2008, at 3:11 PM, Colin Wetherbee wrote:
Care to add one, just to see what happens? :)
You know you've been working too much on the Business Side when you stop
testing stuff like that automatically. sigh...
Indeed. :)
ok...
it works if i have
Jonathan Vanasco wrote:
On Mar 27, 2008, at 8:43 PM, Colin Wetherbee wrote:
Hm. Yep. ResponseHandler can interpret the ::ResponseHandler part as
being a function within Handler.pm, but that does *not* work for
InitHandler.
i have it set up using
PerlFixupHandler
Jonathan Vanasco wrote:
On Mar 26, 2008, at 9:47 AM, Colin Wetherbee wrote:
We seem to have solved the problem, but for the sake of conversation...
When I've tried that in the past, mod_perl would always look for
handler() within JetSet::Handler::AccessHandler.pm.
Wow.
I've got
Jonathan Vanasco wrote:
On Mar 19, 2008, at 2:22 PM, Colin Wetherbee wrote:
PerlAccessHandler JetSet::Handler->AccessHandler
PerlResponseHandler JetSet::Handler->ResponseHandler
sub ResponseHandler
{
my (undef, $r) = @_;
# ...
}
what about...
PerlAccessHandler JetSet::H
André Warnier wrote:
PerlResponseHandler AM::TestStuff->handler
and
sub handler {
my ($self,$r) = @_;
$r->print('$self is a [' . ref($self) . '] and contains [' . $self .
"]\n");
[...]
and the result is
$self is a [] and contains [AM::TestStuff]
doesn't seem to be an object.
I get the
John ORourke wrote:
The only down-side is that (AFAICR) it is creating a new object for each
request - my handler is quite expensive to set up, so I have a
persistent object and use method handlers like this:
Ah, that's quite neat. I might give that a shot.
Thanks for the suggestion.
Colin
André Warnier wrote:
In a similat setup, I successfuly use
my ($self, $r) = @_;
so, if the undef bothers you ..
:)
Do you actually use $self for anything?
Colin
Greetings.
In order to have many handlers in a file, I've put the following lines
and other, similar lines in my virtual host configuration:
PerlAccessHandler JetSet::Handler->AccessHandler
PerlResponseHandler JetSet::Handler->ResponseHandler
Then, my handlers look like this:
sub ResponseHan
Colin Wetherbee wrote:
Beginner wrote:
dpkg -l libapache2-mod-perl2 shows:
ii libapache2-mod-perl2 2.0.2-2.4
It doesn't mention etch but I think this is the correct version.
FYI, here are the versions I get for Debian testing (I believe that's
etch at the moment?).
I
Colin Wetherbee wrote:
Beginner wrote:
dpkg -l libapache2-mod-perl2 shows:
ii libapache2-mod-perl2 2.0.2-2.4
It doesn't mention etch but I think this is the correct version.
FYI, here are the versions I get for Debian testing (I believe that's
etch at the moment?).
[EMAIL
Beginner wrote:
dpkg -l libapache2-mod-perl2 shows:
ii libapache2-mod-perl2 2.0.2-2.4
It doesn't mention etch but I think this is the correct version.
FYI, here are the versions I get for Debian testing (I believe that's
etch at the moment?).
[EMAIL PROTECTED]:~$ dpkg -l libapache2-m
Roberto � wrote:
On Wed, Mar 12, 2008 at 11:02:27PM +, xyon wrote:
Hey everyone,
Firstly, I apologize I sent the previous email under an incorrect subject line.
Yes, but you still hijacked another thread.
=> In-Reply-To: <[EMAIL PROTECTED]>
Please don't do that. Start a new thread by
Ronald Dai. wrote:
Actually RTFM would not be a problem for people from academic
background (meaning MS or PHD educated) at all since they have to do
it all the timebut for people with more team work background
these days, it might not be politically very correct...
I disagree. Granted, I
Ronald Dai. wrote:
I learned what is RTFM here which is very interesting :)...I like the
Ubuntu Forums policy though...but I always think reading is helpful
to any developer...that's why I like both perl and java because I
think they are very well documented generously somewhere within my
reach
Michael Peters wrote:
Colin Wetherbee wrote:
Basically, I'd like to run the 'mapserv' binary from within mod_perl
Why? Don't you just want to sanitize the data? If so you can do that in a
FixUpHandler or even in a separate handler that does an internal_redirect to th
Michael Peters wrote:
Colin Wetherbee wrote:
Basically, I'd like to run the 'mapserv' binary from within mod_perl
Why? Don't you just want to sanitize the data? If so you can do that in a
FixUpHandler or even in a separate handler that does an internal_redirect to the
map
Greetings.
I use a program called MapServer to generate images. It's a C binary,
and most people seem to run it (essentially) directly as a CGI program.
By essentially, I mean the binary is typically requested by JavaScript
or Flash or other things like that.
I'm doing some dynamic mapping
John ORourke wrote:
Might be showing off my lack of unix admin knowledge here but using
'top', it's the value of the 'virt' column - ie. the biggest possible
process size if the whole thing was resident. I've been using it to
work out how many clients I should limit apache to, but looking at i
Kirk wrote:
I'm new to mp2 and have a relatively old application that used the mp1
implementation of grabbing get/post params from incoming requests:
$r = shift;
# grab incoming value
my $value = $r->param('name');
...
...
# assign some value
$r->param('key' => 'val');
And of course, I need
Dami Laurent (PJ) wrote:
I don't know where to find answers to the following questions, so
better ask the list :
- 1) is modperl2 currently compatible with Perl 5.10 ? If not, are
some people working on it ? For which target date ?
- 2) if the answer is YES, then did anybody compile it into a P
Billeb, Andrew (ATS, IT) wrote:
The result is that when I click on a URL like the following (i.e.
missing the the /cgi-bin/):
_http://localhost/ridhwan/script_name.pl_
the script displays fine….but clicking the submit button doesn't do
anythingit just redisplays the same page. But it's th
Zakk wrote:
> Date: Fri, 1 Feb 2008 22:21:12 -0500
> From: [EMAIL PROTECTED]
> To: [EMAIL PROTECTED]
> CC: modperl@perl.apache.org
> Subject: Re: mod_perl's make test fails.
>
> Zakk wrote:
> > For the last few days, I've been trying to install mod_perl for my
> > server. It's running Sl
Zakk wrote:
For the last few days, I've been trying to install mod_perl for my
server. It's running Slackware 12.0 with Apache 2.2.8 (with APR 1.2.12)
and Perl 5.10.0.
I'm under the impression we're still under the "don't use Perl 5.10 with
mod_perl yet" directive.
A number of internal chan
Clinton Gormley wrote:
I'm not sure what you're suggesting. The first few pages of "cache" on
CPAN have some modules for caching data in memory and on disk and so
forth, but I don't see how they relate to my problem.
Which is that of notifying all of my application's perl processes when
an u
Scott Gifford wrote:
Colin Wetherbee <[EMAIL PROTECTED]> writes:
[...]
At the moment (and not in a production environment), every time the
drop-down list is generated for a web page, the script queries the
database to retrieve the entire list of aircraft. I would prefer to
retrieve th
Raful Mr Mitchell H wrote:
I have my code pasted below. My module, loaded with
directive in Apache2, works well. However, sometimes switches don't
respond correctly to bulk queries of fdbPorts object. What I want to do
is to be able print the value of my variables either to the browser or a
John ORourke wrote:
Colin Wetherbee wrote:
John ORourke wrote:
Colin Wetherbee wrote:
Wouldn't a simpler approach be to just restart Apache when you want
to update the lists? You could even have the 'add to list' function
send SIGUSR1 to the parent Apache, causing a graceful
John ORourke wrote:
Colin Wetherbee wrote:
At the moment (and not in a production environment), every time the
drop-down list is generated for a web page, the script queries the
database to retrieve the entire list of aircraft. I would prefer to
retrieve the list of aircraft when each Perl
Greetings.
I have an application that accesses some relatively static database
tables to create drop-down lists. As an example, one of these
tables is a list of common commercial aircraft.
At the moment (and not in a production environment), every time the
drop-down list is generated for a
Jeff Pang wrote:
I met a strange requirement that, given Apache has two virtual hosts,
vhA and vhB, vhA's document root is: /path/a/; vhB's document root
is: /path/b/.
vhA's programs are running under /path/a/cgi-bin, but actually, the
programs of vhA can access vhB's directory (ie,they can open
Tyler Bird wrote:
Hi folks I know this is off topic and hopefully if anybody knows the
sendmail mailing list address please reply.
Yeah, that's pretty off-topic.
http://www.sendmail.org/misc/usenet.php
http://groups.google.com/group/comp.mail.sendmail/topics
Colin
Peter Haworth wrote:
On Sat, 05 Jan 2008 00:56:49 -0500, Colin Wetherbee wrote:
On Jan 4, 2008 9:47 PM, Colin Wetherbee <[EMAIL PROTECTED]>
wrote:
From the Apache2::Cookie documentation, bake() "adds a Set-
Cookie header to the outgoing headers table." Is there a way to
u
Perrin Harkins wrote:
On Jan 5, 2008 12:56 AM, Colin Wetherbee <[EMAIL PROTECTED]> wrote:
Well, I don't mind editing the headers, but I'd rather use standardized
API calls (i.e. through Apache2::Cookie and friends) so that I don't
have to worry about what's going on u
Perrin Harkins wrote:
On Jan 4, 2008 9:47 PM, Colin Wetherbee <[EMAIL PROTECTED]> wrote:
From the Apache2::Cookie documentation, bake() "adds a Set-Cookie
header to the outgoing headers table." Is there a way to undo this
without manually editing the headers, preferably with
Good evening.
Is it possible to un-bake a baked cookie?
From the Apache2::Cookie documentation, bake() "adds a Set-Cookie
header to the outgoing headers table." Is there a way to undo this
without manually editing the headers, preferably with Apache2::Cookie
methods?
(As an aside, would so
Raful Mr Mitchell H wrote:
Here is the complete script
Is this the script that was causing segfaults? It doesn't look anything
like what you originally posted.
#!/usr/bin/perl
package Handlers::Devices;
use DBI;
use HTML::Template;
use Apache2::RequestRec ();
use APR::Request::Param (
Raful Mr Mitchell H wrote:
My script looks like this
use Apache2::Request ();
my $req = Apache2::Request-> new($r)
my $data = req->{/param-name}/
//
It causes a segfault error. Any ideas?
Hello.
Please send us a bit more of your script. This snippet doesn't say much.
Colin
Will Fould wrote:
Is this a reasonable approach? Is it typical to refer to the request
object by package name rather than try to painfully re-factor all
packages and subs to accept $r as a passed reference?
I don't know if this will help your re-factoring, but you should note
you can always g
Adam Prime wrote:
Boysenberry Payne wrote:
I only ask because I tried a $r->status(Apache2::Const::OK) and got
a 500 returned in the header even though my handler returned with
Apache::Const::OK also...
To avoid the 500 header I had to do $r->status(200); I imagine the
status code isn't going
Boysenberry Payne wrote:
I only ask because I tried a $r->status(Apache2::Const::OK) and got a
500 returned in the header even though my handler returned with
Apache::Const::OK also...
To avoid the 500 header I had to do $r->status(200); I imagine the
status code isn't going to change too soo
Boysenberry Payne wrote:
I found that $r->status() required something other than Apache2::Const
in one of my modules and it got me wondering what the Constant values
actually were. Now I could go through and print each one I suppose, but I
thought looking at them in Apache2::Const.pm would be be
Have any of you used mod_perl with Perl 5.10 yet? Are there any gotchas
to consider?
I'm still waiting on the release of the Debian packages.
Colin
Marc M. Adkins wrote:
Can I not return Apache2::Const::NOT_FOUND from handler()?
I've never used filters for this, but you can certainly return NOT_FOUND
from a handler.
Colin
Fred Moyer wrote:
Colin Wetherbee wrote:
[Fri Dec 14 23:57:52 2007] [error] [client 192.168.171.80] Can't
locate object method "log" via package "Apache2::RequestRec" at
/home/cww/sites/js.iron.denterprises.org/htdocs/jet-set/JetSet/Debug.pm
line 33.\n
use Apache2::
Based on some documentation I read [0] [1], I am trying to use the
following function to write messages to my virtual host's error log.
30 sub Debug(@)
31 {
32 my $r = Apache2::RequestUtil->request;
33 $r->log->debug(@_);
34 }
I have tried several variations of this, restarting the server a
Fred Moyer wrote:
I've been having fun with dtrace, and I most recently used it to see
what files are being accessed by mod_perl during requests. I've
preloaded all the modules in my application that I know about into
startup.pl, but when I startup my httpd server and make a request, I got
so
Foo JH wrote:
3. Fast to cook, good to eat
That's my favorite part of mod_perl.
It goes down well with cookies, too, but tastes awful with Java. ;)
And, you know, to keep this on topic, I like the idea that mod_perl on
Windows can be a springboard of sorts for people who may eventually be
d
Colin Wetherbee wrote:
use Apache2::RequestRec;
use Apache2::Const -compile => qw(OK);
To be clear, this also occurs with 'use Apache2::Request' at the top. :)
Colin
Greetings.
I accidentally made the mistake of calling Apache2::Request->new()
without passing $r, and it turns out that causes Apache to segfault and
not return anything to the browser. I'm only pointing this out because
it seems like there should be a more graceful way of handling this.
##
Perrin Harkins wrote:
If you have a reverse proxy, and still have too many connections, you
can look at either SQL Relay or the DBI::Gofer stuff in the latest DBI
releases. DBI::Gofer was created to solve the issue of too many
connections for Shopzilla.com.
DBD::Gofer looks like an excellent s
Mag Gam wrote:
Is it possible to do database connection pooling with mod_perl?
Currently, all of my source code has a my $dbh. Is it possible to have
my database stuff in a pool, and I just include it somehow?
DBI::Pool is a partially complete module for doing this. Tim Bunce and
Stas Bekma
Jeff Pang wrote:
Try change the codes to:
sub handler {
my $r = shift;
...
If his handler is called as a method, $class is an appropriate first
variable to shift out of @_. Using ($class, $r) = @_ is a perfectly
legitimate way of taking care of that.
Colin
Raymond Wan wrote:
I'm not an expert on this, but looked into this briefly as I was worried
about the level of support. From asking around, it seems that you can
install 32-bit Linux on a 64-bit machine, but of course, you lose all
the benefits of the 64 bits (access to larger disks and more m
Jonathan Vanasco wrote:
sub handler {
$page= myapp::Page->new();
$page->whatever;
}
So, Page.pm defines an object... do you have Page.pm including other
Exporter-style modules? And, do those work properly?
Thanks.
Colin
It seems like I've tried everything, and I can't get Apache2::Reload to
reload my modules.
I have a handler in a module called JetSet::Handler. That module
depends on a number of other modules, which I've tried to include with
'use', with limited success. It seems, sometimes, symbols act jus
Colin Wetherbee wrote:
# BEGIN CODE BLOCK
my $req = Apache2::Request->new($r);
$r->content_type('text/html');
$r->print("test\n");
# END CODE BLOCK
OK, problem solved.
I didn't have mod_apreq enabled. For what it's worth, I don't recall
see
Jonathan Vanasco wrote:
As I said in my original post, I tried to use Apache2::Request, but
after creating that object, I couldn't print anything anymore.
Perhaps someone could give me a hint on how to implement it?
could you print beforehand?
'print' might not be tied to the same output.
Foo JH wrote:
You'd see that Apache2::Request exposes more stuff, which you can
(lazily) use. Unless you are looking for some backward compatibility to
tradditional CGI programming, why not embrace the entire modperl library?
That sounds good to me. I'm not looking for any particular backward
Hello!
It's been about four years since I've used mod_perl to any great extent,
and I'm afraid I'm somewhat rusty. I'm trying to create a handler that
can parse CGI parameters, but I'm unsure of the most modern way of doing
that.
I know Apache2::Request is supposed to be able to grab CGI pa
Stas Bekman said:
> Was the request made to that vhost. I'm sure it works if you move it out
> of the container.
Indeed, PerlSwitches -I works outside the vhost container.
Could cause all sorts of conflicts among vhosts that aren't aware of each
other that way, though. :(
Colin
--
Colin W. We
Siyad Ahmed Naina said:
> ModPerl::Registry: HTML::Parser object version 3.35
> does not match bootstrap parameter 3.34 at
This is a module version mismatch. Perhaps you have an old (but still
recent, from the looks of it) version of mod_perl in your path somewhere?
My suggestion is to upgrade a
Greetings.
Following reading Stas's last email to Scot, I poked around on the
configuration directives page and saw that PerlSwitches -I/foo is a
convenient replacement for 'use lib'.
I removed 'use lib' from a script and put the following in my virtual host
section:
PerlSwitches -I/var/www/hydr
Greetings.
Seems I'm confused about how to get mod_perl to send status codes other
than 200 OK.
I want to have my Perl script, upon getting the wrong CGI parameters, to
give a status 404. Then, the ErrorDocument for 404 goes back to that same
Perl script but with the CGI parameter ?page=error404
66 matches
Mail list logo