[systemd-devel] systemd-nspawn at .service is unusable
Peter Lemenkov
lemenkov at gmail.com
Fri Dec 5 01:41:32 PST 2014
2014-12-05 4:43 GMT+03:00 Lennart Poettering <lennart at poettering.net>:
> On Thu, 04.12.14 20:12, Peter Lemenkov (lemenkov at gmail.com) wrote:
>
>> Hello All!
>>
>> I'm playing with systemd-nspawn at .service and cannot make it work. It
>> seems that similar issues were discussed (and addressed upstream) in
>> Debian bug #770275 ( https://bugs.debian.org/770275 ) however I
>> believe I've hit by something else.
>>
>> What I've done so far:
>>
>> * Ensured that /var/lib/container exists
>> * Created both /var/log/journal/<machineid> and
>> /var/lib/container/<containername>/var/log/journal/<machineid>
>> * Ensured that Storage=persistent is set in
>> /var/lib/container/<containername>/etc/systemd/journald.conf
>>
>> Every my attempt to run "systemctl status
>> systemd-nspawn@<containername>" ended up like this:
>>
>> https://paste.fedoraproject.org/156640/14177088/
>>
>> Please note that systemd-journald fails so I can't find out what's
>> going on there. I'm stuck right here. Some other services failed as
>> well, and I can't login using "machinectl login" but that's another
>> story I believe.
>>
>> Any advice on how to debug this and make
>> systemd-nspawn@<containername> usable are highly appreciate!
>
> What happens if you run the same nspawn command from the command line?
> Does journald then start up correctly in it?
Yes, it works perfectly fine if I run it as
$ sudo /usr/bin/systemd-nspawn --keep-unit --boot
--directory=/var/lib/container/earlyannounce
I can login and see logs. Unfortunately no logs from the previous boot
are available (due to failed systemd-journald.service).
> What happens if you add "debug" to the end of the nspawn cmdline? Do
> you see anything interesting in the additional log output this
> generates?
Can't say for sure. Here is a diff between two logs (with whitespace
ignored) - first one is successful boot, second one is the failed boot
(using systemd service):
* https://paste.fedoraproject.org/156867/77223114/raw/
And here are actual boot logs:
* https://paste.fedoraproject.org/156862/17770249/ (from the service-file)
* https://paste.fedoraproject.org/156862/17770249/ (using the command
mentioned above)
--
With best regards, Peter Lemenkov.
More information about the systemd-devel
mailing list