Bug 1302678 - When updating the centos-7.2 image, the boot is broken
When updating the centos-7.2 image, the boot is broken
Status: CLOSED DUPLICATE of bug 1049656
Product: Virtualization Tools
Classification: Community
Component: libguestfs (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Richard W.M. Jones
Depends On:
  Show dependency treegraph
Reported: 2016-01-28 06:35 EST by David Caro
Modified: 2016-06-26 19:51 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-01-28 07:04:17 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description David Caro 2016-01-28 06:35:11 EST
Description of problem:

If you update the centos-7.2 image when building it:

  virt-builder centos-7.2 --update

Then the image does not boot properly complaining about selinux denying access to /dev/vda3.

You can work around it by setting selinux as permissive for the first boot, and then relabeling the root dir, then setting selinux as enforcing does not break the boot process anymore.

Version-Release number of selected component (if applicable):

How reproducible:

virt-builder centos-7.2 --update
Then try booting that disk

Steps to Reproduce:

Actual results:

Expected results:

Additional info:
Comment 1 Richard W.M. Jones 2016-01-28 06:42:51 EST
Can you try adding the --selinux-relabel flag to the command line.
Comment 2 David Caro 2016-01-28 07:02:28 EST
Due to https://bugzilla.redhat.com/show_bug.cgi?id=1049656 that does not work, but as it's suggested there (and you told me by irc): 

 --edit '/usr/lib/systemd/system/rhel-autorelabel.service: $_ = "" if /StandardInput=tty/'

Works like a charm :)
Comment 3 Richard W.M. Jones 2016-01-28 07:04:17 EST
OK let's mark this as another duplicate of that systemd bug.

*** This bug has been marked as a duplicate of bug 1049656 ***

Note You need to log in before you can comment on or make changes to this bug.