Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux-HA: Dev

[Patch 2]Change of the output level of the log of the resource agent of mysql.

 

 

Linux-HA dev RSS feed   Index | Next | Previous | View Threaded


renayama19661014 at ybb

Aug 30, 2011, 1:20 AM

Post #1 of 7 (324 views)
Permalink
[Patch 2]Change of the output level of the log of the resource agent of mysql.

Hi,

The resource agent of mysql outputs error log every time in probe,start,stop.


Aug 11 13:38:31 ib01 mysql[15764]: ERROR: MySQL is not running


When a resource does not start, the resource agent changes the level of the log and should output it.

Otherwise the operator is confused by an error.
I modelled it on other resource agents and changed a level of the log.

I send a patch.

Please examine this patch.

Best Regards,
Hideo Yamauchi.
Attachments: mysql.1651-2.patch (1.78 KB)


renayama19661014 at ybb

Sep 11, 2011, 6:19 PM

Post #2 of 7 (293 views)
Permalink
Re: [Patch 2]Change of the output level of the log of the resource agent of mysql. [In reply to]

Hi Raoul,

How about the modified patch of this place?

Best Regards,
Hidoe Yamauchi.

--- On Tue, 2011/8/30, renayama19661014 [at] ybb <renayama19661014 [at] ybb> wrote:

> Hi,
>
> The resource agent of mysql outputs error log every time in probe,start,stop.
>
>
> Aug 11 13:38:31 ib01 mysql[15764]: ERROR: MySQL is not running
>
>
> When a resource does not start, the resource agent changes the level of the log and should output it.
>
> Otherwise the operator is confused by an error.
> I modelled it on other resource agents and changed a level of the log.
>
> I send a patch.
>
> Please examine this patch.
>
> Best Regards,
> Hideo Yamauchi.
_______________________________________________________
Linux-HA-Dev: Linux-HA-Dev [at] lists
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/


r.bhatia at ipax

Sep 19, 2011, 10:40 AM

Post #3 of 7 (282 views)
Permalink
Re: [Patch 2]Change of the output level of the log of the resource agent of mysql. [In reply to]

hello hideo-san!

i just got to review your patch and got one or two questions (see below)

On 08/30/2011 10:20 AM, renayama19661014 [at] ybb wrote:
> mysql.1651-2.patch
>
>
> diff -r a2d0d723bc62 heartbeat/mysql
> --- a/heartbeat/mysql Wed Aug 31 01:32:38 2011 +0900
> +++ b/heartbeat/mysql Wed Aug 31 01:38:08 2011 +0900
> @@ -807,7 +817,7 @@
> # Let the CRM/LRM time us out if required
> start_wait=1
> while [ $start_wait = 1 ]; do
> - mysql_status
> + mysql_status warn
> rc=$?
> if [ $rc = $OCF_SUCCESS ]; then
> start_wait=0
> @@ -908,7 +918,7 @@
> count=0
> while [ $count -lt $shutdown_timeout ]
> do
> - mysql_status
> + mysql_status info
> rc=$?
> if [ $rc = $OCF_NOT_RUNNING ]; then
> break

in mysql_start() you use the warn level
in mysql_stop() you use the info level.

shouldn't these two be the same levels?
(e.g. both warn?)

> @@ -918,7 +928,7 @@
> ocf_log debug "MySQL still hasn't stopped yet. Waiting..."
> done
>
> - mysql_status
> + mysql_status info
> if [ $? != $OCF_NOT_RUNNING ]; then
> ocf_log info "MySQL failed to stop after ${shutdown_timeout}s using SIGTERM. Trying SIGKILL..."
> /bin/kill -KILL $pid> /dev/null

while reviewing the log leves, should we set this last "ocf_log" line
to "warn"? (sorry for mixing this in here - but maybe you can comment
on that too :) )

cheers,
raoul
_______________________________________________________
Linux-HA-Dev: Linux-HA-Dev [at] lists
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/


renayama19661014 at ybb

Sep 19, 2011, 5:11 PM

Post #4 of 7 (282 views)
Permalink
Re: [Patch 2]Change of the output level of the log of the resource agent of mysql. [In reply to]

Hi Raoul,

Thank you for comment.

The log level of my patch is not decision at suggestion.
We think the log level to be allowed to unify it in WARN or INFO either other than ERROR.

If log in status carried out by start and stop does not come to appear at ERROR level, the system administrator is not confused.

Best Regards,
Hideo Yamauchi.



--- On Tue, 2011/9/20, Raoul Bhatia [IPAX] <r.bhatia [at] ipax> wrote:

