Description of problem: SELinux blocks systemd-nspawn I have a Fedora 25 x64 Jenkins build machine. It builds RPMs with mock, which uses systemd-nspawn. These builds fail under the current policy, while they succeeded under a previous policy. Version-Release number of selected component (if applicable): selinux-policy-3.13.1-225.18.fc25.noarch selinux-policy-targeted-3.13.1-225.18.fc25.noarch systemd-231-17.fc25.x86_64 mock-1.4.2-1.fc25.noarch How reproducible: always Steps to Reproduce: 1. see description 2. 3. Actual results: fail DEBUG util.py:606: child environment: None DEBUG util.py:533: Executing command: ['/usr/bin/systemd-nspawn', '-q', '-M', '61d6d0878d144554837f64551aa1f62c', '-D', '/var/lib/mock/fedora-25-x86_64-gradle-upstream.5JzSZZVEsj/root', '-a', '--setenv=PATH=/usr/bin:/bin:/usr/sbin:/sbin', '--setenv=PROMPT_COMMAND=printf "\\033]0;<mock-chroot>\\007"', '--setenv=SHELL=/bin/bash', '--setenv=PS1=<mock-chroot> \\s-\\v\\$ ', '--setenv=HOSTNAME=mock', '--setenv=HOME=/builddir', '--setenv=TERM=vt100', '--setenv=LANG=en_US.UTF-8', '/usr/sbin/userdel', '-r', '-f', 'mockbuild'] with env {'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;<mock-chroot>\\007"', 'SHELL': '/bin/bash', 'PS1': '<mock-chroot> \\s-\\v\\$ ', 'HOSTNAME': 'mock', 'HOME': '/builddir', 'TERM': 'vt100', 'LANG': 'en_US.UTF-8'} and shell False DEBUG util.py:307: Unsharing. Flags: 134217728 DEBUG util.py:450: Failed to register machine: Connection timed out DEBUG util.py:450: Parent died too early DEBUG util.py:588: Child return code was: 1 No AVCs Expected results: success Additional info: # groups jenkins jenkins : jenkins mock
Setting 'setenforce 0' fixes the build, but is obviously not preferred
Might also be systemd-nspawn itself. I did see some (parts of) jobs succeed and other fail while SELinux was in enforcing.
strange things are happening. closing until I have a better idea of what is going on.
Ok, there might be a bad interaction here between systemd-nspawn and SELinux. It failed again for me and setting SELinux to NOT enforcing fixed it again.
This message is a reminder that Fedora 25 is nearing its end of life. Approximately 4 (four) weeks from now Fedora will stop maintaining and issuing updates for Fedora 25. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '25'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 25 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
This message is a reminder that Fedora 27 is nearing its end of life. On 2018-Nov-30 Fedora will stop maintaining and issuing updates for Fedora 27. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '27'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 27 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 27 changed to end-of-life (EOL) status on 2018-11-30. Fedora 27 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.