[systemd-devel] Machinectl shell/login do not attach to console
arnaud gaboury
arnaud.gaboury at gmail.com
Sat Oct 17 11:06:50 PDT 2015
Honestly, I don't think your issue has to do with the container systemd version.
On my host, archlinux: systemd 227-1
On my container, Fedora 22: sysetemd 219
-------------------------------------
# machinectl login poppy
[sudo] password for gabx:
Connected to machine poppy. Press ^] three times within 1s to exit session.
Fedora release 22 (Twenty Two)
Kernel 4.2.2-1-hortensia on an x86_64 (pts/0)
poppy login:
----------------------------
It is working fine.
On Sat, Oct 17, 2015 at 11:09 AM, Lennart Poettering
<lennart at poettering.net> wrote:
> On Fri, 16.10.15 14:01, Chris Bell (cwbell at narmos.org) wrote:
>
>> On 2015-10-16 13:55, Chris Bell wrote:
>> >On 2015-10-14 15:58, Lennart Poettering wrote:
>> >>On Mon, 05.10.15 12:30, Chris Bell (cwbell at narmos.org) wrote:
>> >>
>> >>>Hi all,
>> >>>
>> >>>I have an Arch machine with systemd 226, running an Arch container,
>> >>>also
>> >>>with systemd 226. For whatever reason in 225, `machinectl login`
>> >>>stopped
>> >>>working correctly, and in 226 `machinectl login` does not work
>> >>>properly. It
>> >>>attaches to the machine, but does not seem to redirect stdin and
>> >>>stdout to
>> >>>the machine. When I attempt to use login, the login prompt is never
>> >>>printed
>> >>>to the command line:
>> >>
>> >>There were some races when machinectl was too fast and the systemd
>> >>inside the container too slow. This should be fixed in systemd git,
>> >>specifically commit 40e1f4ea7458a0a80eaf1ef356e52bfe0835412e and
>> >>related.
>> >
>> >I've recompiled from git, and the problem has, indeed, been solved! Thank
>> >you!
>>
>> Sorry, I was wrong. I was running 'machinectl shell' without a machine name,
>> and it spawned a shell for my host machine. Guest machine still cannot be
>> accessed with 'shell' or 'login' and stdin/out are still redirected to the
>> journal.
>>
>> I compiled commit 7a1e5abbc6e741e5b6995288c607522faa69c8b4 (Master) from the
>> github repo.
>
> You have to upgrade systemd, machined and nspawn in the container as
> well as on the host, and ensure you reexec all three of these
> components. Otherwise the fix has no effect.
>
> Lennart
>
> --
> Lennart Poettering, Red Hat
> _______________________________________________
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
google.com/+arnaudgabourygabx
More information about the systemd-devel
mailing list