netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Siwei Liu <loseweigh@gmail.com>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
	Jiri Pirko <jiri@resnulli.us>,
	kys@microsoft.com, haiyangz@microsoft.com,
	David Miller <davem@davemloft.net>,
	"Samudrala, Sridhar" <sridhar.samudrala@intel.com>,
	Netdev <netdev@vger.kernel.org>,
	Stephen Hemminger <sthemmin@microsoft.com>
Subject: Re: [PATCH net] failover: eliminate callback hell
Date: Fri, 8 Jun 2018 16:44:12 -0700	[thread overview]
Message-ID: <CADGSJ20sq8AmW34Z7w0JrTg6=YnKaM3Hq5R3TfhAH5BkuR2pqA@mail.gmail.com> (raw)
In-Reply-To: <20180608161801.64afda65@xeon-e3>

On Fri, Jun 8, 2018 at 4:18 PM, Stephen Hemminger
<stephen@networkplumber.org> wrote:
> On Fri, 8 Jun 2018 15:25:59 -0700
> Siwei Liu <loseweigh@gmail.com> wrote:
>
>> On Wed, Jun 6, 2018 at 2:24 PM, Stephen Hemminger
>> <stephen@networkplumber.org> wrote:
>> > On Wed, 6 Jun 2018 15:30:27 +0300
>> > "Michael S. Tsirkin" <mst@redhat.com> wrote:
>> >
>> >> On Wed, Jun 06, 2018 at 09:25:12AM +0200, Jiri Pirko wrote:
>> >> > Tue, Jun 05, 2018 at 05:42:31AM CEST, stephen@networkplumber.org wrote:
>> >> > >The net failover should be a simple library, not a virtual
>> >> > >object with function callbacks (see callback hell).
>> >> >
>> >> > Why just a library? It should do a common things. I think it should be a
>> >> > virtual object. Looks like your patch again splits the common
>> >> > functionality into multiple drivers. That is kind of backwards attitude.
>> >> > I don't get it. We should rather focus on fixing the mess the
>> >> > introduction of netvsc-bonding caused and switch netvsc to 3-netdev
>> >> > model.
>> >>
>> >> So it seems that at least one benefit for netvsc would be better
>> >> handling of renames.
>> >>
>> >> Question is how can this change to 3-netdev happen?  Stephen is
>> >> concerned about risk of breaking some userspace.
>> >>
>> >> Stephen, this seems to be the usecase that IFF_HIDDEN was trying to
>> >> address, and you said then "why not use existing network namespaces
>> >> rather than inventing a new abstraction". So how about it then? Do you
>> >> want to find a way to use namespaces to hide the PV device for netvsc
>> >> compatibility?
>> >>
>> >
>> > Netvsc can't work with 3 dev model. MS has worked with enough distro's and
>> > startups that all demand eth0 always be present. And VF may come and go.
>> > After this history, there is a strong motivation not to change how kernel
>> > behaves. Switching to 3 device model would be perceived as breaking
>> > existing userspace.
>> >
>> > With virtio you can  work it out with the distro's yourself.
>> > There is no pre-existing semantics to deal with.
>> >
>> > For the virtio, I don't see the need for IFF_HIDDEN.
>>
>> I have a somewhat different view regarding IFF_HIDDEN. The purpose of
>> that flag, as well as the 1-netdev model, is to have a means to
>> inherit the interface name from the VF, and to eliminate playing hacks
>> around renaming devices, customizing udev rules and et al. Why
>> inheriting VF's name important? To allow existing config/setup around
>> VF continues to work across kernel feature upgrade. Most of network
>> config files in all distros are based on interface names. Few are MAC
>> address based but making lower slaves hidden would cover the rest. And
>> most importantly, preserving the same level of user experience as
>> using raw VF interface once getting all ndo_ops and ethtool_ops
>> exposed. This is essential to realize transparent live migration that
>> users dont have to learn and be aware of the undertaken.
>
> Inheriting the VF name will fail in the migration scenario.
> It is perfectly reasonable to migrate a guest to another machine where
> the VF PCI address is different. And since current udev/systemd model
> is to base network device name off of PCI address, the device will change
> name when guest is migrated.
>
The scenario of having VF on a different PCI address on post migration
is essentially equal to plugging in a new NIC. Why it has to pair with
the original PV? A sepearte PV device should be in place to pair the
new VF.