> hello hideo-san!
>
> i just got to review your patch and got one or two questions (see below)
>
> On 08/30/2011 10:20 AM, renayama19661014 [at] ybb wrote:
> > mysql.1651-2.patch
> >
> >
> > diff -r a2d0d723bc62 heartbeat/mysql
> > --- a/heartbeat/mysql    Wed Aug 31 01:32:38 2011 +0900
> > +++ b/heartbeat/mysql    Wed Aug 31 01:38:08 2011 +0900
> > @@ -807,7 +817,7 @@
> >       # Let the CRM/LRM time us out if required
> >       start_wait=1
> >       while [ $start_wait = 1 ]; do
> > -    mysql_status
> > +    mysql_status warn
> >       rc=$?
> >       if [ $rc = $OCF_SUCCESS ]; then
> >           start_wait=0
> > @@ -908,7 +918,7 @@
> >       count=0
> >       while [ $count -lt $shutdown_timeout ]
> >       do
> > -    mysql_status
> > +    mysql_status info
> >       rc=$?
> >       if [ $rc = $OCF_NOT_RUNNING ]; then
> >           break
>
> in mysql_start() you use the warn level
> in mysql_stop() you use the info level.
>
> shouldn't these two be the same levels?
> (e.g. both warn?)
>
> > @@ -918,7 +928,7 @@
> >       ocf_log debug "MySQL still hasn't stopped yet. Waiting..."
> >       done
> >
> > -    mysql_status
> > +    mysql_status info
> >       if [ $? != $OCF_NOT_RUNNING ]; then
> >       ocf_log info "MySQL failed to stop after ${shutdown_timeout}s using SIGTERM. Trying SIGKILL..."
> >       /bin/kill -KILL $pid>  /dev/null
>
> while reviewing the log leves, should we set this last "ocf_log" line
> to "warn"? (sorry for mixing this in here - but maybe you can comment
> on that too :) )
>
> cheers,
> raoul
>
_______________________________________________________
Linux-HA-Dev: Linux-HA-Dev [at] lists
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/


r.bhatia at ipax

Sep 20, 2011, 1:53 AM

Post #5 of 7 (285 views)
Permalink
Re: [Patch 2]Change of the output level of the log of the resource agent of mysql. [In reply to]

On 09/20/2011 02:11 AM, renayama19661014 [at] ybb wrote:
> Hi Raoul,
>
> Thank you for comment.
>
> The log level of my patch is not decision at suggestion.
> We think the log level to be allowed to unify it in WARN or INFO either other than ERROR.
>
> If log in status carried out by start and stop does not come to appear at ERROR level, the system administrator is not confused.

i've commited your patch with a slight modification in log leves.

please verify:

https://github.com/raoulbhatia/resource-agents/commit/65b7b4202549bc087d3759dc9636b4966e2dafd2

thanks,
raoul
_______________________________________________________
Linux-HA-Dev: Linux-HA-Dev [at] lists
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/


renayama19661014 at ybb

Sep 20, 2011, 2:07 AM

Post #6 of 7 (280 views)
Permalink
Re: [Patch 2]Change of the output level of the log of the resource agent of mysql. [In reply to]

Hi Raoul,

I agree to modified contents.
I will confirm movement tomorrow just to make sure in this resource agent.

Please wait until tomorrow.

Best Regards,
Hideo Yamauchi.


--- On Tue, 2011/9/20, Raoul Bhatia [IPAX] <r.bhatia [at] ipax> wrote:

> On 09/20/2011 02:11 AM, renayama19661014 [at] ybb wrote:
> > Hi Raoul,
> >
> > Thank you for comment.
> >
> > The log level of my patch is not decision at suggestion.
> > We think the log level to be allowed to unify it in WARN or INFO either other than ERROR.
> >
> > If log in status carried out by start and stop does not come to appear at ERROR level, the system administrator is not confused.
>
> i've commited your patch with a slight modification in log leves.
>
> please verify:
>
> https://github.com/raoulbhatia/resource-agents/commit/65b7b4202549bc087d3759dc9636b4966e2dafd2
>
> thanks,
> raoul
>
_______________________________________________________
Linux-HA-Dev: Linux-HA-Dev [at] lists
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/


renayama19661014 at ybb

Sep 20, 2011, 6:15 PM

Post #7 of 7 (291 views)
Permalink
Re: [Patch 2]Change of the output level of the log of the resource agent of mysql. [In reply to]

Hi Raoul,

> > i've commited your patch with a slight modification in log leves.
> >
> > please verify:
> >
> > https://github.com/raoulbhatia/resource-agents/commit/65b7b4202549bc087d3759dc9636b4966e2dafd2

I confirmed movement of RA.
I confirmed log of RA.

There is no problem.

Thanks,
Hideo Yamauchi.



--- On Tue, 2011/9/20, renayama19661014 [at] ybb <renayama19661014 [at] ybb> wrote:

> Hi Raoul,
>
> I agree to modified contents.
> I will confirm movement tomorrow just to make sure in this resource agent.
>
> Please wait until tomorrow.
>
> Best Regards,
> Hideo Yamauchi.
>
>
> --- On Tue, 2011/9/20, Raoul Bhatia [IPAX] <r.bhatia [at] ipax> wrote:
>
> > On 09/20/2011 02:11 AM, renayama19661014 [at] ybb wrote:
> > > Hi Raoul,
> > >
> > > Thank you for comment.
> > >
> > > The log level of my patch is not decision at suggestion.
> > > We think the log level to be allowed to unify it in WARN or INFO either other than ERROR.
> > >
> > > If log in status carried out by start and stop does not come to appear at ERROR level, the system administrator is not confused.
> >
> > i've commited your patch with a slight modification in log leves.
> >
> > please verify:
> >
> > https://github.com/raoulbhatia/resource-agents/commit/65b7b4202549bc087d3759dc9636b4966e2dafd2
> >
> > thanks,
> > raoul
> >
> _______________________________________________________
> Linux-HA-Dev: Linux-HA-Dev [at] lists
> http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
> Home Page: http://linux-ha.org/
>
_______________________________________________________
Linux-HA-Dev: Linux-HA-Dev [at] lists
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/

Linux-HA dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.