As the init script just calls /usr/sbin/xend, it seems that "/usr/sbin/xend stop" does not stop xenstored and xenconsoled. Bad, bad upstream... Can we work around this by taking care of xenstored and xenconsoled from within our init script?
Confirmed here, along with no ill effects from killing xenstored and xenconsoled during /etc/init.d/xend stop (after stopping /usr/sbin/xend, of course).
I may have spoken too soon, so I'm pulling this from the upcoming -r4. I think it needs more testing, and the impact of delaying its inclusion is minimal, at best.
Maybe xen 3.0.3 has fixed this?
lalala
3.0.3 is not in portage anymore. Maybe the new ebuilds? No suitable x86 to try it right now, sorry :(
it's still the same with 3.2.1
Is there any reason not to uncomment the fix in the init script?
I believe Andrew Ross won't be able to help us with this one anymore... I have dug somewhat deeper into that issue. The thing is: if you still have domUs running, do NOT ever kill xenconsoled and xenstored (at LEAST not xenstored). xend alone (without xenstored/xenconsoled) can be restarted without interrupting/impacting running domUs. Currently, the xend init script does not support xends own 'restart' command, thus '/etc/init.d/xend restart' does run the init scripts stop() and start() functions (which will in turn run 'xend stop' + 'xend start'), so I could not just kill xenstored/xenconsoled from the stop() function without any further caretaking. But I have a solution :) I'll patch the init script to only kill xenstored and xenconsoled on '/etc/init.d/xend stop' and NOT on '/etc/init.d/xend restart' (which will only call 'xend restart' then).
Everybody, please test the 3.2.3 ebuilds I just committed to my testing overlay: http://overlays.gentoo.org/dev/wschlich/browser/testing/app-emulation (use "layman -a wschlich-testing"). They contain the fix(es). Reports are very welcome :)
I'm testing the script you posted with xen-tools-3.1.3-r1 and baselayout-1.12.11.1. 1. The restart function won't work at all unless you add a comment containing the strings "svc_stop" and "svc_start" to work around an error check in runscript.sh 2. Based on some very rudimentary tests it certainly looks like the script works as expected.
One must NOT stop xenstored/xenconsoled (not supported by Xen). Other fixes are in portage now (3.4.1-r1).