[Ocfs2-tools-devel] Review of the o2hbmonitor sem patch

Joel Becker Joel.Becker at oracle.com
Thu Dec 9 11:32:29 PST 2010


On Thu, Dec 09, 2010 at 11:24:09AM -0800, Sunil Mushran wrote:
> On 12/09/2010 11:16 AM, Joel Becker wrote:
> >On Wed, Dec 08, 2010 at 06:58:29PM -0800, Sunil Mushran wrote:
> >>Also, if we cannot determine its status, launch o2hbmonitor after printing
> >>a message to stderr. Not syslog. All of this should be upfront. Not after
> >>we open syslog.
> >	You definitely want to syslog.  Maybe stderr too, but what if it
> >scrolls off the boot screen?  This is a daemon, and it should also
> >record details in syslog.
> 
> Well this specific error will only be printed if another instance of
> o2hbmonitor is running. Why can't we print and exit before we even
> daemonize?

	Daemons should always log.  It allows for audit later.  Imagine
that we have a bug that causes starting a second o2hbmonitor to crash
the first.  How do we know that John Q Sysadmin started a second if it
is not in the logs?
	I agree that we should tell the user on stderr why we aren't
starting a second process.  I fail to see how logging the event hurts.

Joel

-- 

Life's Little Instruction Book #444

	"Never underestimate the power of a kind word or deed."

Joel Becker
Senior Development Manager
Oracle
E-mail: joel.becker at oracle.com
Phone: (650) 506-8127



More information about the Ocfs2-tools-devel mailing list