[Pkg-xen-devel] Bug#678923: Bug#678923: Acknowledgement (xcp-xapi: host-disable and host-reboot make host disable forever)

Mike McClurg mike.mcclurg at gmail.com
Thu Jul 5 16:55:40 UTC 2012


On Thu, Jul 5, 2012 at 3:21 AM, George Shuklin <george.shuklin at gmail.com> wrote:
> I've done some additional research on that bug.
>
> Brief bug description:
> xe host-disable; xe host-reboot make host disabled endlessly after reboot
> without chances to be enabled:
>
>
> xe host-enable uuid=
> The specified host is disabled and cannot be re-enabled until after it
> has rebooted
>
> What I found:
>
> 1) That settings (host_disabled_until_reboot) is stored in
> /var/lib/xcp/local.db.
> Stopping xcp-xapi, removing that file and starting xcp-xapi back works . But
> ugly hack.
> 2) That attribute is written during reboot, initiated by xe host-reboot.
>
> Question is: what change that value in XCP? xapi or some other startup
> script?

Okay, I think that the problem is that we forgot to call xapi with the
-onsystemboot flag in the xcp-xapi.init script. Here is an untested
patch that you should be able to manually apply (as in edit the init
file by hand) to test if this fixes the issue.

I'll push a proper patch to my github soon.

Mike

diff --git a/debian/xcp-xapi.init b/debian/xcp-xapi.init
index 055e17b..b3c5959 100755
--- a/debian/xcp-xapi.init
+++ b/debian/xcp-xapi.init
@@ -23,7 +23,7 @@ PATH=/sbin:/usr/sbin:/bin:/usr/bin
 DESC="The XenAPI server"
 NAME=xapi
 DAEMON=/usr/sbin/$NAME
-DAEMON_ARGS="-daemon -writereadyfile $XAPI_STARTUP_COOKIE
-writeinitcomplete $XAPI_INIT_COMPLETE_COOKIE"
+DAEMON_ARGS="-daemon -writereadyfile $XAPI_STARTUP_COOKIE
-writeinitcomplete $XAPI_INIT_COMPLETE_COOKIE -onsystemboot"
 PIDFILE=/var/run/$NAME.pid
 SCRIPTNAME=/etc/init.d/$NAME
 TEMPLATES_MD5_STAMP=/var/lib/xcp/templates.md5





More information about the Pkg-xen-devel mailing list