Not sure if this is a bug or just a functionality misunderstanding on my part. I am rather new to linux and was playing around with rkt containers when I stumbled upon this.
When running the following 2 commands
> systemd-nspawn --version
> echo $?
I get a return code of 1.
Shouldn’t this be a return code of 0?
System Info
VERSION_ID=“20170324”
PRETTY_NAME=“openSUSE Tumbleweed”
OpenSuse is running as a VM inside VMWare workstation. Host is Windows 10.
First a technical feature of the forums here:
Please use CODE tags around copied/pasted computer text in a post. It is the # button in the tool bar of the post editor. When applicable copy/paste complete, that is including the prompt, the command, the output and the next prompt.
When I would then post what you did, it will look like this:
There is no need now to explain “when I did x, I get y”, because we can see it.
The big surprise is of course that doing this to show you an example, I get return code 0 .
I must add that this is on openSUSE 13.2.
The man page (on 13.2) says:
EXIT STATUS
The exit code of the program executed in the container is returned.
As in the --version case there is no program executed, it is a bit doubtful what it should be. 0 looks then logical enough to me.
I will start a LEAP 42.2 system to see what I get.
Which I just did. And guess what? I do get a ) also there.
Thus either you are doing something different (that is why we love you showing all from top to toe), or there is something else going on in your system.
I’ve run the commands again once without sudo and once with, same output.
Maybe there is something strange about my system setup. I’ll try and create a fresh OpenSUSE Tumbleweed VM over the weekend and see if I get the same result. The current VM was “relativly” fresh but hey maybe I did something “interesting” in my noobish ignorance.
Appears as though it is a problem introduced by systemd, however a patch has been applied to the systemd master branch. Now to check if the patch has made it into tumbleweed systemd?
I’m not sure of a convienient way to check if the patch is applied to the builds in the TW repos.
You should submit a bug to bugzilla including the links to the github bug.
The github bug claims that the bug isn’t theirs, it was introduced by someone (Arch?) which is then probably being used as source by other distros.
Only the openSUSE maintainers will know for sure what source is being used.
It’s probably not an openSUSE bug, but only the openSUSE maintainers can know who to notify to fix the bug.