xen-create-image fails to effectively prevent daemon startup on roles execution

Bug #997063 reported by Alessandro Grassi
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
xen-tools (Ubuntu)
Fix Released
Undecided
Axel Beckert

Bug Description

This bug affects xen-tools 4.2.1-1 in Ubuntu 12.04 (precise) LTS.
When installing the base system, debootstrap disables daemon startup by replacing both initctl and start-stop-daemon, this is correct.
When using "installDebianPackage()" from common.sh in xen roles, however, the startup is not correctly prevented because only start-stop-daemon is disabled and not initctl.
This causes processes to remain active even after the filesystem has been unmounted.

Steps to reproduce:

a) create a xen role using installDebianPackage to install apticron
b) create an image with that role

apticron will cause cron to start.

I will provide a patch as soon as i'm finished testing it.

Tags: patch precise

Related branches

Revision history for this message
Alessandro Grassi (xstasi) wrote :

As anticipated in the report, i'm attaching the patch that fixes the problem.

Best regards

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "xen-tools_common.sh.patch" of this bug report has been identified as being a patch. The ubuntu-reviewers team has been subscribed to the bug report so that they can review the patch. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-reviewers team please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

tags: added: patch
Axel Beckert (xtaran)
Changed in xen-tools (Ubuntu):
assignee: nobody → Axel Beckert (xtaran)
status: New → In Progress
Axel Beckert (xtaran)
tags: added: precise
Revision history for this message
Alessandro Grassi (xstasi) wrote :

The previously attached patch was incomplete, in fact i forgot to also patch the enableStartStopDaemon() function.

This patch has been tested and works properly.

I apologize for the mistake.

Axel Beckert (xtaran)
Changed in xen-tools (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package xen-tools - 4.3~rc1-1

---------------
xen-tools (4.3~rc1-1) unstable; urgency=low

  * New upstream release candidate
    - Correctly checks and documents valid values for
      disk_device. (Closes: #621499)
    - Supports creating Ubuntu 11.10 Oneiric DomUs (LP: #848654)
    - Supports creating Ubuntu 12.04 Precise and 12.10 Quantal DomUs
    - Supports creating CentOS 6 DomUs (Closes: #578399; Thanks Johan
      Schurer)
      + Recommend rinse >= 1.9.1-1
    - Supports rinse 2.0
    - Updated mirror list for discontinued releases of Debian and Ubuntu
    - Workaround for missing unit parsing in xen-create-nfs (Closes:
      #648814)
    - Fix wildcard vs regexp in memory configuration parsing.
    - Fix misbehaviour if --ip option is passed multiple times (Closes:
      #652110; Thanks Brian Bennett and Alexander Mette!)
    - Supports /etc/apt/sources.list.d/ (Closes: #650300)
    - xt-guess-suite-and-mirror exits with non-zero if no proper mirror
      could be extracted from /etc/apt/sources.list or
      /etc/apt/sources.list.d/*.list (Thanks Phil Frost!)
    - Only attempts to generate the ssh host keys if not already present
      (Closes: #607236; Thanks Vagrant Cascadian!)
    - New option --apt_proxy (Closes: #610457; Thanks Alex Tomlins!)
    - Always write down root partition as first physical device, otherwise
      pygrub fails (Closes: #609673)
    - No more expect at least one option to mkfs.* calls. Fixes btrfs
      creation. (Closes: #609982)
    - Fixes call to non-existent function logPrint (Closes: #673335)
    - Also disable initctl in the chroot, not only start-stop-daemon
      (LP: #997063; Thanks xstasi!)
    - Massive code deduplication in hooks directory
    - Use release blacklist for libc6-xen instead of whitelist in
      hooks/debian.d/20-setup-apt
    - Enforces umask 022 in 50-setup-hostname* (Hopefully closes: #619630)
  * Add dependency on openssh-client for ssh-keygen (Closes: #649108)
  * Use dh_auto_test for build time tests and add according
    build-dependencies on devscripts and libfile-slurp-perl.
  * No more suggest evms-cli -- it's no more available on any supported
    Dom0 distribution. Thanks to Markus Waldeck for the hint.
  * Add NEWS to debian/docs.
  * Bump Standards-Version to 3.9.3 (no changes)
  * Fix the following Lintian warnings:
    - copyright-refers-to-symlink-license
    - debian-rules-missing-recommended-target
  * debian/copyright: Update copyright years
  * Move xen-utils (for pygrub) from Suggests to Recommends as pygrub
    becomes the necessary way to boot more and more often.
  * Remove xen-shell from Recommends, nobody picked it up. (Closes:
    #603708)

 -- Axel Beckert <email address hidden> Fri, 08 Jun 2012 14:18:38 +0200

Changed in xen-tools (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.