Bug#824779: container getty-static.service causes lxcfs high cpu usage

Antonio Terceiro terceiro at debian.org
Mon Jul 18 16:17:49 BST 2016


On Sat, 16 Jul 2016 15:34:20 +0200 Martin Pitt <mpitt at debian.org> wrote:
> Control: tag -1 pending
> 
> Wang Jian [2016-05-19 23:59 +0800]:
> > getty-static.service starts getty on tty2-6, but container has only 4
> > ttys (1-4) at default. getty will exit and be respawned for tty5-tty6.
> > This leads to high cpu usage on host's lxcfs daemon.
> > 
> 
> There is no point in even wasting four getty processes on tty1-4 in
> LXC -- containers are not meant to have gettys on ttys in the first
> place. I committed a fix to git for that.
> (ConditionVirtualization=!container)

Historically, lxc users kind of expect gettys running in lxc containers.
When you spin up a lxc container in the background, you have two ways of
connecting to it with networking(SSH):

- lxc-attach will open a shell directly in the container
- lxc-console will attach to one of the ttys, where you get a login
  prompt.

lxc-attach is obviusly better, but I am sure lxc-console has its use
cases.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-systemd-maintainers/attachments/20160718/59c29ae6/attachment-0002.sig>


More information about the Pkg-systemd-maintainers mailing list