You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by "J. Bakshi" <jo...@infoservices.in> on 2009/09/22 14:00:13 UTC
[users@httpd] how to get logs per vhosts ?
Hello list,
In my linux server ( opensuse 11) , I am running apache with some
vhosts. All the virtual-hosts are running well. But the apache log
file is common for all the virtual hosts ; that is
/etc/var/log/apache/access.log. How can I get per vhost log so that I
can use awstat as well as monitor log for concerned vhost only ?
thanks.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] how to get logs per vhosts ?
Posted by Rich Bowen <rb...@rcbowen.com>.
On Sep 22, 2009, at 08:56 , J. Bakshi wrote:
> Rich Bowen wrote:
>>
>> On Sep 22, 2009, at 08:24 , J. Bakshi wrote:
>>>
>>> Well there is one side effect for the web hosting server. Generally
>>> these type of servers host a huge no. of vhosts. And the CustomLog
>>> options then creates a serious performance issue. To cope with
>>> that an
>>> alternative is to log all the vhost at a common file and then
>>> break it
>>> to different vhost specific logs. I am searching how to do that. any
>>> help in that direction is always welcome.
>>
>> By adding the %v variable to the beginning of the LogFormat string,
>> you'll have the hostname as the first thing in the log entry. You can
>> then split the logs after the fact using the utility called
>> split-logfile that comes with
>> Apache: http://httpd.apache.org/docs/2.2/programs/other.html
>>
>>
>
> Hello Rich,
>
> My thinking is also flowing on the same direction. I think we need a
> cron to repeatedly generate ( and append ) the log. But still not
> sufficient to produce real time log.
Then you have conflicting requirements. I think that logging to a
database - like the suggested mod_log_mysql - is the right way to do
it. Your assessment that logging to a database would be slower than
logging to the file system doesn't seem to be accurate. It's going to
be a lot faster.
--
Rich Bowen
rbowen@rcbowen.com
RE: [users@httpd] how to get logs per vhosts ?
Posted by "Geurts, G.P.T.M." <g....@i-groep.leidenuniv.nl>.
Using syslog-ng you can log to different facilities and filter
acordingly, or you can filter by contense of the message, so a %v in the
LogFormat enables per vhost logging.
Don't know anything about the performance impact to the server though...
I know there is a BufferLog directive which enables to buffer a number
of messages...
-----Original Message-----
From: J. Bakshi [mailto:joydeep@infoservices.in]
Sent: dinsdag 22 september 2009 14:56
To: users@httpd.apache.org
Subject: Re: [users@httpd] how to get logs per vhosts ?
Rich Bowen wrote:
>
> On Sep 22, 2009, at 08:24 , J. Bakshi wrote:
>>
>> Well there is one side effect for the web hosting server. Generally
>> these type of servers host a huge no. of vhosts. And the CustomLog
>> options then creates a serious performance issue. To cope with that
>> an alternative is to log all the vhost at a common file and then
>> break it to different vhost specific logs. I am searching how to do
>> that. any help in that direction is always welcome.
>
> By adding the %v variable to the beginning of the LogFormat string,
> you'll have the hostname as the first thing in the log entry. You can
> then split the logs after the fact using the utility called
> split-logfile that comes with
> Apache: http://httpd.apache.org/docs/2.2/programs/other.html
>
>
Hello Rich,
My thinking is also flowing on the same direction. I think we need a
cron to repeatedly generate ( and append ) the log. But still not
sufficient to produce real time log.
>
> --
> Rich Bowen
> rbowen@rcbowen.com <ma...@rcbowen.com>
>
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server
Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] how to get logs per vhosts ?
Posted by "J. Bakshi" <jo...@infoservices.in>.
Rich Bowen wrote:
>
> On Sep 22, 2009, at 08:24 , J. Bakshi wrote:
>>
>> Well there is one side effect for the web hosting server. Generally
>> these type of servers host a huge no. of vhosts. And the CustomLog
>> options then creates a serious performance issue. To cope with that an
>> alternative is to log all the vhost at a common file and then break it
>> to different vhost specific logs. I am searching how to do that. any
>> help in that direction is always welcome.
>
> By adding the %v variable to the beginning of the LogFormat string,
> you'll have the hostname as the first thing in the log entry. You can
> then split the logs after the fact using the utility called
> split-logfile that comes with
> Apache: http://httpd.apache.org/docs/2.2/programs/other.html
>
>
Hello Rich,
My thinking is also flowing on the same direction. I think we need a
cron to repeatedly generate ( and append ) the log. But still not
sufficient to produce real time log.
>
> --
> Rich Bowen
> rbowen@rcbowen.com <ma...@rcbowen.com>
>
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] how to get logs per vhosts ?
Posted by Rich Bowen <rb...@rcbowen.com>.
On Sep 22, 2009, at 08:24 , J. Bakshi wrote:
>
> Well there is one side effect for the web hosting server. Generally
> these type of servers host a huge no. of vhosts. And the CustomLog
> options then creates a serious performance issue. To cope with that
> an
> alternative is to log all the vhost at a common file and then break it
> to different vhost specific logs. I am searching how to do that. any
> help in that direction is always welcome.
By adding the %v variable to the beginning of the LogFormat string,
you'll have the hostname as the first thing in the log entry. You can
then split the logs after the fact using the utility called split-
logfile that comes with Apache: http://httpd.apache.org/docs/2.2/programs/other.html
--
Rich Bowen
rbowen@rcbowen.com
Re: [users@httpd] how to get logs per vhosts ?
Posted by "J. Bakshi" <jo...@infoservices.in>.
Serge Fonville wrote:
> Hi,
>
> I'd consider logging to a database instead
>
> Read into mod_log_mysql
> http://www.howtoforge.com/apache2-logging-to-a-mysql-database-with-mod_log_sql-on-debian-etch
> That should get you started.
> It might require som fiddling...
>
> HTH
Hello,
Thanks for your feedback. I am trying to achieve the hosting company
style logging i.e.
1. per vhost base access and error log
2. awstat should work with the access logs.
3. Finally the performance should not fall due to huge no. of vhosts.
I think logging to a database might conflict with #3
>
> Regards,
>
> Serge Fonville
> On Tue, Sep 22, 2009 at 2:24 PM, J. Bakshi <joydeep@infoservices.in
> <ma...@infoservices.in>> wrote:
>
> J. Bakshi wrote:
> > Geurts, G.P.T.M. wrote:
> >
> >> Hello mr Bakshi,
> >> You can define per vhost accesslogs by simply defining them.
> >> If your vhost defenition contains a "CustomLog /var/log/logfile
> >> logformat" directive, it will log all accesslog using LogFormat
> >> logformat
> >> to the file /var/log/logfile for that vhost.
> >> Accesslogs not belonging to that vhost go to you global defined
> >> accesslog
> >>
> >>
> >
> > Hello Sir,
> >
> > Thanks a lot for your prompt solution and clarification.
> > I'll do it accordingly.
> > Once again thanking you.
> >
>
> Well there is one side effect for the web hosting server. Generally
> these type of servers host a huge no. of vhosts. And the CustomLog
> options then creates a serious performance issue. To cope with
> that an
> alternative is to log all the vhost at a common file and then break it
> to different vhost specific logs. I am searching how to do that. any
> help in that direction is always welcome.
>
> thanks
>
> >
> >
> >> -----Original Message-----
> >> From: J. Bakshi [mailto:joydeep@infoservices.in
> <ma...@infoservices.in>]
> >> Sent: dinsdag 22 september 2009 14:00
> >> To: users@httpd.apache.org <ma...@httpd.apache.org>
> >> Subject: [users@httpd] how to get logs per vhosts ?
> >>
> >> Hello list,
> >>
> >> In my linux server ( opensuse 11) , I am running apache with some
> >> vhosts. All the virtual-hosts are running well. But the
> apache log
> >> file is common for all the virtual hosts ; that is
> >> /etc/var/log/apache/access.log. How can I get per vhost log so
> that I
> >> can use awstat as well as monitor log for concerned vhost only ?
> >>
> >> thanks.
> >>
> >>
> ---------------------------------------------------------------------
> >> The official User-To-User support forum of the Apache HTTP Server
> >> Project.
> >> See <URL:http://httpd.apache.org/userslist.html> for more info.
> >> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> >> " from the digest:
> users-digest-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> >> For additional commands, e-mail: users-help@httpd.apache.org
> <ma...@httpd.apache.org>
> >>
> >>
> >>
> ---------------------------------------------------------------------
> >> The official User-To-User support forum of the Apache HTTP
> Server Project.
> >> See <URL:http://httpd.apache.org/userslist.html> for more info.
> >> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> >> " from the digest:
> users-digest-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> >> For additional commands, e-mail: users-help@httpd.apache.org
> <ma...@httpd.apache.org>
> >>
> >>
> >>
> >>
> >
> >
> >
> ---------------------------------------------------------------------
> > The official User-To-User support forum of the Apache HTTP
> Server Project.
> > See <URL:http://httpd.apache.org/userslist.html> for more info.
> > To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> > " from the digest:
> users-digest-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> > For additional commands, e-mail: users-help@httpd.apache.org
> <ma...@httpd.apache.org>
> >
> >
> >
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server
> Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> <ma...@httpd.apache.org>
> For additional commands, e-mail: users-help@httpd.apache.org
> <ma...@httpd.apache.org>
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Log to DBMS other than MySQL? [was Re: how to
get logs per vhosts ?]
Posted by Tom Evans <te...@googlemail.com>.
On Tue, 2009-09-22 at 10:04 -0400, Mark H. Wood wrote:
> On Tue, Sep 22, 2009 at 02:28:51PM +0200, Serge Fonville wrote:
> > I'd consider logging to a database instead
> >
> > Read into mod_log_mysql
> > http://www.howtoforge.com/apache2-logging-to-a-mysql-database-with-mod_log_sql-on-debian-etch
>
> So, are there any log-to-dbms modules for Apache HTTPD out there that
> do *not* demand MySQL?
>
> Not wishing to start an offtopic flamewar, but I already have
> PostgreSQL installed for some years, am comfortable with it, and
> wouldn't like to drag another whole DBMS in for one simple
> application. (There are probably some users of Oracle, DB/2, and the
> like who would be interested as well.)
>
mod_log_sql alleges to support postgres using dbi, which would
presumably mean adding support for any other DB that has a dbi module is
trivial.
Usually the reason why something doesn't exist is that no-one cares
enough to write it.
Cheers
Tom
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Log to DBMS other than MySQL? [was Re: how to get
logs per vhosts ?]
Posted by Nick Kew <ni...@webthing.com>.
Mark H. Wood wrote:
> On Tue, Sep 22, 2009 at 02:28:51PM +0200, Serge Fonville wrote:
>> I'd consider logging to a database instead
>>
>> Read into mod_log_mysql
>> http://www.howtoforge.com/apache2-logging-to-a-mysql-database-with-mod_log_sql-on-debian-etch
>
> So, are there any log-to-dbms modules for Apache HTTPD out there that
> do *not* demand MySQL?
Erm, any DBD-based solution gives you a choice of backend. An article
describing it with mysql is either old (pre-Apache-2.2) or simply
describing exactly what its author did.
> Not wishing to start an offtopic flamewar, but I already have
> PostgreSQL installed for some years, am comfortable with it, and
> wouldn't like to drag another whole DBMS in for one simple
> application. (There are probably some users of Oracle, DB/2, and the
> like who would be interested as well.)
We don't have DB/2 yet (unless you can use it through something
like ODBC), but your other candidates are all supported.
--
Nick Kew
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Log to DBMS other than MySQL? [was Re: how to get
logs per vhosts ?]
Posted by Serge Fonville <se...@gmail.com>.
On Tue, Sep 22, 2009 at 4:04 PM, Mark H. Wood <mw...@iupui.edu> wrote:
> On Tue, Sep 22, 2009 at 02:28:51PM +0200, Serge Fonville wrote:
> > I'd consider logging to a database instead
> >
> > Read into mod_log_mysql
> >
> http://www.howtoforge.com/apache2-logging-to-a-mysql-database-with-mod_log_sql-on-debian-etch
>
> So, are there any log-to-dbms modules for Apache HTTPD out there that
> do *not* demand MySQL?
Mod_log_sql is considered pgsql 'compatible'
But again, it requires fiddling
HTH
Regards,
Serge fonville
>
> Not wishing to start an offtopic flamewar, but I already have
> PostgreSQL installed for some years, am comfortable with it, and
> wouldn't like to drag another whole DBMS in for one simple
> application. (There are probably some users of Oracle, DB/2, and the
> like who would be interested as well.)
>
> --
> Mark H. Wood, Lead System Programmer mwood@IUPUI.Edu
> Friends don't let friends publish revisable-form documents.
>
[users@httpd] Log to DBMS other than MySQL? [was Re: how to get logs per vhosts
?]
Posted by "Mark H. Wood" <mw...@IUPUI.Edu>.
On Tue, Sep 22, 2009 at 02:28:51PM +0200, Serge Fonville wrote:
> I'd consider logging to a database instead
>
> Read into mod_log_mysql
> http://www.howtoforge.com/apache2-logging-to-a-mysql-database-with-mod_log_sql-on-debian-etch
So, are there any log-to-dbms modules for Apache HTTPD out there that
do *not* demand MySQL?
Not wishing to start an offtopic flamewar, but I already have
PostgreSQL installed for some years, am comfortable with it, and
wouldn't like to drag another whole DBMS in for one simple
application. (There are probably some users of Oracle, DB/2, and the
like who would be interested as well.)
--
Mark H. Wood, Lead System Programmer mwood@IUPUI.Edu
Friends don't let friends publish revisable-form documents.
Re: [users@httpd] how to get logs per vhosts ?
Posted by Serge Fonville <se...@gmail.com>.
Hi,
I'd consider logging to a database instead
Read into mod_log_mysql
http://www.howtoforge.com/apache2-logging-to-a-mysql-database-with-mod_log_sql-on-debian-etch
That should get you started.
It might require som fiddling...
HTH
Regards,
Serge Fonville
On Tue, Sep 22, 2009 at 2:24 PM, J. Bakshi <jo...@infoservices.in> wrote:
> J. Bakshi wrote:
> > Geurts, G.P.T.M. wrote:
> >
> >> Hello mr Bakshi,
> >> You can define per vhost accesslogs by simply defining them.
> >> If your vhost defenition contains a "CustomLog /var/log/logfile
> >> logformat" directive, it will log all accesslog using LogFormat
> >> logformat
> >> to the file /var/log/logfile for that vhost.
> >> Accesslogs not belonging to that vhost go to you global defined
> >> accesslog
> >>
> >>
> >
> > Hello Sir,
> >
> > Thanks a lot for your prompt solution and clarification.
> > I'll do it accordingly.
> > Once again thanking you.
> >
>
> Well there is one side effect for the web hosting server. Generally
> these type of servers host a huge no. of vhosts. And the CustomLog
> options then creates a serious performance issue. To cope with that an
> alternative is to log all the vhost at a common file and then break it
> to different vhost specific logs. I am searching how to do that. any
> help in that direction is always welcome.
>
> thanks
>
> >
> >
> >> -----Original Message-----
> >> From: J. Bakshi [mailto:joydeep@infoservices.in]
> >> Sent: dinsdag 22 september 2009 14:00
> >> To: users@httpd.apache.org
> >> Subject: [users@httpd] how to get logs per vhosts ?
> >>
> >> Hello list,
> >>
> >> In my linux server ( opensuse 11) , I am running apache with some
> >> vhosts. All the virtual-hosts are running well. But the apache log
> >> file is common for all the virtual hosts ; that is
> >> /etc/var/log/apache/access.log. How can I get per vhost log so that I
> >> can use awstat as well as monitor log for concerned vhost only ?
> >>
> >> thanks.
> >>
> >> ---------------------------------------------------------------------
> >> The official User-To-User support forum of the Apache HTTP Server
> >> Project.
> >> See <URL:http://httpd.apache.org/userslist.html> for more info.
> >> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> >> " from the digest: users-digest-unsubscribe@httpd.apache.org
> >> For additional commands, e-mail: users-help@httpd.apache.org
> >>
> >>
> >> ---------------------------------------------------------------------
> >> The official User-To-User support forum of the Apache HTTP Server
> Project.
> >> See <URL:http://httpd.apache.org/userslist.html> for more info.
> >> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> >> " from the digest: users-digest-unsubscribe@httpd.apache.org
> >> For additional commands, e-mail: users-help@httpd.apache.org
> >>
> >>
> >>
> >>
> >
> >
> > ---------------------------------------------------------------------
> > The official User-To-User support forum of the Apache HTTP Server
> Project.
> > See <URL:http://httpd.apache.org/userslist.html> for more info.
> > To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> > " from the digest: users-digest-unsubscribe@httpd.apache.org
> > For additional commands, e-mail: users-help@httpd.apache.org
> >
> >
> >
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
Re: [users@httpd] how to get logs per vhosts ?
Posted by "J. Bakshi" <jo...@infoservices.in>.
J. Bakshi wrote:
> Geurts, G.P.T.M. wrote:
>
>> Hello mr Bakshi,
>> You can define per vhost accesslogs by simply defining them.
>> If your vhost defenition contains a "CustomLog /var/log/logfile
>> logformat" directive, it will log all accesslog using LogFormat
>> logformat
>> to the file /var/log/logfile for that vhost.
>> Accesslogs not belonging to that vhost go to you global defined
>> accesslog
>>
>>
>
> Hello Sir,
>
> Thanks a lot for your prompt solution and clarification.
> I'll do it accordingly.
> Once again thanking you.
>
Well there is one side effect for the web hosting server. Generally
these type of servers host a huge no. of vhosts. And the CustomLog
options then creates a serious performance issue. To cope with that an
alternative is to log all the vhost at a common file and then break it
to different vhost specific logs. I am searching how to do that. any
help in that direction is always welcome.
thanks
>
>
>> -----Original Message-----
>> From: J. Bakshi [mailto:joydeep@infoservices.in]
>> Sent: dinsdag 22 september 2009 14:00
>> To: users@httpd.apache.org
>> Subject: [users@httpd] how to get logs per vhosts ?
>>
>> Hello list,
>>
>> In my linux server ( opensuse 11) , I am running apache with some
>> vhosts. All the virtual-hosts are running well. But the apache log
>> file is common for all the virtual hosts ; that is
>> /etc/var/log/apache/access.log. How can I get per vhost log so that I
>> can use awstat as well as monitor log for concerned vhost only ?
>>
>> thanks.
>>
>> ---------------------------------------------------------------------
>> The official User-To-User support forum of the Apache HTTP Server
>> Project.
>> See <URL:http://httpd.apache.org/userslist.html> for more info.
>> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>> " from the digest: users-digest-unsubscribe@httpd.apache.org
>> For additional commands, e-mail: users-help@httpd.apache.org
>>
>>
>> ---------------------------------------------------------------------
>> The official User-To-User support forum of the Apache HTTP Server Project.
>> See <URL:http://httpd.apache.org/userslist.html> for more info.
>> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>> " from the digest: users-digest-unsubscribe@httpd.apache.org
>> For additional commands, e-mail: users-help@httpd.apache.org
>>
>>
>>
>>
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] how to get logs per vhosts ?
Posted by "J. Bakshi" <jo...@infoservices.in>.
Geurts, G.P.T.M. wrote:
> Hello mr Bakshi,
> You can define per vhost accesslogs by simply defining them.
> If your vhost defenition contains a "CustomLog /var/log/logfile
> logformat" directive, it will log all accesslog using LogFormat
> logformat
> to the file /var/log/logfile for that vhost.
> Accesslogs not belonging to that vhost go to you global defined
> accesslog
>
Hello Sir,
Thanks a lot for your prompt solution and clarification.
I'll do it accordingly.
Once again thanking you.
> -----Original Message-----
> From: J. Bakshi [mailto:joydeep@infoservices.in]
> Sent: dinsdag 22 september 2009 14:00
> To: users@httpd.apache.org
> Subject: [users@httpd] how to get logs per vhosts ?
>
> Hello list,
>
> In my linux server ( opensuse 11) , I am running apache with some
> vhosts. All the virtual-hosts are running well. But the apache log
> file is common for all the virtual hosts ; that is
> /etc/var/log/apache/access.log. How can I get per vhost log so that I
> can use awstat as well as monitor log for concerned vhost only ?
>
> thanks.
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server
> Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
RE: [users@httpd] how to get logs per vhosts ?
Posted by "Geurts, G.P.T.M." <g....@i-groep.leidenuniv.nl>.
Hello mr Bakshi,
You can define per vhost accesslogs by simply defining them.
If your vhost defenition contains a "CustomLog /var/log/logfile
logformat" directive, it will log all accesslog using LogFormat
logformat
to the file /var/log/logfile for that vhost.
Accesslogs not belonging to that vhost go to you global defined
accesslog
-----Original Message-----
From: J. Bakshi [mailto:joydeep@infoservices.in]
Sent: dinsdag 22 september 2009 14:00
To: users@httpd.apache.org
Subject: [users@httpd] how to get logs per vhosts ?
Hello list,
In my linux server ( opensuse 11) , I am running apache with some
vhosts. All the virtual-hosts are running well. But the apache log
file is common for all the virtual hosts ; that is
/etc/var/log/apache/access.log. How can I get per vhost log so that I
can use awstat as well as monitor log for concerned vhost only ?
thanks.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server
Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] how to get logs per vhosts ?
Posted by "J. Bakshi" <jo...@infoservices.in>.
Matus UHLAR - fantomas wrote:
> On 22.09.09 17:30, J. Bakshi wrote:
>
>> In my linux server ( opensuse 11) , I am running apache with some
>> vhosts. All the virtual-hosts are running well. But the apache log
>> file is common for all the virtual hosts ; that is
>> /etc/var/log/apache/access.log. How can I get per vhost log so that I
>> can use awstat as well as monitor log for concerned vhost only ?
>>
>
> you can define CustomLog (or TransferLog) directive in each virtual host.
> However I don't recommend that one - many logfiles slows down starting and
> reloading apache since all log files need to be reopened.
>
> You also can't do it for dynamic virtual hosts, for that you need to log to
> a program that will split logs based on virtual host provided.
>
> BTW, awstats is able to extract virtual host logs from common log, so for
> awstats you don't need to use more logfiles.
>
>
I appreciate your response. even I am also very much bother to provide
CustomLog as the server is hosting a no. of vhost. Glad to know that
awstat can simply extract the required info from common log and no
special attention is required. still need the error/access log per vhost
which are very helpful when debugging is required.
Any idea/approach in that direction is very much welcome.
Thanks
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] how to get logs per vhosts ?
Posted by Matus UHLAR - fantomas <uh...@fantomas.sk>.
On 22.09.09 17:30, J. Bakshi wrote:
> In my linux server ( opensuse 11) , I am running apache with some
> vhosts. All the virtual-hosts are running well. But the apache log
> file is common for all the virtual hosts ; that is
> /etc/var/log/apache/access.log. How can I get per vhost log so that I
> can use awstat as well as monitor log for concerned vhost only ?
you can define CustomLog (or TransferLog) directive in each virtual host.
However I don't recommend that one - many logfiles slows down starting and
reloading apache since all log files need to be reopened.
You also can't do it for dynamic virtual hosts, for that you need to log to
a program that will split logs based on virtual host provided.
BTW, awstats is able to extract virtual host logs from common log, so for
awstats you don't need to use more logfiles.
--
Matus UHLAR - fantomas, uhlar@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Silvester Stallone: Father of the RISC concept.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org