Bug 90349

Summary: boot repair tools fail in systemd-nspawn
Product: systemd Reporter: Scott <westlake2012>
Component: generalAssignee: systemd-bugs
Status: RESOLVED NOTABUG QA Contact: systemd-bugs
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description Scott 2015-05-06 19:07:25 UTC
the systemd-nspawn tool used as chroot works as expected using '-b -D /mnt' but for some reason grub-install is failing. 

I think this is important because people occasionally use grub-install to fix boot-up issues. boot repair tools should also work in systemd containers, if not then a capability needs to be added for this to be possible.

I'm starting to look more into using system-nspawn as an alternative to chroot since it is easier to repair both script and bootloader issues in just one container environment.(i'd have to exit systemd-nspawn then reissue mount commands to setup the chroot environment)

(L.P if you're reading this, then you might want to look into this additional capability of support for boot repair tools to work compatible in systemd-nspawn
You mention system-nspawn as an alternative to chroot,  http://0pointer.net/blog/projects/changing-roots.html
)

thanks
Comment 1 Lennart Poettering 2015-05-07 15:40:53 UTC
This is clearly out of focus for nspawn. nspawn is about isolation, and hence explicitly does not open up the host's raw devices to containers. In fact, even if we wanted to support that, we couldn't, since the kernel does not provide device virtualization/namespace for containers.

If you need access to physical devices of the host, then please run your software on the host directly.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.