need phablet support for mods to /etc/lxc/lxc-usernet (vivid+stable ppa overaly)

Bug #1475751 reported by kevin gunn
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical System Image
Invalid
Medium
kevin gunn
lxc (Ubuntu)
Won't Fix
Wishlist
Stéphane Graber

Bug Description

we have a need for phablet to use a network inside a container, currently the /etc/lxc/lxc-usernet file is readonly
would need to be modified to contain something like
phablet veth lxcbr0 10

kevin gunn (kgunn72)
Changed in lxc (Ubuntu):
importance: Undecided → High
no longer affects: lxc
summary: - need phablet support for mods to /etc/lxc/lxc-usernet
+ need phablet support for mods to /etc/lxc/lxc-usernet (vivid+stable ppa
+ overaly)
Changed in canonical-devices-system-image:
importance: Undecided → High
Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

This seems like something the phablet packages should do in a postinst, right?

Or are you asking for the Ubuntu lxc package to add this to the default lxc-usernet file which is installed on all systems?

(Asking since this is marked as affecting lxc)

Revision history for this message
Christopher Townsend (townsend) wrote :

Hi Serge,

Well, the problem is that /etc/lxc/lxc-usernet is read-only, so it can't be modified by a user action. I'm not really sure how modifications of system files is supposed to take place in the New World.

I think for a short-term solution, we can take the Vivid lxc source package and modify it to add a static 'phablet' entry in /lxc-usernet and upload it to the overlay PPA.

Long term, I'm not so sure about...

Revision history for this message
Serge Hallyn (serge-hallyn) wrote : Re: [Bug 1475751] Re: need phablet support for mods to /etc/lxc/lxc-usernet (vivid+stable ppa overaly)

Quoting Christopher Townsend (<email address hidden>):
> Hi Serge,
>
> Well, the problem is that /etc/lxc/lxc-usernet is read-only, so it can't
> be modified by a user action. I'm not really sure how modifications of

Oh! I see, this is in snappy?

> system files is supposed to take place in the New World.

Yeah, me neither. Thanks for the clarification.

> I think for a short-term solution, we can take the Vivid lxc source
> package and modify it to add a static 'phablet' entry in /lxc-usernet
> and upload it to the overlay PPA.
>
> Long term, I'm not so sure about...

I'm sure there must be a "proper" way to do this sort of thing, let's
ask on #ubuntu-devel :)

thanks!

Revision history for this message
Pat McGowan (pat-mcgowan) wrote :

This is for pocket desktop support

Changed in canonical-devices-system-image:
assignee: nobody → kevin gunn (kgunn72)
milestone: none → ww46-2015
status: New → Confirmed
Revision history for this message
kevin gunn (kgunn72) wrote :

@serge - ok to put your name as you might be able to help us here ? ping me on irc if you need

Changed in lxc (Ubuntu):
assignee: nobody → Serge Hallyn (serge-hallyn)
Revision history for this message
kevin gunn (kgunn72) wrote :

chris pointed out that this isn't really needed for pd as we're using a custom chroot not lxc.
but leaving this open as we'll want this eventually.

Changed in canonical-devices-system-image:
importance: High → Medium
Changed in lxc (Ubuntu):
importance: High → Medium
Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

@kgunn72,

depends on what you need. I'm happy to answer any questions, but I don't think i know enough to drive this.

If all you really need is to have a phablet line in the lxc-usernet file as shipped in the package, then probably best for @stgraber to add it.

kevin gunn (kgunn72)
Changed in lxc (Ubuntu):
assignee: Serge Hallyn (serge-hallyn) → Stéphane Graber (stgraber)
Revision history for this message
Stéphane Graber (stgraber) wrote :

Having a special username hardcoded in there seems wrong to me.
Eventually we will want to do proper multi-user on those devices or allow users to rename the user at which point everything will break again.

What we may consider though is having LXC setup a new lxc-net group with a matching group entry in /etc/lxc/lxc-usernet so that any member of that group gets 10 veth in lxcbr0.

For that we'll need LXC 2.0 as I don't believe the lxc-usernet group support existed back in 1.1.

kevin gunn (kgunn72)
Changed in canonical-devices-system-image:
milestone: ww46-2015 → backlog
Revision history for this message
Christopher Townsend (townsend) wrote :

Hey Stéphane,

I agree that hardcoding the phablet user is not the best way to go about this. This is really only needed for The Future in which devices use a kernel that supports unprivileged containers. I think at this juncture, going about the way where members of a lxc-net group automatically get 10 veth devices is best.

Changed in lxc (Ubuntu):
status: New → Triaged
importance: Medium → Wishlist
Changed in lxc (Ubuntu):
status: Triaged → Won't Fix
Changed in canonical-devices-system-image:
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.