You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by Samisa Abeysinghe <sa...@gmail.com> on 2007/11/03 07:11:39 UTC

maximum log file size 1M

I saw this commit where the maximum log file size is set to 1M.

I am just curious to know, what happens when it exceeds 1M?

Also, for a production system, I deem that 1M is too small.

Samisa...

-------- Original Message --------
Subject: 	svn commit: r591271 - 
/webservices/axis2/trunk/c/util/include/axutil_utils.h
Date: 	Fri, 02 Nov 2007 08:58:07 -0000
From: 	damitha@apache.org
To: 	axis2-cvs@ws.apache.org



Author: damitha
Date: Fri Nov  2 01:58:07 2007
New Revision: 591271

URL: http://svn.apache.org/viewvc?rev=591271&view=rev
Log:
made the default maximum log file size 1M

Modified:
    webservices/axis2/trunk/c/util/include/axutil_utils.h

Modified: webservices/axis2/trunk/c/util/include/axutil_utils.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/util/include/axutil_utils.h?rev=591271&r1=591270&r2=591271&view=diff
==============================================================================
--- webservices/axis2/trunk/c/util/include/axutil_utils.h (original)
+++ webservices/axis2/trunk/c/util/include/axutil_utils.h Fri Nov  2 01:58:07 2007
@@ -40,7 +40,7 @@
      * @file axutil_utils.h
      */
 
