[CRIU] RFC: Add owner user namespace to tty_struct
Cyrill Gorcunov
gorcunov at gmail.com
Mon May 29 04:22:37 PDT 2017
On Mon, May 29, 2017 at 02:09:40PM +0300, Pavel Emelyanov wrote:
> On 05/29/2017 01:00 PM, Cyrill Gorcunov wrote:
> > On Mon, May 29, 2017 at 12:43:52PM +0300, Pavel Emelyanov wrote:
> >>>
> >>> Hi Matt! Currently we don't use fake input in criu so at moment it won't
> >>> affect us anyhow, but in longterm I expect more owner_user_ns testing may
> >>> appear. Thus we will need to know which owner tty belong to. I think we
> >>> may extend tty_fops and use show_fdinfo method to print owner_user_ns.
> >>
> >> We have similar problem with net_device:net pairing and with userns:<any other ns>
> >> one -- we need to know which object belongs to which. For the net_device:net case
> >> there has appeared a netdev ioctl, that results in an opened namespace file, just
> >> like if we did open("/proc/pid/ns/net"). I think the same API would be more convenient
> >> for tty:userns. All the more so there's already plenty of ioctls for ttys :)
> >
> > Mind to point which netdev ioctl it is?
>
> It's SIOCGSKNS. And I've made a mistake when told it was netdev->netns, it's
> socket->netns mapper. Still, it returns an open file :)
Look good. Yup we could have the same for ttys I think.
More information about the CRIU
mailing list