You are not logged in.
So, I'm not completely sure this is the right sub-forum for this, but it sounded most fitting.
Since upgrading to systemd-218 (from 217) whenever arch-nspawn or even systemd-nspawn directly is called from a build script in jenkins, it has a return code of 1. I can't see why and it has no other output at all. Running the same commands from the build log as the jenkins user works exactly as intended and as it has for the past many systemd versions.
After eventually figuring out the problem was actually systemd-nspawn and not some logical-seeming change between versions, I've downgraded systemd to v217 and now it all works again swimmingly.
The script is here if anyone is interested, but it's pretty straightforward; just puts some locking around running multiple build agents on a single machine concurrently: https://github.com/justin8/puppet/blob/ … kg-jenkins
Does anyone have any ideas on what might cause this? or a way to show more debug info from systemd-nspawn?
Offline
don't have time to check your script atm, but i'd recommend the following:
-sometimes systemd-nspawn chokes on pipes in the command if you're passing it directly (i.e. no -b). but only SOMETIMES.
-have you tried binding the journal for the nspawn'd machine? check out the --link-journal= option in the man page for systemd-nspawn; you may get some useful output there.
Offline
Thanks for that; the journal linking seems really useful; but when I attempt to run it:
$> systemd-nspawn --link-journal=host -D /chroot/root --register=no --bind=/var/cache/pacman/pkg/ pacman -Syu --noconfirm
Spawning container root on /chroot/root.
Press ^] three times within 1s to kill container.
Container root failed with error code 1.
Last edited by justin-8 (2015-01-01 07:53:12)
Offline
Any solutions for this?
I have a jenkins script that executes extra-x86_64-build, which calls arch-nspawn. This fails in jenkins and prints no error message (but used to work a few months ago).
Offline
Stay on 217 at the moment. I was following the upstream bug and contributing some logs, it's supposed to be fixed in git for v219, so just stick to 217 until 219 is out.
Offline
Okay, thanks for the quick reply. :-)
I guess I can manually run this rarely needed build until 219 is out.
Offline
No problem. I just got back to my computer now; here's the link to the bug if you were interested.
Offline
Ah, that explains why the nspawn command issued by arch-nspawn works when manually pasting it into a terminal, but fails when jenkins does its magic. I'm glad this is already fixed upstream (by Lennart himself ), so it's only a matter of time until the job is back to normal operation.
Thanks again.
Offline
If this is solved please edit the first post to add "[SOLVED]" to the title.
Offline