Apache TransferLog with Apache::LogFile and rotatelogs catastrophy!

Apache TransferLog with Apache::LogFile and rotatelogs catastrophy!

Post by Benjamin Elbi » Sun, 01 Jul 2001 04:10:02



Hello,

Ok, I have this in my conf file:
PerlModule Apache::LogFile
PerlLogFile logs/urs.app_error_log My::URS::ERRLog
TransferLog "|/usr/local/apache/bin/rotatelogs
/usr/local/apache/logs/urs.app_error_log 3600"

When someone accesses the site, it logs the access_log information in
the custom log file I have up there, which I DO NOT want it to do.  If
i turn the TransferLog feature off, everything works fine.

What is going on and how do I fix it?

Thanks to all in advance,

Benjamin Elbirt

 
 
 

1. rotatelog command and CustomLog / TransferLog

I am trying to understand how to use the Apache rotatelog command, and
reading any documentation or newsgroup postings has not completely
answered my questions, so here goes...

Server 1:
Apache running on Sun Solaris server, v2.8
Current httpd.conf information:

LogFormat "%h %l %u %t \"%r\" %>s %b" common
#
# The location and format of the access logfile (Common Logfile Format).

# If you do not define any access logfiles within a <VirtualHost>
# container, they will be logged here.  Contrariwise, if you *do*
# define per-<VirtualHost> access logfiles, transactions will be
# logged therein and *not* in this file.
#
CustomLog /www/a/apache/logs/access_log common

##
## SSL Virtual Host Context
##

<VirtualHost _default_:8443>

#  General setup for the virtual host
DocumentRoot "/www/a/apache/htdocs"
#ServerName abc.xyz.com

ErrorLog /www/a/apache/logs/error_log
TransferLog /www/a/apache/logs/access_log

... So, if I understand this correctly, in this case since there is a
Virtual Host defined, the CustomLog directive is basically ignored and
all logging is put into the file defined by TransferLog (which, in this
case, is the same file ...).  I should be able to modify the TransferLog
statement to read:
TransferLog "|/www/a/apache/bin/rotatelogs
/www/a/apache/logs/access_log 604800"
and the result will be daily access_logs ....

Comments? Am I understanding the information they have in the file?

Server 2:
Apache running on Sun Solaris server, v2.8
Current httpd.conf information:

# The following directives define some format nicknames for use with
# a CustomLog directive (see below).
#
LogFormat "%h %l %u %t \"%r\" %>s %b" common

#
#SetEnvIf directive included to stop pings from being logged - 011303
SetEnvIf Request_URI "HEAD / HTTP/1.0" nolog

#
# The location and format of the access logfile (Common Logfile Format).

# If you do not define any access logfiles within a <VirtualHost>
# container, they will be logged here.  Contrariwise, if you *do*
# define per-<VirtualHost> access logfiles, transactions will be
# logged therein and *not* in this file.
#
# CustomLog logs/access_log common 011303: Replaced with nolog line
CustomLog logs/access_log common env=!nolog

... there is NO Virtual Host or TransferLog defined .....

In this case, how would I use the rotatelogs utility?

I do not think CustomLog "|/www/Artesia/apache/bin/rotatelogs
/www/Artesia/apache/logs/access_logs 604800" env=!nolog  will
work......

Suggestions / comments?

Thanks,
Jon

2. Ghost like app(or can i do this w/ dd)

3. Problems with Start Apache 1.2.0 ==> Invalid command TransferLog

4. Problems using 'dip'

5. Apache, httpd.conf, transferLog: Limiting certain files from being logged

6. Q: Can run two O/S versions concurrently?

7. Apache Transferlog Limit GET

8. PS/2-mouse

9. Apache TransferLog upload count?

10. Apache 1.2.0: TransferLog pipe -- still having problems

11. Apache fatally exits when virtual domain's TransferLog can't be opened !

12. apache 1.2b8: Exclude machines from TransferLog-File

13. Apache: TransferLog directive: | to program?