RE: Apache2::PerlSections $PerlConfig

Josh Narins <[email protected]>
Newsgroups gmane.comp.apache.mod-perl
Message-ID <F61EA32D7A6A79478142BA12E77AEE83266EE72162@MS3.nyc.seniorbridgeinternal.com>
> From: [email protected] [mailto:[email protected]] On Behalf Of Perrin Harkins
> Sent: Friday, November 18, 2011 3:41 PM
>
>> On Fri, Nov 18, 2011 at 3:20 PM, Josh Narins <[email protected]> wrote:
>> my $r = Apache2::RequestUtil->request;
>> $r->add_config($template->output);
>>
>>Which gets me
>>
>> Syntax error on line 66 of /home/web/rosalind-dev9/etc/httpd/httpd.conf:
\t(in cleanup) Global $r object is not available. Set:\n\tPerlOptions +GlobalRequest\nin httpd.conf at /home/web/rosalind-dev9/etc/httpd/httpd.conf line 116.\n
>>
>> This seems odd to me, because +GlobalRequest is set before the <Perl> section, and is clearly set when I check Apache2::Directive in Cleanup.
>
> This is in your conf file, right?  There's no request yet.  I think it's just a confusing error message.
>

Thanks, Perrin, but the server isn't starting when I get this error.



I've used strace a bit, not sure this will help, but here it is.

httpd-tmpl-custom.conf is the local include file for the template, the last part of the template file. Setting $PerlConfig = $template->output is the last line of the <Perl> section.

stat("[...]/etc/httpd/httpd-tmpl-custom.conf", {st_mode=S_IFREG|0600, st_size=344, ...}) = 0
open("[...]/etc/httpd/httpd-tmpl-custom.conf", O_RDONLY) = 4
ioctl(4, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7fff28a46020) = -1 ENOTTY (Inappropriate ioctl for device)
lseek(4, 0, SEEK_CUR)                   = 0
fstat(4, {st_mode=S_IFREG|0600, st_size=344, ...}) = 0
fcntl(4, F_SETFD, FD_CLOEXEC)           = 0
fstat(4, {st_mode=S_IFREG|0600, st_size=344, ...}) = 0
read(4, "# dev3.yaml\n#\n# Apache/mod_perl "..., 4096) = 344
read(4, "", 4096)                       = 0
fstat(4, {st_mode=S_IFREG|0600, st_size=344, ...}) = 0
close(4)                                = 0
write(2, "Syntax error on line 66 of /home"..., 73Syntax error on line 66 of /home/web/rosalind-dev9/etc/httpd/httpd.conf:
) = 73
write(2, "\\t(in cleanup) Global $r object "..., 160\t(in cleanup) Global $r object is not available. Set:\n\tPerlOptions +GlobalRequest\nin httpd.conf at /home/web/rosalind-dev9/etc/httpd/httpd.conf line 117.\n
) = 160
select(0, NULL, NULL, NULL, {0, 10000}) = 0 (Timeout)
brk(0x1f5.....) = 0x1f5 (4 times)
munmap(0x...., .....)         = 0 (14 times)
exit_group(1)                           = ?


Josh Narins
Director of Application Development
SeniorBridge

845 Third Ave
7th Floor
New York, NY 10022
Tel: (212) 994-6194
Mobile: (917) 488-6248
Fax: (212) 994-4260
[email protected]

SeniorBridge
Managing Complex Chronic Care
http://www.seniorbridge.com



SeniorBridge Statement of Confidentiality: The contents of this email message are intended for the exclusive use of the addressee(s) and may contain confidential or privileged information. Any dissemination, distribution or copying of this email by an unintended or mistaken recipient is strictly prohibited. In said event, kindly reply to the sender and destroy all entries of this message and any attachments from your system. Thank you.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.