-#define AXUTIL_LOG_FILE_SIZE 1024 * 1024 * 8
+#define AXUTIL_LOG_FILE_SIZE 1024 * 1024 * 1
 #define AXUTIL_LOG_FILE_NAME_SIZE 512
 
     /** This macro is called to check whether structure on which function is called



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org




-- 
Samisa Abeysinghe

http://people.apache.org/~samisa/


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Damitha Kumarage <da...@gmail.com>.
Samisa Abeysinghe wrote:

> I also notice that the maximum file size limit signal handling logic 
> that I added to log has been removed form the latest changes:
> signal(SIGXFSZ, SIG_IGN);
>
> What was the rationale for removing it?

Frankly I did not intentionally remove it. I'm wondering whether some 
mishap has happened during  my patch. Anyway I fixed it.
Thanks
Damitha


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
I also notice that the maximum file size limit signal handling logic 
that I added to log has been removed form the latest changes:
signal(SIGXFSZ, SIG_IGN);

What was the rationale for removing it?

Samisa...

Samisa Abeysinghe wrote:
> There are few problems in this implementation as far as consistancy is 
> concerned.
> 1. When I ran ./axis2_http_server -h it tells me
> "-s LOG_FILE_SIZE         Maximum log file size in mega bytes, default 
> maximum size is 8MB."
> Looks like it is incorrect. AXUTIL_LOG_FILE_SIZE, which is the default 
> is 1MB
>
> 2. ./axis2_tcp_server -h does not tel anything about log file size :(
>
> 3. How do I contol log file size in case of mod_axis2 httpd module?
>
> Samisa...
>
> Samisa Abeysinghe wrote:
>> Dinesh Premalal wrote:
>>> Hi,
>>>
>>> Samisa Abeysinghe <sa...@gmail.com> writes:
>>>
>>>  
>>>> I saw this commit where the maximum log file size is set to 1M.
>>>>
>>>> I am just curious to know, what happens when it exceeds 1M?
>>>>     
>>> AFAIK, that file is backed up (axis2.log.1) and start new file
>>> (axis2.log). Then , if new one also exceeds 1M, it is backed up over
>>> writing old backed up file.
>>>
>>> Finally, system has only two files, current log file (axis2.log) and 
>>> immediate
>>> recent log file (axis2.log.1).
>>>   
>> So it is only two levels. Is that good enough?
>>
>> The other concern is that, the code is already commited and it was 
>> never discussed on this list, despite it being a major decision :)
>>
>> Have we implemented this so that it works for all the deployment 
>> models like simple http/tcp servers as well as the httpd module?
>>>  
>>>> Also, for a production system, I deem that 1M is too small.
>>>>     
>>> I guess not :), I looked at some other logs (#ls -lah
>>> /var/log/ ) they even hardly exceeds 300K.
>>>   
>> I guess you looked on your PC, it is not a production system, it is? ;-)
>> On my PC, apache error log is 491K already and I hardly run it on a 
>> daily basis.
>>
>> Samisa...
>>> Dinesh
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
>>> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>>>
>>>
>>>   
>>
>>
>
>


-- 
Samisa Abeysinghe 
Software Architect; WSO2 Inc.; http://www.wso2.com/
email: samisa@wso2.com; cell: +94 77 753 7913

"Oxygenating the Web Service Platform."


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: [Axis2] AXIS2_LOG_LEVEL_SERVICE

Posted by Nandika Jayawardana <ja...@gmail.com>.
+1
-- Nandika

On 11/5/07, Damitha Kumarage <da...@gmail.com> wrote:
>
> +1
> Damitha
> Samisa Abeysinghe wrote:
>
> > I see that a new log level named AXIS2_LOG_LEVEL_SERVICE has been
> > added lately.
> >
> > I think, not only the service writer, but also those who implement
> > clients would be interested in such a log level.
> >
> > So I propose that AXIS2_LOG_LEVEL_SERVICE be renamed to
> > AXIS2_LOG_LEVEL_USER, so that both server side as well as client side
> > users could use that log level.
>
> >
> > Samisa...
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-c-dev-help@ws.apache.org
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>


-- 
http://nandikajayawardana.blogspot.com/
WSO2 Inc: http://www.wso2.com

Re: [Axis2] AXIS2_LOG_LEVEL_SERVICE

Posted by Damitha Kumarage <da...@gmail.com>.
+1
Damitha
Samisa Abeysinghe wrote:

> I see that a new log level named AXIS2_LOG_LEVEL_SERVICE has been 
> added lately.
>
> I think, not only the service writer, but also those who implement 
> clients would be interested in such a log level.
>
> So I propose that AXIS2_LOG_LEVEL_SERVICE be renamed to 
> AXIS2_LOG_LEVEL_USER, so that both server side as well as client side 
> users could use that log level.

>
> Samisa...
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: [Axis2] AXIS2_LOG_LEVEL_SERVICE

Posted by Senaka Fernando <se...@wso2.com>.
On Mon, 2007-11-05 at 07:44 +0600, Samisa Abeysinghe wrote:
> I see that a new log level named AXIS2_LOG_LEVEL_SERVICE has been added 
> lately.
> 
> I think, not only the service writer, but also those who implement 
> clients would be interested in such a log level.
> 
> So I propose that AXIS2_LOG_LEVEL_SERVICE be renamed to 
> AXIS2_LOG_LEVEL_USER, so that both server side as well as client side 
> users could use that log level.
+1
> 
> Samisa...
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: [Axis2] AXIS2_LOG_LEVEL_SERVICE

Posted by Dinesh Premalal <xy...@gmail.com>.
On 11/5/07, Samisa Abeysinghe <sa...@wso2.com> wrote:
>
> I see that a new log level named AXIS2_LOG_LEVEL_SERVICE has been added
> lately.
>
> I think, not only the service writer, but also those who implement
> clients would be interested in such a log level.
>
> So I propose that AXIS2_LOG_LEVEL_SERVICE be renamed to
> AXIS2_LOG_LEVEL_USER, so that both server side as well as client side
> users could use that log level.
>

+1

-- 
Dinesh Premalal
http://xydinesh.wordpress.com

[Axis2] AXIS2_LOG_LEVEL_SERVICE

Posted by Samisa Abeysinghe <sa...@wso2.com>.
I see that a new log level named AXIS2_LOG_LEVEL_SERVICE has been added 
lately.

I think, not only the service writer, but also those who implement 
clients would be interested in such a log level.

So I propose that AXIS2_LOG_LEVEL_SERVICE be renamed to 
AXIS2_LOG_LEVEL_USER, so that both server side as well as client side 
users could use that log level.

Samisa...

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
There are few problems in this implementation as far as consistancy is 
concerned.
1. When I ran ./axis2_http_server -h it tells me
"-s LOG_FILE_SIZE         Maximum log file size in mega bytes, default 
maximum size is 8MB."
Looks like it is incorrect. AXUTIL_LOG_FILE_SIZE, which is the default 
is 1MB

2. ./axis2_tcp_server -h does not tel anything about log file size :(

3. How do I contol log file size in case of mod_axis2 httpd module?

Samisa...

Samisa Abeysinghe wrote:
> Dinesh Premalal wrote:
>> Hi,
>>
>> Samisa Abeysinghe <sa...@gmail.com> writes:
>>
>>  
>>> I saw this commit where the maximum log file size is set to 1M.
>>>
>>> I am just curious to know, what happens when it exceeds 1M?
>>>     
>> AFAIK, that file is backed up (axis2.log.1) and start new file
>> (axis2.log). Then , if new one also exceeds 1M, it is backed up over
>> writing old backed up file.
>>
>> Finally, system has only two files, current log file (axis2.log) and 
>> immediate
>> recent log file (axis2.log.1).
>>   
> So it is only two levels. Is that good enough?
>
> The other concern is that, the code is already commited and it was 
> never discussed on this list, despite it being a major decision :)
>
> Have we implemented this so that it works for all the deployment 
> models like simple http/tcp servers as well as the httpd module?
>>  
>>> Also, for a production system, I deem that 1M is too small.
>>>     
>> I guess not :), I looked at some other logs (#ls -lah
>> /var/log/ ) they even hardly exceeds 300K.
>>   
> I guess you looked on your PC, it is not a production system, it is? ;-)
> On my PC, apache error log is 491K already and I hardly run it on a 
> daily basis.
>
> Samisa...
>> Dinesh
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
>> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>>
>>
>>   
>
>


-- 
Samisa Abeysinghe 
Software Architect; WSO2 Inc.; http://www.wso2.com/
email: samisa@wso2.com; cell: +94 77 753 7913

"Oxygenating the Web Service Platform."


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Dinesh Premalal <xy...@gmail.com>.
Samisa Abeysinghe <sa...@wso2.com> writes:
>> AFAIK, that file is backed up (axis2.log.1) and start new file
>> (axis2.log). Then , if new one also exceeds 1M, it is backed up over
>> writing old backed up file.
>>
>> Finally, system has only two files, current log file (axis2.log) and immediate
>> recent log file (axis2.log.1).
>>   
> So it is only two levels. Is that good enough?
Good enough than a single file , I guess :)

> The other concern is that, the code is already commited and it was
> never discussed on this list, despite it being a major decision :)

+1, I also didn't see any discussion regarding this change beforehand.

> Have we implemented this so that it works for all the deployment
> models like simple http/tcp servers as well as the httpd module?

Hope, Damitha will chime in some point :)
>>   
>>> Also, for a production system, I deem that 1M is too small.
>>>     
>> I guess not :), I looked at some other logs (#ls -lah
>> /var/log/ ) they even hardly exceeds 300K.
>>   
> I guess you looked on your PC, it is not a production system, it is? ;-)
> On my PC, apache error log is 491K already and I hardly run it on a
> daily basis.

I'm not sure whether apache using rotational or not. My point is since
log file is a text file, even 1M is too large. WDT?

thanks,
Dinesh

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
>>
>> The other concern is that, the code is already commited and it was 
>> never discussed on this list, despite it being a major decision :)
>
> https://issues.apache.org/jira/browse/AXIS2C-732.
Opps! I filter my mail form Jira :(

Samisa...

-- 
Samisa Abeysinghe 
Software Architect; WSO2 Inc.; http://www.wso2.com/
email: samisa@wso2.com; cell: +94 77 753 7913

"Oxygenating the Web Service Platform."


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
Sanjaya Karunasena wrote:
>>>>>>             
>>>>> I am bit confused here. Why do we couple http transport with logging. I
>>>>> see a violation of seperation of concerns. This logging is for Axis2.
>>>>> Http is just one of the transports. Resposibility shoud be with Axis2.
>>>>>           
>>>> This is about accepting the configuration parameters as server startup
>>>> arguments.
>>>> For example maximum log file size is given for simple axis2 server
>>>> ./axis2_http_server -LOG_FILE_SIZE <value in mb>
>>>> Similarly we need a way to provide this when starting apache2 server
>>>> with axis2 module plugged in. This argument value is appropriatly
>>>> handled by our server startup code and pass to the logging module which
>>>> has no dependancy on transport :)
>>>>         
>>> So my question is shouldn't that be part of axis2.xml? httpd.conf belongs
>>> to the http server. If I run this only using TCP?
>>>       
>> What if I run two server instances using the same axis2.xml?
>>     
>
> Is it two server instances or supporting two transports?
>   

Can be both.
I can run simple axis server as well as httpd with the same repo (same
services and modules)
I can also use http with simple axis server and tcp with tcp server with
the same repo as well.

Samisa...


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Sanjaya Karunasena <sa...@wso2.com>.
On Friday 09 November 2007, Samisa Abeysinghe wrote:
> Sanjaya Karunasena wrote:
> > On Thursday 08 November 2007, Damitha Kumarage wrote:
> >> Hi Sanjaya
> >>
> >> Sanjaya Karunasena wrote:
> >>> On Wednesday 07 November 2007, Samisa Abeysinghe wrote:
> >>>> Damitha Kumarage wrote:
> >>>>> Hmmm, yes we need to add a new config parameter to httpd.conf. How
> >>>>> about Axis2MaxLogFileSize ?
> >>>>
> >>>> +1.
> >>>>
> >>>> Samisa...
> >>>
> >>> I am bit confused here. Why do we couple http transport with logging. I
> >>> see a violation of seperation of concerns. This logging is for Axis2.
> >>> Http is just one of the transports. Resposibility shoud be with Axis2.
> >>
> >> This is about accepting the configuration parameters as server startup
> >> arguments.
> >> For example maximum log file size is given for simple axis2 server
> >> ./axis2_http_server -LOG_FILE_SIZE <value in mb>
> >> Similarly we need a way to provide this when starting apache2 server
> >> with axis2 module plugged in. This argument value is appropriatly
> >> handled by our server startup code and pass to the logging module which
> >> has no dependancy on transport :)
> >
> > So my question is shouldn't that be part of axis2.xml? httpd.conf belongs
> > to the http server. If I run this only using TCP?
>
> What if I run two server instances using the same axis2.xml?

Is it two server instances or supporting two transports?

>
> Samisa...
>
> > /Sanjaya
> >
> >> Thanks,
> >> Damitha
> >>
> >>> Am I missing some thing here?
> >>>
> >>> Thanks
> >>> Sanjaya
> >>>
> >>> ---------------------------------------------------------------------
> >>> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> >>> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> >> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
Sanjaya Karunasena wrote:
> On Thursday 08 November 2007, Damitha Kumarage wrote:
>   
>> Hi Sanjaya
>>
>> Sanjaya Karunasena wrote:
>>     
>>> On Wednesday 07 November 2007, Samisa Abeysinghe wrote:
>>>       
>>>> Damitha Kumarage wrote:
>>>>         
>>>>> Hmmm, yes we need to add a new config parameter to httpd.conf. How about
>>>>> Axis2MaxLogFileSize ?
>>>>>           
>>>> +1.
>>>>
>>>> Samisa...
>>>>         
>>> I am bit confused here. Why do we couple http transport with logging. I
>>> see a violation of seperation of concerns. This logging is for Axis2.
>>> Http is just one of the transports. Resposibility shoud be with Axis2.
>>>       
>> This is about accepting the configuration parameters as server startup
>> arguments.
>> For example maximum log file size is given for simple axis2 server
>> ./axis2_http_server -LOG_FILE_SIZE <value in mb>
>> Similarly we need a way to provide this when starting apache2 server
>> with axis2 module plugged in. This argument value is appropriatly
>> handled by our server startup code and pass to the logging module which
>> has no dependancy on transport :)
>>
>>     
>
> So my question is shouldn't that be part of axis2.xml? httpd.conf belongs to 
> the http server. If I run this only using TCP?
>   
What if I run two server instances using the same axis2.xml?

Samisa...
> /Sanjaya
>
>   
>> Thanks,
>> Damitha
>>
>>     
>>> Am I missing some thing here?
>>>
>>> Thanks
>>> Sanjaya
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
>>> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>>>       
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
>> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>>     
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>
>
>   


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Sanjaya Karunasena <sa...@wso2.com>.
On Thursday 08 November 2007, Damitha Kumarage wrote:
> Hi Sanjaya
>
> Sanjaya Karunasena wrote:
> >On Wednesday 07 November 2007, Samisa Abeysinghe wrote:
> >>Damitha Kumarage wrote:
> >>>Hmmm, yes we need to add a new config parameter to httpd.conf. How about
> >>>Axis2MaxLogFileSize ?
> >>
> >>+1.
> >>
> >>Samisa...
> >
> >I am bit confused here. Why do we couple http transport with logging. I
> > see a violation of seperation of concerns. This logging is for Axis2.
> > Http is just one of the transports. Resposibility shoud be with Axis2.
>
> This is about accepting the configuration parameters as server startup
> arguments.
> For example maximum log file size is given for simple axis2 server
> ./axis2_http_server -LOG_FILE_SIZE <value in mb>
> Similarly we need a way to provide this when starting apache2 server
> with axis2 module plugged in. This argument value is appropriatly
> handled by our server startup code and pass to the logging module which
> has no dependancy on transport :)
>

So my question is shouldn't that be part of axis2.xml? httpd.conf belongs to 
the http server. If I run this only using TCP?

/Sanjaya

> Thanks,
> Damitha
>
> >Am I missing some thing here?
> >
> >Thanks
> >Sanjaya
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> >For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Damitha Kumarage <da...@gmail.com>.
Hi Sanjaya
Sanjaya Karunasena wrote:

>On Wednesday 07 November 2007, Samisa Abeysinghe wrote:
>  
>
>>Damitha Kumarage wrote:
>>    
>>
>>>Hmmm, yes we need to add a new config parameter to httpd.conf. How about
>>>Axis2MaxLogFileSize ?
>>>      
>>>
>>+1.
>>
>>Samisa...
>>    
>>
>
>I am bit confused here. Why do we couple http transport with logging. I see a 
>violation of seperation of concerns. This logging is for Axis2. Http is just 
>one of the transports. Resposibility shoud be with Axis2.
>  
>
This is about accepting the configuration parameters as server startup 
arguments.
For example maximum log file size is given for simple axis2 server
./axis2_http_server -LOG_FILE_SIZE <value in mb>
Similarly we need a way to provide this when starting apache2 server 
with axis2 module plugged in. This argument value is appropriatly 
handled by our server startup code and pass to the logging module which 
has no dependancy on transport :)

Thanks,
Damitha

>Am I missing some thing here?
>
>Thanks
>Sanjaya
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
>For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>
>  
>


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Sanjaya Karunasena <sa...@wso2.com>.
On Wednesday 07 November 2007, Samisa Abeysinghe wrote:
> Damitha Kumarage wrote:
> > Hmmm, yes we need to add a new config parameter to httpd.conf. How about
> > Axis2MaxLogFileSize ?
>
> +1.
>
> Samisa...

I am bit confused here. Why do we couple http transport with logging. I see a 
violation of seperation of concerns. This logging is for Axis2. Http is just 
one of the transports. Resposibility shoud be with Axis2.

Am I missing some thing here?

Thanks
Sanjaya

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
Damitha Kumarage wrote:
> Hmmm, yes we need to add a new config parameter to httpd.conf. How about
> Axis2MaxLogFileSize ?
+1.

Samisa...

-- 
Samisa Abeysinghe 
Software Architect; WSO2 Inc.; http://www.wso2.com/
email: samisa@wso2.com; cell: +94 77 753 7913

"Oxygenating the Web Service Platform."


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Damitha Kumarage <da...@gmail.com>.
Hi,

>>>
>>> I was thinking about the httpd module case, and it looks like we may 
>>> have to introduce a new httpd.conf config parameter to support this.
>>
>>
>> I did the following change to mod_axis2.c
>>
>>       ...........
>>       ...........
>>        else if (!strcasecmp(str, "debug"))
>>        {
>>            level = AXIS2_LOG_LEVEL_DEBUG;
>>        }
>>        else if (!strcasecmp(str, "user"))
>>        {
>>            level = AXIS2_LOG_LEVEL_USER;
>>        }
>>
>> and then changed the log level in httpd.conf as follows
>> Axis2LogLevel user
>>
>> After that when I write an user log in echo server sample it seems to 
>> work. ie. write only user
>> level and critical/error messages in the log file. I hope this has 
>> done what we require. isn't it?
>
> Yes and thanks for the update. This is solving the log level stuff.
>
> My thoughts were on the lines of how to set max log file size when 
> using mod apache2.
>
Hmmm, yes we need to add a new config parameter to httpd.conf. How about
Axis2MaxLogFileSize ?

Damitha



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@gmail.com>.
Damitha Kumarage wrote:
> Hi Samisa,
> Samisa Abeysinghe wrote:
>
>> Damitha Kumarage wrote:
>>
>>> Hi,
>>>
>>>> So it is only two levels. Is that good enough?
>>>
>>>
>>> If this is not sufficient for our production environments, yes we 
>>> need to implement a log rotating mechanism.
>>>
>>>>
>>>> The other concern is that, the code is already commited and it was 
>>>> never discussed on this list, despite it being a major decision :)
>>>
>>>
>>> https://issues.apache.org/jira/browse/AXIS2C-732.
>>>
>>>>
>>>> Have we implemented this so that it works for all the deployment 
>>>> models like simple http/tcp servers as well as the httpd module?
>>>
>>>
>>> It is not implemented for tcp and httpd modules yet.
>>
>> I was thinking about the httpd module case, and it looks like we may 
>> have to introduce a new httpd.conf config parameter to support this.
>
> I did the following change to mod_axis2.c
>
>       ...........
>       ...........
>        else if (!strcasecmp(str, "debug"))
>        {
>            level = AXIS2_LOG_LEVEL_DEBUG;
>        }
>        else if (!strcasecmp(str, "user"))
>        {
>            level = AXIS2_LOG_LEVEL_USER;
>        }
>
> and then changed the log level in httpd.conf as follows
> Axis2LogLevel user
>
> After that when I write an user log in echo server sample it seems to 
> work. ie. write only user
> level and critical/error messages in the log file. I hope this has 
> done what we require. isn't it?
Yes and thanks for the update. This is solving the log level stuff.

My thoughts were on the lines of how to set max log file size when using 
mod apache2.

Thanks,
Samisa...
>
> Damitha
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>


-- 
Samisa Abeysinghe

http://people.apache.org/~samisa/


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Damitha Kumarage <da...@gmail.com>.
Hi Samisa,
Samisa Abeysinghe wrote:

> Damitha Kumarage wrote:
>
>> Hi,
>>
>>> So it is only two levels. Is that good enough?
>>
>>
>> If this is not sufficient for our production environments, yes we 
>> need to implement a log rotating mechanism.
>>
>>>
>>> The other concern is that, the code is already commited and it was 
>>> never discussed on this list, despite it being a major decision :)
>>
>>
>> https://issues.apache.org/jira/browse/AXIS2C-732.
>>
>>>
>>> Have we implemented this so that it works for all the deployment 
>>> models like simple http/tcp servers as well as the httpd module?
>>
>>
>> It is not implemented for tcp and httpd modules yet.
>
> I was thinking about the httpd module case, and it looks like we may 
> have to introduce a new httpd.conf config parameter to support this.

I did the following change to mod_axis2.c

       ...........
       ...........
        else if (!strcasecmp(str, "debug"))
        {
            level = AXIS2_LOG_LEVEL_DEBUG;
        }
        else if (!strcasecmp(str, "user"))
        {
            level = AXIS2_LOG_LEVEL_USER;
        }

and then changed the log level in httpd.conf as follows
Axis2LogLevel user

After that when I write an user log in echo server sample it seems to 
work. ie. write only user
level and critical/error messages in the log file. I hope this has done 
what we require. isn't it?

Damitha

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
Damitha Kumarage wrote:
> Hi,
>
>> So it is only two levels. Is that good enough?
>
> If this is not sufficient for our production environments, yes we need 
> to implement a log rotating mechanism.
>
>>
>> The other concern is that, the code is already commited and it was 
>> never discussed on this list, despite it being a major decision :)
>
> https://issues.apache.org/jira/browse/AXIS2C-732.
>
>>
>> Have we implemented this so that it works for all the deployment 
>> models like simple http/tcp servers as well as the httpd module?
>
> It is not implemented for tcp and httpd modules yet.
I was thinking about the httpd module case, and it looks like we may 
have to introduce a new httpd.conf config parameter to support this.

Samisa...

-- 
Samisa Abeysinghe 
Software Architect; WSO2 Inc.; http://www.wso2.com/
email: samisa@wso2.com; cell: +94 77 753 7913

"Oxygenating the Web Service Platform."


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Damitha Kumarage <da...@gmail.com>.
Hi,

> So it is only two levels. Is that good enough?

If this is not sufficient for our production environments, yes we need 
to implement a log rotating mechanism.

>
> The other concern is that, the code is already commited and it was 
> never discussed on this list, despite it being a major decision :)

https://issues.apache.org/jira/browse/AXIS2C-732.

>
> Have we implemented this so that it works for all the deployment 
> models like simple http/tcp servers as well as the httpd module?

It is not implemented for tcp and httpd modules yet.

thanks,
Damitha

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Samisa Abeysinghe <sa...@wso2.com>.
Dinesh Premalal wrote:
> Hi,
>
> Samisa Abeysinghe <sa...@gmail.com> writes:
>
>   
>> I saw this commit where the maximum log file size is set to 1M.
>>
>> I am just curious to know, what happens when it exceeds 1M?
>>     
> AFAIK, that file is backed up (axis2.log.1) and start new file
> (axis2.log). Then , if new one also exceeds 1M, it is backed up over
> writing old backed up file.
>
> Finally, system has only two files, current log file (axis2.log) and immediate
> recent log file (axis2.log.1).
>   
So it is only two levels. Is that good enough?

The other concern is that, the code is already commited and it was never 
discussed on this list, despite it being a major decision :)

Have we implemented this so that it works for all the deployment models 
like simple http/tcp servers as well as the httpd module?
>   
>> Also, for a production system, I deem that 1M is too small.
>>     
> I guess not :), I looked at some other logs (#ls -lah
> /var/log/ ) they even hardly exceeds 300K.
>   
I guess you looked on your PC, it is not a production system, it is? ;-)
On my PC, apache error log is 491K already and I hardly run it on a 
daily basis.

Samisa...
> Dinesh
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>
>   


-- 
Samisa Abeysinghe 
Software Architect; WSO2 Inc.; http://www.wso2.com/
email: samisa@wso2.com; cell: +94 77 753 7913

"Oxygenating the Web Service Platform."


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Sanjaya Karunasena <sa...@wso2.com>.
If you are debugging, you always has the option of setting the log file size 
to what ever you want.

However, due to some reason, if the log grows up to a level where the machine 
ran out of disk space that's really bad. We don't want this in a production 
environment for sure. This simply could freez the machine and system 
administrators will waste time to figure out what happen.

Thanks
Sanjaya

On Saturday 03 November 2007, senaka@wso2.com wrote:
> Hi all,
>
> > hello,
> > The most common way of handling log file growth is via a rotation
> > procedure.
>
> I don't think we have a serious log file size problem to go for a rotation
> process.
>
> > First we define how many old copies of the log file we want to
> > create/keep,
> >
> > and the rate at which they should be rotate(once a day, once a week and
> > so on). When we rotate a given log file, the original file should rename
> > to have a '.1' suffix, rename the old '.1' file to have a '.2' suffix,
> > and so on. The last copy of the log file (with suffix '.n') should be
> > erased. The renaming process is done from last to first, otherwise we
> > will end up with 'n' copies of the current log file. Once done, we create
> > a new, empty log file, with the same access permissions as the original
> > log file.
> >
> > Rajika
> >
> > On 11/3/07, Dinesh Premalal <xy...@gmail.com> wrote:
> >> Hi,
> >>
> >> Samisa Abeysinghe <sa...@gmail.com> writes:
> >> > I saw this commit where the maximum log file size is set to 1M.
> >> >
> >> > I am just curious to know, what happens when it exceeds 1M?
> >>
> >> AFAIK, that file is backed up (axis2.log.1) and start new file
> >> (axis2.log). Then , if new one also exceeds 1M, it is backed up over
> >> writing old backed up file.
> >>
> >> Finally, system has only two files, current log file (axis2.log) and
> >> immediate
> >> recent log file (axis2.log.1).
> >>
> >> > Also, for a production system, I deem that 1M is too small.
> >>
> >> I guess not :), I looked at some other logs (#ls -lah
> >> /var/log/ ) they even hardly exceeds 300K.
>
> You can always specify the MAX_SIZE of the log file.
> (https://issues.apache.org/jira/browse/AXIS2C-732).
>
> But, 1MB would not be enough is my personal belief. I was trying to figure
> out some memory leaks, and, frequently started and stopped the simple axis
> server. My log file exceeded 1MB in 52 runs. Therefore, I believe that it
> should be at least 5MB+ (making it some 250+ runs).
>
> Senaka.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by se...@wso2.com.
Hi all,

> hello,
> The most common way of handling log file growth is via a rotation
> procedure.

I don't think we have a serious log file size problem to go for a rotation
process.

>
>
> First we define how many old copies of the log file we want to
> create/keep,

> and the rate at which they should be rotate(once a day, once a week and so
> on). When we rotate a given log file, the original file should rename to
> have a '.1' suffix, rename the old '.1' file to have a '.2' suffix, and so
> on. The last copy of the log file (with suffix '.n') should be erased. The
> renaming process is done from last to first, otherwise we will end up with
> 'n' copies of the current log file. Once done, we create a new, empty log
> file, with the same access permissions as the original log file.
>
> Rajika
>
> On 11/3/07, Dinesh Premalal <xy...@gmail.com> wrote:
>>
>> Hi,
>>
>> Samisa Abeysinghe <sa...@gmail.com> writes:
>>
>> > I saw this commit where the maximum log file size is set to 1M.
>> >
>> > I am just curious to know, what happens when it exceeds 1M?
>> AFAIK, that file is backed up (axis2.log.1) and start new file
>> (axis2.log). Then , if new one also exceeds 1M, it is backed up over
>> writing old backed up file.
>>
>> Finally, system has only two files, current log file (axis2.log) and
>> immediate
>> recent log file (axis2.log.1).
>>
>> >
>> > Also, for a production system, I deem that 1M is too small.
>> I guess not :), I looked at some other logs (#ls -lah
>> /var/log/ ) they even hardly exceeds 300K.

You can always specify the MAX_SIZE of the log file.
(https://issues.apache.org/jira/browse/AXIS2C-732).

But, 1MB would not be enough is my personal belief. I was trying to figure
out some memory leaks, and, frequently started and stopped the simple axis
server. My log file exceeded 1MB in 52 runs. Therefore, I believe that it
should be at least 5MB+ (making it some 250+ runs).

Senaka.

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


Re: maximum log file size 1M

Posted by Rajika Kumarasiri <ra...@gmail.com>.
hello,
The most common way of handling log file growth is via a rotation procedure.


First we define how many old copies of the log file we want to create/keep,
and the rate at which they should be rotate(once a day, once a week and so
on). When we rotate a given log file, the original file should rename to
have a '.1' suffix, rename the old '.1' file to have a '.2' suffix, and so
on. The last copy of the log file (with suffix '.n') should be erased. The
renaming process is done from last to first, otherwise we will end up with
'n' copies of the current log file. Once done, we create a new, empty log
file, with the same access permissions as the original log file.

Rajika

On 11/3/07, Dinesh Premalal <xy...@gmail.com> wrote:
>
> Hi,
>
> Samisa Abeysinghe <sa...@gmail.com> writes:
>
> > I saw this commit where the maximum log file size is set to 1M.
> >
> > I am just curious to know, what happens when it exceeds 1M?
> AFAIK, that file is backed up (axis2.log.1) and start new file
> (axis2.log). Then , if new one also exceeds 1M, it is backed up over
> writing old backed up file.
>
> Finally, system has only two files, current log file (axis2.log) and
> immediate
> recent log file (axis2.log.1).
>
> >
> > Also, for a production system, I deem that 1M is too small.
> I guess not :), I looked at some other logs (#ls -lah
> /var/log/ ) they even hardly exceeds 300K.
>
> Dinesh
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>


-- 
comp.lang.c - http://groups.google.com/group/comp.lang.c/topics

Re: maximum log file size 1M

Posted by Dinesh Premalal <xy...@gmail.com>.
Hi,

Samisa Abeysinghe <sa...@gmail.com> writes:

> I saw this commit where the maximum log file size is set to 1M.
>
> I am just curious to know, what happens when it exceeds 1M?
AFAIK, that file is backed up (axis2.log.1) and start new file
(axis2.log). Then , if new one also exceeds 1M, it is backed up over
writing old backed up file.

Finally, system has only two files, current log file (axis2.log) and immediate
recent log file (axis2.log.1).

>
> Also, for a production system, I deem that 1M is too small.
I guess not :), I looked at some other logs (#ls -lah
/var/log/ ) they even hardly exceeds 300K.

Dinesh


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org