[Devel] [RFC rh7 v2] ve/tty: vt -- Implement per VE support for virtual consoles

Cyrill Gorcunov gorcunov at virtuozzo.com
Fri Jul 31 04:57:36 PDT 2015


On Fri, Jul 31, 2015 at 01:53:19PM +0300, Vladimir Davydov wrote:
> > 
> > The distinguishing between VEs is happening on "opener" context,
> > ie join to VE cgroup, and open /dev/vztm1 the kernel calls
> > for get_exec_env and allocates appropriate vzt pair.
> 
> i.e. if I want to open a container's console as a slave I have to put
> myself into its ve cgroup first?

Exactly. On open the kernel will find that the global character
device associated with
 tty_fops
  tty_open
   tty_lookup_driver -> vtty_slave
   tty_driver_lookup_tty -> get_exec_env -> map for tty -> lookup for tty in array



More information about the Devel mailing list