Bug 46423

Summary: systemd-nspawn: cryptic error when fails due to lack of adaquate namespace support
Product: systemd Reporter: Shawn Landden <shawnlandden>
Component: generalAssignee: Lennart Poettering <lennart>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: All   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments: hint the user of why clone() might fail

Description Shawn Landden 2012-02-21 18:32:56 UTC
Created attachment 57429 [details] [review]
hint the user of why clone() might fail

When running systemd-nspawn I got this cryptic error:

clone() failed: Invalid argument

Someone trying to help in #systemd was clueless as well, even when given the above error message.

I had to use strace, and then examine both the <linux/sched.d> and the systemd source in order to figure out this was due to me not compiling in comprehensive namespace support into my kernel.

Here is a patch that gives a more helpful error message for others that may compile their own kernel, or for other reasons end up with a kernel that can't run systemd-nspawn due to lack of CONFIG_*_NS features.

-Shawn

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.