All of lore.kernel.org
 help / color / mirror / Atom feed
From: Libo Chen <clbchenlibo.chen-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
To: Serge Hallyn
	<serge.hallyn-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org>,
	containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org
Cc: hadi-fAAogVwAN2Kw5LPnMra/2Q@public.gmane.org,
	karma-sWkBwLop/e8RbODiWk9XIg@public.gmane.org,
	takano-ryousei-XSdjUN4cZ6fPDbFq/vQRIQ@public.gmane.org,
	caglar-mM0DFpta8ko@public.gmane.org,
	dlezcano-NmTC/0ZBporQT0dZR+AlfA@public.gmane.org,
	"zhangwei(Jovi)"
	<jovi.zhangwei-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>,
	stgraber-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org,
	james.hunt-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org
Subject: a work for lxc monitor network interface
Date: Wed, 18 Dec 2013 16:36:11 +0800	[thread overview]
Message-ID: <52B15E7B.8080009@huawei.com> (raw)

Hello LXC experts,

	lxc tool can set network interface by config, but it is static.
In some scene, the network interface will be dynamic created on the host
and need be shared to container, but it is not suitable to do by hand,
so lxc can not work for it.

	I also know lxc_user_nic() can only do a part of work, but we have
two more work:
1. grasp the netlink/uevent message about network interface online
2. config interface attached to container ip address .

so it can not fully meet my requirements.

	I want there is a monitor can work for network interface hotplug.

1. read config form config file, it describe monitor which network interface
   and what's the network configuration
2. grasp the netlink/uevent message about network interface online on the host
3. create veth pair, put veth attach to container and bridge
4. config the veth attached to container ipaddr

			
         	          netlink  create veth pair
monitor ---> read config  -------> veth0 attach to container --> config ipaddr
				   veth1 attach to bridge

monitor may be the lxc-start or a child forked by lxc-start.


 Is this reasonable?  If so, I'd like to do it.

             reply	other threads:[~2013-12-18  8:36 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-18  8:36 Libo Chen [this message]
     [not found] ` <52B15E7B.8080009-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2013-12-18 20:16   ` a work for lxc monitor network interface Serge Hallyn
2014-01-06  8:38     ` Libo Chen
     [not found]       ` <52CA6B69.1000402-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2014-01-06 16:55         ` Serge Hallyn
2014-01-09 12:29           ` Libo Chen
     [not found]             ` <52CE9620.9040108-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2014-01-22 14:17               ` Serge Hallyn
2014-01-23  1:59                 ` Libo Chen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52B15E7B.8080009@huawei.com \
    --to=clbchenlibo.chen-hv44wf8li93qt0dzr+alfa@public.gmane.org \
    --cc=caglar-mM0DFpta8ko@public.gmane.org \
    --cc=containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=dlezcano-NmTC/0ZBporQT0dZR+AlfA@public.gmane.org \
    --cc=hadi-fAAogVwAN2Kw5LPnMra/2Q@public.gmane.org \
    --cc=james.hunt-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org \
    --cc=jovi.zhangwei-hv44wF8Li93QT0dZR+AlfA@public.gmane.org \
    --cc=karma-sWkBwLop/e8RbODiWk9XIg@public.gmane.org \
    --cc=serge.hallyn-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org \
    --cc=stgraber-GeWIH/nMZzLQT0dZR+AlfA@public.gmane.org \
    --cc=takano-ryousei-XSdjUN4cZ6fPDbFq/vQRIQ@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.