> On Azure, the VF maybe removed (by host) at any time and then later
> reattached. There is no guarantee that VF will show back up at
> the same synthetic PCI address. It will likely have a different
> PCI domain value.

This is something QEMU can do and make sure the PCI address is
consistent after migration.

-Siwei

  reply	other threads:[~2018-06-08 23:44 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-05  3:42 [PATCH net] failover: eliminate callback hell Stephen Hemminger
2018-06-05 17:22 ` Samudrala, Sridhar
2018-06-05 17:45   ` Stephen Hemminger
2018-06-05 18:14     ` David Miller
2018-06-05 18:35 ` Michael S. Tsirkin
2018-06-05 18:53   ` Stephen Hemminger
2018-06-05 19:38     ` Michael S. Tsirkin
2018-06-05 21:52       ` Stephen Hemminger
2018-06-05 23:52         ` Samudrala, Sridhar
2018-06-06  3:51           ` Stephen Hemminger
2018-06-06  5:39             ` Samudrala, Sridhar
2018-06-06  6:00               ` Stephen Hemminger
2018-06-06  6:11                 ` Samudrala, Sridhar
2018-06-06 21:16                   ` Stephen Hemminger
2018-06-06 21:30                     ` Michael S. Tsirkin
2018-06-06 22:21                       ` Stephen Hemminger
2018-06-11 18:07                         ` Michael S. Tsirkin
2018-06-06 12:19             ` Michael S. Tsirkin
2018-06-06 21:17               ` Stephen Hemminger
2018-06-06  7:25 ` Jiri Pirko
2018-06-06 12:30   ` Michael S. Tsirkin
2018-06-06 21:24     ` Stephen Hemminger
2018-06-06 21:47       ` Michael S. Tsirkin
2018-06-06 22:24         ` Stephen Hemminger
2018-06-07 14:57           ` Michael S. Tsirkin
2018-06-07 15:23             ` Stephen Hemminger
2018-06-06 21:54       ` Samudrala, Sridhar
2018-06-06 22:25         ` Stephen Hemminger
2018-06-07 14:17           ` Alexander Duyck
2018-06-07 14:51             ` Stephen Hemminger
2018-06-07 15:41               ` Michael S. Tsirkin
2018-06-07 16:17                 ` Stephen Hemminger
2018-06-07 17:22                   ` Michael S. Tsirkin
2018-06-08 18:30                     ` Stephen Hemminger
2018-06-08 19:04                       ` Michael S. Tsirkin
2018-06-08 22:54         ` Siwei Liu
2018-06-11 15:17           ` Stephen Hemminger
2018-06-08 22:25       ` Siwei Liu
2018-06-08 23:18         ` Stephen Hemminger
2018-06-08 23:44           ` Siwei Liu [this message]
2018-06-09  0:02             ` Stephen Hemminger
2018-06-09  0:42               ` Siwei Liu
2018-06-11 15:22                 ` Stephen Hemminger
2018-06-11 19:23                   ` Siwei Liu
2018-06-11 14:01               ` Michael S. Tsirkin
2018-06-09  1:29             ` Jakub Kicinski
2018-06-11 18:56               ` Siwei Liu
2018-06-12  2:14                 ` Michael S. Tsirkin
2018-06-06 21:26   ` Stephen Hemminger
2018-06-11 18:10 ` Michael S. Tsirkin
2018-06-11 19:34   ` Samudrala, Sridhar
2018-06-12  0:08     ` Samudrala, Sridhar

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='CADGSJ20sq8AmW34Z7w0JrTg6=YnKaM3Hq5R3TfhAH5BkuR2pqA@mail.gmail.com' \
    --to=loseweigh@gmail.com \
    --cc=davem@davemloft.net \
    --cc=haiyangz@microsoft.com \
    --cc=jiri@resnulli.us \
    --cc=kys@microsoft.com \
    --cc=mst@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=sridhar.samudrala@intel.com \
    --cc=stephen@networkplumber.org \
    --cc=sthemmin@microsoft.com \
    /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;
as well as URLs for NNTP newsgroup(s).