[Ovirt-devel] [PATCH] wrappers for taskomatic.rb and host-status.rb

steve linabery slinabery at gmail.com
Fri May 2 17:41:02 UTC 2008


On Thu, May 1, 2008 at 6:09 PM, Hugh O. Brock <hbrock at redhat.com> wrote:
> On Thu, May 01, 2008 at 11:56:38PM +0100, Daniel P. Berrange wrote:
>  > On Thu, May 01, 2008 at 05:37:04PM -0500, steve linabery wrote:
>  >
>
> > This is not really a good idea.
>  >
>  > The decision about how/if to daemonize belows to the initscripts. In
>  > SysV init this is daemon/killproc. In the new Upstart world, it doesn't
>  > daemonize at all - it keeps ownership of the process so it can detect
>  > death & restart.
>  >
>  > Xen used to follow the approach of your patch too and we just spent
>  > time ripping out all that code and making it used daemon/killproc
>  > correctly in the initscripts in F10.
>  >
>  > The simpler way around this problem would have just been to change the
>  > existing initscript to pass '-n' when starting the programs so that
>  > the Daemons.daemonize() call was skipped - it was redundant when running
>  > the program via the 'daemon' shell command. And figuring out whatever  is
>  > needed to make killproc work correctly.
>  >
>  > The existing initscript also really needs to be split up so that there is
>  > one initscript per daemon that ovirt has.
>  >
>  > Dan.
>
>  Whups... guess I shouldna acked it then.
>
>  Steve, care to try again along the lines above?
>
>  --Hugh
>

Hi Hugh and ovirt,

Well, it turns out it is even simpler than that. All I really needed
to do was look at host-keyadd, which cooperates well with daemon &
killproc by doing 'include Daemonize' and calling 'daemonize', as
you'll see in the attached patch.

Patch adjusts taskomatic.rb and host-status.rb accordingly, and now
they play nice with /etc/init.d/ovirt-wui script.

Good day,
Steve Linabery
-------------- next part --------------
A non-text attachment was scrubbed...
Name: daemons.patch
Type: text/x-patch
Size: 1086 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/ovirt-devel/attachments/20080502/10e2d0fd/attachment.bin>


More information about the ovirt-devel mailing list