On 1/10/19 11:52 PM, Pierre-Elliott Bécue wrote: > Hi, > > Le jeudi 30 août 2018 à 09:58:31+0200, Alex Mestiashvili a écrit : >> Package: lxc >> Version: 1:2.0.9-6 >> Severity: normal >> >> >> Steps to reproduce: >> >> install lxc, create a container with debian template (backing store >> doesn't matter in this case) >> >> lxc-create -n deb2 -t debian -B zfs --zfsroot=ocz/lxc >> >> lxc-console -n deb2 -l trace -o console_deb2.lxc.log > > Why using -l, which tend to ruin the interface and hence compromise the > readability of the output?
Well, -l is for the logpriority, that's why it is there. Sorry if that was useless. > > On your paste I can't see a thing saying the console isn't working. > > I never met this issue myself, and I'm unable to reproduce it. > > As lxc moved to version 3, can you give it a try at some point and tell me > if you are still having this issue? > > Cheers > I just gave it another try. And I think I narrowed down the issue with the template. When attaching to a newly created debian container (lxc-create -t debian) with lxc-attach -n <container> I can see that there is only 1 console and no ttys are spawned: root@deb2:/etc# ps -ef | grep agetty root 73 1 0 09:42 console 00:00:00 /sbin/agetty --noclear --keep-baud console 115200,38400,9600 vt220 While in an ubuntu template there are 1 console and 4 pts: ps -ef | grep agetty root 102 1 0 08:58 pts/0 00:00:00 /sbin/agetty --noclear --keep-baud pts/0 115200 38400 9600 vt220 root 103 1 0 08:58 console 00:00:00 /sbin/agetty --noclear --keep-baud console 115200 38400 9600 vt220 root 104 1 0 08:58 pts/3 00:00:00 /sbin/agetty --noclear --keep-baud pts/3 115200 38400 9600 vt220 root 105 1 0 08:58 pts/1 00:00:00 /sbin/agetty --noclear --keep-baud pts/1 115200 38400 9600 vt220 root 106 1 0 08:58 pts/2 00:00:00 /sbin/agetty --noclear --keep-baud pts/2 115200 38400 9600 vt220 So my initial bug report wasn't exactly correct. One can get login prompt on container created with debian template, but only by calling lxc-console -n <container> -t 0 This "-t 0" is not obvious and I can imagine some people don't know about it. lxc and lxc-console are totally ok. It's the debian template with systemd which is by default have a not optimal setup. No idea how to fix that, spent some time, but lost in systemd crosslinked docs. Thanks! Alex