init.d/vz*: do not auto-restart CTs with ONBOOT=no
Since vzctl 4.1 we have a feature to save the list of running containers
on init.d/vz stop, and then start those containers on init.d/vz start
(in addition to ones having explicit ONBOOT=yes).
This feature, while being great per se, creates a controversial behavior:
if a container is specifically marked with ONBOOT=no but it was running
before a reboot, it is started nevertheless.
The solution is to make it work this way:
> The container will be started on boot by vz initscript if
> either the ONBOOT parameter is set to "yes", or the container was running
> just before last reboot, and the ONBOOT parameter is not set to "no".
> Default value is unset, meaning the container will be started if
> it was running before the last reboot.
This patch
1 implements the above logic in initscripts,
2 fixes --onboot description in vzctl(8) man page accordingly,
3 fixes ONBOOT description in ctid.conf(5) man page accordingly.
http://bugzilla.openvz.org/2456
Reported-by: Joseph <joseph@netletter.at>
Signed-off-by: Kir Kolyshkin <kir@openvz.org>
4 files changed