openshift / openshift-sdn

Apache License 2.0
69 stars 63 forks source link

Detect SDN setup requirement when user switches between flat and multitenant plugins #181

Closed pravisankar closed 9 years ago

pravisankar commented 9 years ago

This will eliminate migration script.

pravisankar commented 9 years ago

@danwinship @dcbw PTAL

brenton commented 9 years ago

I apologize if this has been explained elsewhere but could someone describe the behavior admins should expect when switching between the flat and multitenant plugins? Specifically, what happens to projects that already exist before switching plugins? Are they automatically switched over or do they keep using their previous network?

danwinship commented 9 years ago

The first time you start the master with the multitenant plugin, it will assign a unique network ID to each project. So you'll go from fully-connected to fully-isolated.

https://github.com/openshift/origin/pull/5024 adds "oadm pod-network unisolate ...", which takes a --selector arg, so you could do oadm pod-network unisolate --selector=* (or whatever the actual syntax for selectors is) to flip things back.

brenton commented 9 years ago

Thanks @danwinship

pravisankar commented 9 years ago

Once admin user switches from flat sdn to multitenant sdn, all the existing projects will be full-isolated (just like a new project gets isolated when multitenant network plugin is used). Tuning the pod network of the projects can be done later by 'oadm pod-network'.

pravisankar commented 9 years ago

I'll update these details in the openshift-docs

sdodson commented 9 years ago

Thanks, we should detail what happens to running pods. They stay in the existing flat network until a node is restarted at which point the pods are restarted into their isolated networks?

pravisankar commented 9 years ago

@danwinship Updated, ptal

danwinship commented 9 years ago

oh, I thought we had agreed on IRC that you weren't going to change it? Whatever, either way is fine. lgtm

pravisankar commented 9 years ago

When switching from flat to multitenant plugin or vice versa, there is no issue with my change or the change you recommended. However, on a fresh install there won't be any br0 bridge and flat sdn setup won't get executed with my old change.