Linux Container Development
 help / color / mirror / Atom feed
From: ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org (Eric W. Biederman)
To: Gao feng <gaofeng-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
Cc: libvir-list-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
	Michal Privoznik
	<mprivozn-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
	containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org
Subject: Re: [libvirt] necessary to limit container's network bandwidth when use physical nic in container?
Date: Mon, 15 Oct 2012 19:33:33 -0700	[thread overview]
Message-ID: <87vcebb0xu.fsf@xmission.com> (raw)
In-Reply-To: <507CC3C3.7030306-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org> (Gao feng's message of "Tue, 16 Oct 2012 10:17:39 +0800")

Gao feng <gaofeng@cn.fujitsu.com> writes:

> 于 2012年10月15日 16:52, Michal Privoznik 写道:
>> On 15.10.2012 10:35, Gao feng wrote:
>>> we can use tc to limit container's network bandwidth when the container uses veth device.
>>> because one of the veth devices will be seen in the host.so we can set tc rules on this
>>> device on the host.
>>>
>>> I want to know if it's necessary to limit container's network bandwidth when the container
>>> uses a physical nic device. because this nic device is only used by this container.
>>>
>>> And if this is necessary,Be there any good idea?
>>>
>>> Thanks!
>>>
>> 
>> Well, that depends. If you expect you guest to consume all bandwidth
>> then you need to set a floor on root eth. Guest is then still able to
>> use the full bandwidth, however if there are some packets for the host
>> those get prioritized. In general, it's a good idea, but to tell for
>> sure one should learn more about your usage scenario.
>> 
>
> But we can't see container's nic device in host,how can we set a floor on
> container's root eth?

I can't see how any qos shaping of a physical nic directly assigned to a
container is useful.  You may want to limit the total cpu time assigned
to a container which should throttle your network connections.  But I
don't see what limiting the number of packets that go out an interface
will achieve.

Eric

_______________________________________________
Containers mailing list
Containers@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/containers

      parent reply	other threads:[~2012-10-16  2:33 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-15  8:05 necessary to limit container's network bandwidth when use physical nic in container? Gao feng
     [not found] ` <507BC3E0.6070304-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2012-10-15  8:35   ` Gao feng
     [not found]     ` <507BCAC3.4020609-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2012-10-15  8:52       ` [libvirt] " Michal Privoznik
     [not found]         ` <507BCED9.1080003-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2012-10-16  2:17           ` Gao feng
     [not found]             ` <507CC3C3.7030306-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2012-10-16  2:33               ` Eric W. Biederman [this message]

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=87vcebb0xu.fsf@xmission.com \
    --to=ebiederm-as9lmozglivwk0htik3j/w@public.gmane.org \
    --cc=containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=gaofeng-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org \
    --cc=libvir-list-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=mprivozn-H+wXaHxf7aLQT0dZR+AlfA@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox