Bug 1302678 - When updating the centos-7.2 image, the boot is broken
Summary: When updating the centos-7.2 image, the boot is broken
Keywords:
Status: CLOSED DUPLICATE of bug 1049656
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libguestfs
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Richard W.M. Jones
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-01-28 11:35 UTC by David Caro
Modified: 2016-06-26 23:51 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-01-28 12:04:17 UTC
Embargoed:


Attachments (Terms of Use)

Description David Caro 2016-01-28 11:35:11 UTC
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):
libguestfs-1.32.0-1.fc23.x86_64
libguestfs-tools-c-1.32.0-1.fc23.x86_64

How reproducible:

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

Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Richard W.M. Jones 2016-01-28 11:42:51 UTC
Can you try adding the --selinux-relabel flag to the command line.

Comment 2 David Caro 2016-01-28 12:02:28 UTC
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 12:04:17 UTC
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.